]> git.ipfire.org Git - thirdparty/gcc.git/blame - configure
Remove --with-gmp-dir and --with-mpfr-dir
[thirdparty/gcc.git] / configure
CommitLineData
671aa708 1#! /bin/sh
671aa708 2# Guess values for system-dependent variables and create Makefiles.
22e05272
JM
3# Generated by GNU Autoconf 2.69.
4#
5#
6# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
5213506e 7#
671aa708
NN
8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
5213506e
RW
11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
1c710c3c 14
5213506e
RW
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 :
1c710c3c
DJ
18 emulate sh
19 NULLCMD=:
5213506e 20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
1c710c3c
DJ
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
5213506e
RW
23 setopt NO_GLOB_SUBST
24else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30esac
1c710c3c 31fi
1c710c3c 32
5213506e
RW
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 }
1c710c3c
DJ
79fi
80
81
5213506e
RW
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.
22e05272 90as_myself=
5213506e
RW
91case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94for as_dir in $PATH
95do
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100IFS=$as_save_IFS
101
102 ;;
103esac
104# We did not find ourselves, most probably we were run as `sh COMMAND'
105# in which case we are not to be found in the path.
106if test "x$as_myself" = x; then
107 as_myself=$0
108fi
109if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
112fi
113
114# Unset variables that we do not need and which cause bugs (e.g. in
115# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116# suppresses any "Segmentation fault" message there. '((' could
117# trigger a bug in pdksh 5.2.14.
118for as_var in BASH_ENV ENV MAIL MAILPATH
119do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121done
1c710c3c
DJ
122PS1='$ '
123PS2='> '
124PS4='+ '
125
126# NLS nuisances.
5213506e
RW
127LC_ALL=C
128export LC_ALL
129LANGUAGE=C
130export LANGUAGE
131
132# CDPATH.
133(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
22e05272
JM
135# Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140# neutralization value for shells without unset; and this also
141# works around shells that cannot unset nonexistent variables.
142# Preserve -v and -x to the replacement shell.
143BASH_ENV=/dev/null
144ENV=/dev/null
145(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151esac
152exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153# Admittedly, this is quite paranoid, since all the known shells bail
154# out after a failed `exec'.
155$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156as_fn_exit 255
157 fi
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
5213506e
RW
160if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
173 ;;
174esac
175fi
176"
177 as_required="as_fn_return () { (exit \$1); }
178as_fn_success () { as_fn_return 0; }
179as_fn_failure () { as_fn_return 1; }
180as_fn_ret_success () { return 0; }
181as_fn_ret_failure () { return 1; }
182
183exitcode=0
184as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190else
191 exitcode=1; echo positional parameters were not saved.
192fi
22e05272
JM
193test x\$exitcode = x0 || exit 1
194test -x / || exit 1"
5213506e
RW
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
87264276
PB
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199test \$(( 1 + 1 )) = 2 || exit 1"
5213506e
RW
200 if (eval "$as_required") 2>/dev/null; then :
201 as_have_required=yes
202else
203 as_have_required=no
204fi
205 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
206
207else
208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
209as_found=false
210for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
1c710c3c 211do
5213506e
RW
212 IFS=$as_save_IFS
213 test -z "$as_dir" && as_dir=.
214 as_found=:
215 case $as_dir in #(
216 /*)
217 for as_base in sh bash ksh sh5; do
218 # Try only shells that exist, to save several forks.
219 as_shell=$as_dir/$as_base
220 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
221 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
222 CONFIG_SHELL=$as_shell as_have_required=yes
223 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
224 break 2
225fi
226fi
227 done;;
228 esac
229 as_found=false
230done
231$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
233 CONFIG_SHELL=$SHELL as_have_required=yes
234fi; }
235IFS=$as_save_IFS
236
237
238 if test "x$CONFIG_SHELL" != x; then :
22e05272
JM
239 export CONFIG_SHELL
240 # We cannot yet assume a decent shell, so we have to provide a
241# neutralization value for shells without unset; and this also
242# works around shells that cannot unset nonexistent variables.
243# Preserve -v and -x to the replacement shell.
244BASH_ENV=/dev/null
245ENV=/dev/null
246(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247case $- in # ((((
248 *v*x* | *x*v* ) as_opts=-vx ;;
249 *v* ) as_opts=-v ;;
250 *x* ) as_opts=-x ;;
251 * ) as_opts= ;;
252esac
253exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254# Admittedly, this is quite paranoid, since all the known shells bail
255# out after a failed `exec'.
256$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
257exit 255
5213506e
RW
258fi
259
260 if test x$as_have_required = xno; then :
261 $as_echo "$0: This script requires a shell more modern than all"
262 $as_echo "$0: the shells that I found on your system."
263 if test x${ZSH_VERSION+set} = xset ; then
264 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
265 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
1c710c3c 266 else
5213506e
RW
267 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
268$0: including any error possibly output before this
269$0: message. Then install a modern shell, or manually run
270$0: the script under such a shell if you do have one."
1c710c3c 271 fi
5213506e
RW
272 exit 1
273fi
274fi
275fi
276SHELL=${CONFIG_SHELL-/bin/sh}
277export SHELL
278# Unset more variables known to interfere with behavior of common tools.
279CLICOLOR_FORCE= GREP_OPTIONS=
280unset CLICOLOR_FORCE GREP_OPTIONS
281
282## --------------------- ##
283## M4sh Shell Functions. ##
284## --------------------- ##
285# as_fn_unset VAR
286# ---------------
287# Portably unset VAR.
288as_fn_unset ()
289{
290 { eval $1=; unset $1;}
291}
292as_unset=as_fn_unset
293
294# as_fn_set_status STATUS
295# -----------------------
296# Set $? to STATUS, without forking.
297as_fn_set_status ()
298{
299 return $1
300} # as_fn_set_status
1c710c3c 301
5213506e
RW
302# as_fn_exit STATUS
303# -----------------
304# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
305as_fn_exit ()
306{
307 set +e
308 as_fn_set_status $1
309 exit $1
310} # as_fn_exit
311
312# as_fn_mkdir_p
313# -------------
314# Create "$as_dir" as a directory, including parents if necessary.
315as_fn_mkdir_p ()
316{
317
318 case $as_dir in #(
319 -*) as_dir=./$as_dir;;
320 esac
321 test -d "$as_dir" || eval $as_mkdir_p || {
322 as_dirs=
323 while :; do
324 case $as_dir in #(
325 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
326 *) as_qdir=$as_dir;;
327 esac
328 as_dirs="'$as_qdir' $as_dirs"
329 as_dir=`$as_dirname -- "$as_dir" ||
330$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
331 X"$as_dir" : 'X\(//\)[^/]' \| \
332 X"$as_dir" : 'X\(//\)$' \| \
333 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
334$as_echo X"$as_dir" |
335 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
336 s//\1/
337 q
338 }
339 /^X\(\/\/\)[^/].*/{
340 s//\1/
341 q
342 }
343 /^X\(\/\/\)$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\).*/{
348 s//\1/
349 q
350 }
351 s/.*/./; q'`
352 test -d "$as_dir" && break
353 done
354 test -z "$as_dirs" || eval "mkdir $as_dirs"
22e05272 355 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
5213506e
RW
356
357
358} # as_fn_mkdir_p
22e05272
JM
359
360# as_fn_executable_p FILE
361# -----------------------
362# Test if FILE is an executable regular file.
363as_fn_executable_p ()
364{
365 test -f "$1" && test -x "$1"
366} # as_fn_executable_p
5213506e
RW
367# as_fn_append VAR VALUE
368# ----------------------
369# Append the text in VALUE to the end of the definition contained in VAR. Take
370# advantage of any shell optimizations that allow amortized linear growth over
371# repeated appends, instead of the typical quadratic growth present in naive
372# implementations.
373if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
374 eval 'as_fn_append ()
375 {
376 eval $1+=\$2
377 }'
378else
379 as_fn_append ()
380 {
381 eval $1=\$$1\$2
382 }
383fi # as_fn_append
384
385# as_fn_arith ARG...
386# ------------------
387# Perform arithmetic evaluation on the ARGs, and store the result in the
388# global $as_val. Take advantage of shells that can avoid forks. The arguments
389# must be portable across $(()) and expr.
390if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
391 eval 'as_fn_arith ()
392 {
393 as_val=$(( $* ))
394 }'
395else
396 as_fn_arith ()
397 {
398 as_val=`expr "$@" || test $? -eq 1`
399 }
400fi # as_fn_arith
401
402
22e05272
JM
403# as_fn_error STATUS ERROR [LINENO LOG_FD]
404# ----------------------------------------
5213506e
RW
405# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
406# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
22e05272 407# script with STATUS, using 1 if that was 0.
5213506e
RW
408as_fn_error ()
409{
22e05272
JM
410 as_status=$1; test $as_status -eq 0 && as_status=1
411 if test "$4"; then
412 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
413 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
5213506e 414 fi
22e05272 415 $as_echo "$as_me: error: $2" >&2
5213506e
RW
416 as_fn_exit $as_status
417} # as_fn_error
418
419if expr a : '\(a\)' >/dev/null 2>&1 &&
420 test "X`expr 00001 : '.*\(...\)'`" = X001; then
1c710c3c
DJ
421 as_expr=expr
422else
423 as_expr=false
424fi
425
5213506e 426if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
1c710c3c
DJ
427 as_basename=basename
428else
429 as_basename=false
430fi
431
5213506e
RW
432if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
433 as_dirname=dirname
434else
435 as_dirname=false
436fi
1c710c3c 437
5213506e 438as_me=`$as_basename -- "$0" ||
1c710c3c
DJ
439$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
440 X"$0" : 'X\(//\)$' \| \
5213506e
RW
441 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
442$as_echo X/"$0" |
443 sed '/^.*\/\([^/][^/]*\)\/*$/{
444 s//\1/
445 q
446 }
447 /^X\/\(\/\/\)$/{
448 s//\1/
449 q
450 }
451 /^X\/\(\/\).*/{
452 s//\1/
453 q
454 }
455 s/.*/./; q'`
1c710c3c 456
2aeb72e9
DD
457# Avoid depending upon Character Ranges.
458as_cr_letters='abcdefghijklmnopqrstuvwxyz'
459as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
460as_cr_Letters=$as_cr_letters$as_cr_LETTERS
461as_cr_digits='0123456789'
462as_cr_alnum=$as_cr_Letters$as_cr_digits
11a67599 463
1c710c3c 464
5213506e
RW
465 as_lineno_1=$LINENO as_lineno_1a=$LINENO
466 as_lineno_2=$LINENO as_lineno_2a=$LINENO
467 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
468 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
469 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
470 sed -n '
471 p
472 /[$]LINENO/=
473 ' <$as_myself |
1c710c3c 474 sed '
5213506e
RW
475 s/[$]LINENO.*/&-/
476 t lineno
477 b
478 :lineno
1c710c3c 479 N
5213506e
RW
480 :loop
481 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
1c710c3c 482 t loop
5213506e 483 s/-\n.*//
1c710c3c 484 ' >$as_me.lineno &&
5213506e
RW
485 chmod +x "$as_me.lineno" ||
486 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
1c710c3c 487
22e05272
JM
488 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
489 # already done that, so ensure we don't try to do so again and fall
490 # in an infinite loop. This has already happened in practice.
491 _as_can_reexec=no; export _as_can_reexec
1c710c3c
DJ
492 # Don't try to exec as it changes $[0], causing all sort of problems
493 # (the dirname of $[0] is not the place where we might find the
5213506e
RW
494 # original and so on. Autoconf is especially sensitive to this).
495 . "./$as_me.lineno"
1c710c3c
DJ
496 # Exit status is that of the last command.
497 exit
498}
499
5213506e
RW
500ECHO_C= ECHO_N= ECHO_T=
501case `echo -n x` in #(((((
502-n*)
503 case `echo 'xy\c'` in
504 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
505 xy) ECHO_C='\c';;
506 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
507 ECHO_T=' ';;
508 esac;;
509*)
510 ECHO_N='-n';;
1c710c3c
DJ
511esac
512
5213506e
RW
513rm -f conf$$ conf$$.exe conf$$.file
514if test -d conf$$.dir; then
515 rm -f conf$$.dir/conf$$.file
1c710c3c 516else
5213506e
RW
517 rm -f conf$$.dir
518 mkdir conf$$.dir 2>/dev/null
1c710c3c 519fi
5213506e
RW
520if (echo >conf$$.file) 2>/dev/null; then
521 if ln -s conf$$.file conf$$ 2>/dev/null; then
2aeb72e9 522 as_ln_s='ln -s'
5213506e
RW
523 # ... but there are two gotchas:
524 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
22e05272 526 # In both cases, we have to default to `cp -pR'.
5213506e 527 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
22e05272 528 as_ln_s='cp -pR'
5213506e
RW
529 elif ln conf$$.file conf$$ 2>/dev/null; then
530 as_ln_s=ln
531 else
22e05272 532 as_ln_s='cp -pR'
2aeb72e9 533 fi
1c710c3c 534else
22e05272 535 as_ln_s='cp -pR'
1c710c3c 536fi
5213506e
RW
537rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538rmdir conf$$.dir 2>/dev/null
1c710c3c
DJ
539
540if mkdir -p . 2>/dev/null; then
5213506e 541 as_mkdir_p='mkdir -p "$as_dir"'
1c710c3c
DJ
542else
543 test -d ./-p && rmdir ./-p
544 as_mkdir_p=false
545fi
546
22e05272
JM
547as_test_x='test -x'
548as_executable_p=as_fn_executable_p
0b0dc272 549
1c710c3c
DJ
550# Sed expression to map a string onto a valid CPP name.
551as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
552
553# Sed expression to map a string onto a valid variable name.
554as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
555
556
22e05272
JM
557test -n "$DJDIR" || exec 7<&0 </dev/null
558exec 6>&1
1c710c3c
DJ
559
560# Name of the host.
22e05272 561# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
1c710c3c
DJ
562# so uname gets run too.
563ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
564
1c710c3c
DJ
565#
566# Initializations.
567#
671aa708 568ac_default_prefix=/usr/local
5213506e 569ac_clean_files=
1c710c3c 570ac_config_libobj_dir=.
5213506e 571LIBOBJS=
1c710c3c
DJ
572cross_compiling=no
573subdirs=
574MFLAGS=
575MAKEFLAGS=
2aeb72e9 576
1c710c3c
DJ
577# Identity of this package.
578PACKAGE_NAME=
579PACKAGE_TARNAME=
580PACKAGE_VERSION=
581PACKAGE_STRING=
582PACKAGE_BUGREPORT=
5213506e 583PACKAGE_URL=
1c710c3c
DJ
584
585ac_unique_file="move-if-change"
5213506e
RW
586enable_option_checking=no
587ac_subst_vars='LTLIBOBJS
588LIBOBJS
589compare_exclusions
590stage2_werror_flag
591stage1_checking
592stage1_cflags
593MAINT
594MAINTAINER_MODE_FALSE
595MAINTAINER_MODE_TRUE
596COMPILER_NM_FOR_TARGET
597COMPILER_LD_FOR_TARGET
598COMPILER_AS_FOR_TARGET
599FLAGS_FOR_TARGET
600RAW_CXX_FOR_TARGET
601WINDMC_FOR_TARGET
602WINDRES_FOR_TARGET
603STRIP_FOR_TARGET
e7a82751 604READELF_FOR_TARGET
5213506e 605RANLIB_FOR_TARGET
e4a9a572 606OTOOL_FOR_TARGET
5213506e 607OBJDUMP_FOR_TARGET
9bccfdf5 608OBJCOPY_FOR_TARGET
5213506e
RW
609NM_FOR_TARGET
610LIPO_FOR_TARGET
611LD_FOR_TARGET
3b5e8ee4 612DSYMUTIL_FOR_TARGET
5213506e
RW
613DLLTOOL_FOR_TARGET
614AS_FOR_TARGET
615AR_FOR_TARGET
b4c522fa 616GDC_FOR_TARGET
632e2a07 617GOC_FOR_TARGET
5213506e 618GFORTRAN_FOR_TARGET
5213506e
RW
619GCC_FOR_TARGET
620CXX_FOR_TARGET
621CC_FOR_TARGET
5fee5ec3 622GDCFLAGS
e7a82751 623READELF
e4a9a572 624OTOOL
5213506e
RW
625OBJDUMP
626OBJCOPY
627WINDMC
628WINDRES
629STRIP
630RANLIB
631NM
632LIPO
633LD
3b5e8ee4 634DSYMUTIL
5213506e
RW
635DLLTOOL
636AS
637AR
638RUNTEST
639EXPECT
640MAKEINFO
641FLEX
642LEX
643M4
644BISON
645YACC
5213506e
RW
646WINDRES_FOR_BUILD
647WINDMC_FOR_BUILD
648RANLIB_FOR_BUILD
649NM_FOR_BUILD
650LD_FOR_BUILD
651LDFLAGS_FOR_BUILD
b4c522fa 652GDC_FOR_BUILD
632e2a07 653GOC_FOR_BUILD
5213506e 654GFORTRAN_FOR_BUILD
3b5e8ee4 655DSYMUTIL_FOR_BUILD
5213506e
RW
656DLLTOOL_FOR_BUILD
657CXX_FOR_BUILD
658CXXFLAGS_FOR_BUILD
84401ce5
RP
659CPPFLAGS_FOR_BUILD
660CPP_FOR_BUILD
5213506e
RW
661CFLAGS_FOR_BUILD
662CC_FOR_BUILD
663AS_FOR_BUILD
664AR_FOR_BUILD
aae29963 665target_configdirs
5213506e 666configdirs
5213506e 667build_configdirs
5213506e
RW
668INSTALL_GDB_TK
669GDB_TK
670CONFIGURE_GDB_TK
671build_tooldir
672tooldir
673GCC_SHLIB_SUBDIR
674RPATH_ENVVAR
ffedf511
RW
675target_configargs
676host_configargs
677build_configargs
e12c4094 678BUILD_CONFIG
6f57bdf6 679LDFLAGS_FOR_TARGET
5213506e
RW
680CXXFLAGS_FOR_TARGET
681CFLAGS_FOR_TARGET
682DEBUG_PREFIX_CFLAGS_FOR_TARGET
683SYSROOT_CFLAGS_FOR_TARGET
3c36aa6b 684get_gcc_base_ver
1c01ebf6 685extra_host_zlib_configure_flags
d7f09764 686extra_host_libiberty_configure_flags
fca38047 687stage1_languages
cdfee50a 688host_shared
45b3824d
TS
689extra_linker_plugin_flags
690extra_linker_plugin_configure_flags
33ad93b9 691islinc
eae1a5d4 692isllibs
5213506e 693poststage1_ldflags
ed2eaa9f 694poststage1_libs
5213506e 695stage1_ldflags
0b21f5d3 696stage1_libs
0ff2d841 697extra_isl_gmp_configure_flags
5213506e
RW
698extra_mpc_mpfr_configure_flags
699extra_mpc_gmp_configure_flags
700extra_mpfr_configure_flags
701gmpinc
702gmplibs
4a5e71f2
L
703PGO_BUILD_LTO_CFLAGS
704PGO_BUILD_USE_CFLAGS
705PGO_BUILD_GEN_CFLAGS
7ffcf5d6 706HAVE_CXX11_FOR_BUILD
ffac9597 707HAVE_CXX11
5213506e 708do_compare
5fee5ec3 709GDC
5213506e
RW
710GNATMAKE
711GNATBIND
712ac_ct_CXX
713CXXFLAGS
714CXX
715OBJEXT
716EXEEXT
717ac_ct_CC
718CPPFLAGS
719LDFLAGS
720CFLAGS
721CC
5f520819 722extra_liboffloadmic_configure_flags
5213506e
RW
723target_subdir
724host_subdir
725build_subdir
726build_libsubdir
87264276
PB
727AWK
728SED
5213506e
RW
729LN_S
730LN
731INSTALL_DATA
732INSTALL_SCRIPT
733INSTALL_PROGRAM
734target_os
735target_vendor
736target_cpu
737target
738host_os
739host_vendor
740host_cpu
741host
742target_noncanonical
743host_noncanonical
744build_noncanonical
745build_os
746build_vendor
747build_cpu
748build
749TOPLEVEL_CONFIGURE_ARGUMENTS
750target_alias
751host_alias
752build_alias
753LIBS
754ECHO_T
755ECHO_N
756ECHO_C
757DEFS
758mandir
759localedir
760libdir
761psdir
762pdfdir
763dvidir
764htmldir
765infodir
766docdir
767oldincludedir
768includedir
769localstatedir
770sharedstatedir
771sysconfdir
772datadir
773datarootdir
774libexecdir
775sbindir
776bindir
777program_transform_name
778prefix
779exec_prefix
780PACKAGE_URL
781PACKAGE_BUGREPORT
782PACKAGE_STRING
783PACKAGE_VERSION
784PACKAGE_TARNAME
785PACKAGE_NAME
786PATH_SEPARATOR
787SHELL'
788ac_subst_files='serialization_dependencies
789host_makefile_frag
790target_makefile_frag
791alphaieee_frag
792ospace_frag'
793ac_user_opts='
794enable_option_checking
795with_build_libsubdir
a05c2c75 796with_system_zlib
85c64bbe
BS
797enable_as_accelerator_for
798enable_offload_targets
fe5bfa67 799enable_offload_defaulted
5213506e 800enable_gold
21539e2e 801enable_ld
78edb32f 802enable_compressed_debug_sections
87e6d9dc
TB
803enable_libquadmath
804enable_libquadmath_support
5213506e
RW
805enable_libada
806enable_libssp
1873ec0c 807enable_libstdcxx
5f520819 808enable_liboffloadmic
ff3ac0f4 809enable_bootstrap
4a5e71f2 810enable_pgo_build
5213506e
RW
811with_mpc
812with_mpc_include
813with_mpc_lib
5213506e
RW
814with_mpfr
815with_mpfr_include
816with_mpfr_lib
5213506e
RW
817with_gmp
818with_gmp_include
819with_gmp_lib
5213506e 820with_stage1_libs
aac9103b 821with_static_standard_libraries
0b21f5d3 822with_stage1_ldflags
5213506e 823with_boot_libs
ed2eaa9f 824with_boot_ldflags
33ad93b9
RG
825with_isl
826with_isl_include
827with_isl_lib
828enable_isl_version_check
d7f09764 829enable_lto
45b3824d
TS
830enable_linker_plugin_configure_flags
831enable_linker_plugin_flags
cdfee50a 832enable_host_shared
5213506e 833enable_stage1_languages
43c40f3e 834enable_objc_gc
114bf3f1
MK
835with_target_bdw_gc
836with_target_bdw_gc_include
837with_target_bdw_gc_lib
3c36aa6b 838with_gcc_major_version_only
5213506e
RW
839with_build_sysroot
840with_debug_prefix_map
5646b7b9 841with_build_config
beeda1d9 842enable_vtable_verify
5213506e
RW
843enable_serial_configure
844with_build_time_tools
845enable_maintainer_mode
846enable_stage1_checking
847enable_werror
5213506e
RW
848'
849 ac_precious_vars='build_alias
850host_alias
851target_alias
852CC
853CFLAGS
854LDFLAGS
855LIBS
856CPPFLAGS
857CXX
858CXXFLAGS
859CCC
ffedf511
RW
860build_configargs
861host_configargs
862target_configargs
5213506e
RW
863AR
864AS
865DLLTOOL
3b5e8ee4 866DSYMUTIL
5213506e
RW
867LD
868LIPO
869NM
870RANLIB
871STRIP
872WINDRES
873WINDMC
874OBJCOPY
875OBJDUMP
e4a9a572 876OTOOL
e7a82751 877READELF
5213506e
RW
878CC_FOR_TARGET
879CXX_FOR_TARGET
880GCC_FOR_TARGET
5213506e 881GFORTRAN_FOR_TARGET
632e2a07 882GOC_FOR_TARGET
b4c522fa 883GDC_FOR_TARGET
5213506e
RW
884AR_FOR_TARGET
885AS_FOR_TARGET
886DLLTOOL_FOR_TARGET
3b5e8ee4 887DSYMUTIL_FOR_TARGET
5213506e
RW
888LD_FOR_TARGET
889LIPO_FOR_TARGET
890NM_FOR_TARGET
9bccfdf5 891OBJCOPY_FOR_TARGET
5213506e 892OBJDUMP_FOR_TARGET
e4a9a572 893OTOOL_FOR_TARGET
5213506e 894RANLIB_FOR_TARGET
e7a82751 895READELF_FOR_TARGET
5213506e
RW
896STRIP_FOR_TARGET
897WINDRES_FOR_TARGET
898WINDMC_FOR_TARGET'
899
671aa708
NN
900
901# Initialize some variables set by options.
1c710c3c
DJ
902ac_init_help=
903ac_init_version=false
5213506e
RW
904ac_unrecognized_opts=
905ac_unrecognized_sep=
671aa708
NN
906# The variables have the same names as the options, with
907# dashes changed to underlines.
1c710c3c 908cache_file=/dev/null
671aa708 909exec_prefix=NONE
671aa708 910no_create=
671aa708
NN
911no_recursion=
912prefix=NONE
913program_prefix=NONE
914program_suffix=NONE
915program_transform_name=s,x,x,
916silent=
917site=
918srcdir=
671aa708
NN
919verbose=
920x_includes=NONE
921x_libraries=NONE
1c710c3c
DJ
922
923# Installation directory options.
924# These are left unexpanded so users can "make install exec_prefix=/foo"
925# and all the variables that are supposed to be based on exec_prefix
926# by default will actually change.
927# Use braces instead of parens because sh, perl, etc. also accept them.
5213506e 928# (The list follows the same order as the GNU Coding Standards.)
671aa708
NN
929bindir='${exec_prefix}/bin'
930sbindir='${exec_prefix}/sbin'
931libexecdir='${exec_prefix}/libexec'
5213506e
RW
932datarootdir='${prefix}/share'
933datadir='${datarootdir}'
671aa708
NN
934sysconfdir='${prefix}/etc'
935sharedstatedir='${prefix}/com'
936localstatedir='${prefix}/var'
671aa708
NN
937includedir='${prefix}/include'
938oldincludedir='/usr/include'
5213506e
RW
939docdir='${datarootdir}/doc/${PACKAGE}'
940infodir='${datarootdir}/info'
941htmldir='${docdir}'
942dvidir='${docdir}'
943pdfdir='${docdir}'
944psdir='${docdir}'
945libdir='${exec_prefix}/lib'
946localedir='${datarootdir}/locale'
947mandir='${datarootdir}/man'
79c06341 948
671aa708 949ac_prev=
5213506e 950ac_dashdash=
671aa708
NN
951for ac_option
952do
671aa708
NN
953 # If the previous option needs an argument, assign it.
954 if test -n "$ac_prev"; then
5213506e 955 eval $ac_prev=\$ac_option
671aa708
NN
956 ac_prev=
957 continue
958 fi
79c06341 959
5213506e 960 case $ac_option in
22e05272
JM
961 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
962 *=) ac_optarg= ;;
963 *) ac_optarg=yes ;;
5213506e 964 esac
671aa708
NN
965
966 # Accept the important Cygnus configure options, so we can diagnose typos.
967
5213506e
RW
968 case $ac_dashdash$ac_option in
969 --)
970 ac_dashdash=yes ;;
671aa708
NN
971
972 -bindir | --bindir | --bindi | --bind | --bin | --bi)
973 ac_prev=bindir ;;
974 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1c710c3c 975 bindir=$ac_optarg ;;
671aa708
NN
976
977 -build | --build | --buil | --bui | --bu)
1c710c3c 978 ac_prev=build_alias ;;
671aa708 979 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1c710c3c 980 build_alias=$ac_optarg ;;
671aa708
NN
981
982 -cache-file | --cache-file | --cache-fil | --cache-fi \
983 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
984 ac_prev=cache_file ;;
985 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
986 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1c710c3c
DJ
987 cache_file=$ac_optarg ;;
988
989 --config-cache | -C)
990 cache_file=config.cache ;;
671aa708 991
5213506e 992 -datadir | --datadir | --datadi | --datad)
671aa708 993 ac_prev=datadir ;;
5213506e 994 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1c710c3c 995 datadir=$ac_optarg ;;
671aa708 996
5213506e
RW
997 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
998 | --dataroo | --dataro | --datar)
999 ac_prev=datarootdir ;;
1000 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1001 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1002 datarootdir=$ac_optarg ;;
1003
671aa708 1004 -disable-* | --disable-*)
5213506e 1005 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
671aa708 1006 # Reject names that are not valid shell variable names.
5213506e 1007 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1008 as_fn_error $? "invalid feature name: $ac_useropt"
5213506e
RW
1009 ac_useropt_orig=$ac_useropt
1010 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1011 case $ac_user_opts in
1012 *"
1013"enable_$ac_useropt"
1014"*) ;;
1015 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1016 ac_unrecognized_sep=', ';;
1017 esac
1018 eval enable_$ac_useropt=no ;;
1019
1020 -docdir | --docdir | --docdi | --doc | --do)
1021 ac_prev=docdir ;;
1022 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1023 docdir=$ac_optarg ;;
1024
1025 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1026 ac_prev=dvidir ;;
1027 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1028 dvidir=$ac_optarg ;;
671aa708
NN
1029
1030 -enable-* | --enable-*)
5213506e 1031 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
671aa708 1032 # Reject names that are not valid shell variable names.
5213506e 1033 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1034 as_fn_error $? "invalid feature name: $ac_useropt"
5213506e
RW
1035 ac_useropt_orig=$ac_useropt
1036 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1037 case $ac_user_opts in
1038 *"
1039"enable_$ac_useropt"
1040"*) ;;
1041 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1042 ac_unrecognized_sep=', ';;
2aeb72e9 1043 esac
5213506e 1044 eval enable_$ac_useropt=\$ac_optarg ;;
671aa708
NN
1045
1046 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1047 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1048 | --exec | --exe | --ex)
1049 ac_prev=exec_prefix ;;
1050 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1051 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1052 | --exec=* | --exe=* | --ex=*)
1c710c3c 1053 exec_prefix=$ac_optarg ;;
671aa708
NN
1054
1055 -gas | --gas | --ga | --g)
1056 # Obsolete; use --with-gas.
1057 with_gas=yes ;;
1058
1c710c3c
DJ
1059 -help | --help | --hel | --he | -h)
1060 ac_init_help=long ;;
1061 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1062 ac_init_help=recursive ;;
1063 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1064 ac_init_help=short ;;
671aa708
NN
1065
1066 -host | --host | --hos | --ho)
1c710c3c 1067 ac_prev=host_alias ;;
671aa708 1068 -host=* | --host=* | --hos=* | --ho=*)
1c710c3c 1069 host_alias=$ac_optarg ;;
671aa708 1070
5213506e
RW
1071 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1072 ac_prev=htmldir ;;
1073 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1074 | --ht=*)
1075 htmldir=$ac_optarg ;;
1076
671aa708
NN
1077 -includedir | --includedir | --includedi | --included | --include \
1078 | --includ | --inclu | --incl | --inc)
1079 ac_prev=includedir ;;
1080 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1081 | --includ=* | --inclu=* | --incl=* | --inc=*)
1c710c3c 1082 includedir=$ac_optarg ;;
671aa708
NN
1083
1084 -infodir | --infodir | --infodi | --infod | --info | --inf)
1085 ac_prev=infodir ;;
1086 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1c710c3c 1087 infodir=$ac_optarg ;;
671aa708
NN
1088
1089 -libdir | --libdir | --libdi | --libd)
1090 ac_prev=libdir ;;
1091 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1c710c3c 1092 libdir=$ac_optarg ;;
671aa708
NN
1093
1094 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1095 | --libexe | --libex | --libe)
1096 ac_prev=libexecdir ;;
1097 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1098 | --libexe=* | --libex=* | --libe=*)
1c710c3c 1099 libexecdir=$ac_optarg ;;
671aa708 1100
5213506e
RW
1101 -localedir | --localedir | --localedi | --localed | --locale)
1102 ac_prev=localedir ;;
1103 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1104 localedir=$ac_optarg ;;
1105
671aa708 1106 -localstatedir | --localstatedir | --localstatedi | --localstated \
5213506e 1107 | --localstate | --localstat | --localsta | --localst | --locals)
671aa708
NN
1108 ac_prev=localstatedir ;;
1109 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
5213506e 1110 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1c710c3c 1111 localstatedir=$ac_optarg ;;
671aa708
NN
1112
1113 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1114 ac_prev=mandir ;;
1115 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1c710c3c 1116 mandir=$ac_optarg ;;
671aa708
NN
1117
1118 -nfp | --nfp | --nf)
1119 # Obsolete; use --without-fp.
1120 with_fp=no ;;
1121
1122 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1c710c3c 1123 | --no-cr | --no-c | -n)
671aa708
NN
1124 no_create=yes ;;
1125
1126 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1127 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1128 no_recursion=yes ;;
1129
1130 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1131 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1132 | --oldin | --oldi | --old | --ol | --o)
1133 ac_prev=oldincludedir ;;
1134 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1135 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1136 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1c710c3c 1137 oldincludedir=$ac_optarg ;;
671aa708
NN
1138
1139 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1140 ac_prev=prefix ;;
1141 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1c710c3c 1142 prefix=$ac_optarg ;;
671aa708
NN
1143
1144 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1145 | --program-pre | --program-pr | --program-p)
1146 ac_prev=program_prefix ;;
1147 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1148 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1c710c3c 1149 program_prefix=$ac_optarg ;;
671aa708
NN
1150
1151 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1152 | --program-suf | --program-su | --program-s)
1153 ac_prev=program_suffix ;;
1154 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1155 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1c710c3c 1156 program_suffix=$ac_optarg ;;
671aa708
NN
1157
1158 -program-transform-name | --program-transform-name \
1159 | --program-transform-nam | --program-transform-na \
1160 | --program-transform-n | --program-transform- \
1161 | --program-transform | --program-transfor \
1162 | --program-transfo | --program-transf \
1163 | --program-trans | --program-tran \
1164 | --progr-tra | --program-tr | --program-t)
1165 ac_prev=program_transform_name ;;
1166 -program-transform-name=* | --program-transform-name=* \
1167 | --program-transform-nam=* | --program-transform-na=* \
1168 | --program-transform-n=* | --program-transform-=* \
1169 | --program-transform=* | --program-transfor=* \
1170 | --program-transfo=* | --program-transf=* \
1171 | --program-trans=* | --program-tran=* \
1172 | --progr-tra=* | --program-tr=* | --program-t=*)
1c710c3c 1173 program_transform_name=$ac_optarg ;;
671aa708 1174
5213506e
RW
1175 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1176 ac_prev=pdfdir ;;
1177 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1178 pdfdir=$ac_optarg ;;
1179
1180 -psdir | --psdir | --psdi | --psd | --ps)
1181 ac_prev=psdir ;;
1182 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1183 psdir=$ac_optarg ;;
1184
671aa708
NN
1185 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1186 | -silent | --silent | --silen | --sile | --sil)
1187 silent=yes ;;
1188
1189 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1190 ac_prev=sbindir ;;
1191 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1192 | --sbi=* | --sb=*)
1c710c3c 1193 sbindir=$ac_optarg ;;
671aa708
NN
1194
1195 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1196 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1197 | --sharedst | --shareds | --shared | --share | --shar \
1198 | --sha | --sh)
1199 ac_prev=sharedstatedir ;;
1200 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1201 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1202 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1203 | --sha=* | --sh=*)
1c710c3c 1204 sharedstatedir=$ac_optarg ;;
671aa708
NN
1205
1206 -site | --site | --sit)
1207 ac_prev=site ;;
1208 -site=* | --site=* | --sit=*)
1c710c3c 1209 site=$ac_optarg ;;
671aa708
NN
1210
1211 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1212 ac_prev=srcdir ;;
1213 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1c710c3c 1214 srcdir=$ac_optarg ;;
671aa708
NN
1215
1216 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1217 | --syscon | --sysco | --sysc | --sys | --sy)
1218 ac_prev=sysconfdir ;;
1219 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1220 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1c710c3c 1221 sysconfdir=$ac_optarg ;;
671aa708
NN
1222
1223 -target | --target | --targe | --targ | --tar | --ta | --t)
1c710c3c 1224 ac_prev=target_alias ;;
671aa708 1225 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1c710c3c 1226 target_alias=$ac_optarg ;;
671aa708
NN
1227
1228 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1229 verbose=yes ;;
1230
1c710c3c
DJ
1231 -version | --version | --versio | --versi | --vers | -V)
1232 ac_init_version=: ;;
671aa708
NN
1233
1234 -with-* | --with-*)
5213506e 1235 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
671aa708 1236 # Reject names that are not valid shell variable names.
5213506e 1237 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1238 as_fn_error $? "invalid package name: $ac_useropt"
5213506e
RW
1239 ac_useropt_orig=$ac_useropt
1240 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1241 case $ac_user_opts in
1242 *"
1243"with_$ac_useropt"
1244"*) ;;
1245 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1246 ac_unrecognized_sep=', ';;
2aeb72e9 1247 esac
5213506e 1248 eval with_$ac_useropt=\$ac_optarg ;;
671aa708
NN
1249
1250 -without-* | --without-*)
5213506e 1251 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
671aa708 1252 # Reject names that are not valid shell variable names.
5213506e 1253 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1254 as_fn_error $? "invalid package name: $ac_useropt"
5213506e
RW
1255 ac_useropt_orig=$ac_useropt
1256 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1257 case $ac_user_opts in
1258 *"
1259"with_$ac_useropt"
1260"*) ;;
1261 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1262 ac_unrecognized_sep=', ';;
1263 esac
1264 eval with_$ac_useropt=no ;;
671aa708
NN
1265
1266 --x)
1267 # Obsolete; use --with-x.
1268 with_x=yes ;;
1269
1270 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1271 | --x-incl | --x-inc | --x-in | --x-i)
1272 ac_prev=x_includes ;;
1273 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1274 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1c710c3c 1275 x_includes=$ac_optarg ;;
671aa708
NN
1276
1277 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1278 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1279 ac_prev=x_libraries ;;
1280 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1281 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1c710c3c 1282 x_libraries=$ac_optarg ;;
671aa708 1283
22e05272
JM
1284 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1285Try \`$0 --help' for more information"
671aa708
NN
1286 ;;
1287
1c710c3c
DJ
1288 *=*)
1289 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1290 # Reject names that are not valid shell variable names.
5213506e
RW
1291 case $ac_envvar in #(
1292 '' | [0-9]* | *[!_$as_cr_alnum]* )
22e05272 1293 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
5213506e
RW
1294 esac
1295 eval $ac_envvar=\$ac_optarg
1c710c3c
DJ
1296 export $ac_envvar ;;
1297
671aa708 1298 *)
1c710c3c 1299 # FIXME: should be removed in autoconf 3.0.
5213506e 1300 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1c710c3c 1301 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
5213506e 1302 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
22e05272 1303 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
671aa708
NN
1304 ;;
1305
1306 esac
1307done
1308
1309if test -n "$ac_prev"; then
1c710c3c 1310 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
22e05272 1311 as_fn_error $? "missing argument to $ac_option"
af71363e 1312fi
af71363e 1313
5213506e
RW
1314if test -n "$ac_unrecognized_opts"; then
1315 case $enable_option_checking in
1316 no) ;;
22e05272 1317 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
5213506e 1318 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2aeb72e9 1319 esac
5213506e 1320fi
2aeb72e9 1321
5213506e
RW
1322# Check all directory arguments for consistency.
1323for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1324 datadir sysconfdir sharedstatedir localstatedir includedir \
1325 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1326 libdir localedir mandir
2aeb72e9 1327do
5213506e
RW
1328 eval ac_val=\$$ac_var
1329 # Remove trailing slashes.
1330 case $ac_val in
1331 */ )
1332 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1333 eval $ac_var=\$ac_val;;
1334 esac
1335 # Be sure to have absolute directory names.
2aeb72e9 1336 case $ac_val in
5213506e
RW
1337 [\\/$]* | ?:[\\/]* ) continue;;
1338 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
671aa708 1339 esac
22e05272 1340 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
671aa708
NN
1341done
1342
1c710c3c
DJ
1343# There might be people who depend on the old broken behavior: `$host'
1344# used to hold the argument of --host etc.
1345# FIXME: To remove some day.
1346build=$build_alias
1347host=$host_alias
1348target=$target_alias
0b0dc272 1349
1c710c3c
DJ
1350# FIXME: To remove some day.
1351if test "x$host_alias" != x; then
1352 if test "x$build_alias" = x; then
1353 cross_compiling=maybe
1c710c3c
DJ
1354 elif test "x$build_alias" != "x$host_alias"; then
1355 cross_compiling=yes
1356 fi
1357fi
1358
1359ac_tool_prefix=
1360test -n "$host_alias" && ac_tool_prefix=$host_alias-
1361
1362test "$silent" = yes && exec 6>/dev/null
671aa708 1363
671aa708 1364
5213506e
RW
1365ac_pwd=`pwd` && test -n "$ac_pwd" &&
1366ac_ls_di=`ls -di .` &&
1367ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
22e05272 1368 as_fn_error $? "working directory cannot be determined"
5213506e 1369test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
22e05272 1370 as_fn_error $? "pwd does not report name of working directory"
5213506e
RW
1371
1372
671aa708
NN
1373# Find the source files, if location was not specified.
1374if test -z "$srcdir"; then
1375 ac_srcdir_defaulted=yes
5213506e
RW
1376 # Try the directory containing this script, then the parent directory.
1377 ac_confdir=`$as_dirname -- "$as_myself" ||
1378$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1379 X"$as_myself" : 'X\(//\)[^/]' \| \
1380 X"$as_myself" : 'X\(//\)$' \| \
1381 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1382$as_echo X"$as_myself" |
1383 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1384 s//\1/
1385 q
1386 }
1387 /^X\(\/\/\)[^/].*/{
1388 s//\1/
1389 q
1390 }
1391 /^X\(\/\/\)$/{
1392 s//\1/
1393 q
1394 }
1395 /^X\(\/\).*/{
1396 s//\1/
1397 q
1398 }
1399 s/.*/./; q'`
671aa708 1400 srcdir=$ac_confdir
5213506e 1401 if test ! -r "$srcdir/$ac_unique_file"; then
671aa708
NN
1402 srcdir=..
1403 fi
1404else
1405 ac_srcdir_defaulted=no
1406fi
5213506e
RW
1407if test ! -r "$srcdir/$ac_unique_file"; then
1408 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
22e05272 1409 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
5213506e
RW
1410fi
1411ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1412ac_abs_confdir=`(
22e05272 1413 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
5213506e
RW
1414 pwd)`
1415# When building in place, set srcdir=.
1416if test "$ac_abs_confdir" = "$ac_pwd"; then
1417 srcdir=.
1418fi
1419# Remove unnecessary trailing slashes from srcdir.
1420# Double slashes in file names in object file debugging info
1421# mess up M-x gdb in Emacs.
1422case $srcdir in
1423*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1424esac
87841584
AM
1425case $srcdir in
1426 *" "*)
22e05272 1427 as_fn_error $? "path to source, $srcdir, contains spaces"
87841584
AM
1428 ;;
1429esac
ac9e6043
RW
1430ac_subdirs_all=`cd $srcdir && echo */configure | sed 's,/configure,,g'`
1431
5213506e
RW
1432for ac_var in $ac_precious_vars; do
1433 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1434 eval ac_env_${ac_var}_value=\$${ac_var}
1435 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1436 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1437done
1c710c3c
DJ
1438
1439#
1440# Report the --help message.
1441#
1442if test "$ac_init_help" = "long"; then
1443 # Omit some internal or obsolete options to make the list less imposing.
1444 # This message is too long to be a string in the A/UX 3.1 sh.
1445 cat <<_ACEOF
1446\`configure' configures this package to adapt to many kinds of systems.
1447
1448Usage: $0 [OPTION]... [VAR=VALUE]...
1449
1450To assign environment variables (e.g., CC, CFLAGS...), specify them as
1451VAR=VALUE. See below for descriptions of some of the useful variables.
1452
1453Defaults for the options are specified in brackets.
1454
1455Configuration:
1456 -h, --help display this help and exit
1457 --help=short display options specific to this package
1458 --help=recursive display the short help of all the included packages
1459 -V, --version display version information and exit
22e05272 1460 -q, --quiet, --silent do not print \`checking ...' messages
1c710c3c
DJ
1461 --cache-file=FILE cache test results in FILE [disabled]
1462 -C, --config-cache alias for \`--cache-file=config.cache'
1463 -n, --no-create do not create output files
1464 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1465
1c710c3c
DJ
1466Installation directories:
1467 --prefix=PREFIX install architecture-independent files in PREFIX
5213506e 1468 [$ac_default_prefix]
1c710c3c 1469 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
5213506e 1470 [PREFIX]
1c710c3c
DJ
1471
1472By default, \`make install' will install all the files in
1473\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1474an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1475for instance \`--prefix=\$HOME'.
1476
1477For better control, use the options below.
1478
1479Fine tuning of the installation directories:
5213506e
RW
1480 --bindir=DIR user executables [EPREFIX/bin]
1481 --sbindir=DIR system admin executables [EPREFIX/sbin]
1482 --libexecdir=DIR program executables [EPREFIX/libexec]
1483 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1484 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1485 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1486 --libdir=DIR object code libraries [EPREFIX/lib]
1487 --includedir=DIR C header files [PREFIX/include]
1488 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1489 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1490 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1491 --infodir=DIR info documentation [DATAROOTDIR/info]
1492 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1493 --mandir=DIR man documentation [DATAROOTDIR/man]
1494 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1495 --htmldir=DIR html documentation [DOCDIR]
1496 --dvidir=DIR dvi documentation [DOCDIR]
1497 --pdfdir=DIR pdf documentation [DOCDIR]
1498 --psdir=DIR ps documentation [DOCDIR]
1c710c3c
DJ
1499_ACEOF
1500
1501 cat <<\_ACEOF
1502
1503Program names:
1504 --program-prefix=PREFIX prepend PREFIX to installed program names
1505 --program-suffix=SUFFIX append SUFFIX to installed program names
1506 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1507
1508System types:
1509 --build=BUILD configure for building on BUILD [guessed]
1510 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1511 --target=TARGET configure for building compilers for TARGET [HOST]
1512_ACEOF
1513fi
1514
1515if test -n "$ac_init_help"; then
1516
1517 cat <<\_ACEOF
1518
1519Optional Features:
5213506e 1520 --disable-option-checking ignore unrecognized --enable/--with options
1c710c3c
DJ
1521 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1522 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
85c64bbe
BS
1523 --enable-as-accelerator-for=ARG
1524 build as offload target compiler. Specify offload
1525 host triple by ARG
1526 --enable-offload-targets=LIST
1527 enable offloading to devices from comma-separated
1528 LIST of TARGET[=DIR]. Use optional path to find
1529 offload target compiler during the build
fe5bfa67
TB
1530 --enable-offload-defaulted
1531 If enabled, configured but not installed offload compilers and
1532 libgomp plugins are silently ignored. Useful for distribution
1533 compilers where those are in separate optional packages.
1534
21539e2e 1535 --enable-gold[=ARG] build gold [ARG={default,yes,no}]
33e39b66 1536 --enable-ld[=ARG] build ld [ARG={default,yes,no}]
324402a0 1537 --enable-compressed-debug-sections={all,gas,gold,ld,none}
78edb32f
L
1538 Enable compressed debug sections for gas, gold or ld
1539 by default
87e6d9dc
TB
1540 --disable-libquadmath do not build libquadmath directory
1541 --disable-libquadmath-support
1542 disable libquadmath support for Fortran
30b74385
RW
1543 --enable-libada build libada directory
1544 --enable-libssp build libssp directory
1873ec0c 1545 --disable-libstdcxx do not build libstdc++-v3 directory
5f520819
KY
1546 --enable-liboffloadmic=ARG
1547 build liboffloadmic [ARG={no,host,target}]
ff3ac0f4 1548 --enable-bootstrap enable bootstrapping [yes if native build]
4a5e71f2
L
1549 --enable-pgo-build[=lto]
1550 enable the PGO build
33ad93b9 1551 --disable-isl-version-check
560d18d3 1552 disable check for isl version
d7f09764 1553 --enable-lto enable link time optimization support
45b3824d
TS
1554 --enable-linker-plugin-configure-flags=FLAGS
1555 additional flags for configuring linker plugins
1556 [none]
1557 --enable-linker-plugin-flags=FLAGS
1558 additional flags for configuring and building linker
1559 plugins [none]
cdfee50a 1560 --enable-host-shared build host code as shared libraries
33e39b66
AS
1561 --enable-stage1-languages[=all]
1562 choose additional languages to build during stage1.
1563 Mostly useful for compiler development
43c40f3e
RO
1564 --enable-objc-gc enable use of Boehm's garbage collector with the GNU
1565 Objective-C runtime
318a4e6d 1566 --enable-vtable-verify Enable vtable verification feature
30b74385 1567 --enable-serial-[{host,target,build}-]configure
33e39b66
AS
1568 force sequential configuration of sub-packages for
1569 the host, target or build machine, or all
1570 sub-packages
1571 --enable-maintainer-mode
1572 enable make rules and dependencies not useful (and
1573 sometimes confusing) to the casual installer
1574 --enable-stage1-checking[=all]
1575 choose additional checking for stage1 of the
1576 compiler
1c710c3c
DJ
1577 --enable-werror enable -Werror in bootstrap stage2 and later
1578
1579Optional Packages:
1580 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1581 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1582 --with-build-libsubdir=DIR Directory where to find libraries for build system
a05c2c75 1583 --with-system-zlib use installed libz
33e39b66
AS
1584 --with-mpc=PATH specify prefix directory for installed MPC package.
1585 Equivalent to --with-mpc-include=PATH/include plus
1586 --with-mpc-lib=PATH/lib
1587 --with-mpc-include=PATH specify directory for installed MPC include files
1588 --with-mpc-lib=PATH specify directory for the installed MPC library
30b74385 1589 --with-mpfr=PATH specify prefix directory for installed MPFR package.
33e39b66
AS
1590 Equivalent to --with-mpfr-include=PATH/include plus
1591 --with-mpfr-lib=PATH/lib
1c710c3c 1592 --with-mpfr-include=PATH
30b74385
RW
1593 specify directory for installed MPFR include files
1594 --with-mpfr-lib=PATH specify directory for the installed MPFR library
33e39b66
AS
1595 --with-gmp=PATH specify prefix directory for the installed GMP
1596 package. Equivalent to
1597 --with-gmp-include=PATH/include plus
1598 --with-gmp-lib=PATH/lib
30b74385
RW
1599 --with-gmp-include=PATH specify directory for installed GMP include files
1600 --with-gmp-lib=PATH specify directory for the installed GMP library
0b21f5d3 1601 --with-stage1-libs=LIBS libraries for stage1
aac9103b
TT
1602 --with-static-standard-libraries
1603 use -static-libstdc++ and -static-libgcc
1604 (default=auto)
33e39b66
AS
1605 --with-stage1-ldflags=FLAGS
1606 linker flags for stage1
33e39b66
AS
1607 --with-boot-libs=LIBS libraries for stage2 and later
1608 --with-boot-ldflags=FLAGS
1609 linker flags for stage2 and later
e357a5e0 1610 --with-isl=PATH Specify prefix directory for the installed isl
33e39b66 1611 package. Equivalent to
33ad93b9
RG
1612 --with-isl-include=PATH/include plus
1613 --with-isl-lib=PATH/lib
560d18d3
AK
1614 --with-isl-include=PATH Specify directory for installed isl include files
1615 --with-isl-lib=PATH Specify the directory for the installed isl library
114bf3f1
MK
1616 --with-target-bdw-gc=PATHLIST
1617 specify prefix directory for installed bdw-gc
1618 package. Equivalent to
1619 --with-target-bdw-gc-include=PATH/include plus
1620 --with-target-bdw-gc-lib=PATH/lib
1621 --with-target-bdw-gc-include=PATHLIST
1622 specify directories for installed bdw-gc include
1623 files
1624 --with-target-bdw-gc-lib=PATHLIST
1625 specify directories for installed bdw-gc library
3c36aa6b
JJ
1626 --with-gcc-major-version-only
1627 use only GCC major number in filesystem paths
30b74385 1628 --with-build-sysroot=SYSROOT
1c710c3c 1629 use sysroot as the system root during the build
c8aea42c 1630 --with-debug-prefix-map='A=B C=D ...'
33e39b66
AS
1631 map A to B, C to D ... in debug information
1632 --with-build-config='NAME NAME2...'
1633 use config/NAME.mk build configuration
30b74385 1634 --with-build-time-tools=PATH
1c710c3c 1635 use given path to find target tools during the build
1c710c3c
DJ
1636
1637Some influential environment variables:
1638 CC C compiler command
1639 CFLAGS C compiler flags
1640 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1641 nonstandard directory <lib dir>
5213506e 1642 LIBS libraries to pass to the linker, e.g. -l<library>
22e05272 1643 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
5213506e 1644 you have headers in a nonstandard directory <include dir>
c3a86da9
DJ
1645 CXX C++ compiler command
1646 CXXFLAGS C++ compiler flags
ffedf511
RW
1647 build_configargs
1648 additional configure arguments for build directories
1649 host_configargs
1650 additional configure arguments for host directories
1651 target_configargs
1652 additional configure arguments for target directories
278a7a38
AO
1653 AR AR for the host
1654 AS AS for the host
1655 DLLTOOL DLLTOOL for the host
3b5e8ee4 1656 DSYMUTIL DSYMUTIL for the host
278a7a38
AO
1657 LD LD for the host
1658 LIPO LIPO for the host
1659 NM NM for the host
1660 RANLIB RANLIB for the host
1661 STRIP STRIP for the host
1662 WINDRES WINDRES for the host
901119ae 1663 WINDMC WINDMC for the host
278a7a38
AO
1664 OBJCOPY OBJCOPY for the host
1665 OBJDUMP OBJDUMP for the host
e4a9a572 1666 OTOOL OTOOL for the host
e7a82751 1667 READELF READELF for the host
278a7a38
AO
1668 CC_FOR_TARGET
1669 CC for the target
1670 CXX_FOR_TARGET
1671 CXX for the target
1672 GCC_FOR_TARGET
1673 GCC for the target
278a7a38
AO
1674 GFORTRAN_FOR_TARGET
1675 GFORTRAN for the target
632e2a07
ILT
1676 GOC_FOR_TARGET
1677 GOC for the target
b4c522fa
IB
1678 GDC_FOR_TARGET
1679 GDC for the target
278a7a38
AO
1680 AR_FOR_TARGET
1681 AR for the target
1682 AS_FOR_TARGET
1683 AS for the target
1684 DLLTOOL_FOR_TARGET
1685 DLLTOOL for the target
3b5e8ee4
IS
1686 DSYMUTIL_FOR_TARGET
1687 DSYMUTIL for the target
278a7a38
AO
1688 LD_FOR_TARGET
1689 LD for the target
1690 LIPO_FOR_TARGET
1691 LIPO for the target
1692 NM_FOR_TARGET
1693 NM for the target
9bccfdf5
AP
1694 OBJCOPY_FOR_TARGET
1695 OBJCOPY for the target
278a7a38
AO
1696 OBJDUMP_FOR_TARGET
1697 OBJDUMP for the target
e4a9a572
IS
1698 OTOOL_FOR_TARGET
1699 OTOOL for the target
278a7a38
AO
1700 RANLIB_FOR_TARGET
1701 RANLIB for the target
e7a82751
RM
1702 READELF_FOR_TARGET
1703 READELF for the target
278a7a38
AO
1704 STRIP_FOR_TARGET
1705 STRIP for the target
1706 WINDRES_FOR_TARGET
1707 WINDRES for the target
901119ae
KT
1708 WINDMC_FOR_TARGET
1709 WINDMC for the target
1c710c3c
DJ
1710
1711Use these variables to override the choices made by `configure' or to help
1712it to find libraries and programs with nonstandard names/locations.
1713
5213506e 1714Report bugs to the package provider.
1c710c3c 1715_ACEOF
5213506e 1716ac_status=$?
1c710c3c
DJ
1717fi
1718
1719if test "$ac_init_help" = "recursive"; then
1720 # If there are subdirs, report their specific --help.
1c710c3c 1721 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
5213506e
RW
1722 test -d "$ac_dir" ||
1723 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1724 continue
1c710c3c
DJ
1725 ac_builddir=.
1726
5213506e
RW
1727case "$ac_dir" in
1728.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1729*)
1730 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1731 # A ".." for each directory in $ac_dir_suffix.
1732 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1733 case $ac_top_builddir_sub in
1734 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1735 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1736 esac ;;
1737esac
1738ac_abs_top_builddir=$ac_pwd
1739ac_abs_builddir=$ac_pwd$ac_dir_suffix
1740# for backward compatibility:
1741ac_top_builddir=$ac_top_build_prefix
1c710c3c
DJ
1742
1743case $srcdir in
5213506e 1744 .) # We are building in place.
1c710c3c 1745 ac_srcdir=.
5213506e
RW
1746 ac_top_srcdir=$ac_top_builddir_sub
1747 ac_abs_top_srcdir=$ac_pwd ;;
1748 [\\/]* | ?:[\\/]* ) # Absolute name.
1c710c3c 1749 ac_srcdir=$srcdir$ac_dir_suffix;
5213506e
RW
1750 ac_top_srcdir=$srcdir
1751 ac_abs_top_srcdir=$srcdir ;;
1752 *) # Relative name.
1753 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1754 ac_top_srcdir=$ac_top_build_prefix$srcdir
1755 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2aeb72e9 1756esac
5213506e
RW
1757ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1758
1759 cd "$ac_dir" || { ac_status=$?; continue; }
1760 # Check for guested configure.
1761 if test -f "$ac_srcdir/configure.gnu"; then
1762 echo &&
1763 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1764 elif test -f "$ac_srcdir/configure"; then
1765 echo &&
1766 $SHELL "$ac_srcdir/configure" --help=recursive
1c710c3c 1767 else
5213506e
RW
1768 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1769 fi || ac_status=$?
1770 cd "$ac_pwd" || { ac_status=$?; break; }
1c710c3c
DJ
1771 done
1772fi
1773
5213506e 1774test -n "$ac_init_help" && exit $ac_status
1c710c3c
DJ
1775if $ac_init_version; then
1776 cat <<\_ACEOF
5213506e 1777configure
22e05272 1778generated by GNU Autoconf 2.69
1c710c3c 1779
22e05272 1780Copyright (C) 2012 Free Software Foundation, Inc.
1c710c3c
DJ
1781This configure script is free software; the Free Software Foundation
1782gives unlimited permission to copy, distribute and modify it.
1783_ACEOF
5213506e 1784 exit
0b0dc272 1785fi
5213506e
RW
1786
1787## ------------------------ ##
1788## Autoconf initialization. ##
1789## ------------------------ ##
1790
1791# ac_fn_c_try_compile LINENO
1792# --------------------------
1793# Try to compile conftest.$ac_ext, and return whether this succeeded.
1794ac_fn_c_try_compile ()
1795{
1796 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1797 rm -f conftest.$ac_objext
1798 if { { ac_try="$ac_compile"
1799case "(($ac_try" in
1800 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1801 *) ac_try_echo=$ac_try;;
1802esac
1803eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1804$as_echo "$ac_try_echo"; } >&5
1805 (eval "$ac_compile") 2>conftest.err
1806 ac_status=$?
1807 if test -s conftest.err; then
1808 grep -v '^ *+' conftest.err >conftest.er1
1809 cat conftest.er1 >&5
1810 mv -f conftest.er1 conftest.err
1811 fi
1812 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1813 test $ac_status = 0; } && {
1814 test -z "$ac_c_werror_flag" ||
1815 test ! -s conftest.err
1816 } && test -s conftest.$ac_objext; then :
1817 ac_retval=0
1818else
1819 $as_echo "$as_me: failed program was:" >&5
1820sed 's/^/| /' conftest.$ac_ext >&5
1821
1822 ac_retval=1
1823fi
22e05272
JM
1824 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1825 as_fn_set_status $ac_retval
5213506e
RW
1826
1827} # ac_fn_c_try_compile
1828
1829# ac_fn_cxx_try_compile LINENO
1830# ----------------------------
1831# Try to compile conftest.$ac_ext, and return whether this succeeded.
1832ac_fn_cxx_try_compile ()
1833{
1834 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1835 rm -f conftest.$ac_objext
1836 if { { ac_try="$ac_compile"
1837case "(($ac_try" in
1838 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1839 *) ac_try_echo=$ac_try;;
1840esac
1841eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1842$as_echo "$ac_try_echo"; } >&5
1843 (eval "$ac_compile") 2>conftest.err
1844 ac_status=$?
1845 if test -s conftest.err; then
1846 grep -v '^ *+' conftest.err >conftest.er1
1847 cat conftest.er1 >&5
1848 mv -f conftest.er1 conftest.err
1849 fi
1850 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1851 test $ac_status = 0; } && {
1852 test -z "$ac_cxx_werror_flag" ||
1853 test ! -s conftest.err
1854 } && test -s conftest.$ac_objext; then :
1855 ac_retval=0
1856else
1857 $as_echo "$as_me: failed program was:" >&5
1858sed 's/^/| /' conftest.$ac_ext >&5
1859
1860 ac_retval=1
1861fi
22e05272
JM
1862 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1863 as_fn_set_status $ac_retval
5213506e
RW
1864
1865} # ac_fn_cxx_try_compile
1866
0b21f5d3
EB
1867# ac_fn_cxx_try_link LINENO
1868# -------------------------
1869# Try to link conftest.$ac_ext, and return whether this succeeded.
1870ac_fn_cxx_try_link ()
1871{
1872 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1873 rm -f conftest.$ac_objext conftest$ac_exeext
1874 if { { ac_try="$ac_link"
1875case "(($ac_try" in
1876 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1877 *) ac_try_echo=$ac_try;;
1878esac
1879eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1880$as_echo "$ac_try_echo"; } >&5
1881 (eval "$ac_link") 2>conftest.err
1882 ac_status=$?
1883 if test -s conftest.err; then
1884 grep -v '^ *+' conftest.err >conftest.er1
1885 cat conftest.er1 >&5
1886 mv -f conftest.er1 conftest.err
1887 fi
1888 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1889 test $ac_status = 0; } && {
1890 test -z "$ac_cxx_werror_flag" ||
1891 test ! -s conftest.err
1892 } && test -s conftest$ac_exeext && {
1893 test "$cross_compiling" = yes ||
22e05272 1894 test -x conftest$ac_exeext
0b21f5d3
EB
1895 }; then :
1896 ac_retval=0
1897else
1898 $as_echo "$as_me: failed program was:" >&5
1899sed 's/^/| /' conftest.$ac_ext >&5
1900
1901 ac_retval=1
1902fi
1903 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1904 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1905 # interfere with the next link command; also delete a directory that is
1906 # left behind by Apple's compiler. We do this before executing the actions.
1907 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
22e05272
JM
1908 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1909 as_fn_set_status $ac_retval
0b21f5d3
EB
1910
1911} # ac_fn_cxx_try_link
1912
5213506e
RW
1913# ac_fn_c_try_link LINENO
1914# -----------------------
1915# Try to link conftest.$ac_ext, and return whether this succeeded.
1916ac_fn_c_try_link ()
1917{
1918 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1919 rm -f conftest.$ac_objext conftest$ac_exeext
1920 if { { ac_try="$ac_link"
1921case "(($ac_try" in
1922 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1923 *) ac_try_echo=$ac_try;;
1924esac
1925eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1926$as_echo "$ac_try_echo"; } >&5
1927 (eval "$ac_link") 2>conftest.err
1928 ac_status=$?
1929 if test -s conftest.err; then
1930 grep -v '^ *+' conftest.err >conftest.er1
1931 cat conftest.er1 >&5
1932 mv -f conftest.er1 conftest.err
1933 fi
1934 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1935 test $ac_status = 0; } && {
1936 test -z "$ac_c_werror_flag" ||
1937 test ! -s conftest.err
1938 } && test -s conftest$ac_exeext && {
1939 test "$cross_compiling" = yes ||
22e05272 1940 test -x conftest$ac_exeext
5213506e
RW
1941 }; then :
1942 ac_retval=0
1943else
1944 $as_echo "$as_me: failed program was:" >&5
1945sed 's/^/| /' conftest.$ac_ext >&5
1946
1947 ac_retval=1
1948fi
1949 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1950 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1951 # interfere with the next link command; also delete a directory that is
1952 # left behind by Apple's compiler. We do this before executing the actions.
1953 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
22e05272
JM
1954 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1955 as_fn_set_status $ac_retval
5213506e
RW
1956
1957} # ac_fn_c_try_link
1958cat >config.log <<_ACEOF
1c710c3c
DJ
1959This file contains any messages produced by compilers while
1960running configure, to aid debugging if configure makes a mistake.
1961
1962It was created by $as_me, which was
22e05272 1963generated by GNU Autoconf 2.69. Invocation command line was
1c710c3c
DJ
1964
1965 $ $0 $@
1966
1967_ACEOF
5213506e 1968exec 5>>config.log
1c710c3c
DJ
1969{
1970cat <<_ASUNAME
1971## --------- ##
1972## Platform. ##
1973## --------- ##
1974
1975hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1976uname -m = `(uname -m) 2>/dev/null || echo unknown`
1977uname -r = `(uname -r) 2>/dev/null || echo unknown`
1978uname -s = `(uname -s) 2>/dev/null || echo unknown`
1979uname -v = `(uname -v) 2>/dev/null || echo unknown`
1980
1981/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1982/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1983
1984/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1985/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1986/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
5213506e 1987/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
1c710c3c
DJ
1988/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1989/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1990/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1991
1992_ASUNAME
1993
1994as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1995for as_dir in $PATH
1996do
1997 IFS=$as_save_IFS
1998 test -z "$as_dir" && as_dir=.
5213506e
RW
1999 $as_echo "PATH: $as_dir"
2000 done
2001IFS=$as_save_IFS
1c710c3c
DJ
2002
2003} >&5
2004
2005cat >&5 <<_ACEOF
2006
2007
2008## ----------- ##
2009## Core tests. ##
2010## ----------- ##
2011
2012_ACEOF
2013
2014
2015# Keep a trace of the command line.
2016# Strip out --no-create and --no-recursion so they do not pile up.
2017# Strip out --silent because we don't want to record it for future runs.
2018# Also quote any args containing shell meta-characters.
2019# Make two passes to allow for proper duplicate-argument suppression.
2020ac_configure_args=
2021ac_configure_args0=
2022ac_configure_args1=
1c710c3c
DJ
2023ac_must_keep_next=false
2024for ac_pass in 1 2
2025do
2026 for ac_arg
2027 do
2028 case $ac_arg in
2029 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2030 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2031 | -silent | --silent | --silen | --sile | --sil)
2032 continue ;;
5213506e
RW
2033 *\'*)
2034 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1c710c3c
DJ
2035 esac
2036 case $ac_pass in
5213506e 2037 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
1c710c3c 2038 2)
5213506e 2039 as_fn_append ac_configure_args1 " '$ac_arg'"
1c710c3c
DJ
2040 if test $ac_must_keep_next = true; then
2041 ac_must_keep_next=false # Got value, back to normal.
2042 else
2043 case $ac_arg in
2044 *=* | --config-cache | -C | -disable-* | --disable-* \
2045 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2046 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2047 | -with-* | --with-* | -without-* | --without-* | --x)
2048 case "$ac_configure_args0 " in
2049 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2050 esac
2051 ;;
2052 -* ) ac_must_keep_next=true ;;
2053 esac
2054 fi
5213506e 2055 as_fn_append ac_configure_args " '$ac_arg'"
1c710c3c
DJ
2056 ;;
2057 esac
2058 done
2059done
5213506e
RW
2060{ ac_configure_args0=; unset ac_configure_args0;}
2061{ ac_configure_args1=; unset ac_configure_args1;}
1c710c3c
DJ
2062
2063# When interrupted or exit'd, cleanup temporary files, and complete
2064# config.log. We remove comments because anyway the quotes in there
2065# would cause problems or look ugly.
5213506e
RW
2066# WARNING: Use '\'' to represent an apostrophe within the trap.
2067# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1c710c3c
DJ
2068trap 'exit_status=$?
2069 # Save into config.log some information that might help in debugging.
2070 {
2071 echo
2072
22e05272 2073 $as_echo "## ---------------- ##
1c710c3c 2074## Cache variables. ##
22e05272 2075## ---------------- ##"
1c710c3c
DJ
2076 echo
2077 # The following way of writing the cache mishandles newlines in values,
5213506e
RW
2078(
2079 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2080 eval ac_val=\$$ac_var
2081 case $ac_val in #(
2082 *${as_nl}*)
2083 case $ac_var in #(
2084 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2085$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2086 esac
2087 case $ac_var in #(
2088 _ | IFS | as_nl) ;; #(
2089 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2090 *) { eval $ac_var=; unset $ac_var;} ;;
2091 esac ;;
2092 esac
2093 done
1c710c3c 2094 (set) 2>&1 |
5213506e
RW
2095 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2096 *${as_nl}ac_space=\ *)
1c710c3c 2097 sed -n \
5213506e
RW
2098 "s/'\''/'\''\\\\'\'''\''/g;
2099 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2100 ;; #(
1c710c3c 2101 *)
5213506e 2102 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1c710c3c 2103 ;;
5213506e
RW
2104 esac |
2105 sort
2106)
1c710c3c
DJ
2107 echo
2108
22e05272 2109 $as_echo "## ----------------- ##
1c710c3c 2110## Output variables. ##
22e05272 2111## ----------------- ##"
1c710c3c
DJ
2112 echo
2113 for ac_var in $ac_subst_vars
2114 do
5213506e
RW
2115 eval ac_val=\$$ac_var
2116 case $ac_val in
2117 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2118 esac
2119 $as_echo "$ac_var='\''$ac_val'\''"
1c710c3c
DJ
2120 done | sort
2121 echo
2122
2123 if test -n "$ac_subst_files"; then
22e05272 2124 $as_echo "## ------------------- ##
5213506e 2125## File substitutions. ##
22e05272 2126## ------------------- ##"
1c710c3c
DJ
2127 echo
2128 for ac_var in $ac_subst_files
2129 do
5213506e
RW
2130 eval ac_val=\$$ac_var
2131 case $ac_val in
2132 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2133 esac
2134 $as_echo "$ac_var='\''$ac_val'\''"
1c710c3c
DJ
2135 done | sort
2136 echo
2137 fi
2138
2139 if test -s confdefs.h; then
22e05272 2140 $as_echo "## ----------- ##
1c710c3c 2141## confdefs.h. ##
22e05272 2142## ----------- ##"
1c710c3c 2143 echo
5213506e 2144 cat confdefs.h
1c710c3c
DJ
2145 echo
2146 fi
2147 test "$ac_signal" != 0 &&
5213506e
RW
2148 $as_echo "$as_me: caught signal $ac_signal"
2149 $as_echo "$as_me: exit $exit_status"
1c710c3c 2150 } >&5
5213506e
RW
2151 rm -f core *.core core.conftest.* &&
2152 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1c710c3c 2153 exit $exit_status
5213506e 2154' 0
1c710c3c 2155for ac_signal in 1 2 13 15; do
5213506e 2156 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
1c710c3c
DJ
2157done
2158ac_signal=0
2159
2160# confdefs.h avoids OS command line length limits that DEFS can exceed.
5213506e
RW
2161rm -f -r conftest* confdefs.h
2162
2163$as_echo "/* confdefs.h */" > confdefs.h
1c710c3c
DJ
2164
2165# Predefined preprocessor variables.
2166
2167cat >>confdefs.h <<_ACEOF
2168#define PACKAGE_NAME "$PACKAGE_NAME"
2169_ACEOF
2170
1c710c3c
DJ
2171cat >>confdefs.h <<_ACEOF
2172#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2173_ACEOF
2174
1c710c3c
DJ
2175cat >>confdefs.h <<_ACEOF
2176#define PACKAGE_VERSION "$PACKAGE_VERSION"
2177_ACEOF
0b0dc272 2178
1c710c3c
DJ
2179cat >>confdefs.h <<_ACEOF
2180#define PACKAGE_STRING "$PACKAGE_STRING"
2181_ACEOF
2182
1c710c3c
DJ
2183cat >>confdefs.h <<_ACEOF
2184#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2185_ACEOF
2186
5213506e
RW
2187cat >>confdefs.h <<_ACEOF
2188#define PACKAGE_URL "$PACKAGE_URL"
2189_ACEOF
2190
1c710c3c
DJ
2191
2192# Let the site file select an alternate cache file if it wants to.
5213506e
RW
2193# Prefer an explicitly selected file to automatically selected ones.
2194ac_site_file1=NONE
2195ac_site_file2=NONE
2196if test -n "$CONFIG_SITE"; then
22e05272
JM
2197 # We do not want a PATH search for config.site.
2198 case $CONFIG_SITE in #((
2199 -*) ac_site_file1=./$CONFIG_SITE;;
2200 */*) ac_site_file1=$CONFIG_SITE;;
2201 *) ac_site_file1=./$CONFIG_SITE;;
2202 esac
5213506e
RW
2203elif test "x$prefix" != xNONE; then
2204 ac_site_file1=$prefix/share/config.site
2205 ac_site_file2=$prefix/etc/config.site
2206else
2207 ac_site_file1=$ac_default_prefix/share/config.site
2208 ac_site_file2=$ac_default_prefix/etc/config.site
671aa708 2209fi
5213506e
RW
2210for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2211do
2212 test "x$ac_site_file" = xNONE && continue
22e05272 2213 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
5213506e
RW
2214 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2215$as_echo "$as_me: loading site script $ac_site_file" >&6;}
1c710c3c 2216 sed 's/^/| /' "$ac_site_file" >&5
22e05272
JM
2217 . "$ac_site_file" \
2218 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2219$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2220as_fn_error $? "failed to load site script $ac_site_file
2221See \`config.log' for more details" "$LINENO" 5; }
671aa708
NN
2222 fi
2223done
2224
2225if test -r "$cache_file"; then
22e05272
JM
2226 # Some versions of bash will fail to source /dev/null (special files
2227 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2228 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
5213506e
RW
2229 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2230$as_echo "$as_me: loading cache $cache_file" >&6;}
1c710c3c 2231 case $cache_file in
5213506e
RW
2232 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2233 *) . "./$cache_file";;
1c710c3c
DJ
2234 esac
2235 fi
671aa708 2236else
5213506e
RW
2237 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2238$as_echo "$as_me: creating cache $cache_file" >&6;}
1c710c3c
DJ
2239 >$cache_file
2240fi
2241
2242# Check that the precious variables saved in the cache have kept the same
2243# value.
2244ac_cache_corrupted=false
5213506e 2245for ac_var in $ac_precious_vars; do
1c710c3c
DJ
2246 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2247 eval ac_new_set=\$ac_env_${ac_var}_set
5213506e
RW
2248 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2249 eval ac_new_val=\$ac_env_${ac_var}_value
1c710c3c
DJ
2250 case $ac_old_set,$ac_new_set in
2251 set,)
5213506e
RW
2252 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2253$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1c710c3c
DJ
2254 ac_cache_corrupted=: ;;
2255 ,set)
5213506e
RW
2256 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2257$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1c710c3c
DJ
2258 ac_cache_corrupted=: ;;
2259 ,);;
2260 *)
2261 if test "x$ac_old_val" != "x$ac_new_val"; then
5213506e
RW
2262 # differences in whitespace do not lead to failure.
2263 ac_old_val_w=`echo x $ac_old_val`
2264 ac_new_val_w=`echo x $ac_new_val`
2265 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2266 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2267$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2268 ac_cache_corrupted=:
2269 else
2270 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2271$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2272 eval $ac_var=\$ac_old_val
2273 fi
2274 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2275$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2276 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2277$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
1c710c3c
DJ
2278 fi;;
2279 esac
2280 # Pass precious variables to config.status.
2281 if test "$ac_new_set" = set; then
2282 case $ac_new_val in
5213506e 2283 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1c710c3c
DJ
2284 *) ac_arg=$ac_var=$ac_new_val ;;
2285 esac
2286 case " $ac_configure_args " in
2287 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
5213506e 2288 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
1c710c3c
DJ
2289 esac
2290 fi
2291done
2292if $ac_cache_corrupted; then
5213506e
RW
2293 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2294$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2295 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2296$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
22e05272 2297 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
671aa708 2298fi
5213506e
RW
2299## -------------------- ##
2300## Main body of script. ##
2301## -------------------- ##
671aa708 2302
2aeb72e9
DD
2303ac_ext=c
2304ac_cpp='$CPP $CPPFLAGS'
2305ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2306ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2307ac_compiler_gnu=$ac_cv_c_compiler_gnu
2308
1c710c3c
DJ
2309
2310
2311
1c710c3c
DJ
2312
2313
0115d4a3 2314
1c710c3c 2315
ad33ff57
RW
2316progname=$0
2317# if PWD already has a value, it is probably wrong.
2318if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
2319
2320# Export original configure arguments for use by sub-configures.
2321# Quote arguments with shell meta charatcers.
2322TOPLEVEL_CONFIGURE_ARGUMENTS=
2323set -- "$progname" "$@"
2324for ac_arg
2325do
2326 case "$ac_arg" in
2327 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\']*)
2328 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
2329 # if the argument is of the form -foo=baz, quote the baz part only
2330 ac_arg=`echo "'$ac_arg'" | sed "s/^'\([-a-zA-Z0-9]*=\)/\\1'/"` ;;
2331 *) ;;
2332 esac
2333 # Add the quoted argument to the list.
2334 TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS $ac_arg"
2335done
2336if test "$silent" = yes; then
2337 TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS --silent"
2338fi
2339# Remove the initial space we just introduced and, as these will be
2340# expanded by make, quote '$'.
2341TOPLEVEL_CONFIGURE_ARGUMENTS=`echo "x$TOPLEVEL_CONFIGURE_ARGUMENTS" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
2342
1c710c3c
DJ
2343
2344# Find the build, host, and target systems.
671aa708 2345ac_aux_dir=
5213506e 2346for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
22e05272
JM
2347 if test -f "$ac_dir/install-sh"; then
2348 ac_aux_dir=$ac_dir
2349 ac_install_sh="$ac_aux_dir/install-sh -c"
2350 break
2351 elif test -f "$ac_dir/install.sh"; then
2352 ac_aux_dir=$ac_dir
2353 ac_install_sh="$ac_aux_dir/install.sh -c"
2354 break
2355 elif test -f "$ac_dir/shtool"; then
2356 ac_aux_dir=$ac_dir
2357 ac_install_sh="$ac_aux_dir/shtool install -c"
2358 break
2359 fi
671aa708
NN
2360done
2361if test -z "$ac_aux_dir"; then
22e05272 2362 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
671aa708 2363fi
5213506e
RW
2364
2365# These three variables are undocumented and unsupported,
2366# and are intended to be withdrawn in a future Autoconf release.
2367# They can cause serious problems if a builder's source tree is in a directory
2368# whose full name contains unusual characters.
2369ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2370ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2371ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2372
671aa708 2373
1c710c3c 2374# Make sure we can run config.sub.
5213506e 2375$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
22e05272 2376 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5213506e
RW
2377
2378{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2379$as_echo_n "checking build system type... " >&6; }
22e05272 2380if ${ac_cv_build+:} false; then :
5213506e
RW
2381 $as_echo_n "(cached) " >&6
2382else
2383 ac_build_alias=$build_alias
2384test "x$ac_build_alias" = x &&
2385 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2386test "x$ac_build_alias" = x &&
22e05272 2387 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
5213506e 2388ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
22e05272 2389 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5213506e
RW
2390
2391fi
2392{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2393$as_echo "$ac_cv_build" >&6; }
2394case $ac_cv_build in
2395*-*-*) ;;
22e05272 2396*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
5213506e 2397esac
1c710c3c 2398build=$ac_cv_build
5213506e
RW
2399ac_save_IFS=$IFS; IFS='-'
2400set x $ac_cv_build
2401shift
2402build_cpu=$1
2403build_vendor=$2
2404shift; shift
2405# Remember, the first character of IFS is used to create $*,
2406# except with old shells:
2407build_os=$*
2408IFS=$ac_save_IFS
2409case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
671aa708 2410
671aa708 2411
1c710c3c
DJ
2412 case ${build_alias} in
2413 "") build_noncanonical=${build} ;;
2414 *) build_noncanonical=${build_alias} ;;
af71363e
AS
2415esac
2416
2417
af71363e 2418
1c710c3c
DJ
2419 case ${host_alias} in
2420 "") host_noncanonical=${build_noncanonical} ;;
2421 *) host_noncanonical=${host_alias} ;;
af71363e
AS
2422esac
2423
af71363e 2424
1c710c3c
DJ
2425
2426 case ${target_alias} in
2427 "") target_noncanonical=${host_noncanonical} ;;
2428 *) target_noncanonical=${target_alias} ;;
af71363e
AS
2429esac
2430
af71363e 2431
1c710c3c
DJ
2432
2433
2434test "$host_noncanonical" = "$target_noncanonical" &&
671aa708
NN
2435 test "$program_prefix$program_suffix$program_transform_name" = \
2436 NONENONEs,x,x, &&
1c710c3c 2437 program_transform_name=s,y,y,
af71363e 2438
5213506e
RW
2439{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2440$as_echo_n "checking host system type... " >&6; }
22e05272 2441if ${ac_cv_host+:} false; then :
5213506e 2442 $as_echo_n "(cached) " >&6
af71363e 2443else
5213506e
RW
2444 if test "x$host_alias" = x; then
2445 ac_cv_host=$ac_cv_build
2446else
2447 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
22e05272 2448 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5213506e 2449fi
1c710c3c 2450
af71363e 2451fi
5213506e
RW
2452{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2453$as_echo "$ac_cv_host" >&6; }
2454case $ac_cv_host in
2455*-*-*) ;;
22e05272 2456*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
5213506e 2457esac
1c710c3c 2458host=$ac_cv_host
5213506e
RW
2459ac_save_IFS=$IFS; IFS='-'
2460set x $ac_cv_host
2461shift
2462host_cpu=$1
2463host_vendor=$2
2464shift; shift
2465# Remember, the first character of IFS is used to create $*,
2466# except with old shells:
2467host_os=$*
2468IFS=$ac_save_IFS
2469case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2aeb72e9
DD
2470
2471
5213506e
RW
2472{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
2473$as_echo_n "checking target system type... " >&6; }
22e05272 2474if ${ac_cv_target+:} false; then :
5213506e 2475 $as_echo_n "(cached) " >&6
1c710c3c 2476else
5213506e
RW
2477 if test "x$target_alias" = x; then
2478 ac_cv_target=$ac_cv_host
2479else
2480 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
22e05272 2481 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
5213506e 2482fi
1c710c3c
DJ
2483
2484fi
5213506e
RW
2485{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
2486$as_echo "$ac_cv_target" >&6; }
2487case $ac_cv_target in
2488*-*-*) ;;
22e05272 2489*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
5213506e 2490esac
1c710c3c 2491target=$ac_cv_target
5213506e
RW
2492ac_save_IFS=$IFS; IFS='-'
2493set x $ac_cv_target
2494shift
2495target_cpu=$1
2496target_vendor=$2
2497shift; shift
2498# Remember, the first character of IFS is used to create $*,
2499# except with old shells:
2500target_os=$*
2501IFS=$ac_save_IFS
2502case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
1c710c3c
DJ
2503
2504
2505# The aliases save the names the user supplied, while $host etc.
2506# will get canonicalized.
2507test -n "$target_alias" &&
2508 test "$program_prefix$program_suffix$program_transform_name" = \
2509 NONENONEs,x,x, &&
2510 program_prefix=${target_alias}-
5213506e 2511
671aa708 2512test "$program_prefix" != NONE &&
5213506e 2513 program_transform_name="s&^&$program_prefix&;$program_transform_name"
671aa708
NN
2514# Use a double $ so make ignores it.
2515test "$program_suffix" != NONE &&
5213506e
RW
2516 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2517# Double any \ or $.
1c710c3c 2518# By default was `s,x,x', remove it if useless.
5213506e
RW
2519ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2520program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
af71363e 2521
671aa708
NN
2522
2523
775956d0
NN
2524# Get 'install' or 'install-sh' and its variants.
2525# Find a good install program. We prefer a C program (faster),
2526# so one script is as good as another. But avoid the broken or
2527# incompatible versions:
2528# SysV /etc/install, /usr/sbin/install
2529# SunOS /usr/etc/install
2530# IRIX /sbin/install
2531# AIX /bin/install
1c710c3c 2532# AmigaOS /C/install, which installs bootblocks on floppy discs
775956d0
NN
2533# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2534# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2535# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1c710c3c 2536# OS/2's system install, which has a completely different semantic
775956d0 2537# ./install, which can be erroneously created by make from ./install.sh.
38d24731 2538# Reject install programs that cannot install multiple files.
5213506e
RW
2539{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
2540$as_echo_n "checking for a BSD-compatible install... " >&6; }
775956d0 2541if test -z "$INSTALL"; then
22e05272 2542if ${ac_cv_path_install+:} false; then :
5213506e 2543 $as_echo_n "(cached) " >&6
1c710c3c
DJ
2544else
2545 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2546for as_dir in $PATH
2547do
2548 IFS=$as_save_IFS
2549 test -z "$as_dir" && as_dir=.
5213506e
RW
2550 # Account for people who put trailing slashes in PATH elements.
2551case $as_dir/ in #((
2552 ./ | .// | /[cC]/* | \
1c710c3c 2553 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5213506e 2554 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
1c710c3c
DJ
2555 /usr/ucb/* ) ;;
2556 *)
2557 # OSF1 and SCO ODT 3.0 have their own names for install.
2558 # Don't use installbsd from OSF since it installs stuff as root
2559 # by default.
2560 for ac_prog in ginstall scoinst install; do
2561 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 2562 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
775956d0 2563 if test $ac_prog = install &&
1c710c3c 2564 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
775956d0
NN
2565 # AIX install. It has an incompatible calling convention.
2566 :
1c710c3c
DJ
2567 elif test $ac_prog = install &&
2568 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2569 # program-specific install script used by HP pwplus--don't use.
2570 :
775956d0 2571 else
38d24731
RW
2572 rm -rf conftest.one conftest.two conftest.dir
2573 echo one > conftest.one
2574 echo two > conftest.two
2575 mkdir conftest.dir
2576 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
2577 test -s conftest.one && test -s conftest.two &&
2578 test -s conftest.dir/conftest.one &&
2579 test -s conftest.dir/conftest.two
2580 then
2581 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2582 break 3
2583 fi
775956d0
NN
2584 fi
2585 fi
2586 done
1c710c3c
DJ
2587 done
2588 ;;
2589esac
5213506e
RW
2590
2591 done
2592IFS=$as_save_IFS
1c710c3c 2593
38d24731 2594rm -rf conftest.one conftest.two conftest.dir
775956d0
NN
2595
2596fi
2597 if test "${ac_cv_path_install+set}" = set; then
1c710c3c 2598 INSTALL=$ac_cv_path_install
775956d0 2599 else
38d24731
RW
2600 # As a last resort, use the slow shell script. Don't cache a
2601 # value for INSTALL within a source directory, because that will
775956d0 2602 # break other packages using the cache if that directory is
38d24731 2603 # removed, or if the value is a relative name.
1c710c3c 2604 INSTALL=$ac_install_sh
775956d0
NN
2605 fi
2606fi
5213506e
RW
2607{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
2608$as_echo "$INSTALL" >&6; }
775956d0
NN
2609
2610# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2611# It thinks the first close brace ends the variable substitution.
2612test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2613
1c710c3c 2614test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
775956d0
NN
2615
2616test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2617
5213506e
RW
2618{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln works" >&5
2619$as_echo_n "checking whether ln works... " >&6; }
22e05272 2620if ${acx_cv_prog_LN+:} false; then :
5213506e 2621 $as_echo_n "(cached) " >&6
ad6717df
PB
2622else
2623 rm -f conftestdata_t
2624echo >conftestdata_f
2625if ln conftestdata_f conftestdata_t 2>/dev/null
2626then
2627 acx_cv_prog_LN=ln
2628else
2629 acx_cv_prog_LN=no
2630fi
2631rm -f conftestdata_f conftestdata_t
2632
2633fi
2634if test $acx_cv_prog_LN = no; then
2635 LN="cp"
5213506e
RW
2636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN" >&5
2637$as_echo "no, using $LN" >&6; }
ad6717df
PB
2638else
2639 LN="$acx_cv_prog_LN"
5213506e
RW
2640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2641$as_echo "yes" >&6; }
ad6717df
PB
2642fi
2643
5213506e
RW
2644{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
2645$as_echo_n "checking whether ln -s works... " >&6; }
1c710c3c
DJ
2646LN_S=$as_ln_s
2647if test "$LN_S" = "ln -s"; then
5213506e
RW
2648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2649$as_echo "yes" >&6; }
fb0103e5 2650else
5213506e
RW
2651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
2652$as_echo "no, using $LN_S" >&6; }
148907ea
PB
2653fi
2654
87264276
PB
2655{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
2656$as_echo_n "checking for a sed that does not truncate output... " >&6; }
22e05272 2657if ${ac_cv_path_SED+:} false; then :
87264276
PB
2658 $as_echo_n "(cached) " >&6
2659else
2660 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
2661 for ac_i in 1 2 3 4 5 6 7; do
2662 ac_script="$ac_script$as_nl$ac_script"
2663 done
2664 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
2665 { ac_script=; unset ac_script;}
2666 if test -z "$SED"; then
2667 ac_path_SED_found=false
2668 # Loop through the user's path and test for each of PROGNAME-LIST
2669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2670for as_dir in $PATH
2671do
2672 IFS=$as_save_IFS
2673 test -z "$as_dir" && as_dir=.
2674 for ac_prog in sed gsed; do
2675 for ac_exec_ext in '' $ac_executable_extensions; do
2676 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
22e05272 2677 as_fn_executable_p "$ac_path_SED" || continue
87264276
PB
2678# Check for GNU ac_path_SED and select it if it is found.
2679 # Check for GNU $ac_path_SED
2680case `"$ac_path_SED" --version 2>&1` in
2681*GNU*)
2682 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
2683*)
2684 ac_count=0
2685 $as_echo_n 0123456789 >"conftest.in"
2686 while :
2687 do
2688 cat "conftest.in" "conftest.in" >"conftest.tmp"
2689 mv "conftest.tmp" "conftest.in"
2690 cp "conftest.in" "conftest.nl"
2691 $as_echo '' >> "conftest.nl"
2692 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
2693 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
2694 as_fn_arith $ac_count + 1 && ac_count=$as_val
2695 if test $ac_count -gt ${ac_path_SED_max-0}; then
2696 # Best one so far, save it but keep looking for a better one
2697 ac_cv_path_SED="$ac_path_SED"
2698 ac_path_SED_max=$ac_count
2699 fi
2700 # 10*(2^10) chars as input seems more than enough
2701 test $ac_count -gt 10 && break
2702 done
2703 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
2704esac
2705
2706 $ac_path_SED_found && break 3
2707 done
2708 done
2709 done
2710IFS=$as_save_IFS
2711 if test -z "$ac_cv_path_SED"; then
22e05272 2712 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
87264276
PB
2713 fi
2714else
2715 ac_cv_path_SED=$SED
2716fi
2717
2718fi
2719{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
2720$as_echo "$ac_cv_path_SED" >&6; }
2721 SED="$ac_cv_path_SED"
2722 rm -f conftest.sed
2723
2724for ac_prog in gawk mawk nawk awk
2725do
2726 # Extract the first word of "$ac_prog", so it can be a program name with args.
2727set dummy $ac_prog; ac_word=$2
2728{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2729$as_echo_n "checking for $ac_word... " >&6; }
22e05272 2730if ${ac_cv_prog_AWK+:} false; then :
87264276
PB
2731 $as_echo_n "(cached) " >&6
2732else
2733 if test -n "$AWK"; then
2734 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2735else
2736as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2737for as_dir in $PATH
2738do
2739 IFS=$as_save_IFS
2740 test -z "$as_dir" && as_dir=.
2741 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 2742 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
87264276
PB
2743 ac_cv_prog_AWK="$ac_prog"
2744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2745 break 2
2746 fi
2747done
2748 done
2749IFS=$as_save_IFS
2750
2751fi
2752fi
2753AWK=$ac_cv_prog_AWK
2754if test -n "$AWK"; then
2755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
2756$as_echo "$AWK" >&6; }
2757else
2758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2759$as_echo "no" >&6; }
2760fi
2761
2762
2763 test -n "$AWK" && break
2764done
2765
775956d0 2766
ee6a22df
L
2767srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
2768
2769# We pass INSTALL explicitly to sub-makes. Make sure that it is not
2770# a relative path.
2771if test "$INSTALL" = "${srcdir}/install-sh -c"; then
2772 INSTALL="${srcpwd}/install-sh -c"
2773fi
2774
671aa708
NN
2775# Set srcdir to "." if that's what it is.
2776# This is important for multilib support.
2777pwd=`${PWDCMD-pwd}`
671aa708
NN
2778if test "${pwd}" = "${srcpwd}" ; then
2779 srcdir=.
79c06341
JL
2780fi
2781
671aa708 2782topsrcdir=$srcpwd
5d4a5ee6 2783
671aa708 2784extra_host_args=
afabd8e6 2785
671aa708
NN
2786### To add a new directory to the tree, first choose whether it is a target
2787### or a host dependent tool. Then put it into the appropriate list
2788### (library or tools, host or target), doing a dependency sort.
79c06341 2789
1c710c3c 2790# Subdirs will be configured in the order listed in build_configdirs,
671aa708 2791# configdirs, or target_configdirs; see the serialization section below.
79c06341 2792
1c710c3c
DJ
2793# Dependency sorting is only needed when *configuration* must be done in
2794# a particular order. In all cases a dependency should be specified in
671aa708 2795# the Makefile, whether or not it's implicitly specified here.
79c06341 2796
671aa708
NN
2797# Double entries in build_configdirs, configdirs, or target_configdirs may
2798# cause circular dependencies and break everything horribly.
79c06341 2799
23f6b2f9
PB
2800# these library is used by various programs built for the build
2801# environment
2802#
929315a9 2803build_libs="build-libiberty build-libcpp"
23f6b2f9
PB
2804
2805# these tools are built for the build environment
85bfb75e 2806build_tools="build-texinfo build-flex build-bison build-m4 build-fixincludes"
23f6b2f9 2807
671aa708 2808# these libraries are used by various programs built for the host environment
eae1a5d4 2809#f
36230329 2810host_libs="intl libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libcody libdecnumber gmp mpfr mpc isl libelf libiconv libctf"
671aa708 2811
671aa708
NN
2812# these tools are built for the host environment
2813# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
2814# know that we are building the simulator.
2815# binutils, gas and ld appear in that order because it makes sense to run
2816# "make check" in that particular order.
38e3d868 2817# If --enable-gold is used, "gold" may replace "ld".
2efd8b1f 2818host_tools="texinfo flex bison binutils gas ld fixincludes gcc cgen sid sim gdb gdbserver gprof etc expect dejagnu m4 utils guile fastjar gnattools libcc1 gotools c++tools"
671aa708 2819
671aa708
NN
2820# these libraries are built for the target environment, and are built after
2821# the host libraries and the host tools (which may be a cross compiler)
8499116a 2822# Note that libiberty is not a target library.
291f172e 2823target_libraries="target-libgcc \
eff02e4f 2824 target-libbacktrace \
671aa708
NN
2825 target-libgloss \
2826 target-newlib \
6d3b5aea 2827 target-libgomp \
5f520819 2828 target-liboffloadmic \
48310492 2829 target-libatomic \
0a35513e 2830 target-libitm \
cb543528 2831 target-libstdc++-v3 \
f35db108 2832 target-libsanitizer \
2077db1b 2833 target-libvtv \
77008252 2834 target-libssp \
1ec601bf 2835 target-libquadmath \
6de9cd9a 2836 target-libgfortran \
012447ea 2837 target-libffi \
d9cdb878 2838 target-libobjc \
632e2a07 2839 target-libada \
b4c522fa 2840 target-libgo \
bb50312e
IB
2841 target-libphobos \
2842 target-zlib"
671aa708 2843
4dbda6f0
NN
2844# these tools are built using the target libraries, and are intended to
2845# run only in the target environment
671aa708 2846#
4dbda6f0 2847# note: any program that *uses* libraries that are in the "target_libraries"
1bcce263 2848# list belongs in this list.
671aa708 2849#
85bfb75e 2850target_tools="target-rda"
79c06341 2851
671aa708 2852################################################################################
79c06341 2853
671aa708
NN
2854## All tools belong in one of the four categories, and are assigned above
2855## We assign ${configdirs} this way to remove all embedded newlines. This
2856## is important because configure will choke if they ever get through.
2857## ${configdirs} is directories we build using the host tools.
2858## ${target_configdirs} is directories we build using the target tools.
671aa708 2859configdirs=`echo ${host_libs} ${host_tools}`
4dbda6f0 2860target_configdirs=`echo ${target_libraries} ${target_tools}`
71b5d516 2861build_configdirs=`echo ${build_libs} ${build_tools}`
8b87bb96 2862
ac9e6043
RW
2863
2864
671aa708 2865################################################################################
79c06341 2866
671aa708 2867srcname="gnu development package"
79c06341 2868
671aa708
NN
2869# This gets set non-empty for some net releases of packages.
2870appdirs=""
79c06341 2871
671aa708
NN
2872# Define is_cross_compiler to save on calls to 'test'.
2873is_cross_compiler=
2874if test x"${host}" = x"${target}" ; then
2875 is_cross_compiler=no
79c06341 2876else
671aa708 2877 is_cross_compiler=yes
1c710c3c 2878fi
79c06341 2879
b4acb5ef 2880# Find the build and target subdir names.
8b87bb96 2881
2e9e6f68
DJ
2882# post-stage1 host modules use a different CC_FOR_BUILD so, in order to
2883# have matching libraries, they should use host libraries: Makefile.tpl
2884# arranges to pass --with-build-libsubdir=$(HOST_SUBDIR).
2885# However, they still use the build modules, because the corresponding
2886# host modules (e.g. bison) are only built for the host when bootstrap
2887# finishes. So:
2888# - build_subdir is where we find build modules, and never changes.
2889# - build_libsubdir is where we find build libraries, and can be overridden.
2890
2891# Prefix 'build-' so this never conflicts with target_subdir.
8b87bb96 2892build_subdir="build-${build_noncanonical}"
1c710c3c 2893
5213506e
RW
2894# Check whether --with-build-libsubdir was given.
2895if test "${with_build_libsubdir+set}" = set; then :
2896 withval=$with_build_libsubdir; build_libsubdir="$withval"
2e9e6f68
DJ
2897else
2898 build_libsubdir="$build_subdir"
5213506e
RW
2899fi
2900
215c351a
PB
2901# --srcdir=. covers the toplevel, while "test -d" covers the subdirectories
2902if ( test $srcdir = . && test -d gcc ) \
2903 || test -d $srcdir/../host-${host_noncanonical}; then
2904 host_subdir="host-${host_noncanonical}"
2905else
2906 host_subdir=.
2907fi
8b87bb96
NN
2908# No prefix.
2909target_subdir=${target_noncanonical}
1c710c3c 2910
0db770bd
RW
2911# Be sure to cover against remnants of an in-tree build.
2912if test $srcdir != . && test -d $srcdir/host-${host_noncanonical}; then
22e05272 2913 as_fn_error $? "building out of tree but $srcdir contains host-${host_noncanonical}.
0db770bd
RW
2914Use a pristine source tree when building in a separate tree" "$LINENO" 5
2915fi
79c06341 2916
671aa708
NN
2917# Skipdirs are removed silently.
2918skipdirs=
2919# Noconfigdirs are removed loudly.
2920noconfigdirs=""
79c06341 2921
671aa708
NN
2922use_gnu_ld=
2923# Make sure we don't let GNU ld be added if we didn't want it.
2924if test x$with_gnu_ld = xno ; then
2925 use_gnu_ld=no
5afab7ad 2926 noconfigdirs="$noconfigdirs ld gold"
79c06341
JL
2927fi
2928
671aa708
NN
2929use_gnu_as=
2930# Make sure we don't let GNU as be added if we didn't want it.
2931if test x$with_gnu_as = xno ; then
2932 use_gnu_as=no
2933 noconfigdirs="$noconfigdirs gas"
79c06341
JL
2934fi
2935
d7f09764 2936use_included_zlib=
a05c2c75
L
2937
2938# Check whether --with-system-zlib was given.
2939if test "${with_system_zlib+set}" = set; then :
2940 withval=$with_system_zlib;
2941fi
2942
d7f09764
DN
2943# Make sure we don't let ZLIB be added if we didn't want it.
2944if test x$with_system_zlib = xyes ; then
2945 use_included_zlib=no
2946 noconfigdirs="$noconfigdirs zlib"
2947fi
2948
1c710c3c 2949# some tools are so dependent upon X11 that if we're not building with X,
671aa708 2950# it's not even worth trying to configure, much less build, that tool.
79c06341 2951
671aa708
NN
2952case ${with_x} in
2953 yes | "") ;; # the default value for this tree is that X11 is available
2954 no)
b4f96efe 2955 skipdirs="${skipdirs} tk itcl libgui"
671aa708 2956 # We won't be able to build gdbtk without X.
1c710c3c 2957 enable_gdbtk=no
671aa708
NN
2958 ;;
2959 *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
2960esac
79c06341 2961
1bcce263 2962# Some are only suitable for cross toolchains.
671aa708
NN
2963# Remove these if host=target.
2964cross_only="target-libgloss target-newlib target-opcodes"
2965
2966case $is_cross_compiler in
2967 no) skipdirs="${skipdirs} ${cross_only}" ;;
671aa708 2968esac
79c06341 2969
671aa708
NN
2970# If both --with-headers and --with-libs are specified, default to
2971# --without-newlib.
ee6a22df
L
2972if test x"${with_headers}" != x && test x"${with_headers}" != xno \
2973 && test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
671aa708
NN
2974 if test x"${with_newlib}" = x ; then
2975 with_newlib=no
2976 fi
79c06341
JL
2977fi
2978
671aa708
NN
2979# Recognize --with-newlib/--without-newlib.
2980case ${with_newlib} in
2981 no) skipdirs="${skipdirs} target-newlib" ;;
2982 yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
2983esac
79c06341 2984
85c64bbe
BS
2985# Check whether --enable-as-accelerator-for was given.
2986if test "${enable_as_accelerator_for+set}" = set; then :
4b4f2e35 2987 enableval=$enable_as_accelerator_for;
85c64bbe
BS
2988fi
2989
2990
2991# Check whether --enable-offload-targets was given.
2992if test "${enable_offload_targets+set}" = set; then :
2993 enableval=$enable_offload_targets;
2994 if test x"$enable_offload_targets" = x; then
22e05272 2995 as_fn_error $? "no offload targets specified" "$LINENO" 5
85c64bbe
BS
2996 fi
2997
2998else
2999 enable_offload_targets=
3000fi
3001
3002
fe5bfa67
TB
3003# Check whether --enable-offload-defaulted was given.
3004if test "${enable_offload_defaulted+set}" = set; then :
3005 enableval=$enable_offload_defaulted; enable_offload_defaulted=$enableval
3006else
3007 enable_offload_defaulted=
3008fi
3009
3010
21539e2e
MK
3011# Handle --enable-gold, --enable-ld.
3012# --disable-gold [--enable-ld]
3013# Build only ld. Default option.
9580395f
L
3014# --enable-gold [--enable-ld]
3015# Build both gold and ld. Install gold as "ld.gold", install ld
3016# as "ld.bfd" and "ld".
3017# --enable-gold=default [--enable-ld]
21539e2e
MK
3018# Build both gold and ld. Install gold as "ld.gold" and "ld",
3019# install ld as "ld.bfd".
3020# --enable-gold[=default] --disable-ld
3021# Build only gold, which is then installed as both "ld.gold" and "ld".
3022# --enable-gold --enable-ld=default
9580395f
L
3023# Build both gold (installed as "ld.gold") and ld (installed as "ld"
3024# and ld.bfd).
21539e2e
MK
3025# In other words, ld is default
3026# --enable-gold=default --enable-ld=default
3027# Error.
3028
3029default_ld=
5213506e
RW
3030# Check whether --enable-gold was given.
3031if test "${enable_gold+set}" = set; then :
3032 enableval=$enable_gold; ENABLE_GOLD=$enableval
5afab7ad
ILT
3033else
3034 ENABLE_GOLD=no
5213506e
RW
3035fi
3036
21539e2e
MK
3037case "${ENABLE_GOLD}" in
3038 yes|default)
38e3d868
RM
3039 # Check for ELF target.
3040 is_elf=no
3041 case "${target}" in
3042 *-*-elf* | *-*-sysv4* | *-*-unixware* | *-*-eabi* | hppa*64*-*-hpux* \
0e76460f 3043 | *-*-linux* | *-*-gnu* | frv-*-uclinux* | *-*-irix5* | *-*-irix6* \
8c6d158a 3044 | *-*-netbsd* | *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* \
ff4b7a7e 3045 | *-*-solaris2* | *-*-nto* | *-*-nacl*)
38e3d868
RM
3046 case "${target}" in
3047 *-*-linux*aout* | *-*-linux*oldld*)
3048 ;;
3049 *)
3050 is_elf=yes
3051 ;;
3052 esac
3053 esac
3054
3055 if test "$is_elf" = "yes"; then
3056 # Check for target supported by gold.
5afab7ad 3057 case "${target}" in
7705dfd1 3058 i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-* \
1b858e76 3059 | aarch64*-*-* | tilegx*-*-* | mips*-*-* | s390*-*-*)
21539e2e
MK
3060 configdirs="$configdirs gold"
3061 if test x${ENABLE_GOLD} = xdefault; then
3062 default_ld=gold
3063 fi
38e3d868 3064 ENABLE_GOLD=yes
5afab7ad
ILT
3065 ;;
3066 esac
38e3d868
RM
3067 fi
3068 ;;
3069 no)
3070 ;;
3071 *)
22e05272 3072 as_fn_error $? "invalid --enable-gold argument" "$LINENO" 5
38e3d868 3073 ;;
21539e2e
MK
3074esac
3075
3076# Check whether --enable-ld was given.
3077if test "${enable_ld+set}" = set; then :
3078 enableval=$enable_ld; ENABLE_LD=$enableval
3079else
3080 ENABLE_LD=yes
3081fi
3082
3083
3084case "${ENABLE_LD}" in
3085 default)
9580395f 3086 if test x${default_ld} != x; then
22e05272 3087 as_fn_error $? "either gold or ld can be the default ld" "$LINENO" 5
21539e2e
MK
3088 fi
3089 ;;
3090 yes)
3091 ;;
3092 no)
3093 if test x${ENABLE_GOLD} != xyes; then
3094 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: neither ld nor gold are enabled" >&5
3095$as_echo "$as_me: WARNING: neither ld nor gold are enabled" >&2;}
3096 fi
3097 configdirs=`echo " ${configdirs} " | sed -e 's/ ld / /'`
3098 ;;
3099 *)
22e05272 3100 as_fn_error $? "invalid --enable-ld argument" "$LINENO" 5
21539e2e
MK
3101 ;;
3102esac
5afab7ad 3103
78edb32f
L
3104# PR gas/19109
3105# Decide the default method for compressing debug sections.
3106# Provide a configure time option to override our default.
3107# Check whether --enable-compressed_debug_sections was given.
3108if test "${enable_compressed_debug_sections+set}" = set; then :
3109 enableval=$enable_compressed_debug_sections;
3110 if test x"$enable_compressed_debug_sections" = xyes; then
22e05272 3111 as_fn_error $? "no program with compressed debug sections specified" "$LINENO" 5
78edb32f
L
3112 fi
3113
3114else
3115 enable_compressed_debug_sections=
3116fi
3117
3118
671aa708 3119# Configure extra directories which are host specific
79c06341 3120
671aa708
NN
3121case "${host}" in
3122 *-cygwin*)
3123 configdirs="$configdirs libtermcap" ;;
3124esac
79c06341 3125
4fab7234
HPN
3126# A target can indicate whether a language isn't supported for some reason.
3127# Only spaces may be used in this macro; not newlines or tabs.
3128unsupported_languages=
3129
1c710c3c 3130# Remove more programs from consideration, based on the host or
671aa708
NN
3131# target this usually means that a port of the program doesn't
3132# exist yet.
ec8d6ddc 3133
671aa708 3134case "${host}" in
111eeb6e 3135 i[3456789]86-*-msdosdjgpp*)
c9bdb152 3136 noconfigdirs="$noconfigdirs tcl tk itcl"
671aa708 3137 ;;
671aa708 3138esac
ec8d6ddc 3139
6de9cd9a 3140
87e6d9dc
TB
3141# Check whether --enable-libquadmath was given.
3142if test "${enable_libquadmath+set}" = set; then :
3143 enableval=$enable_libquadmath; ENABLE_LIBQUADMATH=$enableval
3144else
3145 ENABLE_LIBQUADMATH=yes
3146fi
3147
3148if test "${ENABLE_LIBQUADMATH}" = "no" ; then
3149 noconfigdirs="$noconfigdirs target-libquadmath"
3150fi
3151
3152
3153# Check whether --enable-libquadmath-support was given.
3154if test "${enable_libquadmath_support+set}" = set; then :
3155 enableval=$enable_libquadmath_support; ENABLE_LIBQUADMATH_SUPPORT=$enableval
3156else
3157 ENABLE_LIBQUADMATH_SUPPORT=yes
3158fi
3159
3160enable_libquadmath_support=
3161if test "${ENABLE_LIBQUADMATH_SUPPORT}" = "no" ; then
3162 enable_libquadmath_support=no
3163fi
3164
3165
5213506e
RW
3166# Check whether --enable-libada was given.
3167if test "${enable_libada+set}" = set; then :
3168 enableval=$enable_libada; ENABLE_LIBADA=$enableval
d9cdb878
AC
3169else
3170 ENABLE_LIBADA=yes
5213506e
RW
3171fi
3172
d9cdb878 3173if test "${ENABLE_LIBADA}" != "yes" ; then
5395b47b 3174 noconfigdirs="$noconfigdirs gnattools"
d9cdb878
AC
3175fi
3176
5213506e
RW
3177# Check whether --enable-libssp was given.
3178if test "${enable_libssp+set}" = set; then :
3179 enableval=$enable_libssp; ENABLE_LIBSSP=$enableval
ef0087a7
KH
3180else
3181 ENABLE_LIBSSP=yes
5213506e
RW
3182fi
3183
ef0087a7 3184
1873ec0c
L
3185# Check whether --enable-libstdcxx was given.
3186if test "${enable_libstdcxx+set}" = set; then :
3187 enableval=$enable_libstdcxx; ENABLE_LIBSTDCXX=$enableval
3188else
3189 ENABLE_LIBSTDCXX=default
3190fi
3191
3192if test "${ENABLE_LIBSTDCXX}" = "no" ; then
1007a55c 3193 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1873ec0c
L
3194fi
3195
5f520819
KY
3196# If this is accelerator compiler and its target is intelmic we enable
3197# target liboffloadmic by default. If this is compiler with offloading
3198# for intelmic we enable host liboffloadmic by default. Otherwise
3199# liboffloadmic is disabled by default.
3200# Check whether --enable-liboffloadmic was given.
3201if test "${enable_liboffloadmic+set}" = set; then :
3202 enableval=$enable_liboffloadmic; case "$enableval" in
3203 no | host | target)
3204 enable_liboffloadmic=$enableval ;;
3205 *)
22e05272 3206 as_fn_error $? "--enable-liboffloadmic=no/host/target" "$LINENO" 5 ;;
5f520819
KY
3207esac
3208else
4b4f2e35 3209 if test x"$enable_as_accelerator_for" != x; then
5f520819
KY
3210 case "${target}" in
3211 *-intelmic-* | *-intelmicemul-*)
3212 enable_liboffloadmic=target
3213 extra_liboffloadmic_configure_flags="--enable-liboffloadmic=target"
3214 ;;
3215 *)
3216 enable_liboffloadmic=no
3217 ;;
3218 esac
3219else
3220 case "${enable_offload_targets}" in
3221 *-intelmic-* | *-intelmicemul-*)
3222 enable_liboffloadmic=host
3223 extra_liboffloadmic_configure_flags="--enable-liboffloadmic=host"
3224 ;;
3225 *)
3226 enable_liboffloadmic=no
3227 ;;
3228 esac
3229fi
3230fi
3231
3232
3233
44a7d18d 3234# Enable libgomp by default on hosted POSIX systems, and a few others.
27079765 3235if test x$enable_libgomp = x ; then
953ff289 3236 case "${target}" in
416ac4d4 3237 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
953ff289 3238 ;;
8c6d158a 3239 *-*-netbsd* | *-*-freebsd* | *-*-openbsd* | *-*-dragonfly*)
953ff289 3240 ;;
b24513a1 3241 *-*-solaris2* | *-*-hpux11*)
953ff289 3242 ;;
cac90078 3243 *-*-darwin* | *-*-aix*)
953ff289 3244 ;;
29b1533a 3245 nvptx*-*-* | amdgcn*-*-*)
44a7d18d 3246 ;;
953ff289
DN
3247 *)
3248 noconfigdirs="$noconfigdirs target-libgomp"
3249 ;;
3250 esac
27079765 3251fi
953ff289 3252
48310492
RH
3253# Disable libatomic on unsupported systems.
3254if test -d ${srcdir}/libatomic; then
3255 if test x$enable_libatomic = x; then
3256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libatomic support" >&5
3257$as_echo_n "checking for libatomic support... " >&6; }
3258 if (srcdir=${srcdir}/libatomic; \
3259 . ${srcdir}/configure.tgt; \
3260 test -n "$UNSUPPORTED")
3261 then
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3263$as_echo "no" >&6; }
3264 noconfigdirs="$noconfigdirs target-libatomic"
3265 else
3266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3267$as_echo "yes" >&6; }
3268 fi
3269 fi
3270fi
3271
5f520819
KY
3272# Disable liboffloadmic on unsupported systems.
3273if test -d ${srcdir}/liboffloadmic; then
3274 if test x$enable_liboffloadmic != xno; then
3275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for liboffloadmic support" >&5
3276$as_echo_n "checking for liboffloadmic support... " >&6; }
3277 if (srcdir=${srcdir}/liboffloadmic; \
3278 . ${srcdir}/configure.tgt; \
3279 test -n "$UNSUPPORTED")
3280 then
3281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3282$as_echo "no" >&6; }
3283 noconfigdirs="$noconfigdirs target-liboffloadmic"
3284 else
3285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3286$as_echo "yes" >&6; }
3287 fi
3288 fi
3289fi
3290
e948157d
RH
3291# Disable libitm on unsupported systems.
3292if test -d ${srcdir}/libitm; then
3293 if test x$enable_libitm = x; then
3294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libitm support" >&5
01f3428c 3295$as_echo_n "checking for libitm support... " >&6; }
e948157d
RH
3296 if (srcdir=${srcdir}/libitm; \
3297 . ${srcdir}/configure.tgt; \
3298 test -n "$UNSUPPORTED")
3299 then
3300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
01f3428c 3301$as_echo "no" >&6; }
e948157d
RH
3302 noconfigdirs="$noconfigdirs target-libitm"
3303 else
3304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
01f3428c 3305$as_echo "yes" >&6; }
e948157d
RH
3306 fi
3307 fi
0a35513e
AH
3308fi
3309
93bf5390
RH
3310# Disable libsanitizer on unsupported systems.
3311if test -d ${srcdir}/libsanitizer; then
3312 if test x$enable_libsanitizer = x; then
3313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libsanitizer support" >&5
3314$as_echo_n "checking for libsanitizer support... " >&6; }
3315 if (srcdir=${srcdir}/libsanitizer; \
3316 . ${srcdir}/configure.tgt; \
3317 test -n "$UNSUPPORTED")
3318 then
3319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3320$as_echo "no" >&6; }
3321 noconfigdirs="$noconfigdirs target-libsanitizer"
3322 else
3323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3324$as_echo "yes" >&6; }
3325 fi
3326 fi
3327fi
3328
2077db1b
CT
3329# Disable libvtv on unsupported systems.
3330if test -d ${srcdir}/libvtv; then
3331 if test x$enable_libvtv = x; then
3332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libvtv support" >&5
3333$as_echo_n "checking for libvtv support... " >&6; }
3334 if (srcdir=${srcdir}/libvtv; \
3335 . ${srcdir}/configure.tgt; \
1e74b850 3336 test "$VTV_SUPPORTED" != "yes")
2077db1b
CT
3337 then
3338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3339$as_echo "no" >&6; }
3340 noconfigdirs="$noconfigdirs target-libvtv"
3341 else
3342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3343$as_echo "yes" >&6; }
3344 fi
3345 fi
3346fi
3347
d91491e5
SE
3348# Disable libquadmath for some systems.
3349case "${target}" in
e7fae550
DE
3350 avr-*-*)
3351 noconfigdirs="$noconfigdirs target-libquadmath"
3352 ;;
d91491e5
SE
3353 # libquadmath is unused on AIX and libquadmath build process use of
3354 # LD_LIBRARY_PATH can break AIX bootstrap.
3355 powerpc-*-aix* | rs6000-*-aix*)
3356 noconfigdirs="$noconfigdirs target-libquadmath"
3357 ;;
3358esac
3359
1e9e0e23
JM
3360# Disable libssp for some systems.
3361case "${target}" in
3362 avr-*-*)
b318fb4b 3363 # No hosted I/O support.
1e9e0e23
JM
3364 noconfigdirs="$noconfigdirs target-libssp"
3365 ;;
91dfef96
JM
3366 bpf-*-*)
3367 noconfigdirs="$noconfigdirs target-libssp"
3368 ;;
1e9e0e23
JM
3369 powerpc-*-aix* | rs6000-*-aix*)
3370 noconfigdirs="$noconfigdirs target-libssp"
85b8555e 3371 ;;
8d2af3a2
DD
3372 pru-*-*)
3373 # No hosted I/O support.
3374 noconfigdirs="$noconfigdirs target-libssp"
3375 ;;
85b8555e 3376 rl78-*-*)
7cb62ef1
EB
3377 # libssp uses a misaligned load to trigger a fault, but the RL78
3378 # doesn't fault for those - instead, it gives a build-time error
3379 # for explicit misaligned loads.
85b8555e 3380 noconfigdirs="$noconfigdirs target-libssp"
1e9e0e23 3381 ;;
0969ec7d
EB
3382 visium-*-*)
3383 # No hosted I/O support.
3384 noconfigdirs="$noconfigdirs target-libssp"
3385 ;;
1e9e0e23
JM
3386esac
3387
1e9e0e23 3388# Disable libstdc++-v3 for some systems.
67a1cb2a 3389# Allow user to override this if they pass --enable-libstdcxx
1873ec0c
L
3390if test "${ENABLE_LIBSTDCXX}" = "default" ; then
3391 case "${target}" in
3392 *-*-vxworks*)
3393 # VxWorks uses the Dinkumware C++ library.
3394 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3395 ;;
afa3d80e
TS
3396 amdgcn*-*-*)
3397 # Not ported/fails to build when using newlib.
3398 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3399 ;;
1873ec0c
L
3400 arm*-wince-pe*)
3401 # the C++ libraries don't build on top of CE's C libraries
3402 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3403 ;;
3404 avr-*-*)
3405 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3406 ;;
91dfef96
JM
3407 bpf-*-*)
3408 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3409 ;;
fef939d6
JB
3410 ft32-*-*)
3411 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3412 ;;
1873ec0c
L
3413 esac
3414fi
1e9e0e23 3415
91dfef96
JM
3416# Disable C++ on systems where it is known to not work.
3417# For testing, you can override this with --enable-languages=c++.
3418case ,${enable_languages}, in
3419 *,c++,*)
3420 ;;
3421 *)
3422 case "${target}" in
3423 bpf-*-*)
3424 unsupported_languages="$unsupported_languages c++"
3425 ;;
3426 esac
3427 ;;
3428esac
3429
3430# Disable Objc on systems where it is known to not work.
3431# For testing, you can override this with --enable-languages=objc.
3432case ,${enable_languages}, in
3433 *,objc,*)
3434 ;;
3435 *)
3436 case "${target}" in
3437 bpf-*-*)
3438 unsupported_languages="$unsupported_languages objc"
3439 ;;
3440 esac
3441 ;;
3442esac
3443
260eedb9
IB
3444# Disable D on systems where it is known to not work.
3445# For testing, you can override this with --enable-languages=d.
3446case ,${enable_languages}, in
3447 *,d,*)
3448 ;;
3449 *)
3450 case "${target}" in
91dfef96 3451 bpf-*-*)
260eedb9
IB
3452 unsupported_languages="$unsupported_languages d"
3453 ;;
3454 esac
3455 ;;
3456esac
3457
3458# Disable libphobos on unsupported systems.
3459# For testing, you can override this with --enable-libphobos.
3460if test -d ${srcdir}/libphobos; then
3461 if test x$enable_libphobos = x; then
3462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libphobos support" >&5
3463$as_echo_n "checking for libphobos support... " >&6; }
3464 if (srcdir=${srcdir}/libphobos; \
3465 . ${srcdir}/configure.tgt; \
7d31d331 3466 test "$LIBPHOBOS_SUPPORTED" != "yes")
260eedb9
IB
3467 then
3468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3469$as_echo "no" >&6; }
3470 noconfigdirs="$noconfigdirs target-libphobos"
3471 else
3472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3473$as_echo "yes" >&6; }
3474 fi
3475 fi
3476fi
3477
1e9e0e23
JM
3478# Disable Fortran for some systems.
3479case "${target}" in
3480 mmix-*-*)
3481 # See <http://gcc.gnu.org/ml/gcc-patches/2004-11/msg00572.html>.
3482 unsupported_languages="$unsupported_languages fortran"
3483 ;;
91dfef96
JM
3484 bpf-*-*)
3485 unsupported_languages="$unsupported_languages fortran"
3486 ;;
1e9e0e23
JM
3487esac
3488
012447ea
JJ
3489# Disable libffi for some systems.
3490case "${target}" in
3491 powerpc-*-darwin*)
3492 ;;
3493 i[3456789]86-*-darwin*)
3494 ;;
3495 x86_64-*-darwin[912]*)
3496 ;;
3497 *-*-darwin*)
3498 noconfigdirs="$noconfigdirs target-libffi"
3499 ;;
3500 *-*-netware*)
3501 noconfigdirs="$noconfigdirs target-libffi"
3502 ;;
3503 *-*-phoenix*)
3504 noconfigdirs="$noconfigdirs target-libffi"
3505 ;;
3506 *-*-rtems*)
3507 noconfigdirs="$noconfigdirs target-libffi"
3508 ;;
3509 *-*-tpf*)
3510 noconfigdirs="$noconfigdirs target-libffi"
3511 ;;
3512 *-*-uclinux*)
3513 noconfigdirs="$noconfigdirs target-libffi"
3514 ;;
3515 *-*-vxworks*)
3516 noconfigdirs="$noconfigdirs target-libffi"
3517 ;;
b20e7532
AT
3518 aarch64*-*-freebsd*)
3519 noconfigdirs="$noconfigdirs target-libffi"
3520 ;;
012447ea
JJ
3521 alpha*-*-*vms*)
3522 noconfigdirs="$noconfigdirs target-libffi"
3523 ;;
3524 arm*-*-freebsd*)
3525 noconfigdirs="$noconfigdirs target-libffi"
3526 ;;
3527 arm-wince-pe)
3528 noconfigdirs="$noconfigdirs target-libffi"
3529 ;;
3530 arm*-*-symbianelf*)
3531 noconfigdirs="$noconfigdirs target-libffi"
3532 ;;
91dfef96
JM
3533 bpf-*-*)
3534 noconfigdirs="$noconfigdirs target-libffi"
3535 ;;
012447ea
JJ
3536 cris-*-* | crisv32-*-*)
3537 case "${target}" in
3538 *-*-linux*)
3539 ;;
3540 *) # See PR46792 regarding target-libffi.
3541 noconfigdirs="$noconfigdirs target-libffi";;
3542 esac
3543 ;;
3544 hppa*64*-*-hpux*)
3545 noconfigdirs="$noconfigdirs target-libffi"
3546 ;;
3547 hppa*-hp-hpux11*)
3548 ;;
3549 hppa*-*-hpux*)
3550 noconfigdirs="$noconfigdirs target-libffi"
3551 ;;
3552 ia64*-*-*vms*)
3553 noconfigdirs="$noconfigdirs target-libffi"
3554 ;;
3555 i[3456789]86-w64-mingw*)
3556 noconfigdirs="$noconfigdirs target-libffi"
3557 ;;
3558 i[3456789]86-*-mingw*)
3559 noconfigdirs="$noconfigdirs target-libffi"
3560 ;;
3561 x86_64-*-mingw*)
3562 noconfigdirs="$noconfigdirs target-libffi"
3563 ;;
3564 mmix-*-*)
3565 noconfigdirs="$noconfigdirs target-libffi"
3566 ;;
3567 powerpc-*-aix*)
012447ea
JJ
3568 ;;
3569 rs6000-*-aix*)
012447ea
JJ
3570 ;;
3571 ft32-*-*)
3572 noconfigdirs="$noconfigdirs target-libffi"
3573 ;;
3574 *-*-lynxos*)
3575 noconfigdirs="$noconfigdirs target-libffi"
3576 ;;
3577esac
3578
3579# Disable the go frontend on systems where it is known to not work. Please keep
3580# this in sync with contrib/config-list.mk.
3581case "${target}" in
91dfef96 3582*-*-darwin* | *-*-cygwin* | *-*-mingw* | bpf-* )
012447ea
JJ
3583 unsupported_languages="$unsupported_languages go"
3584 ;;
3585esac
3586
f9d09df0
TT
3587# Only allow gdbserver on some systems.
3588if test -d ${srcdir}/gdbserver; then
3589 if test x$enable_gdbserver = x; then
3590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdbserver support" >&5
3591$as_echo_n "checking for gdbserver support... " >&6; }
3592 if (srcdir=${srcdir}/gdbserver; \
3593 . ${srcdir}/configure.srv; \
3594 test -n "$UNSUPPORTED")
3595 then
3596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3597$as_echo "no" >&6; }
3598 noconfigdirs="$noconfigdirs gdbserver"
3599 else
3600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3601$as_echo "yes" >&6; }
3602 fi
3603 fi
3604fi
3605
cdbc9e92
ILT
3606# Disable libgo for some systems where it is known to not work.
3607# For testing, you can easily override this with --enable-libgo.
3608if test x$enable_libgo = x; then
3609 case "${target}" in
3610 *-*-darwin*)
3611 # PR 46986
3612 noconfigdirs="$noconfigdirs target-libgo"
3613 ;;
3614 *-*-cygwin* | *-*-mingw*)
3615 noconfigdirs="$noconfigdirs target-libgo"
3616 ;;
91dfef96
JM
3617 bpf-*-*)
3618 noconfigdirs="$noconfigdirs target-libgo"
3619 ;;
cdbc9e92
ILT
3620 esac
3621fi
3622
c03353e2
RIL
3623# Default libgloss CPU subdirectory.
3624libgloss_dir="$target_cpu"
6de9cd9a 3625
fbcf0dca
JM
3626case "${target}" in
3627 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
3628 libgloss_dir=wince
3629 ;;
4dddfc74
YZ
3630 aarch64*-*-* )
3631 libgloss_dir=aarch64
3632 ;;
fbcf0dca
JM
3633 arm*-*-*)
3634 libgloss_dir=arm
3635 ;;
3636 cris-*-* | crisv32-*-*)
3637 libgloss_dir=cris
3638 ;;
3639 hppa*-*-*)
3640 libgloss_dir=pa
3641 ;;
3642 i[3456789]86-*-*)
3643 libgloss_dir=i386
3644 ;;
3645 m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
3646 libgloss_dir=m68hc11
3647 ;;
3648 m68*-*-* | fido-*-*)
3649 libgloss_dir=m68k
3650 ;;
3651 mips*-*-*)
3652 libgloss_dir=mips
3653 ;;
3654 powerpc*-*-*)
3655 libgloss_dir=rs6000
3656 ;;
8d2af3a2
DD
3657 pru-*-*)
3658 libgloss_dir=pru
3659 ;;
fbcf0dca
JM
3660 sparc*-*-*)
3661 libgloss_dir=sparc
3662 ;;
3663esac
3664
6a789d5e 3665# Disable newlib and libgloss for various target OSes.
671aa708 3666case "${target}" in
6a789d5e
JM
3667 alpha*-dec-osf*)
3668 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3669 ;;
3670 i[3456789]86-*-linux*)
3671 # This section makes it possible to build newlib natively on linux.
3672 # If we are using a cross compiler then don't configure newlib.
3673 if test x${is_cross_compiler} != xno ; then
3674 noconfigdirs="$noconfigdirs target-newlib"
3675 fi
3676 noconfigdirs="$noconfigdirs target-libgloss"
3677 # If we are not using a cross compiler, do configure newlib.
3678 # Note however, that newlib will only be configured in this situation
3679 # if the --with-newlib option has been given, because otherwise
3680 # 'target-newlib' will appear in skipdirs.
3681 ;;
3682 i[3456789]86-*-rdos*)
3683 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3684 ;;
3685 sh*-*-pe|mips*-*-pe|arm-wince-pe)
3686 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3687 ;;
3688 sparc-*-sunos4*)
3689 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3690 ;;
91dfef96
JM
3691 bpf-*-*)
3692 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3693 ;;
6a789d5e
JM
3694 *-*-aix*)
3695 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3696 ;;
3697 *-*-beos*)
3698 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3699 ;;
671aa708 3700 *-*-chorusos)
0036370f 3701 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
671aa708 3702 ;;
6a789d5e
JM
3703 *-*-dragonfly*)
3704 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3705 ;;
3706 *-*-freebsd*)
3707 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3708 ;;
3709 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
3710 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3711 ;;
3712 *-*-lynxos*)
3713 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3714 ;;
3715 *-*-mingw*)
3716 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3717 ;;
3718 *-*-netbsd*)
3719 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3720 ;;
3721 *-*-netware*)
3722 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3723 ;;
3724 *-*-tpf*)
3725 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3726 ;;
3727 *-*-uclinux*)
3728 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3729 ;;
3730 *-*-vxworks*)
3731 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3732 ;;
3733esac
3734
3735case "${target}" in
3736 *-*-chorusos)
3737 ;;
3be96231
TG
3738 aarch64-*-darwin*)
3739 noconfigdirs="$noconfigdirs ld gas gdb gprof"
3740 noconfigdirs="$noconfigdirs sim target-rda"
3741 ;;
7431c1a1
AS
3742 amdgcn*-*-*)
3743 ;;
3be96231
TG
3744 arm-*-darwin*)
3745 noconfigdirs="$noconfigdirs ld gas gdb gprof"
3746 noconfigdirs="$noconfigdirs sim target-rda"
3747 ;;
75eeae1a 3748 powerpc-*-darwin*)
e1514c3f 3749 noconfigdirs="$noconfigdirs ld gas gdb gprof"
9c8f9ec2 3750 noconfigdirs="$noconfigdirs sim target-rda"
940cde4d 3751 ;;
354ebf88
RW
3752 i[3456789]86-*-darwin*)
3753 noconfigdirs="$noconfigdirs ld gprof"
3754 noconfigdirs="$noconfigdirs sim target-rda"
3755 ;;
3756 x86_64-*-darwin[912]*)
0db3a858
TG
3757 noconfigdirs="$noconfigdirs ld gas gprof"
3758 noconfigdirs="$noconfigdirs sim target-rda"
3759 ;;
42c1cd8a
AT
3760 *-*-darwin*)
3761 noconfigdirs="$noconfigdirs ld gas gdb gprof"
3762 noconfigdirs="$noconfigdirs sim target-rda"
42c1cd8a 3763 ;;
8c6d158a 3764 *-*-dragonfly*)
8c6d158a 3765 ;;
c3f84f61 3766 *-*-freebsd*)
88252529 3767 if test "x$with_gmp" = x \
c0d0a722 3768 && ! test -d ${srcdir}/gmp \
6de9cd9a
DN
3769 && test -f /usr/local/include/gmp.h; then
3770 with_gmp=/usr/local
3771 fi
6de9cd9a 3772 ;;
ef4e7569
US
3773 *-*-kaos*)
3774 # Remove unsupported stuff on all kaOS configurations.
ef4e7569
US
3775 noconfigdirs="$noconfigdirs target-libgloss"
3776 ;;
671aa708 3777 *-*-netbsd*)
671aa708 3778 ;;
61fec9ff 3779 *-*-netware*)
671aa708 3780 ;;
fd6487af
JS
3781 *-*-phoenix*)
3782 noconfigdirs="$noconfigdirs target-libgloss"
3783 ;;
671aa708 3784 *-*-rtems*)
2909494b 3785 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3786 ;;
a8ba31f2
EC
3787 # The tpf target doesn't support gdb yet.
3788 *-*-tpf*)
6a789d5e 3789 noconfigdirs="$noconfigdirs gdb tcl tk libgui itcl"
a8ba31f2 3790 ;;
5785c0ed 3791 *-*-uclinux*)
6a789d5e 3792 noconfigdirs="$noconfigdirs target-rda"
5785c0ed 3793 ;;
671aa708 3794 *-*-vxworks*)
671aa708
NN
3795 ;;
3796 alpha*-dec-osf*)
3797 # ld works, but does not support shared libraries.
671aa708 3798 # gas doesn't generate exception information.
6a789d5e 3799 noconfigdirs="$noconfigdirs gas ld"
671aa708
NN
3800 ;;
3801 alpha*-*-*vms*)
2909494b 3802 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
671aa708 3803 ;;
671aa708
NN
3804 alpha*-*-*)
3805 # newlib is not 64 bit ready
2909494b 3806 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
671aa708 3807 ;;
91dfef96
JM
3808 bpf-*-*)
3809 noconfigdirs="$noconfigdirs target-libobjc target-libbacktrace"
3810 ;;
671aa708 3811 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
b4f96efe 3812 noconfigdirs="$noconfigdirs tcl tk itcl libgui sim"
671aa708 3813 ;;
2fd88f4f
AK
3814 arc*-*-*)
3815 noconfigdirs="$noconfigdirs sim"
3816 ;;
671aa708 3817 arm-*-pe*)
2909494b 3818 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3819 ;;
671aa708 3820 arm-*-riscix*)
0036370f 3821 noconfigdirs="$noconfigdirs ld target-libgloss"
671aa708 3822 ;;
b588ae30
GJL
3823 avr-*-*)
3824 if test x${with_avrlibc} != xno; then
3825 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3826 fi
3827 ;;
671aa708 3828 c4x-*-* | tic4x-*-*)
0036370f 3829 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3830 ;;
0036370f
JM
3831 tic54x-*-*)
3832 noconfigdirs="$noconfigdirs target-libgloss gdb"
671aa708 3833 ;;
671aa708 3834 d10v-*-*)
0036370f 3835 noconfigdirs="$noconfigdirs target-libgloss"
671aa708
NN
3836 ;;
3837 d30v-*-*)
0036370f 3838 noconfigdirs="$noconfigdirs gdb"
671aa708
NN
3839 ;;
3840 fr30-*-elf*)
2909494b 3841 noconfigdirs="$noconfigdirs gdb"
671aa708 3842 ;;
a05c2c75
L
3843 ft32-*-*)
3844 noconfigdirs="$noconfigdirs target-rda gprof"
3845 ;;
55f2d967 3846 moxie-*-*)
a05c2c75 3847 noconfigdirs="$noconfigdirs"
55f2d967 3848 ;;
671aa708 3849 h8300*-*-*)
2909494b 3850 noconfigdirs="$noconfigdirs target-libgloss"
671aa708
NN
3851 ;;
3852 h8500-*-*)
0036370f 3853 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3854 ;;
ee6a22df 3855 hppa1.1-*-osf* | hppa1.1-*-bsd* )
ee6a22df 3856 ;;
a05c2c75
L
3857 hppa*64*-*-hpux*)
3858 noconfigdirs="$noconfigdirs gdb"
3859 ;;
3860 hppa*-*-hpux11*)
3861 noconfigdirs="$noconfigdirs gdb ld"
3862 ;;
4569f85e 3863 hppa*64*-*-linux*)
671aa708 3864 ;;
56f8587a 3865 hppa*-*-linux*)
3e732ba0 3866 ;;
671aa708 3867 hppa*-*-*elf* | \
671aa708
NN
3868 hppa*-*-lites* | \
3869 hppa*-*-openbsd* | \
3870 hppa*64*-*-*)
671aa708 3871 ;;
c03353e2 3872 hppa*-*-pro*)
c03353e2 3873 ;;
671aa708 3874 hppa*-*-*)
2909494b 3875 noconfigdirs="$noconfigdirs ld"
671aa708 3876 ;;
fb87ad5d 3877 i960-*-*)
0036370f 3878 noconfigdirs="$noconfigdirs gdb"
fb87ad5d 3879 ;;
671aa708
NN
3880 ia64*-*-elf*)
3881 # No gdb support yet.
1bcce263 3882 noconfigdirs="$noconfigdirs readline libgui itcl gdb"
671aa708
NN
3883 ;;
3884 ia64*-**-hpux*)
5a2931d1 3885 # No ld support yet.
a05c2c75 3886 noconfigdirs="$noconfigdirs gdb libgui itcl ld"
671aa708 3887 ;;
52535a64 3888 ia64*-*-*vms*)
091fe9ca
TG
3889 # No ld support yet.
3890 noconfigdirs="$noconfigdirs libgui itcl ld"
52535a64 3891 ;;
ef4c4300 3892 i[3456789]86-w64-mingw*)
ef4c4300
KT
3893 ;;
3894 i[3456789]86-*-mingw*)
b91f0a41 3895 target_configdirs="$target_configdirs target-winsup"
1c710c3c 3896 ;;
671aa708
NN
3897 *-*-cygwin*)
3898 target_configdirs="$target_configdirs target-libtermcap target-winsup"
1bcce263 3899 noconfigdirs="$noconfigdirs target-libgloss"
801e2270 3900 # always build newlib if winsup directory is present.
b91f0a41 3901 if test -d "$srcdir/winsup/cygwin"; then
801e2270 3902 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
ee6a22df 3903 elif test -d "$srcdir/newlib"; then
b91f0a41 3904 echo "Warning: winsup/cygwin is missing so newlib can't be built."
801e2270 3905 fi
1c710c3c 3906 ;;
f2a0e225 3907 i[3456789]86-*-pe)
ebb9f8b0 3908 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3909 ;;
f2a0e225 3910 i[3456789]86-*-sco3.2v5*)
671aa708
NN
3911 # The linker does not yet know about weak symbols in COFF,
3912 # and is not configured to handle mixed ELF and COFF.
0036370f 3913 noconfigdirs="$noconfigdirs ld target-libgloss"
671aa708 3914 ;;
f2a0e225 3915 i[3456789]86-*-sco*)
0036370f 3916 noconfigdirs="$noconfigdirs gprof target-libgloss"
671aa708 3917 ;;
fbdd5d87 3918 i[3456789]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*)
671aa708
NN
3919 noconfigdirs="$noconfigdirs target-libgloss"
3920 ;;
f2a0e225 3921 i[3456789]86-*-sysv4*)
0036370f 3922 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3923 ;;
f2a0e225 3924 i[3456789]86-*-beos*)
6a789d5e 3925 noconfigdirs="$noconfigdirs gdb"
3aa83176 3926 ;;
d1f8db0c 3927 i[3456789]86-*-rdos*)
6a789d5e 3928 noconfigdirs="$noconfigdirs gdb"
c03353e2 3929 ;;
671aa708 3930 mmix-*-*)
2909494b 3931 noconfigdirs="$noconfigdirs gdb"
671aa708 3932 ;;
ab34901f 3933 mt-*-*)
79dd769c
AH
3934 noconfigdirs="$noconfigdirs sim"
3935 ;;
58b40a67
FT
3936 nfp-*-*)
3937 noconfigdirs="$noconfigdirs ld gas gdb gprof sim"
3938 noconfigdirs="$noconfigdirs $target_libraries"
3939 ;;
e6cbe965
SC
3940 pdp11-*-*)
3941 noconfigdirs="$noconfigdirs gdb gprof"
3942 ;;
671aa708
NN
3943 powerpc-*-aix*)
3944 # copied from rs6000-*-* entry
6a789d5e 3945 noconfigdirs="$noconfigdirs gprof"
671aa708 3946 ;;
4569f85e 3947 powerpc*-*-winnt* | powerpc*-*-pe*)
671aa708 3948 target_configdirs="$target_configdirs target-winsup"
0036370f 3949 noconfigdirs="$noconfigdirs gdb tcl tk target-libgloss itcl"
671aa708
NN
3950 # always build newlib.
3951 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
3952 ;;
3953 # This is temporary until we can link against shared libraries
3954 powerpcle-*-solaris*)
0036370f 3955 noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
671aa708
NN
3956 ;;
3957 powerpc-*-beos*)
6a789d5e 3958 noconfigdirs="$noconfigdirs gdb"
671aa708 3959 ;;
671aa708 3960 rs6000-*-lynxos*)
6a789d5e 3961 noconfigdirs="$noconfigdirs gprof"
671aa708
NN
3962 ;;
3963 rs6000-*-aix*)
6a789d5e 3964 noconfigdirs="$noconfigdirs gprof"
671aa708
NN
3965 ;;
3966 rs6000-*-*)
2909494b 3967 noconfigdirs="$noconfigdirs gprof"
671aa708
NN
3968 ;;
3969 m68k-apollo-*)
0036370f 3970 noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss"
671aa708 3971 ;;
ca9fe997 3972 microblaze*)
2909494b 3973 noconfigdirs="$noconfigdirs gprof"
ca9fe997 3974 ;;
d896cc4d 3975 mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
d9dced13
RS
3976 if test x$with_newlib = xyes; then
3977 noconfigdirs="$noconfigdirs gprof"
3978 fi
d9dced13 3979 ;;
671aa708 3980 mips*-*-irix5*)
0036370f 3981 noconfigdirs="$noconfigdirs gprof target-libgloss"
671aa708
NN
3982 ;;
3983 mips*-*-irix6*)
2909494b 3984 noconfigdirs="$noconfigdirs gprof target-libgloss"
671aa708 3985 ;;
671aa708 3986 mips*-*-bsd*)
bc98bcc4 3987 noconfigdirs="$noconfigdirs ld gas gprof target-libgloss"
671aa708 3988 ;;
671aa708 3989 mips*-*-linux*)
671aa708 3990 ;;
bc98bcc4
JBG
3991 mips*-*-ultrix* | mips*-*-osf* | mips*-*-ecoff* | mips*-*-pe* \
3992 | mips*-*-irix* | mips*-*-lnews* | mips*-*-riscos*)
3993 noconfigdirs="$noconfigdirs ld gas gprof"
3994 ;;
671aa708 3995 mips*-*-*)
2909494b 3996 noconfigdirs="$noconfigdirs gprof"
671aa708 3997 ;;
738f2522 3998 nvptx*-*-*)
738f2522
BS
3999 noconfigdirs="$noconfigdirs target-libssp target-libstdc++-v3 target-libobjc"
4000 ;;
bc6d9014 4001 sh-*-*)
ea2002ba
CB
4002 case "${target}" in
4003 sh*-*-elf)
2909494b 4004 ;;
ea2002ba 4005 *)
2909494b 4006 noconfigdirs="$noconfigdirs target-libgloss" ;;
ea2002ba 4007 esac
671aa708 4008 ;;
671aa708 4009 sparc-*-sunos4*)
6a789d5e 4010 if test x${is_cross_compiler} = xno ; then
671aa708
NN
4011 use_gnu_ld=no
4012 fi
4013 ;;
b42f0d7e 4014 tic6x-*-*)
0d557ff8 4015 noconfigdirs="$noconfigdirs sim"
b42f0d7e 4016 ;;
341c653c 4017 tilepro*-*-* | tilegx*-*-*)
db1d217c
WL
4018 noconfigdirs="$noconfigdirs sim"
4019 ;;
671aa708 4020 v810-*-*)
0036370f 4021 noconfigdirs="$noconfigdirs bfd binutils gas gdb ld opcodes target-libgloss"
671aa708
NN
4022 ;;
4023 vax-*-*)
2909494b 4024 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
671aa708 4025 ;;
1fc1d82e
MR
4026 wasm32-*-*)
4027 noconfigdirs="$noconfigdirs ld"
4028 ;;
671aa708 4029esac
79c06341 4030
671aa708
NN
4031# If we aren't building newlib, then don't build libgloss, since libgloss
4032# depends upon some newlib header files.
4033case "${noconfigdirs}" in
4034 *target-libgloss*) ;;
4035 *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
4036esac
4037
671aa708 4038# Work in distributions that contain no compiler tools, like Autoconf.
671aa708
NN
4039host_makefile_frag=/dev/null
4040if test -d ${srcdir}/config ; then
4041case "${host}" in
f2a0e225 4042 i[3456789]86-*-msdosdjgpp*)
671aa708
NN
4043 host_makefile_frag="config/mh-djgpp"
4044 ;;
4045 *-cygwin*)
2a79c47f 4046
5213506e
RW
4047{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if cat works as expected" >&5
4048$as_echo_n "checking to see if cat works as expected... " >&6; }
2a79c47f 4049echo a >cygwin-cat-check
e25a8c82 4050if test `cat cygwin-cat-check` = a ; then
2a79c47f 4051 rm cygwin-cat-check
5213506e
RW
4052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4053$as_echo "yes" >&6; }
2a79c47f
NC
4054else
4055 rm cygwin-cat-check
5213506e
RW
4056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4057$as_echo "no" >&6; }
22e05272 4058 as_fn_error $? "The cat command does not ignore carriage return characters.
2a79c47f
NC
4059 Please either mount the build directory in binary mode or run the following
4060 commands before running any configure script:
4061set -o igncr
4062export SHELLOPTS
5213506e 4063 " "$LINENO" 5
2a79c47f
NC
4064fi
4065
671aa708
NN
4066 host_makefile_frag="config/mh-cygwin"
4067 ;;
c53a18d3 4068 *-mingw*)
1f5a6b84 4069 host_makefile_frag="config/mh-mingw"
95af8923 4070 ;;
cabb9d59 4071 alpha*-linux*)
13be44ed
UB
4072 host_makefile_frag="config/mh-alpha-linux"
4073 ;;
efd41714 4074 hppa*-hp-hpux10*)
efd41714 4075 host_makefile_frag="config/mh-pa-hpux10"
671aa708 4076 ;;
111eeb6e 4077 hppa*-hp-hpux*)
efd41714
PB
4078 host_makefile_frag="config/mh-pa"
4079 ;;
4080 hppa*-*)
4081 host_makefile_frag="config/mh-pa"
4082 ;;
54258e22 4083 i?86-*-darwin[89]* | i?86-*-darwin1[0-7]* | powerpc*-*-darwin*)
d8ed14ce 4084 host_makefile_frag="config/mh-darwin"
be8fff81 4085 ;;
d19bca38
PB
4086 powerpc-*-aix*)
4087 host_makefile_frag="config/mh-ppc-aix"
4088 ;;
4089 rs6000-*-aix*)
4090 host_makefile_frag="config/mh-ppc-aix"
4091 ;;
671aa708
NN
4092esac
4093fi
4094
55ffb5ed 4095if test "${build}" != "${host}" ; then
0999159b
PB
4096 AR_FOR_BUILD=${AR_FOR_BUILD-ar}
4097 AS_FOR_BUILD=${AS_FOR_BUILD-as}
55ffb5ed 4098 CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
c841dc0a 4099 CPP_FOR_BUILD="${CPP_FOR_BUILD-\$(CC_FOR_BUILD) -E}"
0999159b 4100 CXX_FOR_BUILD=${CXX_FOR_BUILD-g++}
3b5e8ee4 4101 DSYMUTIL_FOR_BUILD=${DSYMUTIL_FOR_BUILD-dsymutil}
0999159b 4102 GFORTRAN_FOR_BUILD=${GFORTRAN_FOR_BUILD-gfortran}
632e2a07 4103 GOC_FOR_BUILD=${GOC_FOR_BUILD-gccgo}
b4c522fa 4104 GDC_FOR_BUILD=${GDC_FOR_BUILD-gdc}
0999159b
PB
4105 DLLTOOL_FOR_BUILD=${DLLTOOL_FOR_BUILD-dlltool}
4106 LD_FOR_BUILD=${LD_FOR_BUILD-ld}
4107 NM_FOR_BUILD=${NM_FOR_BUILD-nm}
4108 RANLIB_FOR_BUILD=${RANLIB_FOR_BUILD-ranlib}
4109 WINDRES_FOR_BUILD=${WINDRES_FOR_BUILD-windres}
4110 WINDMC_FOR_BUILD=${WINDMC_FOR_BUILD-windmc}
4111else
4112 AR_FOR_BUILD="\$(AR)"
4113 AS_FOR_BUILD="\$(AS)"
fb0103e5 4114 CC_FOR_BUILD="\$(CC)"
0999159b 4115 CXX_FOR_BUILD="\$(CXX)"
3b5e8ee4 4116 DSYMUTIL_FOR_BUILD="\$(DSYMUTIL)"
0999159b 4117 GFORTRAN_FOR_BUILD="\$(GFORTRAN)"
632e2a07 4118 GOC_FOR_BUILD="\$(GOC)"
b4c522fa 4119 GDC_FOR_BUILD="\$(GDC)"
0999159b
PB
4120 DLLTOOL_FOR_BUILD="\$(DLLTOOL)"
4121 LD_FOR_BUILD="\$(LD)"
4122 NM_FOR_BUILD="\$(NM)"
4123 RANLIB_FOR_BUILD="\$(RANLIB)"
4124 WINDRES_FOR_BUILD="\$(WINDRES)"
4125 WINDMC_FOR_BUILD="\$(WINDMC)"
c3a86da9
DJ
4126fi
4127
4128ac_ext=c
1c710c3c
DJ
4129ac_cpp='$CPP $CPPFLAGS'
4130ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4131ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4132ac_compiler_gnu=$ac_cv_c_compiler_gnu
4133if test -n "$ac_tool_prefix"; then
4134 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4135set dummy ${ac_tool_prefix}gcc; ac_word=$2
5213506e
RW
4136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4137$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4138if ${ac_cv_prog_CC+:} false; then :
5213506e 4139 $as_echo_n "(cached) " >&6
1c710c3c
DJ
4140else
4141 if test -n "$CC"; then
4142 ac_cv_prog_CC="$CC" # Let the user override the test.
4143else
4144as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4145for as_dir in $PATH
4146do
4147 IFS=$as_save_IFS
4148 test -z "$as_dir" && as_dir=.
5213506e 4149 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4150 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4151 ac_cv_prog_CC="${ac_tool_prefix}gcc"
5213506e 4152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4153 break 2
4154 fi
4155done
5213506e
RW
4156 done
4157IFS=$as_save_IFS
1c710c3c
DJ
4158
4159fi
4160fi
4161CC=$ac_cv_prog_CC
4162if test -n "$CC"; then
5213506e
RW
4163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4164$as_echo "$CC" >&6; }
1c710c3c 4165else
5213506e
RW
4166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4167$as_echo "no" >&6; }
1c710c3c
DJ
4168fi
4169
5213506e 4170
1c710c3c
DJ
4171fi
4172if test -z "$ac_cv_prog_CC"; then
4173 ac_ct_CC=$CC
fb0103e5
RG
4174 # Extract the first word of "gcc", so it can be a program name with args.
4175set dummy gcc; ac_word=$2
5213506e
RW
4176{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4177$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4178if ${ac_cv_prog_ac_ct_CC+:} false; then :
5213506e 4179 $as_echo_n "(cached) " >&6
1c710c3c
DJ
4180else
4181 if test -n "$ac_ct_CC"; then
4182 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4183else
4184as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4185for as_dir in $PATH
4186do
4187 IFS=$as_save_IFS
4188 test -z "$as_dir" && as_dir=.
5213506e 4189 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4190 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4191 ac_cv_prog_ac_ct_CC="gcc"
5213506e 4192 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4193 break 2
4194 fi
4195done
5213506e
RW
4196 done
4197IFS=$as_save_IFS
1c710c3c
DJ
4198
4199fi
4200fi
4201ac_ct_CC=$ac_cv_prog_ac_ct_CC
4202if test -n "$ac_ct_CC"; then
5213506e
RW
4203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4204$as_echo "$ac_ct_CC" >&6; }
1c710c3c 4205else
5213506e
RW
4206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4207$as_echo "no" >&6; }
1c710c3c
DJ
4208fi
4209
5213506e
RW
4210 if test "x$ac_ct_CC" = x; then
4211 CC=""
4212 else
4213 case $cross_compiling:$ac_tool_warned in
4214yes:)
4215{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4216$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4217ac_tool_warned=yes ;;
4218esac
4219 CC=$ac_ct_CC
4220 fi
1c710c3c
DJ
4221else
4222 CC="$ac_cv_prog_CC"
4223fi
4224
4225if test -z "$CC"; then
5213506e
RW
4226 if test -n "$ac_tool_prefix"; then
4227 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1c710c3c 4228set dummy ${ac_tool_prefix}cc; ac_word=$2
5213506e
RW
4229{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4230$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4231if ${ac_cv_prog_CC+:} false; then :
5213506e 4232 $as_echo_n "(cached) " >&6
55ffb5ed
NN
4233else
4234 if test -n "$CC"; then
4235 ac_cv_prog_CC="$CC" # Let the user override the test.
4236else
1c710c3c
DJ
4237as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4238for as_dir in $PATH
4239do
4240 IFS=$as_save_IFS
4241 test -z "$as_dir" && as_dir=.
5213506e 4242 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4243 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4244 ac_cv_prog_CC="${ac_tool_prefix}cc"
5213506e 4245 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4246 break 2
4247 fi
4248done
5213506e
RW
4249 done
4250IFS=$as_save_IFS
1c710c3c 4251
0b0dc272 4252fi
0b0dc272 4253fi
1c710c3c 4254CC=$ac_cv_prog_CC
af71363e 4255if test -n "$CC"; then
5213506e
RW
4256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4257$as_echo "$CC" >&6; }
2aeb72e9 4258else
5213506e
RW
4259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4260$as_echo "no" >&6; }
2aeb72e9
DD
4261fi
4262
2aeb72e9 4263
5213506e 4264 fi
1c710c3c 4265fi
55ffb5ed
NN
4266if test -z "$CC"; then
4267 # Extract the first word of "cc", so it can be a program name with args.
4268set dummy cc; ac_word=$2
5213506e
RW
4269{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4270$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4271if ${ac_cv_prog_CC+:} false; then :
5213506e 4272 $as_echo_n "(cached) " >&6
55ffb5ed
NN
4273else
4274 if test -n "$CC"; then
4275 ac_cv_prog_CC="$CC" # Let the user override the test.
4276else
0b0dc272 4277 ac_prog_rejected=no
1c710c3c
DJ
4278as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4279for as_dir in $PATH
4280do
4281 IFS=$as_save_IFS
4282 test -z "$as_dir" && as_dir=.
5213506e 4283 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4284 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c
DJ
4285 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4286 ac_prog_rejected=yes
4287 continue
4288 fi
4289 ac_cv_prog_CC="cc"
5213506e 4290 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4291 break 2
4292 fi
4293done
5213506e
RW
4294 done
4295IFS=$as_save_IFS
1c710c3c 4296
55ffb5ed
NN
4297if test $ac_prog_rejected = yes; then
4298 # We found a bogon in the path, so make sure we never use it.
4299 set dummy $ac_cv_prog_CC
4300 shift
1c710c3c 4301 if test $# != 0; then
55ffb5ed
NN
4302 # We chose a different compiler from the bogus one.
4303 # However, it has the same basename, so the bogon will be chosen
4304 # first if we set CC to just the basename; use the full file name.
4305 shift
1c710c3c 4306 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
55ffb5ed
NN
4307 fi
4308fi
4309fi
4310fi
1c710c3c 4311CC=$ac_cv_prog_CC
55ffb5ed 4312if test -n "$CC"; then
5213506e
RW
4313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4314$as_echo "$CC" >&6; }
55ffb5ed 4315else
5213506e
RW
4316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4317$as_echo "no" >&6; }
55ffb5ed
NN
4318fi
4319
5213506e 4320
1c710c3c
DJ
4321fi
4322if test -z "$CC"; then
4323 if test -n "$ac_tool_prefix"; then
5213506e 4324 for ac_prog in cl.exe
1c710c3c
DJ
4325 do
4326 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4327set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5213506e
RW
4328{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4329$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4330if ${ac_cv_prog_CC+:} false; then :
5213506e 4331 $as_echo_n "(cached) " >&6
55ffb5ed
NN
4332else
4333 if test -n "$CC"; then
4334 ac_cv_prog_CC="$CC" # Let the user override the test.
4335else
1c710c3c
DJ
4336as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4337for as_dir in $PATH
4338do
4339 IFS=$as_save_IFS
4340 test -z "$as_dir" && as_dir=.
5213506e 4341 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4342 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4343 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5213506e 4344 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4345 break 2
4346 fi
4347done
5213506e
RW
4348 done
4349IFS=$as_save_IFS
1c710c3c 4350
55ffb5ed
NN
4351fi
4352fi
1c710c3c 4353CC=$ac_cv_prog_CC
55ffb5ed 4354if test -n "$CC"; then
5213506e
RW
4355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4356$as_echo "$CC" >&6; }
a4b9e93e 4357else
5213506e
RW
4358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4359$as_echo "no" >&6; }
fb0103e5 4360fi
af71363e 4361
5213506e 4362
1c710c3c
DJ
4363 test -n "$CC" && break
4364 done
af71363e 4365fi
1c710c3c
DJ
4366if test -z "$CC"; then
4367 ac_ct_CC=$CC
5213506e 4368 for ac_prog in cl.exe
1c710c3c
DJ
4369do
4370 # Extract the first word of "$ac_prog", so it can be a program name with args.
4371set dummy $ac_prog; ac_word=$2
5213506e
RW
4372{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4373$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4374if ${ac_cv_prog_ac_ct_CC+:} false; then :
5213506e 4375 $as_echo_n "(cached) " >&6
0b0dc272 4376else
1c710c3c
DJ
4377 if test -n "$ac_ct_CC"; then
4378 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
0b0dc272 4379else
1c710c3c
DJ
4380as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4381for as_dir in $PATH
4382do
4383 IFS=$as_save_IFS
4384 test -z "$as_dir" && as_dir=.
5213506e 4385 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4386 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4387 ac_cv_prog_ac_ct_CC="$ac_prog"
5213506e 4388 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4389 break 2
4390 fi
4391done
5213506e
RW
4392 done
4393IFS=$as_save_IFS
1c710c3c 4394
af71363e
AS
4395fi
4396fi
1c710c3c
DJ
4397ac_ct_CC=$ac_cv_prog_ac_ct_CC
4398if test -n "$ac_ct_CC"; then
5213506e
RW
4399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4400$as_echo "$ac_ct_CC" >&6; }
fb0103e5 4401else
5213506e
RW
4402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4403$as_echo "no" >&6; }
af71363e 4404fi
0b0dc272 4405
5213506e 4406
1c710c3c
DJ
4407 test -n "$ac_ct_CC" && break
4408done
4409
5213506e
RW
4410 if test "x$ac_ct_CC" = x; then
4411 CC=""
4412 else
4413 case $cross_compiling:$ac_tool_warned in
4414yes:)
4415{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4416$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4417ac_tool_warned=yes ;;
4418esac
4419 CC=$ac_ct_CC
4420 fi
1c710c3c
DJ
4421fi
4422
4423fi
4424
4425
5213506e
RW
4426test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4427$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4428as_fn_error $? "no acceptable C compiler found in \$PATH
4429See \`config.log' for more details" "$LINENO" 5; }
1c710c3c
DJ
4430
4431# Provide some information about the compiler.
5213506e
RW
4432$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4433set X $ac_compile
4434ac_compiler=$2
4435for ac_option in --version -v -V -qversion; do
4436 { { ac_try="$ac_compiler $ac_option >&5"
4437case "(($ac_try" in
4438 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4439 *) ac_try_echo=$ac_try;;
4440esac
4441eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4442$as_echo "$ac_try_echo"; } >&5
4443 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
1c710c3c 4444 ac_status=$?
5213506e
RW
4445 if test -s conftest.err; then
4446 sed '10a\
4447... rest of stderr output deleted ...
4448 10q' conftest.err >conftest.er1
4449 cat conftest.er1 >&5
5213506e 4450 fi
22e05272 4451 rm -f conftest.er1 conftest.err
5213506e
RW
4452 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4453 test $ac_status = 0; }
4454done
1c710c3c 4455
5213506e 4456cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4457/* end confdefs.h. */
4458
4459int
4460main ()
4461{
4462
4463 ;
4464 return 0;
4465}
4466_ACEOF
4467ac_clean_files_save=$ac_clean_files
22e05272 4468ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
1c710c3c
DJ
4469# Try to create an executable without -o first, disregard a.out.
4470# It will help us diagnose broken compilers, and finding out an intuition
4471# of exeext.
22e05272
JM
4472{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4473$as_echo_n "checking whether the C compiler works... " >&6; }
5213506e
RW
4474ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4475
4476# The possible output files:
4477ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4478
4479ac_rmfiles=
4480for ac_file in $ac_files
4481do
4482 case $ac_file in
4483 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4484 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4485 esac
4486done
4487rm -f $ac_rmfiles
4488
4489if { { ac_try="$ac_link_default"
4490case "(($ac_try" in
4491 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4492 *) ac_try_echo=$ac_try;;
4493esac
4494eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4495$as_echo "$ac_try_echo"; } >&5
4496 (eval "$ac_link_default") 2>&5
1c710c3c 4497 ac_status=$?
5213506e
RW
4498 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4499 test $ac_status = 0; }; then :
4500 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4501# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4502# in a Makefile. We should not override ac_cv_exeext if it was cached,
4503# so that the user can short-circuit this test for compilers unknown to
4504# Autoconf.
4505for ac_file in $ac_files ''
1c710c3c
DJ
4506do
4507 test -f "$ac_file" || continue
4508 case $ac_file in
5213506e 4509 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
1c710c3c
DJ
4510 ;;
4511 [ab].out )
4512 # We found the default executable, but exeext='' is most
4513 # certainly right.
4514 break;;
4515 *.* )
5213506e
RW
4516 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4517 then :; else
4518 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4519 fi
4520 # We set ac_cv_exeext here because the later test for it is not
4521 # safe: cross compilers may not add the suffix if given an `-o'
4522 # argument, so we may need to know it at that point already.
4523 # Even if this section looks crufty: it has the advantage of
4524 # actually working.
1c710c3c
DJ
4525 break;;
4526 * )
4527 break;;
4528 esac
4529done
5213506e
RW
4530test "$ac_cv_exeext" = no && ac_cv_exeext=
4531
1c710c3c 4532else
5213506e
RW
4533 ac_file=''
4534fi
5213506e 4535if test -z "$ac_file"; then :
22e05272
JM
4536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4537$as_echo "no" >&6; }
4538$as_echo "$as_me: failed program was:" >&5
1c710c3c
DJ
4539sed 's/^/| /' conftest.$ac_ext >&5
4540
5213506e
RW
4541{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4542$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4543as_fn_error 77 "C compiler cannot create executables
4544See \`config.log' for more details" "$LINENO" 5; }
4545else
4546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4547$as_echo "yes" >&6; }
1c710c3c 4548fi
22e05272
JM
4549{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4550$as_echo_n "checking for C compiler default output file name... " >&6; }
4551{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4552$as_echo "$ac_file" >&6; }
1c710c3c 4553ac_exeext=$ac_cv_exeext
1c710c3c 4554
22e05272 4555rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
1c710c3c 4556ac_clean_files=$ac_clean_files_save
5213506e
RW
4557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4558$as_echo_n "checking for suffix of executables... " >&6; }
4559if { { ac_try="$ac_link"
4560case "(($ac_try" in
4561 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4562 *) ac_try_echo=$ac_try;;
4563esac
4564eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4565$as_echo "$ac_try_echo"; } >&5
4566 (eval "$ac_link") 2>&5
1c710c3c 4567 ac_status=$?
5213506e
RW
4568 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4569 test $ac_status = 0; }; then :
1c710c3c
DJ
4570 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4571# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4572# work properly (i.e., refer to `conftest.exe'), while it won't with
4573# `rm'.
4574for ac_file in conftest.exe conftest conftest.*; do
4575 test -f "$ac_file" || continue
4576 case $ac_file in
5213506e 4577 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
1c710c3c 4578 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1c710c3c
DJ
4579 break;;
4580 * ) break;;
4581 esac
4582done
af71363e 4583else
5213506e
RW
4584 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4585$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4586as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4587See \`config.log' for more details" "$LINENO" 5; }
1c710c3c 4588fi
22e05272 4589rm -f conftest conftest$ac_cv_exeext
5213506e
RW
4590{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4591$as_echo "$ac_cv_exeext" >&6; }
1c710c3c
DJ
4592
4593rm -f conftest.$ac_ext
4594EXEEXT=$ac_cv_exeext
4595ac_exeext=$EXEEXT
22e05272
JM
4596cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4597/* end confdefs.h. */
4598#include <stdio.h>
4599int
4600main ()
4601{
4602FILE *f = fopen ("conftest.out", "w");
4603 return ferror (f) || fclose (f) != 0;
4604
4605 ;
4606 return 0;
4607}
4608_ACEOF
4609ac_clean_files="$ac_clean_files conftest.out"
4610# Check that the compiler produces executables we can run. If not, either
4611# the compiler is broken, or we cross compile.
4612{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4613$as_echo_n "checking whether we are cross compiling... " >&6; }
4614if test "$cross_compiling" != yes; then
4615 { { ac_try="$ac_link"
4616case "(($ac_try" in
4617 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4618 *) ac_try_echo=$ac_try;;
4619esac
4620eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4621$as_echo "$ac_try_echo"; } >&5
4622 (eval "$ac_link") 2>&5
4623 ac_status=$?
4624 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4625 test $ac_status = 0; }
4626 if { ac_try='./conftest$ac_cv_exeext'
4627 { { case "(($ac_try" in
4628 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4629 *) ac_try_echo=$ac_try;;
4630esac
4631eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4632$as_echo "$ac_try_echo"; } >&5
4633 (eval "$ac_try") 2>&5
4634 ac_status=$?
4635 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4636 test $ac_status = 0; }; }; then
4637 cross_compiling=no
4638 else
4639 if test "$cross_compiling" = maybe; then
4640 cross_compiling=yes
4641 else
4642 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4643$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4644as_fn_error $? "cannot run C compiled programs.
4645If you meant to cross compile, use \`--host'.
4646See \`config.log' for more details" "$LINENO" 5; }
4647 fi
4648 fi
4649fi
4650{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4651$as_echo "$cross_compiling" >&6; }
4652
4653rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4654ac_clean_files=$ac_clean_files_save
5213506e
RW
4655{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4656$as_echo_n "checking for suffix of object files... " >&6; }
22e05272 4657if ${ac_cv_objext+:} false; then :
5213506e 4658 $as_echo_n "(cached) " >&6
1c710c3c 4659else
5213506e 4660 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4661/* end confdefs.h. */
4662
4663int
4664main ()
4665{
4666
4667 ;
4668 return 0;
4669}
4670_ACEOF
4671rm -f conftest.o conftest.obj
5213506e
RW
4672if { { ac_try="$ac_compile"
4673case "(($ac_try" in
4674 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4675 *) ac_try_echo=$ac_try;;
4676esac
4677eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4678$as_echo "$ac_try_echo"; } >&5
4679 (eval "$ac_compile") 2>&5
1c710c3c 4680 ac_status=$?
5213506e
RW
4681 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4682 test $ac_status = 0; }; then :
4683 for ac_file in conftest.o conftest.obj conftest.*; do
4684 test -f "$ac_file" || continue;
1c710c3c 4685 case $ac_file in
5213506e 4686 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
1c710c3c
DJ
4687 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4688 break;;
4689 esac
4690done
4691else
5213506e 4692 $as_echo "$as_me: failed program was:" >&5
1c710c3c
DJ
4693sed 's/^/| /' conftest.$ac_ext >&5
4694
5213506e
RW
4695{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4696$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4697as_fn_error $? "cannot compute suffix of object files: cannot compile
4698See \`config.log' for more details" "$LINENO" 5; }
1c710c3c 4699fi
1c710c3c
DJ
4700rm -f conftest.$ac_cv_objext conftest.$ac_ext
4701fi
5213506e
RW
4702{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4703$as_echo "$ac_cv_objext" >&6; }
1c710c3c
DJ
4704OBJEXT=$ac_cv_objext
4705ac_objext=$OBJEXT
5213506e
RW
4706{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4707$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
22e05272 4708if ${ac_cv_c_compiler_gnu+:} false; then :
5213506e 4709 $as_echo_n "(cached) " >&6
1c710c3c 4710else
5213506e 4711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4712/* end confdefs.h. */
4713
4714int
4715main ()
4716{
4717#ifndef __GNUC__
4718 choke me
4719#endif
4720
4721 ;
4722 return 0;
4723}
4724_ACEOF
5213506e 4725if ac_fn_c_try_compile "$LINENO"; then :
1c710c3c
DJ
4726 ac_compiler_gnu=yes
4727else
5213506e 4728 ac_compiler_gnu=no
1c710c3c 4729fi
5213506e 4730rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1c710c3c
DJ
4731ac_cv_c_compiler_gnu=$ac_compiler_gnu
4732
4733fi
5213506e
RW
4734{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4735$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4736if test $ac_compiler_gnu = yes; then
4737 GCC=yes
4738else
4739 GCC=
4740fi
1c710c3c
DJ
4741ac_test_CFLAGS=${CFLAGS+set}
4742ac_save_CFLAGS=$CFLAGS
5213506e
RW
4743{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4744$as_echo_n "checking whether $CC accepts -g... " >&6; }
22e05272 4745if ${ac_cv_prog_cc_g+:} false; then :
5213506e
RW
4746 $as_echo_n "(cached) " >&6
4747else
4748 ac_save_c_werror_flag=$ac_c_werror_flag
4749 ac_c_werror_flag=yes
4750 ac_cv_prog_cc_g=no
4751 CFLAGS="-g"
4752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4753/* end confdefs.h. */
4754
4755int
4756main ()
4757{
4758
4759 ;
4760 return 0;
4761}
4762_ACEOF
5213506e 4763if ac_fn_c_try_compile "$LINENO"; then :
55ffb5ed
NN
4764 ac_cv_prog_cc_g=yes
4765else
5213506e
RW
4766 CFLAGS=""
4767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4768/* end confdefs.h. */
4769
4770int
4771main ()
4772{
4773
4774 ;
4775 return 0;
4776}
4777_ACEOF
4778if ac_fn_c_try_compile "$LINENO"; then :
4779
4780else
4781 ac_c_werror_flag=$ac_save_c_werror_flag
4782 CFLAGS="-g"
4783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4784/* end confdefs.h. */
af71363e 4785
5213506e
RW
4786int
4787main ()
4788{
4789
4790 ;
4791 return 0;
4792}
4793_ACEOF
4794if ac_fn_c_try_compile "$LINENO"; then :
4795 ac_cv_prog_cc_g=yes
4796fi
4797rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
0b0dc272 4798fi
5213506e 4799rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1c710c3c 4800fi
5213506e
RW
4801rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4802 ac_c_werror_flag=$ac_save_c_werror_flag
4803fi
4804{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4805$as_echo "$ac_cv_prog_cc_g" >&6; }
55ffb5ed 4806if test "$ac_test_CFLAGS" = set; then
1c710c3c 4807 CFLAGS=$ac_save_CFLAGS
55ffb5ed
NN
4808elif test $ac_cv_prog_cc_g = yes; then
4809 if test "$GCC" = yes; then
4810 CFLAGS="-g -O2"
4811 else
4812 CFLAGS="-g"
4813 fi
4814else
4815 if test "$GCC" = yes; then
4816 CFLAGS="-O2"
4817 else
4818 CFLAGS=
4819 fi
4820fi
5213506e
RW
4821{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4822$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
22e05272 4823if ${ac_cv_prog_cc_c89+:} false; then :
5213506e 4824 $as_echo_n "(cached) " >&6
1c710c3c 4825else
5213506e 4826 ac_cv_prog_cc_c89=no
1c710c3c 4827ac_save_CC=$CC
5213506e 4828cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4829/* end confdefs.h. */
4830#include <stdarg.h>
4831#include <stdio.h>
22e05272 4832struct stat;
1c710c3c
DJ
4833/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4834struct buf { int x; };
4835FILE * (*rcsopen) (struct buf *, struct stat *, int);
4836static char *e (p, i)
4837 char **p;
4838 int i;
4839{
4840 return p[i];
4841}
4842static char *f (char * (*g) (char **, int), char **p, ...)
4843{
4844 char *s;
4845 va_list v;
4846 va_start (v,p);
4847 s = g (p, va_arg (v,int));
4848 va_end (v);
4849 return s;
4850}
4851
4852/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4853 function prototypes and stuff, but not '\xHH' hex character constants.
4854 These don't provoke an error unfortunately, instead are silently treated
5213506e 4855 as 'x'. The following induces an error, until -std is added to get
1c710c3c
DJ
4856 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4857 array size at least. It's necessary to write '\x00'==0 to get something
5213506e 4858 that's true only with -std. */
1c710c3c
DJ
4859int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4860
5213506e
RW
4861/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4862 inside strings and character constants. */
4863#define FOO(x) 'x'
4864int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4865
1c710c3c
DJ
4866int test (int i, double x);
4867struct s1 {int (*f) (int a);};
4868struct s2 {int (*f) (double a);};
4869int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4870int argc;
4871char **argv;
4872int
4873main ()
4874{
4875return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4876 ;
4877 return 0;
4878}
4879_ACEOF
5213506e
RW
4880for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4881 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1c710c3c
DJ
4882do
4883 CC="$ac_save_CC $ac_arg"
5213506e
RW
4884 if ac_fn_c_try_compile "$LINENO"; then :
4885 ac_cv_prog_cc_c89=$ac_arg
1c710c3c 4886fi
5213506e
RW
4887rm -f core conftest.err conftest.$ac_objext
4888 test "x$ac_cv_prog_cc_c89" != "xno" && break
1c710c3c 4889done
5213506e 4890rm -f conftest.$ac_ext
1c710c3c
DJ
4891CC=$ac_save_CC
4892
4893fi
5213506e
RW
4894# AC_CACHE_VAL
4895case "x$ac_cv_prog_cc_c89" in
4896 x)
4897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4898$as_echo "none needed" >&6; } ;;
4899 xno)
4900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4901$as_echo "unsupported" >&6; } ;;
1c710c3c 4902 *)
5213506e
RW
4903 CC="$CC $ac_cv_prog_cc_c89"
4904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4905$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
1c710c3c 4906esac
5213506e 4907if test "x$ac_cv_prog_cc_c89" != xno; then :
1c710c3c 4908
2aeb72e9
DD
4909fi
4910
2aeb72e9
DD
4911ac_ext=c
4912ac_cpp='$CPP $CPPFLAGS'
4913ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4914ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4915ac_compiler_gnu=$ac_cv_c_compiler_gnu
4916
91743432
NC
4917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
4918$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
4919if ${ac_cv_prog_cc_c99+:} false; then :
4920 $as_echo_n "(cached) " >&6
4921else
4922 ac_cv_prog_cc_c99=no
4923ac_save_CC=$CC
4924cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4925/* end confdefs.h. */
4926#include <stdarg.h>
4927#include <stdbool.h>
4928#include <stdlib.h>
4929#include <wchar.h>
4930#include <stdio.h>
4931
4932// Check varargs macros. These examples are taken from C99 6.10.3.5.
4933#define debug(...) fprintf (stderr, __VA_ARGS__)
4934#define showlist(...) puts (#__VA_ARGS__)
4935#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4936static void
4937test_varargs_macros (void)
4938{
4939 int x = 1234;
4940 int y = 5678;
4941 debug ("Flag");
4942 debug ("X = %d\n", x);
4943 showlist (The first, second, and third items.);
4944 report (x>y, "x is %d but y is %d", x, y);
4945}
4946
4947// Check long long types.
4948#define BIG64 18446744073709551615ull
4949#define BIG32 4294967295ul
4950#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4951#if !BIG_OK
4952 your preprocessor is broken;
4953#endif
4954#if BIG_OK
4955#else
4956 your preprocessor is broken;
4957#endif
4958static long long int bignum = -9223372036854775807LL;
4959static unsigned long long int ubignum = BIG64;
4960
4961struct incomplete_array
4962{
4963 int datasize;
4964 double data[];
4965};
4966
4967struct named_init {
4968 int number;
4969 const wchar_t *name;
4970 double average;
4971};
4972
4973typedef const char *ccp;
4974
4975static inline int
4976test_restrict (ccp restrict text)
4977{
4978 // See if C++-style comments work.
4979 // Iterate through items via the restricted pointer.
4980 // Also check for declarations in for loops.
4981 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4982 continue;
4983 return 0;
4984}
4985
4986// Check varargs and va_copy.
4987static void
4988test_varargs (const char *format, ...)
4989{
4990 va_list args;
4991 va_start (args, format);
4992 va_list args_copy;
4993 va_copy (args_copy, args);
4994
4995 const char *str;
4996 int number;
4997 float fnumber;
4998
4999 while (*format)
5000 {
5001 switch (*format++)
5002 {
5003 case 's': // string
5004 str = va_arg (args_copy, const char *);
5005 break;
5006 case 'd': // int
5007 number = va_arg (args_copy, int);
5008 break;
5009 case 'f': // float
5010 fnumber = va_arg (args_copy, double);
5011 break;
5012 default:
5013 break;
5014 }
5015 }
5016 va_end (args_copy);
5017 va_end (args);
5018}
5019
5020int
5021main ()
5022{
5023
5024 // Check bool.
5025 _Bool success = false;
5026
5027 // Check restrict.
5028 if (test_restrict ("String literal") == 0)
5029 success = true;
5030 char *restrict newvar = "Another string";
5031
5032 // Check varargs.
5033 test_varargs ("s, d' f .", "string", 65, 34.234);
5034 test_varargs_macros ();
5035
5036 // Check flexible array members.
5037 struct incomplete_array *ia =
5038 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5039 ia->datasize = 10;
5040 for (int i = 0; i < ia->datasize; ++i)
5041 ia->data[i] = i * 1.234;
5042
5043 // Check named initializers.
5044 struct named_init ni = {
5045 .number = 34,
5046 .name = L"Test wide string",
5047 .average = 543.34343,
5048 };
5049
5050 ni.number = 58;
5051
5052 int dynamic_array[ni.number];
5053 dynamic_array[ni.number - 1] = 543;
5054
5055 // work around unused variable warnings
5056 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5057 || dynamic_array[ni.number - 1] != 543);
5058
5059 ;
5060 return 0;
5061}
5062_ACEOF
5063for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
5064do
5065 CC="$ac_save_CC $ac_arg"
5066 if ac_fn_c_try_compile "$LINENO"; then :
5067 ac_cv_prog_cc_c99=$ac_arg
5068fi
5069rm -f core conftest.err conftest.$ac_objext
5070 test "x$ac_cv_prog_cc_c99" != "xno" && break
5071done
5072rm -f conftest.$ac_ext
5073CC=$ac_save_CC
5074
5075fi
5076# AC_CACHE_VAL
5077case "x$ac_cv_prog_cc_c99" in
5078 x)
5079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5080$as_echo "none needed" >&6; } ;;
5081 xno)
5082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5083$as_echo "unsupported" >&6; } ;;
5084 *)
5085 CC="$CC $ac_cv_prog_cc_c99"
5086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5087$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
5088esac
5089if test "x$ac_cv_prog_cc_c99" != xno; then :
5090
5091fi
5092
5093
5213506e 5094ac_ext=cpp
2aeb72e9
DD
5095ac_cpp='$CXXCPP $CPPFLAGS'
5096ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5097ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5098ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5213506e
RW
5099if test -z "$CXX"; then
5100 if test -n "$CCC"; then
5101 CXX=$CCC
5102 else
5103 if test -n "$ac_tool_prefix"; then
5104 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
2aeb72e9
DD
5105 do
5106 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5107set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5213506e
RW
5108{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5109$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5110if ${ac_cv_prog_CXX+:} false; then :
5213506e 5111 $as_echo_n "(cached) " >&6
2aeb72e9
DD
5112else
5113 if test -n "$CXX"; then
5114 ac_cv_prog_CXX="$CXX" # Let the user override the test.
5115else
5116as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5117for as_dir in $PATH
5118do
5119 IFS=$as_save_IFS
5120 test -z "$as_dir" && as_dir=.
5213506e 5121 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2aeb72e9 5123 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
5213506e 5124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2aeb72e9
DD
5125 break 2
5126 fi
5127done
5213506e
RW
5128 done
5129IFS=$as_save_IFS
55ffb5ed 5130
c3a86da9
DJ
5131fi
5132fi
5133CXX=$ac_cv_prog_CXX
5134if test -n "$CXX"; then
5213506e
RW
5135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5136$as_echo "$CXX" >&6; }
c3a86da9 5137else
5213506e
RW
5138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5139$as_echo "no" >&6; }
c3a86da9
DJ
5140fi
5141
5213506e 5142
c3a86da9
DJ
5143 test -n "$CXX" && break
5144 done
5145fi
5146if test -z "$CXX"; then
5147 ac_ct_CXX=$CXX
5213506e 5148 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
c3a86da9
DJ
5149do
5150 # Extract the first word of "$ac_prog", so it can be a program name with args.
5151set dummy $ac_prog; ac_word=$2
5213506e
RW
5152{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5153$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5154if ${ac_cv_prog_ac_ct_CXX+:} false; then :
5213506e 5155 $as_echo_n "(cached) " >&6
c3a86da9
DJ
5156else
5157 if test -n "$ac_ct_CXX"; then
5158 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
5159else
5160as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5161for as_dir in $PATH
5162do
5163 IFS=$as_save_IFS
5164 test -z "$as_dir" && as_dir=.
5213506e 5165 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5166 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
c3a86da9 5167 ac_cv_prog_ac_ct_CXX="$ac_prog"
5213506e 5168 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
c3a86da9
DJ
5169 break 2
5170 fi
5171done
5213506e
RW
5172 done
5173IFS=$as_save_IFS
c3a86da9
DJ
5174
5175fi
5176fi
5177ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
5178if test -n "$ac_ct_CXX"; then
5213506e
RW
5179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
5180$as_echo "$ac_ct_CXX" >&6; }
c3a86da9 5181else
5213506e
RW
5182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5183$as_echo "no" >&6; }
c3a86da9
DJ
5184fi
5185
5213506e 5186
c3a86da9
DJ
5187 test -n "$ac_ct_CXX" && break
5188done
c3a86da9 5189
5213506e
RW
5190 if test "x$ac_ct_CXX" = x; then
5191 CXX="g++"
5192 else
5193 case $cross_compiling:$ac_tool_warned in
5194yes:)
5195{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5196$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5197ac_tool_warned=yes ;;
5198esac
5199 CXX=$ac_ct_CXX
5200 fi
c3a86da9
DJ
5201fi
5202
5213506e
RW
5203 fi
5204fi
c3a86da9 5205# Provide some information about the compiler.
5213506e
RW
5206$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
5207set X $ac_compile
5208ac_compiler=$2
5209for ac_option in --version -v -V -qversion; do
5210 { { ac_try="$ac_compiler $ac_option >&5"
5211case "(($ac_try" in
5212 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5213 *) ac_try_echo=$ac_try;;
5214esac
5215eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5216$as_echo "$ac_try_echo"; } >&5
5217 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
c3a86da9 5218 ac_status=$?
5213506e
RW
5219 if test -s conftest.err; then
5220 sed '10a\
5221... rest of stderr output deleted ...
5222 10q' conftest.err >conftest.er1
5223 cat conftest.er1 >&5
5213506e 5224 fi
22e05272 5225 rm -f conftest.er1 conftest.err
5213506e
RW
5226 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5227 test $ac_status = 0; }
5228done
c3a86da9 5229
5213506e
RW
5230{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
5231$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
22e05272 5232if ${ac_cv_cxx_compiler_gnu+:} false; then :
5213506e 5233 $as_echo_n "(cached) " >&6
c3a86da9 5234else
5213506e 5235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9
DJ
5236/* end confdefs.h. */
5237
5238int
5239main ()
5240{
5241#ifndef __GNUC__
5242 choke me
5243#endif
5244
5245 ;
5246 return 0;
5247}
5248_ACEOF
5213506e 5249if ac_fn_cxx_try_compile "$LINENO"; then :
c3a86da9
DJ
5250 ac_compiler_gnu=yes
5251else
5213506e 5252 ac_compiler_gnu=no
c3a86da9 5253fi
5213506e 5254rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c3a86da9
DJ
5255ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
5256
5257fi
5213506e
RW
5258{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
5259$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
5260if test $ac_compiler_gnu = yes; then
5261 GXX=yes
5262else
5263 GXX=
5264fi
c3a86da9
DJ
5265ac_test_CXXFLAGS=${CXXFLAGS+set}
5266ac_save_CXXFLAGS=$CXXFLAGS
5213506e
RW
5267{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
5268$as_echo_n "checking whether $CXX accepts -g... " >&6; }
22e05272 5269if ${ac_cv_prog_cxx_g+:} false; then :
5213506e
RW
5270 $as_echo_n "(cached) " >&6
5271else
5272 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5273 ac_cxx_werror_flag=yes
5274 ac_cv_prog_cxx_g=no
5275 CXXFLAGS="-g"
5276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9
DJ
5277/* end confdefs.h. */
5278
5279int
5280main ()
5281{
5282
5283 ;
5284 return 0;
5285}
5286_ACEOF
5213506e 5287if ac_fn_cxx_try_compile "$LINENO"; then :
c3a86da9
DJ
5288 ac_cv_prog_cxx_g=yes
5289else
5213506e
RW
5290 CXXFLAGS=""
5291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9 5292/* end confdefs.h. */
5213506e 5293
c3a86da9
DJ
5294int
5295main ()
5296{
5213506e 5297
c3a86da9
DJ
5298 ;
5299 return 0;
5300}
5301_ACEOF
5213506e 5302if ac_fn_cxx_try_compile "$LINENO"; then :
23f6b2f9 5303
5213506e
RW
5304else
5305 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5306 CXXFLAGS="-g"
5307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9 5308/* end confdefs.h. */
5213506e 5309
c3a86da9
DJ
5310int
5311main ()
5312{
5213506e 5313
c3a86da9
DJ
5314 ;
5315 return 0;
5316}
5317_ACEOF
5213506e
RW
5318if ac_fn_cxx_try_compile "$LINENO"; then :
5319 ac_cv_prog_cxx_g=yes
11a67599 5320fi
5213506e
RW
5321rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5322fi
5323rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5324fi
5325rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5326 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5327fi
5328{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
5329$as_echo "$ac_cv_prog_cxx_g" >&6; }
5330if test "$ac_test_CXXFLAGS" = set; then
5331 CXXFLAGS=$ac_save_CXXFLAGS
5332elif test $ac_cv_prog_cxx_g = yes; then
5333 if test "$GXX" = yes; then
5334 CXXFLAGS="-g -O2"
5335 else
5336 CXXFLAGS="-g"
5337 fi
5338else
5339 if test "$GXX" = yes; then
5340 CXXFLAGS="-O2"
5341 else
5342 CXXFLAGS=
5343 fi
c3a86da9 5344fi
c3a86da9
DJ
5345ac_ext=c
5346ac_cpp='$CPP $CPPFLAGS'
5347ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5348ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5349ac_compiler_gnu=$ac_cv_c_compiler_gnu
5350
5351
5352# We must set the default linker to the linker used by gcc for the correct
5353# operation of libtool. If LD is not defined and we are using gcc, try to
5354# set the LD default to the ld used by gcc.
5355if test -z "$LD"; then
5356 if test "$GCC" = yes; then
5357 case $build in
5358 *-*-mingw*)
5359 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
5360 *)
5361 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
5362 esac
5363 case $gcc_prog_ld in
5364 # Accept absolute paths.
5365 [\\/]* | [A-Za-z]:[\\/]*)
5366 LD="$gcc_prog_ld" ;;
5367 esac
5368 fi
23f6b2f9
PB
5369fi
5370
0b21f5d3
EB
5371# Check whether -static-libstdc++ -static-libgcc is supported.
5372have_static_libs=no
5373if test "$GCC" = yes; then
5374 saved_LDFLAGS="$LDFLAGS"
5375
5376 LDFLAGS="$LDFLAGS -static-libstdc++ -static-libgcc"
5377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether g++ accepts -static-libstdc++ -static-libgcc" >&5
5378$as_echo_n "checking whether g++ accepts -static-libstdc++ -static-libgcc... " >&6; }
5379 ac_ext=cpp
5380ac_cpp='$CXXCPP $CPPFLAGS'
5381ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5382ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5383ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5384
5385
5386cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5387/* end confdefs.h. */
0d6414b2
EB
5388
5389#if (__GNUC__ < 4) || (__GNUC__ == 4 && __GNUC_MINOR__ < 5)
5390#error -static-libstdc++ not implemented
5391#endif
0b21f5d3
EB
5392int main() {}
5393_ACEOF
5394if ac_fn_cxx_try_link "$LINENO"; then :
5395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5396$as_echo "yes" >&6; }; have_static_libs=yes
5397else
5398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5399$as_echo "no" >&6; }
5400fi
5401rm -f core conftest.err conftest.$ac_objext \
5402 conftest$ac_exeext conftest.$ac_ext
5403 ac_ext=c
5404ac_cpp='$CPP $CPPFLAGS'
5405ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5406ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5407ac_compiler_gnu=$ac_cv_c_compiler_gnu
5408
5409
5410 LDFLAGS="$saved_LDFLAGS"
5411fi
5412
23f6b2f9
PB
5413
5414
55ffb5ed 5415
1c710c3c
DJ
5416if test -n "$ac_tool_prefix"; then
5417 # Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args.
55ffb5ed 5418set dummy ${ac_tool_prefix}gnatbind; ac_word=$2
5213506e
RW
5419{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5420$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5421if ${ac_cv_prog_GNATBIND+:} false; then :
5213506e 5422 $as_echo_n "(cached) " >&6
55ffb5ed
NN
5423else
5424 if test -n "$GNATBIND"; then
5425 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
5426else
1c710c3c
DJ
5427as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5428for as_dir in $PATH
5429do
5430 IFS=$as_save_IFS
5431 test -z "$as_dir" && as_dir=.
5213506e 5432 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5433 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5434 ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind"
5213506e 5435 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5436 break 2
5437 fi
5438done
5213506e
RW
5439 done
5440IFS=$as_save_IFS
1c710c3c 5441
55ffb5ed
NN
5442fi
5443fi
1c710c3c 5444GNATBIND=$ac_cv_prog_GNATBIND
55ffb5ed 5445if test -n "$GNATBIND"; then
5213506e
RW
5446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATBIND" >&5
5447$as_echo "$GNATBIND" >&6; }
55ffb5ed 5448else
5213506e
RW
5449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5450$as_echo "no" >&6; }
55ffb5ed
NN
5451fi
5452
5213506e 5453
1c710c3c 5454fi
55ffb5ed 5455if test -z "$ac_cv_prog_GNATBIND"; then
1c710c3c 5456 ac_ct_GNATBIND=$GNATBIND
55ffb5ed
NN
5457 # Extract the first word of "gnatbind", so it can be a program name with args.
5458set dummy gnatbind; ac_word=$2
5213506e
RW
5459{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5460$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5461if ${ac_cv_prog_ac_ct_GNATBIND+:} false; then :
5213506e 5462 $as_echo_n "(cached) " >&6
55ffb5ed 5463else
1c710c3c
DJ
5464 if test -n "$ac_ct_GNATBIND"; then
5465 ac_cv_prog_ac_ct_GNATBIND="$ac_ct_GNATBIND" # Let the user override the test.
55ffb5ed 5466else
1c710c3c
DJ
5467as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5468for as_dir in $PATH
5469do
5470 IFS=$as_save_IFS
5471 test -z "$as_dir" && as_dir=.
5213506e 5472 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5473 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5474 ac_cv_prog_ac_ct_GNATBIND="gnatbind"
5213506e 5475 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5476 break 2
5477 fi
5478done
5213506e
RW
5479 done
5480IFS=$as_save_IFS
1c710c3c 5481
55ffb5ed
NN
5482fi
5483fi
1c710c3c
DJ
5484ac_ct_GNATBIND=$ac_cv_prog_ac_ct_GNATBIND
5485if test -n "$ac_ct_GNATBIND"; then
5213506e
RW
5486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATBIND" >&5
5487$as_echo "$ac_ct_GNATBIND" >&6; }
55ffb5ed 5488else
5213506e
RW
5489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5490$as_echo "no" >&6; }
55ffb5ed
NN
5491fi
5492
5213506e
RW
5493 if test "x$ac_ct_GNATBIND" = x; then
5494 GNATBIND="no"
5495 else
5496 case $cross_compiling:$ac_tool_warned in
5497yes:)
5498{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5499$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5500ac_tool_warned=yes ;;
5501esac
5502 GNATBIND=$ac_ct_GNATBIND
5503 fi
55ffb5ed 5504else
1c710c3c 5505 GNATBIND="$ac_cv_prog_GNATBIND"
55ffb5ed
NN
5506fi
5507
1c710c3c
DJ
5508if test -n "$ac_tool_prefix"; then
5509 # Extract the first word of "${ac_tool_prefix}gnatmake", so it can be a program name with args.
5305be7e 5510set dummy ${ac_tool_prefix}gnatmake; ac_word=$2
5213506e
RW
5511{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5512$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5513if ${ac_cv_prog_GNATMAKE+:} false; then :
5213506e 5514 $as_echo_n "(cached) " >&6
5305be7e
RG
5515else
5516 if test -n "$GNATMAKE"; then
5517 ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test.
5518else
1c710c3c
DJ
5519as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5520for as_dir in $PATH
5521do
5522 IFS=$as_save_IFS
5523 test -z "$as_dir" && as_dir=.
5213506e 5524 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5526 ac_cv_prog_GNATMAKE="${ac_tool_prefix}gnatmake"
5213506e 5527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5528 break 2
5529 fi
5530done
5213506e
RW
5531 done
5532IFS=$as_save_IFS
1c710c3c 5533
5305be7e
RG
5534fi
5535fi
1c710c3c 5536GNATMAKE=$ac_cv_prog_GNATMAKE
5305be7e 5537if test -n "$GNATMAKE"; then
5213506e
RW
5538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATMAKE" >&5
5539$as_echo "$GNATMAKE" >&6; }
5305be7e 5540else
5213506e
RW
5541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5542$as_echo "no" >&6; }
5305be7e
RG
5543fi
5544
5213506e 5545
1c710c3c 5546fi
5305be7e 5547if test -z "$ac_cv_prog_GNATMAKE"; then
1c710c3c 5548 ac_ct_GNATMAKE=$GNATMAKE
5305be7e
RG
5549 # Extract the first word of "gnatmake", so it can be a program name with args.
5550set dummy gnatmake; ac_word=$2
5213506e
RW
5551{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5552$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5553if ${ac_cv_prog_ac_ct_GNATMAKE+:} false; then :
5213506e 5554 $as_echo_n "(cached) " >&6
5305be7e 5555else
1c710c3c
DJ
5556 if test -n "$ac_ct_GNATMAKE"; then
5557 ac_cv_prog_ac_ct_GNATMAKE="$ac_ct_GNATMAKE" # Let the user override the test.
5305be7e 5558else
1c710c3c
DJ
5559as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5560for as_dir in $PATH
5561do
5562 IFS=$as_save_IFS
5563 test -z "$as_dir" && as_dir=.
5213506e 5564 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5565 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5566 ac_cv_prog_ac_ct_GNATMAKE="gnatmake"
5213506e 5567 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5568 break 2
5569 fi
5570done
5213506e
RW
5571 done
5572IFS=$as_save_IFS
1c710c3c 5573
5305be7e
RG
5574fi
5575fi
1c710c3c
DJ
5576ac_ct_GNATMAKE=$ac_cv_prog_ac_ct_GNATMAKE
5577if test -n "$ac_ct_GNATMAKE"; then
5213506e
RW
5578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATMAKE" >&5
5579$as_echo "$ac_ct_GNATMAKE" >&6; }
5305be7e 5580else
5213506e
RW
5581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5582$as_echo "no" >&6; }
5305be7e
RG
5583fi
5584
5213506e
RW
5585 if test "x$ac_ct_GNATMAKE" = x; then
5586 GNATMAKE="no"
5587 else
5588 case $cross_compiling:$ac_tool_warned in
5589yes:)
5590{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5591$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5592ac_tool_warned=yes ;;
5593esac
5594 GNATMAKE=$ac_ct_GNATMAKE
5595 fi
5305be7e 5596else
1c710c3c 5597 GNATMAKE="$ac_cv_prog_GNATMAKE"
5305be7e
RG
5598fi
5599
5213506e
RW
5600{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler driver understands Ada" >&5
5601$as_echo_n "checking whether compiler driver understands Ada... " >&6; }
22e05272 5602if ${acx_cv_cc_gcc_supports_ada+:} false; then :
5213506e 5603 $as_echo_n "(cached) " >&6
55ffb5ed
NN
5604else
5605 cat >conftest.adb <<EOF
5606procedure conftest is begin null; end conftest;
5607EOF
5608acx_cv_cc_gcc_supports_ada=no
5609# There is a bug in old released versions of GCC which causes the
5610# driver to exit successfully when the appropriate language module
5611# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
5612# Therefore we must check for the error message as well as an
5613# unsuccessful exit.
1db673ca
RO
5614# Other compilers, like HP Tru64 UNIX cc, exit successfully when
5615# given a .adb file, but produce no object file. So we must check
5616# if an object file was really produced to guard against this.
55ffb5ed 5617errors=`(${CC} -c conftest.adb) 2>&1 || echo failure`
1db673ca 5618if test x"$errors" = x && test -f conftest.$ac_objext; then
55ffb5ed 5619 acx_cv_cc_gcc_supports_ada=yes
55ffb5ed
NN
5620fi
5621rm -f conftest.*
5622fi
5213506e
RW
5623{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_cc_gcc_supports_ada" >&5
5624$as_echo "$acx_cv_cc_gcc_supports_ada" >&6; }
55ffb5ed 5625
7cb62ef1 5626if test "x$GNATBIND" != xno && test "x$GNATMAKE" != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
55ffb5ed
NN
5627 have_gnat=yes
5628else
5629 have_gnat=no
5630fi
5631
5fee5ec3
IB
5632
5633
5634if test -n "$ac_tool_prefix"; then
5635 # Extract the first word of "${ac_tool_prefix}gdc", so it can be a program name with args.
5636set dummy ${ac_tool_prefix}gdc; ac_word=$2
5637{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5638$as_echo_n "checking for $ac_word... " >&6; }
5639if ${ac_cv_prog_GDC+:} false; then :
5640 $as_echo_n "(cached) " >&6
5641else
5642 if test -n "$GDC"; then
5643 ac_cv_prog_GDC="$GDC" # Let the user override the test.
5644else
5645as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5646for as_dir in $PATH
5647do
5648 IFS=$as_save_IFS
5649 test -z "$as_dir" && as_dir=.
5650 for ac_exec_ext in '' $ac_executable_extensions; do
5651 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5652 ac_cv_prog_GDC="${ac_tool_prefix}gdc"
5653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5654 break 2
5655 fi
5656done
5657 done
5658IFS=$as_save_IFS
5659
5660fi
5661fi
5662GDC=$ac_cv_prog_GDC
5663if test -n "$GDC"; then
5664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC" >&5
5665$as_echo "$GDC" >&6; }
5666else
5667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5668$as_echo "no" >&6; }
5669fi
5670
5671
5672fi
5673if test -z "$ac_cv_prog_GDC"; then
5674 ac_ct_GDC=$GDC
5675 # Extract the first word of "gdc", so it can be a program name with args.
5676set dummy gdc; ac_word=$2
5677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5678$as_echo_n "checking for $ac_word... " >&6; }
5679if ${ac_cv_prog_ac_ct_GDC+:} false; then :
5680 $as_echo_n "(cached) " >&6
5681else
5682 if test -n "$ac_ct_GDC"; then
5683 ac_cv_prog_ac_ct_GDC="$ac_ct_GDC" # Let the user override the test.
5684else
5685as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5686for as_dir in $PATH
5687do
5688 IFS=$as_save_IFS
5689 test -z "$as_dir" && as_dir=.
5690 for ac_exec_ext in '' $ac_executable_extensions; do
5691 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5692 ac_cv_prog_ac_ct_GDC="gdc"
5693 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5694 break 2
5695 fi
5696done
5697 done
5698IFS=$as_save_IFS
5699
5700fi
5701fi
5702ac_ct_GDC=$ac_cv_prog_ac_ct_GDC
5703if test -n "$ac_ct_GDC"; then
5704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GDC" >&5
5705$as_echo "$ac_ct_GDC" >&6; }
5706else
5707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5708$as_echo "no" >&6; }
5709fi
5710
5711 if test "x$ac_ct_GDC" = x; then
5712 GDC="no"
5713 else
5714 case $cross_compiling:$ac_tool_warned in
5715yes:)
5716{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5717$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5718ac_tool_warned=yes ;;
5719esac
5720 GDC=$ac_ct_GDC
5721 fi
5722else
5723 GDC="$ac_cv_prog_GDC"
5724fi
5725
7c6ae994
IB
5726{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the D compiler works" >&5
5727$as_echo_n "checking whether the D compiler works... " >&6; }
5728if ${acx_cv_d_compiler_works+:} false; then :
5729 $as_echo_n "(cached) " >&6
5730else
5731 cat >conftest.d <<EOF
5732module conftest; int main() { return 0; }
5733EOF
5734acx_cv_d_compiler_works=no
5fee5ec3 5735if test "x$GDC" != xno; then
7c6ae994
IB
5736 errors=`(${GDC} -c conftest.d) 2>&1 || echo failure`
5737 if test x"$errors" = x && test -f conftest.$ac_objext; then
5738 acx_cv_d_compiler_works=yes
5739 fi
5740 rm -f conftest.*
5741fi
5742fi
5743{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_d_compiler_works" >&5
5744$as_echo "$acx_cv_d_compiler_works" >&6; }
5745if test "x$GDC" != xno && test x$acx_cv_d_compiler_works != xno; then
5fee5ec3
IB
5746 have_gdc=yes
5747else
5748 have_gdc=no
5749fi
5750
5213506e
RW
5751{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to compare bootstrapped objects" >&5
5752$as_echo_n "checking how to compare bootstrapped objects... " >&6; }
22e05272 5753if ${gcc_cv_prog_cmp_skip+:} false; then :
5213506e 5754 $as_echo_n "(cached) " >&6
a76494aa
PB
5755else
5756 echo abfoo >t1
5757 echo cdfoo >t2
b55e6680 5758 gcc_cv_prog_cmp_skip='tail -c +17 $$f1 > tmp-foo1; tail -c +17 $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
6cf1ac42
PB
5759 if cmp t1 t2 2 2 > /dev/null 2>&1; then
5760 if cmp t1 t2 1 1 > /dev/null 2>&1; then
5761 :
5762 else
5763 gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
5764 fi
5765 fi
a76494aa
PB
5766 if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
5767 if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
6cf1ac42 5768 :
a76494aa
PB
5769 else
5770 gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
5771 fi
5772 fi
5773 rm t1 t2
5774
5775fi
5213506e
RW
5776{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_cmp_skip" >&5
5777$as_echo "$gcc_cv_prog_cmp_skip" >&6; }
a76494aa
PB
5778do_compare="$gcc_cv_prog_cmp_skip"
5779
5780
55ffb5ed 5781
ff3ac0f4
ILT
5782# Check whether --enable-bootstrap was given.
5783if test "${enable_bootstrap+set}" = set; then :
5784 enableval=$enable_bootstrap;
5785else
5786 enable_bootstrap=default
5787fi
5788
5789
5790# Issue errors and warnings for invalid/strange bootstrap combinations.
bf03b9ff
ILT
5791if test -r $srcdir/gcc/configure; then
5792 have_compiler=yes
5793else
5794 have_compiler=no
5795fi
ff3ac0f4
ILT
5796
5797case "$have_compiler:$host:$target:$enable_bootstrap" in
5798 *:*:*:no) ;;
5799
5800 # Default behavior. Enable bootstrap if we have a compiler
5801 # and we are in a native configuration.
5802 yes:$build:$build:default)
5803 enable_bootstrap=yes ;;
5804
5805 *:*:*:default)
5806 enable_bootstrap=no ;;
5807
5808 # We have a compiler and we are in a native configuration, bootstrap is ok
5809 yes:$build:$build:yes)
5810 ;;
5811
5812 # Other configurations, but we have a compiler. Assume the user knows
5813 # what he's doing.
5814 yes:*:*:yes)
5815 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: trying to bootstrap a cross compiler" >&5
5816$as_echo "$as_me: WARNING: trying to bootstrap a cross compiler" >&2;}
5817 ;;
5818
5819 # No compiler: if they passed --enable-bootstrap explicitly, fail
5820 no:*:*:yes)
22e05272 5821 as_fn_error $? "cannot bootstrap without a compiler" "$LINENO" 5 ;;
ff3ac0f4
ILT
5822
5823 # Fail if wrong command line
5824 *)
22e05272 5825 as_fn_error $? "invalid option for --enable-bootstrap" "$LINENO" 5
ff3ac0f4
ILT
5826 ;;
5827esac
5828
5329b59a 5829# When bootstrapping with GCC, build stage 1 in C++11 mode to ensure that a
ffac9597
JM
5830# C++11 compiler can still start the bootstrap. Otherwise, if building GCC,
5831# require C++11 (or higher).
46070488 5832if test "$enable_bootstrap:$GXX" = "yes:yes"; then
5329b59a 5833 CXX="$CXX -std=c++11"
ffac9597
JM
5834elif test "$have_compiler" = yes; then
5835 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
5836 ac_ext=cpp
5837ac_cpp='$CXXCPP $CPPFLAGS'
5838ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5839ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5840ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5841 ac_success=no
5842
5843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
5844$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
5845if ${ax_cv_cxx_compile_cxx11+:} false; then :
5846 $as_echo_n "(cached) " >&6
5847else
5848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5849/* end confdefs.h. */
5850
5851
5852// If the compiler admits that it is not ready for C++11, why torture it?
5853// Hopefully, this will speed up the test.
5854
5855#ifndef __cplusplus
5856
5857#error "This is not a C++ compiler"
5858
5859#elif __cplusplus < 201103L
5860
5861#error "This is not a C++11 compiler"
5862
5863#else
5864
5865namespace cxx11
5866{
5867
5868 namespace test_static_assert
5869 {
5870
5871 template <typename T>
5872 struct check
5873 {
5874 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5875 };
5876
5877 }
5878
5879 namespace test_final_override
5880 {
5881
5882 struct Base
5883 {
5884 virtual ~Base() {}
5885 virtual void f() {}
5886 };
5887
5888 struct Derived : public Base
5889 {
5890 virtual ~Derived() override {}
5891 virtual void f() override {}
5892 };
5893
5894 }
5895
5896 namespace test_double_right_angle_brackets
5897 {
5898
5899 template < typename T >
5900 struct check {};
5901
5902 typedef check<void> single_type;
5903 typedef check<check<void>> double_type;
5904 typedef check<check<check<void>>> triple_type;
5905 typedef check<check<check<check<void>>>> quadruple_type;
5906
5907 }
5908
5909 namespace test_decltype
5910 {
5911
5912 int
5913 f()
5914 {
5915 int a = 1;
5916 decltype(a) b = 2;
5917 return a + b;
5918 }
5919
5920 }
5921
5922 namespace test_type_deduction
5923 {
5924
5925 template < typename T1, typename T2 >
5926 struct is_same
5927 {
5928 static const bool value = false;
5929 };
5930
5931 template < typename T >
5932 struct is_same<T, T>
5933 {
5934 static const bool value = true;
5935 };
5936
5937 template < typename T1, typename T2 >
5938 auto
5939 add(T1 a1, T2 a2) -> decltype(a1 + a2)
5940 {
5941 return a1 + a2;
5942 }
5943
5944 int
5945 test(const int c, volatile int v)
5946 {
5947 static_assert(is_same<int, decltype(0)>::value == true, "");
5948 static_assert(is_same<int, decltype(c)>::value == false, "");
5949 static_assert(is_same<int, decltype(v)>::value == false, "");
5950 auto ac = c;
5951 auto av = v;
5952 auto sumi = ac + av + 'x';
5953 auto sumf = ac + av + 1.0;
5954 static_assert(is_same<int, decltype(ac)>::value == true, "");
5955 static_assert(is_same<int, decltype(av)>::value == true, "");
5956 static_assert(is_same<int, decltype(sumi)>::value == true, "");
5957 static_assert(is_same<int, decltype(sumf)>::value == false, "");
5958 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
5959 return (sumf > 0.0) ? sumi : add(c, v);
5960 }
5961
5962 }
5963
5964 namespace test_noexcept
5965 {
5966
5967 int f() { return 0; }
5968 int g() noexcept { return 0; }
5969
5970 static_assert(noexcept(f()) == false, "");
5971 static_assert(noexcept(g()) == true, "");
5972
5973 }
5974
5975 namespace test_constexpr
5976 {
5977
5978 template < typename CharT >
5979 unsigned long constexpr
5980 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
5981 {
5982 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
5983 }
5984
5985 template < typename CharT >
5986 unsigned long constexpr
5987 strlen_c(const CharT *const s) noexcept
5988 {
5989 return strlen_c_r(s, 0UL);
5990 }
5991
5992 static_assert(strlen_c("") == 0UL, "");
5993 static_assert(strlen_c("1") == 1UL, "");
5994 static_assert(strlen_c("example") == 7UL, "");
5995 static_assert(strlen_c("another\0example") == 7UL, "");
5996
5997 }
5998
5999 namespace test_rvalue_references
6000 {
6001
6002 template < int N >
6003 struct answer
6004 {
6005 static constexpr int value = N;
6006 };
6007
6008 answer<1> f(int&) { return answer<1>(); }
6009 answer<2> f(const int&) { return answer<2>(); }
6010 answer<3> f(int&&) { return answer<3>(); }
6011
6012 void
6013 test()
6014 {
6015 int i = 0;
6016 const int c = 0;
6017 static_assert(decltype(f(i))::value == 1, "");
6018 static_assert(decltype(f(c))::value == 2, "");
6019 static_assert(decltype(f(0))::value == 3, "");
6020 }
6021
6022 }
6023
6024 namespace test_uniform_initialization
6025 {
6026
6027 struct test
6028 {
6029 static const int zero {};
6030 static const int one {1};
6031 };
6032
6033 static_assert(test::zero == 0, "");
6034 static_assert(test::one == 1, "");
6035
6036 }
6037
6038 namespace test_lambdas
6039 {
6040
6041 void
6042 test1()
6043 {
6044 auto lambda1 = [](){};
6045 auto lambda2 = lambda1;
6046 lambda1();
6047 lambda2();
6048 }
6049
6050 int
6051 test2()
6052 {
6053 auto a = [](int i, int j){ return i + j; }(1, 2);
6054 auto b = []() -> int { return '0'; }();
6055 auto c = [=](){ return a + b; }();
6056 auto d = [&](){ return c; }();
6057 auto e = [a, &b](int x) mutable {
6058 const auto identity = [](int y){ return y; };
6059 for (auto i = 0; i < a; ++i)
6060 a += b--;
6061 return x + identity(a + b);
6062 }(0);
6063 return a + b + c + d + e;
6064 }
6065
6066 int
6067 test3()
6068 {
6069 const auto nullary = [](){ return 0; };
6070 const auto unary = [](int x){ return x; };
6071 using nullary_t = decltype(nullary);
6072 using unary_t = decltype(unary);
6073 const auto higher1st = [](nullary_t f){ return f(); };
6074 const auto higher2nd = [unary](nullary_t f1){
6075 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6076 };
6077 return higher1st(nullary) + higher2nd(nullary)(unary);
6078 }
6079
6080 }
6081
6082 namespace test_variadic_templates
6083 {
6084
6085 template <int...>
6086 struct sum;
6087
6088 template <int N0, int... N1toN>
6089 struct sum<N0, N1toN...>
6090 {
6091 static constexpr auto value = N0 + sum<N1toN...>::value;
6092 };
6093
6094 template <>
6095 struct sum<>
6096 {
6097 static constexpr auto value = 0;
6098 };
6099
6100 static_assert(sum<>::value == 0, "");
6101 static_assert(sum<1>::value == 1, "");
6102 static_assert(sum<23>::value == 23, "");
6103 static_assert(sum<1, 2>::value == 3, "");
6104 static_assert(sum<5, 5, 11>::value == 21, "");
6105 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6106
6107 }
6108
6109 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6110 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6111 // because of this.
6112 namespace test_template_alias_sfinae
6113 {
6114
6115 struct foo {};
6116
6117 template<typename T>
6118 using member = typename T::member_type;
6119
6120 template<typename T>
6121 void func(...) {}
6122
6123 template<typename T>
6124 void func(member<T>*) {}
6125
6126 void test();
6127
6128 void test() { func<foo>(0); }
6129
6130 }
6131
6132} // namespace cxx11
6133
6134#endif // __cplusplus >= 201103L
6135
6136
6137
6138_ACEOF
6139if ac_fn_cxx_try_compile "$LINENO"; then :
6140 ax_cv_cxx_compile_cxx11=yes
6141else
6142 ax_cv_cxx_compile_cxx11=no
6143fi
6144rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6145fi
6146{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
6147$as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
6148 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
6149 ac_success=yes
6150 fi
6151
6152 if test x$ac_success = xno; then
6153 for alternative in ${ax_cxx_compile_alternatives}; do
6154 switch="-std=gnu++${alternative}"
6155 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
6156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
6157$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
6158if eval \${$cachevar+:} false; then :
6159 $as_echo_n "(cached) " >&6
6160else
6161 ac_save_CXX="$CXX"
6162 CXX="$CXX $switch"
6163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6164/* end confdefs.h. */
6165
6166
6167// If the compiler admits that it is not ready for C++11, why torture it?
6168// Hopefully, this will speed up the test.
6169
6170#ifndef __cplusplus
6171
6172#error "This is not a C++ compiler"
6173
6174#elif __cplusplus < 201103L
6175
6176#error "This is not a C++11 compiler"
6177
6178#else
6179
6180namespace cxx11
6181{
6182
6183 namespace test_static_assert
6184 {
6185
6186 template <typename T>
6187 struct check
6188 {
6189 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6190 };
6191
6192 }
6193
6194 namespace test_final_override
6195 {
6196
6197 struct Base
6198 {
6199 virtual ~Base() {}
6200 virtual void f() {}
6201 };
6202
6203 struct Derived : public Base
6204 {
6205 virtual ~Derived() override {}
6206 virtual void f() override {}
6207 };
6208
6209 }
6210
6211 namespace test_double_right_angle_brackets
6212 {
6213
6214 template < typename T >
6215 struct check {};
6216
6217 typedef check<void> single_type;
6218 typedef check<check<void>> double_type;
6219 typedef check<check<check<void>>> triple_type;
6220 typedef check<check<check<check<void>>>> quadruple_type;
6221
6222 }
6223
6224 namespace test_decltype
6225 {
6226
6227 int
6228 f()
6229 {
6230 int a = 1;
6231 decltype(a) b = 2;
6232 return a + b;
6233 }
6234
6235 }
6236
6237 namespace test_type_deduction
6238 {
6239
6240 template < typename T1, typename T2 >
6241 struct is_same
6242 {
6243 static const bool value = false;
6244 };
6245
6246 template < typename T >
6247 struct is_same<T, T>
6248 {
6249 static const bool value = true;
6250 };
6251
6252 template < typename T1, typename T2 >
6253 auto
6254 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6255 {
6256 return a1 + a2;
6257 }
6258
6259 int
6260 test(const int c, volatile int v)
6261 {
6262 static_assert(is_same<int, decltype(0)>::value == true, "");
6263 static_assert(is_same<int, decltype(c)>::value == false, "");
6264 static_assert(is_same<int, decltype(v)>::value == false, "");
6265 auto ac = c;
6266 auto av = v;
6267 auto sumi = ac + av + 'x';
6268 auto sumf = ac + av + 1.0;
6269 static_assert(is_same<int, decltype(ac)>::value == true, "");
6270 static_assert(is_same<int, decltype(av)>::value == true, "");
6271 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6272 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6273 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6274 return (sumf > 0.0) ? sumi : add(c, v);
6275 }
6276
6277 }
6278
6279 namespace test_noexcept
6280 {
6281
6282 int f() { return 0; }
6283 int g() noexcept { return 0; }
6284
6285 static_assert(noexcept(f()) == false, "");
6286 static_assert(noexcept(g()) == true, "");
6287
6288 }
6289
6290 namespace test_constexpr
6291 {
6292
6293 template < typename CharT >
6294 unsigned long constexpr
6295 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6296 {
6297 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6298 }
6299
6300 template < typename CharT >
6301 unsigned long constexpr
6302 strlen_c(const CharT *const s) noexcept
6303 {
6304 return strlen_c_r(s, 0UL);
6305 }
6306
6307 static_assert(strlen_c("") == 0UL, "");
6308 static_assert(strlen_c("1") == 1UL, "");
6309 static_assert(strlen_c("example") == 7UL, "");
6310 static_assert(strlen_c("another\0example") == 7UL, "");
6311
6312 }
6313
6314 namespace test_rvalue_references
6315 {
6316
6317 template < int N >
6318 struct answer
6319 {
6320 static constexpr int value = N;
6321 };
6322
6323 answer<1> f(int&) { return answer<1>(); }
6324 answer<2> f(const int&) { return answer<2>(); }
6325 answer<3> f(int&&) { return answer<3>(); }
6326
6327 void
6328 test()
6329 {
6330 int i = 0;
6331 const int c = 0;
6332 static_assert(decltype(f(i))::value == 1, "");
6333 static_assert(decltype(f(c))::value == 2, "");
6334 static_assert(decltype(f(0))::value == 3, "");
6335 }
6336
6337 }
6338
6339 namespace test_uniform_initialization
6340 {
6341
6342 struct test
6343 {
6344 static const int zero {};
6345 static const int one {1};
6346 };
6347
6348 static_assert(test::zero == 0, "");
6349 static_assert(test::one == 1, "");
6350
6351 }
6352
6353 namespace test_lambdas
6354 {
6355
6356 void
6357 test1()
6358 {
6359 auto lambda1 = [](){};
6360 auto lambda2 = lambda1;
6361 lambda1();
6362 lambda2();
6363 }
6364
6365 int
6366 test2()
6367 {
6368 auto a = [](int i, int j){ return i + j; }(1, 2);
6369 auto b = []() -> int { return '0'; }();
6370 auto c = [=](){ return a + b; }();
6371 auto d = [&](){ return c; }();
6372 auto e = [a, &b](int x) mutable {
6373 const auto identity = [](int y){ return y; };
6374 for (auto i = 0; i < a; ++i)
6375 a += b--;
6376 return x + identity(a + b);
6377 }(0);
6378 return a + b + c + d + e;
6379 }
6380
6381 int
6382 test3()
6383 {
6384 const auto nullary = [](){ return 0; };
6385 const auto unary = [](int x){ return x; };
6386 using nullary_t = decltype(nullary);
6387 using unary_t = decltype(unary);
6388 const auto higher1st = [](nullary_t f){ return f(); };
6389 const auto higher2nd = [unary](nullary_t f1){
6390 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6391 };
6392 return higher1st(nullary) + higher2nd(nullary)(unary);
6393 }
6394
6395 }
6396
6397 namespace test_variadic_templates
6398 {
6399
6400 template <int...>
6401 struct sum;
6402
6403 template <int N0, int... N1toN>
6404 struct sum<N0, N1toN...>
6405 {
6406 static constexpr auto value = N0 + sum<N1toN...>::value;
6407 };
6408
6409 template <>
6410 struct sum<>
6411 {
6412 static constexpr auto value = 0;
6413 };
6414
6415 static_assert(sum<>::value == 0, "");
6416 static_assert(sum<1>::value == 1, "");
6417 static_assert(sum<23>::value == 23, "");
6418 static_assert(sum<1, 2>::value == 3, "");
6419 static_assert(sum<5, 5, 11>::value == 21, "");
6420 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6421
6422 }
6423
6424 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6425 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6426 // because of this.
6427 namespace test_template_alias_sfinae
6428 {
6429
6430 struct foo {};
6431
6432 template<typename T>
6433 using member = typename T::member_type;
6434
6435 template<typename T>
6436 void func(...) {}
6437
6438 template<typename T>
6439 void func(member<T>*) {}
6440
6441 void test();
6442
6443 void test() { func<foo>(0); }
6444
6445 }
6446
6447} // namespace cxx11
6448
6449#endif // __cplusplus >= 201103L
6450
6451
6452
6453_ACEOF
6454if ac_fn_cxx_try_compile "$LINENO"; then :
6455 eval $cachevar=yes
6456else
6457 eval $cachevar=no
6458fi
6459rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6460 CXX="$ac_save_CXX"
6461fi
6462eval ac_res=\$$cachevar
6463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6464$as_echo "$ac_res" >&6; }
6465 if eval test x\$$cachevar = xyes; then
6466 CXX="$CXX $switch"
6467 if test -n "$CXXCPP" ; then
6468 CXXCPP="$CXXCPP $switch"
6469 fi
6470 ac_success=yes
6471 break
6472 fi
6473 done
6474 fi
6475
6476 if test x$ac_success = xno; then
6477 for alternative in ${ax_cxx_compile_alternatives}; do
6478 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
6479 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
6480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
6481$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
6482if eval \${$cachevar+:} false; then :
6483 $as_echo_n "(cached) " >&6
6484else
6485 ac_save_CXX="$CXX"
6486 CXX="$CXX $switch"
6487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6488/* end confdefs.h. */
6489
6490
6491// If the compiler admits that it is not ready for C++11, why torture it?
6492// Hopefully, this will speed up the test.
6493
6494#ifndef __cplusplus
6495
6496#error "This is not a C++ compiler"
6497
6498#elif __cplusplus < 201103L
6499
6500#error "This is not a C++11 compiler"
6501
6502#else
6503
6504namespace cxx11
6505{
6506
6507 namespace test_static_assert
6508 {
6509
6510 template <typename T>
6511 struct check
6512 {
6513 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6514 };
6515
6516 }
6517
6518 namespace test_final_override
6519 {
6520
6521 struct Base
6522 {
6523 virtual ~Base() {}
6524 virtual void f() {}
6525 };
6526
6527 struct Derived : public Base
6528 {
6529 virtual ~Derived() override {}
6530 virtual void f() override {}
6531 };
6532
6533 }
6534
6535 namespace test_double_right_angle_brackets
6536 {
6537
6538 template < typename T >
6539 struct check {};
6540
6541 typedef check<void> single_type;
6542 typedef check<check<void>> double_type;
6543 typedef check<check<check<void>>> triple_type;
6544 typedef check<check<check<check<void>>>> quadruple_type;
6545
6546 }
6547
6548 namespace test_decltype
6549 {
6550
6551 int
6552 f()
6553 {
6554 int a = 1;
6555 decltype(a) b = 2;
6556 return a + b;
6557 }
6558
6559 }
6560
6561 namespace test_type_deduction
6562 {
6563
6564 template < typename T1, typename T2 >
6565 struct is_same
6566 {
6567 static const bool value = false;
6568 };
6569
6570 template < typename T >
6571 struct is_same<T, T>
6572 {
6573 static const bool value = true;
6574 };
6575
6576 template < typename T1, typename T2 >
6577 auto
6578 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6579 {
6580 return a1 + a2;
6581 }
6582
6583 int
6584 test(const int c, volatile int v)
6585 {
6586 static_assert(is_same<int, decltype(0)>::value == true, "");
6587 static_assert(is_same<int, decltype(c)>::value == false, "");
6588 static_assert(is_same<int, decltype(v)>::value == false, "");
6589 auto ac = c;
6590 auto av = v;
6591 auto sumi = ac + av + 'x';
6592 auto sumf = ac + av + 1.0;
6593 static_assert(is_same<int, decltype(ac)>::value == true, "");
6594 static_assert(is_same<int, decltype(av)>::value == true, "");
6595 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6596 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6597 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6598 return (sumf > 0.0) ? sumi : add(c, v);
6599 }
6600
6601 }
6602
6603 namespace test_noexcept
6604 {
6605
6606 int f() { return 0; }
6607 int g() noexcept { return 0; }
6608
6609 static_assert(noexcept(f()) == false, "");
6610 static_assert(noexcept(g()) == true, "");
6611
6612 }
6613
6614 namespace test_constexpr
6615 {
6616
6617 template < typename CharT >
6618 unsigned long constexpr
6619 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6620 {
6621 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6622 }
6623
6624 template < typename CharT >
6625 unsigned long constexpr
6626 strlen_c(const CharT *const s) noexcept
6627 {
6628 return strlen_c_r(s, 0UL);
6629 }
6630
6631 static_assert(strlen_c("") == 0UL, "");
6632 static_assert(strlen_c("1") == 1UL, "");
6633 static_assert(strlen_c("example") == 7UL, "");
6634 static_assert(strlen_c("another\0example") == 7UL, "");
6635
6636 }
6637
6638 namespace test_rvalue_references
6639 {
6640
6641 template < int N >
6642 struct answer
6643 {
6644 static constexpr int value = N;
6645 };
6646
6647 answer<1> f(int&) { return answer<1>(); }
6648 answer<2> f(const int&) { return answer<2>(); }
6649 answer<3> f(int&&) { return answer<3>(); }
6650
6651 void
6652 test()
6653 {
6654 int i = 0;
6655 const int c = 0;
6656 static_assert(decltype(f(i))::value == 1, "");
6657 static_assert(decltype(f(c))::value == 2, "");
6658 static_assert(decltype(f(0))::value == 3, "");
6659 }
6660
6661 }
6662
6663 namespace test_uniform_initialization
6664 {
6665
6666 struct test
6667 {
6668 static const int zero {};
6669 static const int one {1};
6670 };
6671
6672 static_assert(test::zero == 0, "");
6673 static_assert(test::one == 1, "");
6674
6675 }
6676
6677 namespace test_lambdas
6678 {
6679
6680 void
6681 test1()
6682 {
6683 auto lambda1 = [](){};
6684 auto lambda2 = lambda1;
6685 lambda1();
6686 lambda2();
6687 }
6688
6689 int
6690 test2()
6691 {
6692 auto a = [](int i, int j){ return i + j; }(1, 2);
6693 auto b = []() -> int { return '0'; }();
6694 auto c = [=](){ return a + b; }();
6695 auto d = [&](){ return c; }();
6696 auto e = [a, &b](int x) mutable {
6697 const auto identity = [](int y){ return y; };
6698 for (auto i = 0; i < a; ++i)
6699 a += b--;
6700 return x + identity(a + b);
6701 }(0);
6702 return a + b + c + d + e;
6703 }
6704
6705 int
6706 test3()
6707 {
6708 const auto nullary = [](){ return 0; };
6709 const auto unary = [](int x){ return x; };
6710 using nullary_t = decltype(nullary);
6711 using unary_t = decltype(unary);
6712 const auto higher1st = [](nullary_t f){ return f(); };
6713 const auto higher2nd = [unary](nullary_t f1){
6714 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6715 };
6716 return higher1st(nullary) + higher2nd(nullary)(unary);
6717 }
6718
6719 }
6720
6721 namespace test_variadic_templates
6722 {
6723
6724 template <int...>
6725 struct sum;
6726
6727 template <int N0, int... N1toN>
6728 struct sum<N0, N1toN...>
6729 {
6730 static constexpr auto value = N0 + sum<N1toN...>::value;
6731 };
6732
6733 template <>
6734 struct sum<>
6735 {
6736 static constexpr auto value = 0;
6737 };
6738
6739 static_assert(sum<>::value == 0, "");
6740 static_assert(sum<1>::value == 1, "");
6741 static_assert(sum<23>::value == 23, "");
6742 static_assert(sum<1, 2>::value == 3, "");
6743 static_assert(sum<5, 5, 11>::value == 21, "");
6744 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6745
6746 }
6747
6748 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6749 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6750 // because of this.
6751 namespace test_template_alias_sfinae
6752 {
6753
6754 struct foo {};
6755
6756 template<typename T>
6757 using member = typename T::member_type;
6758
6759 template<typename T>
6760 void func(...) {}
6761
6762 template<typename T>
6763 void func(member<T>*) {}
6764
6765 void test();
6766
6767 void test() { func<foo>(0); }
6768
6769 }
6770
6771} // namespace cxx11
6772
6773#endif // __cplusplus >= 201103L
6774
6775
6776
6777_ACEOF
6778if ac_fn_cxx_try_compile "$LINENO"; then :
6779 eval $cachevar=yes
6780else
6781 eval $cachevar=no
6782fi
6783rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6784 CXX="$ac_save_CXX"
6785fi
6786eval ac_res=\$$cachevar
6787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6788$as_echo "$ac_res" >&6; }
6789 if eval test x\$$cachevar = xyes; then
6790 CXX="$CXX $switch"
6791 if test -n "$CXXCPP" ; then
6792 CXXCPP="$CXXCPP $switch"
6793 fi
6794 ac_success=yes
6795 break
6796 fi
6797 done
6798 if test x$ac_success = xyes; then
6799 break
6800 fi
6801 done
6802 fi
7ffcf5d6 6803
ffac9597
JM
6804 ac_ext=c
6805ac_cpp='$CPP $CPPFLAGS'
6806ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6807ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6808ac_compiler_gnu=$ac_cv_c_compiler_gnu
6809
6810 if test x$ax_cxx_compile_cxx11_required = xtrue; then
6811 if test x$ac_success = xno; then
6812 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
6813 fi
6814 fi
6815 if test x$ac_success = xno; then
6816 HAVE_CXX11=0
6817 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
6818$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
6819 else
6820 HAVE_CXX11=1
6821
6822$as_echo "#define HAVE_CXX11 1" >>confdefs.h
6823
6824 fi
6825
6826
7ffcf5d6
TB
6827
6828 if test "${build}" != "${host}"; then
6829 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
6830 ac_ext=cpp
6831ac_cpp='$CXXCPP $CPPFLAGS'
6832ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6833ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6834ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6835 ac_success=no
6836 ax_cv_cxx_compile_cxx11_orig_cxx="$CXX"
6837 ax_cv_cxx_compile_cxx11_orig_cxxflags="$CXXFLAGS"
6838 ax_cv_cxx_compile_cxx11_orig_cppflags="$CPPFLAGS"
6839 CXX="$CXX_FOR_BUILD"
6840 CXXFLAGS="$CXXFLAGS_FOR_BUILD"
6841 CPPFLAGS="$CPPFLAGS_FOR_BUILD"
6842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
6843$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
6844if ${ax_cv_cxx_compile_cxx11_FOR_BUILD+:} false; then :
6845 $as_echo_n "(cached) " >&6
6846else
6847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6848/* end confdefs.h. */
6849
6850
6851// If the compiler admits that it is not ready for C++11, why torture it?
6852// Hopefully, this will speed up the test.
6853
6854#ifndef __cplusplus
6855
6856#error "This is not a C++ compiler"
6857
6858#elif __cplusplus < 201103L
6859
6860#error "This is not a C++11 compiler"
6861
6862#else
6863
6864namespace cxx11
6865{
6866
6867 namespace test_static_assert
6868 {
6869
6870 template <typename T>
6871 struct check
6872 {
6873 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6874 };
6875
6876 }
6877
6878 namespace test_final_override
6879 {
6880
6881 struct Base
6882 {
6883 virtual ~Base() {}
6884 virtual void f() {}
6885 };
6886
6887 struct Derived : public Base
6888 {
6889 virtual ~Derived() override {}
6890 virtual void f() override {}
6891 };
6892
6893 }
6894
6895 namespace test_double_right_angle_brackets
6896 {
6897
6898 template < typename T >
6899 struct check {};
6900
6901 typedef check<void> single_type;
6902 typedef check<check<void>> double_type;
6903 typedef check<check<check<void>>> triple_type;
6904 typedef check<check<check<check<void>>>> quadruple_type;
6905
6906 }
6907
6908 namespace test_decltype
6909 {
6910
6911 int
6912 f()
6913 {
6914 int a = 1;
6915 decltype(a) b = 2;
6916 return a + b;
6917 }
6918
6919 }
6920
6921 namespace test_type_deduction
6922 {
6923
6924 template < typename T1, typename T2 >
6925 struct is_same
6926 {
6927 static const bool value = false;
6928 };
6929
6930 template < typename T >
6931 struct is_same<T, T>
6932 {
6933 static const bool value = true;
6934 };
6935
6936 template < typename T1, typename T2 >
6937 auto
6938 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6939 {
6940 return a1 + a2;
6941 }
6942
6943 int
6944 test(const int c, volatile int v)
6945 {
6946 static_assert(is_same<int, decltype(0)>::value == true, "");
6947 static_assert(is_same<int, decltype(c)>::value == false, "");
6948 static_assert(is_same<int, decltype(v)>::value == false, "");
6949 auto ac = c;
6950 auto av = v;
6951 auto sumi = ac + av + 'x';
6952 auto sumf = ac + av + 1.0;
6953 static_assert(is_same<int, decltype(ac)>::value == true, "");
6954 static_assert(is_same<int, decltype(av)>::value == true, "");
6955 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6956 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6957 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6958 return (sumf > 0.0) ? sumi : add(c, v);
6959 }
6960
6961 }
6962
6963 namespace test_noexcept
6964 {
6965
6966 int f() { return 0; }
6967 int g() noexcept { return 0; }
6968
6969 static_assert(noexcept(f()) == false, "");
6970 static_assert(noexcept(g()) == true, "");
6971
6972 }
6973
6974 namespace test_constexpr
6975 {
6976
6977 template < typename CharT >
6978 unsigned long constexpr
6979 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6980 {
6981 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6982 }
6983
6984 template < typename CharT >
6985 unsigned long constexpr
6986 strlen_c(const CharT *const s) noexcept
6987 {
6988 return strlen_c_r(s, 0UL);
6989 }
6990
6991 static_assert(strlen_c("") == 0UL, "");
6992 static_assert(strlen_c("1") == 1UL, "");
6993 static_assert(strlen_c("example") == 7UL, "");
6994 static_assert(strlen_c("another\0example") == 7UL, "");
6995
6996 }
6997
6998 namespace test_rvalue_references
6999 {
7000
7001 template < int N >
7002 struct answer
7003 {
7004 static constexpr int value = N;
7005 };
7006
7007 answer<1> f(int&) { return answer<1>(); }
7008 answer<2> f(const int&) { return answer<2>(); }
7009 answer<3> f(int&&) { return answer<3>(); }
7010
7011 void
7012 test()
7013 {
7014 int i = 0;
7015 const int c = 0;
7016 static_assert(decltype(f(i))::value == 1, "");
7017 static_assert(decltype(f(c))::value == 2, "");
7018 static_assert(decltype(f(0))::value == 3, "");
7019 }
7020
7021 }
7022
7023 namespace test_uniform_initialization
7024 {
7025
7026 struct test
7027 {
7028 static const int zero {};
7029 static const int one {1};
7030 };
7031
7032 static_assert(test::zero == 0, "");
7033 static_assert(test::one == 1, "");
7034
7035 }
7036
7037 namespace test_lambdas
7038 {
7039
7040 void
7041 test1()
7042 {
7043 auto lambda1 = [](){};
7044 auto lambda2 = lambda1;
7045 lambda1();
7046 lambda2();
7047 }
7048
7049 int
7050 test2()
7051 {
7052 auto a = [](int i, int j){ return i + j; }(1, 2);
7053 auto b = []() -> int { return '0'; }();
7054 auto c = [=](){ return a + b; }();
7055 auto d = [&](){ return c; }();
7056 auto e = [a, &b](int x) mutable {
7057 const auto identity = [](int y){ return y; };
7058 for (auto i = 0; i < a; ++i)
7059 a += b--;
7060 return x + identity(a + b);
7061 }(0);
7062 return a + b + c + d + e;
7063 }
7064
7065 int
7066 test3()
7067 {
7068 const auto nullary = [](){ return 0; };
7069 const auto unary = [](int x){ return x; };
7070 using nullary_t = decltype(nullary);
7071 using unary_t = decltype(unary);
7072 const auto higher1st = [](nullary_t f){ return f(); };
7073 const auto higher2nd = [unary](nullary_t f1){
7074 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
7075 };
7076 return higher1st(nullary) + higher2nd(nullary)(unary);
7077 }
7078
7079 }
7080
7081 namespace test_variadic_templates
7082 {
7083
7084 template <int...>
7085 struct sum;
7086
7087 template <int N0, int... N1toN>
7088 struct sum<N0, N1toN...>
7089 {
7090 static constexpr auto value = N0 + sum<N1toN...>::value;
7091 };
7092
7093 template <>
7094 struct sum<>
7095 {
7096 static constexpr auto value = 0;
7097 };
7098
7099 static_assert(sum<>::value == 0, "");
7100 static_assert(sum<1>::value == 1, "");
7101 static_assert(sum<23>::value == 23, "");
7102 static_assert(sum<1, 2>::value == 3, "");
7103 static_assert(sum<5, 5, 11>::value == 21, "");
7104 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
7105
7106 }
7107
7108 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
7109 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
7110 // because of this.
7111 namespace test_template_alias_sfinae
7112 {
7113
7114 struct foo {};
7115
7116 template<typename T>
7117 using member = typename T::member_type;
7118
7119 template<typename T>
7120 void func(...) {}
7121
7122 template<typename T>
7123 void func(member<T>*) {}
7124
7125 void test();
7126
7127 void test() { func<foo>(0); }
7128
7129 }
7130
7131} // namespace cxx11
7132
7133#endif // __cplusplus >= 201103L
7134
7135
7136
7137_ACEOF
7138if ac_fn_cxx_try_compile "$LINENO"; then :
7139 ax_cv_cxx_compile_cxx11_FOR_BUILD=yes
7140else
7141 ax_cv_cxx_compile_cxx11_FOR_BUILD=no
7142fi
7143rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7144fi
7145{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11_FOR_BUILD" >&5
7146$as_echo "$ax_cv_cxx_compile_cxx11_FOR_BUILD" >&6; }
7147 if test x$ax_cv_cxx_compile_cxx11_FOR_BUILD = xyes; then
7148 ac_success=yes
7149 fi
7150
7151 if test x$ac_success = xno; then
7152 for alternative in ${ax_cxx_compile_alternatives}; do
7153 switch="-std=gnu++${alternative}"
7154 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_FOR_BUILD_$switch" | $as_tr_sh`
7155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
7156$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
7157if eval \${$cachevar+:} false; then :
7158 $as_echo_n "(cached) " >&6
7159else
7160 ac_save_CXX="$CXX"
7161 CXX="$CXX $switch"
7162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7163/* end confdefs.h. */
7164
7165
7166// If the compiler admits that it is not ready for C++11, why torture it?
7167// Hopefully, this will speed up the test.
7168
7169#ifndef __cplusplus
7170
7171#error "This is not a C++ compiler"
7172
7173#elif __cplusplus < 201103L
7174
7175#error "This is not a C++11 compiler"
7176
7177#else
7178
7179namespace cxx11
7180{
7181
7182 namespace test_static_assert
7183 {
7184
7185 template <typename T>
7186 struct check
7187 {
7188 static_assert(sizeof(int) <= sizeof(T), "not big enough");
7189 };
7190
7191 }
7192
7193 namespace test_final_override
7194 {
7195
7196 struct Base
7197 {
7198 virtual ~Base() {}
7199 virtual void f() {}
7200 };
7201
7202 struct Derived : public Base
7203 {
7204 virtual ~Derived() override {}
7205 virtual void f() override {}
7206 };
7207
7208 }
7209
7210 namespace test_double_right_angle_brackets
7211 {
7212
7213 template < typename T >
7214 struct check {};
7215
7216 typedef check<void> single_type;
7217 typedef check<check<void>> double_type;
7218 typedef check<check<check<void>>> triple_type;
7219 typedef check<check<check<check<void>>>> quadruple_type;
7220
7221 }
7222
7223 namespace test_decltype
7224 {
7225
7226 int
7227 f()
7228 {
7229 int a = 1;
7230 decltype(a) b = 2;
7231 return a + b;
7232 }
7233
7234 }
7235
7236 namespace test_type_deduction
7237 {
7238
7239 template < typename T1, typename T2 >
7240 struct is_same
7241 {
7242 static const bool value = false;
7243 };
7244
7245 template < typename T >
7246 struct is_same<T, T>
7247 {
7248 static const bool value = true;
7249 };
7250
7251 template < typename T1, typename T2 >
7252 auto
7253 add(T1 a1, T2 a2) -> decltype(a1 + a2)
7254 {
7255 return a1 + a2;
7256 }
7257
7258 int
7259 test(const int c, volatile int v)
7260 {
7261 static_assert(is_same<int, decltype(0)>::value == true, "");
7262 static_assert(is_same<int, decltype(c)>::value == false, "");
7263 static_assert(is_same<int, decltype(v)>::value == false, "");
7264 auto ac = c;
7265 auto av = v;
7266 auto sumi = ac + av + 'x';
7267 auto sumf = ac + av + 1.0;
7268 static_assert(is_same<int, decltype(ac)>::value == true, "");
7269 static_assert(is_same<int, decltype(av)>::value == true, "");
7270 static_assert(is_same<int, decltype(sumi)>::value == true, "");
7271 static_assert(is_same<int, decltype(sumf)>::value == false, "");
7272 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
7273 return (sumf > 0.0) ? sumi : add(c, v);
7274 }
7275
7276 }
7277
7278 namespace test_noexcept
7279 {
7280
7281 int f() { return 0; }
7282 int g() noexcept { return 0; }
7283
7284 static_assert(noexcept(f()) == false, "");
7285 static_assert(noexcept(g()) == true, "");
7286
7287 }
7288
7289 namespace test_constexpr
7290 {
7291
7292 template < typename CharT >
7293 unsigned long constexpr
7294 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
7295 {
7296 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
7297 }
7298
7299 template < typename CharT >
7300 unsigned long constexpr
7301 strlen_c(const CharT *const s) noexcept
7302 {
7303 return strlen_c_r(s, 0UL);
7304 }
7305
7306 static_assert(strlen_c("") == 0UL, "");
7307 static_assert(strlen_c("1") == 1UL, "");
7308 static_assert(strlen_c("example") == 7UL, "");
7309 static_assert(strlen_c("another\0example") == 7UL, "");
7310
7311 }
7312
7313 namespace test_rvalue_references
7314 {
7315
7316 template < int N >
7317 struct answer
7318 {
7319 static constexpr int value = N;
7320 };
7321
7322 answer<1> f(int&) { return answer<1>(); }
7323 answer<2> f(const int&) { return answer<2>(); }
7324 answer<3> f(int&&) { return answer<3>(); }
7325
7326 void
7327 test()
7328 {
7329 int i = 0;
7330 const int c = 0;
7331 static_assert(decltype(f(i))::value == 1, "");
7332 static_assert(decltype(f(c))::value == 2, "");
7333 static_assert(decltype(f(0))::value == 3, "");
7334 }
7335
7336 }
7337
7338 namespace test_uniform_initialization
7339 {
7340
7341 struct test
7342 {
7343 static const int zero {};
7344 static const int one {1};
7345 };
7346
7347 static_assert(test::zero == 0, "");
7348 static_assert(test::one == 1, "");
7349
7350 }
7351
7352 namespace test_lambdas
7353 {
7354
7355 void
7356 test1()
7357 {
7358 auto lambda1 = [](){};
7359 auto lambda2 = lambda1;
7360 lambda1();
7361 lambda2();
7362 }
7363
7364 int
7365 test2()
7366 {
7367 auto a = [](int i, int j){ return i + j; }(1, 2);
7368 auto b = []() -> int { return '0'; }();
7369 auto c = [=](){ return a + b; }();
7370 auto d = [&](){ return c; }();
7371 auto e = [a, &b](int x) mutable {
7372 const auto identity = [](int y){ return y; };
7373 for (auto i = 0; i < a; ++i)
7374 a += b--;
7375 return x + identity(a + b);
7376 }(0);
7377 return a + b + c + d + e;
7378 }
7379
7380 int
7381 test3()
7382 {
7383 const auto nullary = [](){ return 0; };
7384 const auto unary = [](int x){ return x; };
7385 using nullary_t = decltype(nullary);
7386 using unary_t = decltype(unary);
7387 const auto higher1st = [](nullary_t f){ return f(); };
7388 const auto higher2nd = [unary](nullary_t f1){
7389 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
7390 };
7391 return higher1st(nullary) + higher2nd(nullary)(unary);
7392 }
7393
7394 }
7395
7396 namespace test_variadic_templates
7397 {
7398
7399 template <int...>
7400 struct sum;
7401
7402 template <int N0, int... N1toN>
7403 struct sum<N0, N1toN...>
7404 {
7405 static constexpr auto value = N0 + sum<N1toN...>::value;
7406 };
7407
7408 template <>
7409 struct sum<>
7410 {
7411 static constexpr auto value = 0;
7412 };
7413
7414 static_assert(sum<>::value == 0, "");
7415 static_assert(sum<1>::value == 1, "");
7416 static_assert(sum<23>::value == 23, "");
7417 static_assert(sum<1, 2>::value == 3, "");
7418 static_assert(sum<5, 5, 11>::value == 21, "");
7419 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
7420
7421 }
7422
7423 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
7424 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
7425 // because of this.
7426 namespace test_template_alias_sfinae
7427 {
7428
7429 struct foo {};
7430
7431 template<typename T>
7432 using member = typename T::member_type;
7433
7434 template<typename T>
7435 void func(...) {}
7436
7437 template<typename T>
7438 void func(member<T>*) {}
7439
7440 void test();
7441
7442 void test() { func<foo>(0); }
7443
7444 }
7445
7446} // namespace cxx11
7447
7448#endif // __cplusplus >= 201103L
7449
7450
7451
7452_ACEOF
7453if ac_fn_cxx_try_compile "$LINENO"; then :
7454 eval $cachevar=yes
7455else
7456 eval $cachevar=no
7457fi
7458rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7459 CXX="$ac_save_CXX"
7460fi
7461eval ac_res=\$$cachevar
7462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7463$as_echo "$ac_res" >&6; }
7464 if eval test x\$$cachevar = xyes; then
7465 CXX="$CXX $switch"
7466 if test -n "$CXXCPP" ; then
7467 CXXCPP="$CXXCPP $switch"
7468 fi
7469 ac_success=yes
7470 break
7471 fi
7472 done
7473 fi
7474
7475 if test x$ac_success = xno; then
7476 for alternative in ${ax_cxx_compile_alternatives}; do
7477 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
7478 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_FOR_BUILD_$switch" | $as_tr_sh`
7479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
7480$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
7481if eval \${$cachevar+:} false; then :
7482 $as_echo_n "(cached) " >&6
7483else
7484 ac_save_CXX="$CXX"
7485 CXX="$CXX $switch"
7486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7487/* end confdefs.h. */
7488
7489
7490// If the compiler admits that it is not ready for C++11, why torture it?
7491// Hopefully, this will speed up the test.
7492
7493#ifndef __cplusplus
7494
7495#error "This is not a C++ compiler"
7496
7497#elif __cplusplus < 201103L
7498
7499#error "This is not a C++11 compiler"
7500
7501#else
7502
7503namespace cxx11
7504{
7505
7506 namespace test_static_assert
7507 {
7508
7509 template <typename T>
7510 struct check
7511 {
7512 static_assert(sizeof(int) <= sizeof(T), "not big enough");
7513 };
7514
7515 }
7516
7517 namespace test_final_override
7518 {
7519
7520 struct Base
7521 {
7522 virtual ~Base() {}
7523 virtual void f() {}
7524 };
7525
7526 struct Derived : public Base
7527 {
7528 virtual ~Derived() override {}
7529 virtual void f() override {}
7530 };
7531
7532 }
7533
7534 namespace test_double_right_angle_brackets
7535 {
7536
7537 template < typename T >
7538 struct check {};
7539
7540 typedef check<void> single_type;
7541 typedef check<check<void>> double_type;
7542 typedef check<check<check<void>>> triple_type;
7543 typedef check<check<check<check<void>>>> quadruple_type;
7544
7545 }
7546
7547 namespace test_decltype
7548 {
7549
7550 int
7551 f()
7552 {
7553 int a = 1;
7554 decltype(a) b = 2;
7555 return a + b;
7556 }
7557
7558 }
7559
7560 namespace test_type_deduction
7561 {
7562
7563 template < typename T1, typename T2 >
7564 struct is_same
7565 {
7566 static const bool value = false;
7567 };
7568
7569 template < typename T >
7570 struct is_same<T, T>
7571 {
7572 static const bool value = true;
7573 };
7574
7575 template < typename T1, typename T2 >
7576 auto
7577 add(T1 a1, T2 a2) -> decltype(a1 + a2)
7578 {
7579 return a1 + a2;
7580 }
7581
7582 int
7583 test(const int c, volatile int v)
7584 {
7585 static_assert(is_same<int, decltype(0)>::value == true, "");
7586 static_assert(is_same<int, decltype(c)>::value == false, "");
7587 static_assert(is_same<int, decltype(v)>::value == false, "");
7588 auto ac = c;
7589 auto av = v;
7590 auto sumi = ac + av + 'x';
7591 auto sumf = ac + av + 1.0;
7592 static_assert(is_same<int, decltype(ac)>::value == true, "");
7593 static_assert(is_same<int, decltype(av)>::value == true, "");
7594 static_assert(is_same<int, decltype(sumi)>::value == true, "");
7595 static_assert(is_same<int, decltype(sumf)>::value == false, "");
7596 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
7597 return (sumf > 0.0) ? sumi : add(c, v);
7598 }
7599
7600 }
7601
7602 namespace test_noexcept
7603 {
7604
7605 int f() { return 0; }
7606 int g() noexcept { return 0; }
7607
7608 static_assert(noexcept(f()) == false, "");
7609 static_assert(noexcept(g()) == true, "");
7610
7611 }
7612
7613 namespace test_constexpr
7614 {
7615
7616 template < typename CharT >
7617 unsigned long constexpr
7618 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
7619 {
7620 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
7621 }
7622
7623 template < typename CharT >
7624 unsigned long constexpr
7625 strlen_c(const CharT *const s) noexcept
7626 {
7627 return strlen_c_r(s, 0UL);
7628 }
7629
7630 static_assert(strlen_c("") == 0UL, "");
7631 static_assert(strlen_c("1") == 1UL, "");
7632 static_assert(strlen_c("example") == 7UL, "");
7633 static_assert(strlen_c("another\0example") == 7UL, "");
7634
7635 }
7636
7637 namespace test_rvalue_references
7638 {
7639
7640 template < int N >
7641 struct answer
7642 {
7643 static constexpr int value = N;
7644 };
7645
7646 answer<1> f(int&) { return answer<1>(); }
7647 answer<2> f(const int&) { return answer<2>(); }
7648 answer<3> f(int&&) { return answer<3>(); }
7649
7650 void
7651 test()
7652 {
7653 int i = 0;
7654 const int c = 0;
7655 static_assert(decltype(f(i))::value == 1, "");
7656 static_assert(decltype(f(c))::value == 2, "");
7657 static_assert(decltype(f(0))::value == 3, "");
7658 }
7659
7660 }
7661
7662 namespace test_uniform_initialization
7663 {
7664
7665 struct test
7666 {
7667 static const int zero {};
7668 static const int one {1};
7669 };
7670
7671 static_assert(test::zero == 0, "");
7672 static_assert(test::one == 1, "");
7673
7674 }
7675
7676 namespace test_lambdas
7677 {
7678
7679 void
7680 test1()
7681 {
7682 auto lambda1 = [](){};
7683 auto lambda2 = lambda1;
7684 lambda1();
7685 lambda2();
7686 }
7687
7688 int
7689 test2()
7690 {
7691 auto a = [](int i, int j){ return i + j; }(1, 2);
7692 auto b = []() -> int { return '0'; }();
7693 auto c = [=](){ return a + b; }();
7694 auto d = [&](){ return c; }();
7695 auto e = [a, &b](int x) mutable {
7696 const auto identity = [](int y){ return y; };
7697 for (auto i = 0; i < a; ++i)
7698 a += b--;
7699 return x + identity(a + b);
7700 }(0);
7701 return a + b + c + d + e;
7702 }
7703
7704 int
7705 test3()
7706 {
7707 const auto nullary = [](){ return 0; };
7708 const auto unary = [](int x){ return x; };
7709 using nullary_t = decltype(nullary);
7710 using unary_t = decltype(unary);
7711 const auto higher1st = [](nullary_t f){ return f(); };
7712 const auto higher2nd = [unary](nullary_t f1){
7713 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
7714 };
7715 return higher1st(nullary) + higher2nd(nullary)(unary);
7716 }
7717
7718 }
7719
7720 namespace test_variadic_templates
7721 {
7722
7723 template <int...>
7724 struct sum;
7725
7726 template <int N0, int... N1toN>
7727 struct sum<N0, N1toN...>
7728 {
7729 static constexpr auto value = N0 + sum<N1toN...>::value;
7730 };
7731
7732 template <>
7733 struct sum<>
7734 {
7735 static constexpr auto value = 0;
7736 };
7737
7738 static_assert(sum<>::value == 0, "");
7739 static_assert(sum<1>::value == 1, "");
7740 static_assert(sum<23>::value == 23, "");
7741 static_assert(sum<1, 2>::value == 3, "");
7742 static_assert(sum<5, 5, 11>::value == 21, "");
7743 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
7744
7745 }
7746
7747 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
7748 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
7749 // because of this.
7750 namespace test_template_alias_sfinae
7751 {
7752
7753 struct foo {};
7754
7755 template<typename T>
7756 using member = typename T::member_type;
7757
7758 template<typename T>
7759 void func(...) {}
7760
7761 template<typename T>
7762 void func(member<T>*) {}
7763
7764 void test();
7765
7766 void test() { func<foo>(0); }
7767
7768 }
7769
7770} // namespace cxx11
7771
7772#endif // __cplusplus >= 201103L
7773
7774
7775
7776_ACEOF
7777if ac_fn_cxx_try_compile "$LINENO"; then :
7778 eval $cachevar=yes
7779else
7780 eval $cachevar=no
7781fi
7782rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7783 CXX="$ac_save_CXX"
7784fi
7785eval ac_res=\$$cachevar
7786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7787$as_echo "$ac_res" >&6; }
7788 if eval test x\$$cachevar = xyes; then
7789 CXX="$CXX $switch"
7790 if test -n "$CXXCPP" ; then
7791 CXXCPP="$CXXCPP $switch"
7792 fi
7793 ac_success=yes
7794 break
7795 fi
7796 done
7797 if test x$ac_success = xyes; then
7798 break
7799 fi
7800 done
7801 fi
7802 CXX_FOR_BUILD="$CXX"
7803 CXXFLAGS_FOR_BUILD="$CXXFLAGS"
7804 CPPFLAGS_FOR_BUILD="$CPPFLAGS"
7805 CXX="$ax_cv_cxx_compile_cxx11_orig_cxx"
7806 CXXFLAGS="$ax_cv_cxx_compile_cxx11_orig_cxxflags"
7807 CPPFLAGS="$ax_cv_cxx_compile_cxx11_orig_cppflags"
7808 ac_ext=c
7809ac_cpp='$CPP $CPPFLAGS'
7810ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7811ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7812ac_compiler_gnu=$ac_cv_c_compiler_gnu
7813
7814 if test x$ax_cxx_compile_cxx11_required = xtrue; then
7815 if test x$ac_success = xno; then
7816 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
7817 fi
7818 fi
7819 if test x$ac_success = xno; then
7820 HAVE_CXX11_FOR_BUILD=0
7821 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
7822$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
7823 else
7824 HAVE_CXX11_FOR_BUILD=1
7825
7826$as_echo "#define HAVE_CXX11_FOR_BUILD 1" >>confdefs.h
7827
7828 fi
7829
7830
7831 fi
46070488
JM
7832fi
7833
4a5e71f2
L
7834# Check whether --enable-pgo-build was given.
7835if test "${enable_pgo_build+set}" = set; then :
7836 enableval=$enable_pgo_build; enable_pgo_build=$enableval
7837else
7838 enable_pgo_build=no
7839fi
7840
7841
7842# Issue errors and warnings for invalid/strange PGO build combinations.
7843case "$have_compiler:$host:$target:$enable_pgo_build" in
7844 *:*:*:no) ;;
7845
7846 # Allow the PGO build only if we aren't building a compiler and
7847 # we are in a native configuration.
7848 no:$build:$build:yes | no:$build:$build:lto) ;;
7849
7850 # Disallow the PGO bootstrap if we are building a compiler.
7851 yes:*:*:yes | yes:*:*:lto)
7852 as_fn_error $? "cannot perform the PGO bootstrap when building a compiler" "$LINENO" 5 ;;
7853
7854 *)
7855 as_fn_error $? "invalid option for --enable-pgo-build" "$LINENO" 5
7856 ;;
7857esac
7858
7859if test "$enable_pgo_build" != "no"; then
7860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fprofile-generate" >&5
7861$as_echo_n "checking whether the compiler supports -fprofile-generate... " >&6; }
7862 old_CFLAGS="$CFLAGS"
7863 PGO_BUILD_GEN_CFLAGS="-fprofile-generate"
7864 CFLAGS="$CFLAGS $PGO_BUILD_CFLAGS"
7865
7866cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7867/* end confdefs.h. */
7868int foo;
7869_ACEOF
7870if ac_fn_c_try_compile "$LINENO"; then :
7871
7872else
7873 PGO_BUILD_GEN_CFLAGS=
7874fi
7875rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7876 CFLAGS="$old_CFLAGS"
7877 if test -n "$PGO_BUILD_GEN_CFLAGS"; then
7878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7879$as_echo "yes" >&6; }
7880 PGO_BUILD_USE_CFLAGS="-fprofile-use"
7881 else
7882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7883$as_echo "no" >&6; }
7884 as_fn_error $? "cannot perform the PGO build without -fprofile-generate" "$LINENO" 5
7885 fi
7886
7887 if test "$enable_pgo_build" = "lto"; then
7888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -flto=jobserver -ffat-lto-objects" >&5
7889$as_echo_n "checking whether the compiler supports -flto=jobserver -ffat-lto-objects... " >&6; }
7890 old_CFLAGS="$CFLAGS"
7891 PGO_BUILD_LTO_CFLAGS="-flto=jobserver -ffat-lto-objects"
7892 CFLAGS="$CFLAGS $PGO_BUILD_LTO_CFLAGS"
7893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7894/* end confdefs.h. */
7895int foo;
7896_ACEOF
7897if ac_fn_c_try_compile "$LINENO"; then :
7898
7899else
7900 PGO_BUILD_LTO_CFLAGS=
7901fi
7902rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7903 CFLAGS="$old_CFLAGS"
7904 if test -n "$PGO_BUILD_LTO_CFLAGS"; then
7905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7906$as_echo "yes" >&6; }
7907 else
7908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7909$as_echo "no" >&6; }
7910 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: LTO is disabled for the PGO build" >&5
7911$as_echo "$as_me: WARNING: LTO is disabled for the PGO build" >&2;}
7912 fi
7913 fi
7914fi
7915
7916
7917
7918
592c90ff
KG
7919# Used for setting $lt_cv_objdir
7920{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
7921$as_echo_n "checking for objdir... " >&6; }
22e05272 7922if ${lt_cv_objdir+:} false; then :
592c90ff
KG
7923 $as_echo_n "(cached) " >&6
7924else
7925 rm -f .libs 2>/dev/null
7926mkdir .libs 2>/dev/null
7927if test -d .libs; then
7928 lt_cv_objdir=.libs
7929else
7930 # MS-DOS does not allow filenames that begin with a dot.
7931 lt_cv_objdir=_libs
7932fi
7933rmdir .libs 2>/dev/null
7934fi
7935{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
7936$as_echo "$lt_cv_objdir" >&6; }
7937objdir=$lt_cv_objdir
7938
7939
7940
7941
7942
7943cat >>confdefs.h <<_ACEOF
7944#define LT_OBJDIR "$lt_cv_objdir/"
7945_ACEOF
7946
7947
7948
acd26225 7949# Check for GMP, MPFR and MPC
3a5729ea 7950gmplibs="-lmpc -lmpfr -lgmp"
6de9cd9a 7951gmpinc=
e69bf64b 7952have_gmp=no
acd26225
KG
7953
7954# Specify a location for mpc
7955# check for this first so it ends up on the link line before mpfr.
7956
5213506e
RW
7957# Check whether --with-mpc was given.
7958if test "${with_mpc+set}" = set; then :
7959 withval=$with_mpc;
7960fi
acd26225 7961
acd26225 7962
9965e3cd 7963# Check whether --with-mpc-include was given.
5213506e
RW
7964if test "${with_mpc_include+set}" = set; then :
7965 withval=$with_mpc_include;
7966fi
acd26225 7967
acd26225 7968
9965e3cd 7969# Check whether --with-mpc-lib was given.
5213506e
RW
7970if test "${with_mpc_lib+set}" = set; then :
7971 withval=$with_mpc_lib;
7972fi
acd26225 7973
acd26225
KG
7974
7975if test "x$with_mpc" != x; then
3a5729ea
KG
7976 gmplibs="-L$with_mpc/lib $gmplibs"
7977 gmpinc="-I$with_mpc/include $gmpinc"
acd26225
KG
7978fi
7979if test "x$with_mpc_include" != x; then
3a5729ea 7980 gmpinc="-I$with_mpc_include $gmpinc"
acd26225
KG
7981fi
7982if test "x$with_mpc_lib" != x; then
3a5729ea 7983 gmplibs="-L$with_mpc_lib $gmplibs"
acd26225
KG
7984fi
7985if test "x$with_mpc$with_mpc_include$with_mpc_lib" = x && test -d ${srcdir}/mpc; then
592c90ff 7986 gmplibs='-L$$r/$(HOST_SUBDIR)/mpc/src/'"$lt_cv_objdir $gmplibs"
3a5729ea 7987 gmpinc='-I$$s/mpc/src '"$gmpinc"
acd26225
KG
7988 # Do not test the mpc version. Assume that it is sufficient, since
7989 # it is in the source tree, and the library has not been built yet
7990 # but it would be included on the link line in the version check below
7991 # hence making the test fail.
3a5729ea 7992 have_gmp=yes
acd26225 7993fi
e69bf64b 7994
bebf829d
PB
7995# Specify a location for mpfr
7996# check for this first so it ends up on the link line before gmp.
1c710c3c 7997
5213506e
RW
7998# Check whether --with-mpfr was given.
7999if test "${with_mpfr+set}" = set; then :
8000 withval=$with_mpfr;
8001fi
1c710c3c 8002
bebf829d 8003
9965e3cd 8004# Check whether --with-mpfr-include was given.
5213506e
RW
8005if test "${with_mpfr_include+set}" = set; then :
8006 withval=$with_mpfr_include;
8007fi
1c710c3c 8008
8a877c9c 8009
9965e3cd 8010# Check whether --with-mpfr-lib was given.
5213506e
RW
8011if test "${with_mpfr_lib+set}" = set; then :
8012 withval=$with_mpfr_lib;
8013fi
8a877c9c 8014
bebf829d
PB
8015
8016if test "x$with_mpfr" != x; then
8017 gmplibs="-L$with_mpfr/lib $gmplibs"
3a5729ea 8018 gmpinc="-I$with_mpfr/include $gmpinc"
bebf829d 8019fi
8a877c9c 8020if test "x$with_mpfr_include" != x; then
3a5729ea 8021 gmpinc="-I$with_mpfr_include $gmpinc"
8a877c9c
KG
8022fi
8023if test "x$with_mpfr_lib" != x; then
8024 gmplibs="-L$with_mpfr_lib $gmplibs"
8025fi
e69bf64b 8026if test "x$with_mpfr$with_mpfr_include$with_mpfr_lib" = x && test -d ${srcdir}/mpfr; then
8f3675f8
MR
8027 # MPFR v3.1.0 moved the sources into a src sub-directory.
8028 if ! test -d ${srcdir}/mpfr/src; then
22e05272 8029 as_fn_error $? "Building GCC with MPFR in the source tree is only handled for MPFR 3.1.0+." "$LINENO" 5
8f3675f8 8030 fi
00f35794
BE
8031 gmplibs='-L$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir $gmplibs"
8032 gmpinc='-I$$r/$(HOST_SUBDIR)/mpfr/src -I$$s/mpfr/src '"$gmpinc"
8033 extra_mpc_mpfr_configure_flags='--with-mpfr-include=$$s/mpfr/src --with-mpfr-lib=$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir"
e69bf64b
PB
8034 # Do not test the mpfr version. Assume that it is sufficient, since
8035 # it is in the source tree, and the library has not been built yet
8036 # but it would be included on the link line in the version check below
8037 # hence making the test fail.
8038 have_gmp=yes
8039fi
bebf829d 8040
6de9cd9a 8041# Specify a location for gmp
1c710c3c 8042
5213506e
RW
8043# Check whether --with-gmp was given.
8044if test "${with_gmp+set}" = set; then :
8045 withval=$with_gmp;
8046fi
1c710c3c 8047
6de9cd9a 8048
9965e3cd 8049# Check whether --with-gmp-include was given.
5213506e
RW
8050if test "${with_gmp_include+set}" = set; then :
8051 withval=$with_gmp_include;
8052fi
1c710c3c 8053
8a877c9c 8054
9965e3cd 8055# Check whether --with-gmp-lib was given.
5213506e
RW
8056if test "${with_gmp_lib+set}" = set; then :
8057 withval=$with_gmp_lib;
8058fi
8a877c9c
KG
8059
8060
6de9cd9a 8061
bebf829d
PB
8062if test "x$with_gmp" != x; then
8063 gmplibs="-L$with_gmp/lib $gmplibs"
8064 gmpinc="-I$with_gmp/include $gmpinc"
6de9cd9a 8065fi
8a877c9c
KG
8066if test "x$with_gmp_include" != x; then
8067 gmpinc="-I$with_gmp_include $gmpinc"
8068fi
8069if test "x$with_gmp_lib" != x; then
8070 gmplibs="-L$with_gmp_lib $gmplibs"
8071fi
e69bf64b 8072if test "x$with_gmp$with_gmp_include$with_gmp_lib" = x && test -d ${srcdir}/gmp; then
592c90ff 8073 gmplibs='-L$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir $gmplibs"
e69bf64b 8074 gmpinc='-I$$r/$(HOST_SUBDIR)/gmp -I$$s/gmp '"$gmpinc"
9183bdcf 8075 extra_mpfr_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
592c90ff 8076 extra_mpc_gmp_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
0ff2d841 8077 extra_isl_gmp_configure_flags='--with-gmp-builddir=$$r/$(HOST_SUBDIR)/gmp'
e69bf64b
PB
8078 # Do not test the gmp version. Assume that it is sufficient, since
8079 # it is in the source tree, and the library has not been built yet
8080 # but it would be included on the link line in the version check below
8081 # hence making the test fail.
8082 have_gmp=yes
8083fi
6de9cd9a 8084
d943d7c4 8085if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then
e69bf64b
PB
8086 have_gmp=yes
8087 saved_CFLAGS="$CFLAGS"
8088 CFLAGS="$CFLAGS $gmpinc"
362c6d2f
KG
8089 # Check for the recommended and required versions of GMP.
8090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of gmp.h" >&5
8091$as_echo_n "checking for the correct version of gmp.h... " >&6; }
4a5e71f2 8092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
362c6d2f
KG
8093/* end confdefs.h. */
8094#include "gmp.h"
8095int
8096main ()
8097{
8098
8099 #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
8100 #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
385c0681 8101 #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,2,3)
362c6d2f
KG
8102 choke me
8103 #endif
8104
8105 ;
8106 return 0;
8107}
8108_ACEOF
8109if ac_fn_c_try_compile "$LINENO"; then :
e8fd69bb 8110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c 8111/* end confdefs.h. */
362c6d2f 8112#include <gmp.h>
1c710c3c
DJ
8113int
8114main ()
8115{
6de9cd9a 8116
362c6d2f
KG
8117 #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
8118 #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
8119 #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,3,2)
e69bf64b
PB
8120 choke me
8121 #endif
1c710c3c
DJ
8122
8123 ;
8124 return 0;
8125}
8126_ACEOF
5213506e
RW
8127if ac_fn_c_try_compile "$LINENO"; then :
8128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8129$as_echo "yes" >&6; }
362c6d2f
KG
8130else
8131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
8132$as_echo "buggy but acceptable" >&6; }
8133fi
8134rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1c710c3c 8135else
5213506e
RW
8136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8137$as_echo "no" >&6; }; have_gmp=no
1c710c3c 8138fi
5213506e 8139rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6de9cd9a 8140
acd26225 8141 # If we have GMP, check the MPFR version.
e69bf64b 8142 if test x"$have_gmp" = xyes; then
362c6d2f
KG
8143 # Check for the recommended and required versions of MPFR.
8144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of mpfr.h" >&5
8145$as_echo_n "checking for the correct version of mpfr.h... " >&6; }
5213506e 8146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c 8147/* end confdefs.h. */
70ec446f 8148#include <gmp.h>
e69bf64b 8149 #include <mpfr.h>
1c710c3c
DJ
8150int
8151main ()
8152{
e48d66a9 8153
8be34204 8154 #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,0)
e69bf64b
PB
8155 choke me
8156 #endif
1c710c3c
DJ
8157
8158 ;
8159 return 0;
8160}
8161_ACEOF
5213506e
RW
8162if ac_fn_c_try_compile "$LINENO"; then :
8163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c 8164/* end confdefs.h. */
a3993f33 8165#include <gmp.h>
e69bf64b 8166 #include <mpfr.h>
1c710c3c
DJ
8167int
8168main ()
8169{
a3993f33 8170
8be34204 8171 #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,6)
e69bf64b
PB
8172 choke me
8173 #endif
acd26225
KG
8174
8175 ;
8176 return 0;
8177}
8178_ACEOF
5213506e
RW
8179if ac_fn_c_try_compile "$LINENO"; then :
8180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8181$as_echo "yes" >&6; }
acd26225 8182else
5213506e
RW
8183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
8184$as_echo "buggy but acceptable" >&6; }
acd26225 8185fi
5213506e 8186rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225 8187else
5213506e
RW
8188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8189$as_echo "no" >&6; }; have_gmp=no
acd26225 8190fi
5213506e 8191rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225
KG
8192 fi
8193
8194 # Check for the MPC header version.
3a5729ea 8195 if test x"$have_gmp" = xyes ; then
362c6d2f 8196 # Check for the recommended and required versions of MPC.
5213506e
RW
8197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of mpc.h" >&5
8198$as_echo_n "checking for the correct version of mpc.h... " >&6; }
8199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
acd26225
KG
8200/* end confdefs.h. */
8201#include <mpc.h>
8202int
8203main ()
8204{
8205
362c6d2f
KG
8206 #if MPC_VERSION < MPC_VERSION_NUM(0,8,0)
8207 choke me
8208 #endif
8209
8210 ;
8211 return 0;
8212}
8213_ACEOF
8214if ac_fn_c_try_compile "$LINENO"; then :
8215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8216/* end confdefs.h. */
8217#include <mpc.h>
8218int
8219main ()
8220{
8221
8222 #if MPC_VERSION < MPC_VERSION_NUM(0,8,1)
acd26225
KG
8223 choke me
8224 #endif
8225
8226 ;
8227 return 0;
8228}
8229_ACEOF
5213506e
RW
8230if ac_fn_c_try_compile "$LINENO"; then :
8231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3a5729ea 8232$as_echo "yes" >&6; }
362c6d2f
KG
8233else
8234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
8235$as_echo "buggy but acceptable" >&6; }
8236fi
8237rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225 8238else
5213506e 8239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3a5729ea 8240$as_echo "no" >&6; }; have_gmp=no
acd26225 8241fi
5213506e 8242rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225
KG
8243 fi
8244
8245 # Now check the MPFR library.
8246 if test x"$have_gmp" = xyes; then
8247 saved_LIBS="$LIBS"
8248 LIBS="$LIBS $gmplibs"
3a5729ea
KG
8249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of the gmp/mpfr/mpc libraries" >&5
8250$as_echo_n "checking for the correct version of the gmp/mpfr/mpc libraries... " >&6; }
5213506e 8251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
acd26225 8252/* end confdefs.h. */
3a5729ea 8253#include <mpc.h>
acd26225
KG
8254int
8255main ()
8256{
8257
8258 mpfr_t n;
8259 mpfr_t x;
3a5729ea 8260 mpc_t c;
acd26225
KG
8261 int t;
8262 mpfr_init (n);
8263 mpfr_init (x);
90ca6847
TB
8264 mpfr_atan2 (n, n, x, MPFR_RNDN);
8265 mpfr_erfc (n, x, MPFR_RNDN);
8266 mpfr_subnormalize (x, t, MPFR_RNDN);
3a5729ea
KG
8267 mpfr_clear(n);
8268 mpfr_clear(x);
8269 mpc_init2 (c, 53);
8270 mpc_set_ui_ui (c, 1, 1, MPC_RNDNN);
8271 mpc_cosh (c, c, MPC_RNDNN);
8272 mpc_pow (c, c, c, MPC_RNDNN);
8273 mpc_acosh (c, c, MPC_RNDNN);
8274 mpc_clear (c);
1c710c3c
DJ
8275
8276 ;
8277 return 0;
8278}
8279_ACEOF
5213506e
RW
8280if ac_fn_c_try_link "$LINENO"; then :
8281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8282$as_echo "yes" >&6; }
1c710c3c 8283else
5213506e
RW
8284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8285$as_echo "no" >&6; }; have_gmp=no
1c710c3c 8286fi
5213506e
RW
8287rm -f core conftest.err conftest.$ac_objext \
8288 conftest$ac_exeext conftest.$ac_ext
acd26225
KG
8289 LIBS="$saved_LIBS"
8290 fi
8291
e69bf64b 8292 CFLAGS="$saved_CFLAGS"
6de9cd9a 8293
362c6d2f
KG
8294# The library versions listed in the error message below should match
8295# the HARD-minimums enforced above.
e69bf64b 8296 if test x$have_gmp != xyes; then
8be34204 8297 as_fn_error $? "Building GCC requires GMP 4.2+, MPFR 3.1.0+ and MPC 0.8.0+.
3a5729ea
KG
8298Try the --with-gmp, --with-mpfr and/or --with-mpc options to specify
8299their locations. Source code for these libraries can be found at
8300their respective hosting sites as well as at
aeebd94c 8301https://gcc.gnu.org/pub/gcc/infrastructure/. See also
3a5729ea
KG
8302http://gcc.gnu.org/install/prerequisites.html for additional info. If
8303you obtained GMP, MPFR and/or MPC from a vendor distribution package,
8304make sure that you have installed both the libraries and the header
8305files. They may be located in separate packages." "$LINENO" 5
e69bf64b 8306 fi
70ec446f
KG
8307fi
8308
acd26225
KG
8309# Flags needed for both GMP, MPFR and/or MPC.
8310
8311
6de9cd9a
DN
8312
8313
8314
9e3eba15 8315
0ff2d841 8316
0b21f5d3 8317# Libraries to use for stage1 or when not bootstrapping.
00020c16 8318
0b21f5d3
EB
8319# Check whether --with-stage1-libs was given.
8320if test "${with_stage1_libs+set}" = set; then :
8321 withval=$with_stage1_libs; if test "$withval" = "no" -o "$withval" = "yes"; then
8322 stage1_libs=
00020c16 8323 else
0b21f5d3 8324 stage1_libs=$withval
00020c16
ILT
8325 fi
8326else
5dc85f7e 8327 stage1_libs=
5213506e
RW
8328fi
8329
00020c16
ILT
8330
8331
aac9103b
TT
8332# Whether or not to use -static-libstdc++ and -static-libgcc. The
8333# default is yes if gcc is being built; no otherwise. The reason for
8334# this default is that gdb is sometimes linked against GNU Source
8335# Highlight, which is a shared library that uses C++ exceptions. In
8336# this case, -static-libstdc++ will cause crashes.
8337
8338# Check whether --with-static-standard-libraries was given.
8339if test "${with_static_standard_libraries+set}" = set; then :
8340 withval=$with_static_standard_libraries;
8341else
8342 with_static_standard_libraries=auto
8343fi
8344
8345if test "$with_static_standard_libraries" = auto; then
8346 with_static_standard_libraries=$have_compiler
8347fi
8348
0b21f5d3 8349# Linker flags to use for stage1 or when not bootstrapping.
00020c16 8350
0b21f5d3
EB
8351# Check whether --with-stage1-ldflags was given.
8352if test "${with_stage1_ldflags+set}" = set; then :
8353 withval=$with_stage1_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
8354 stage1_ldflags=
00020c16 8355 else
0b21f5d3 8356 stage1_ldflags=$withval
00020c16
ILT
8357 fi
8358else
0b21f5d3
EB
8359 stage1_ldflags=
8360 # In stage 1, default to linking libstdc++ and libgcc statically with GCC
8361 # if supported. But if the user explicitly specified the libraries to use,
8362 # trust that they are doing what they want.
aac9103b
TT
8363 if test "$with_static_standard_libraries" = yes -a "$stage1_libs" = "" \
8364 -a "$have_static_libs" = yes; then
0b21f5d3
EB
8365 stage1_ldflags="-static-libstdc++ -static-libgcc"
8366 fi
5213506e
RW
8367fi
8368
00020c16
ILT
8369
8370
5dc85f7e 8371# Libraries to use for stage2 and later builds.
00020c16 8372
5213506e
RW
8373# Check whether --with-boot-libs was given.
8374if test "${with_boot_libs+set}" = set; then :
8375 withval=$with_boot_libs; if test "$withval" = "no" -o "$withval" = "yes"; then
e90e6bd7
ILT
8376 poststage1_libs=
8377 else
8378 poststage1_libs=$withval
8379 fi
8380else
5dc85f7e 8381 poststage1_libs=
5213506e
RW
8382fi
8383
00020c16
ILT
8384
8385
ed2eaa9f
ILT
8386# Linker flags to use for stage2 and later builds.
8387
8388# Check whether --with-boot-ldflags was given.
8389if test "${with_boot_ldflags+set}" = set; then :
8390 withval=$with_boot_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
8391 poststage1_ldflags=
8392 else
8393 poststage1_ldflags=$withval
8394 fi
8395else
8396 poststage1_ldflags=
bec93d73
ILT
8397 # In stages 2 and 3, default to linking libstdc++ and libgcc
8398 # statically. But if the user explicitly specified the libraries to
8399 # use, trust that they are doing what they want.
8400 if test "$poststage1_libs" = ""; then
ed2eaa9f
ILT
8401 poststage1_ldflags="-static-libstdc++ -static-libgcc"
8402 fi
8403fi
8404
8405
8406
e357a5e0 8407# GCC GRAPHITE dependency isl.
4a9bb2aa 8408# Basic setup is inlined here, actual checks are in config/isl.m4
f8bf9252
SP
8409
8410
33ad93b9
RG
8411# Check whether --with-isl was given.
8412if test "${with_isl+set}" = set; then :
8413 withval=$with_isl;
5213506e 8414fi
f8bf9252 8415
f8bf9252 8416
eae1a5d4 8417# Treat --without-isl as a request to disable
625afa23 8418# GRAPHITE support and skip all following checks.
eae1a5d4 8419if test "x$with_isl" != "xno"; then
e357a5e0 8420 # Check for isl
625afa23
RG
8421
8422
33ad93b9
RG
8423# Check whether --with-isl-include was given.
8424if test "${with_isl_include+set}" = set; then :
8425 withval=$with_isl_include;
5213506e
RW
8426fi
8427
f8bf9252 8428
33ad93b9
RG
8429# Check whether --with-isl-lib was given.
8430if test "${with_isl_lib+set}" = set; then :
8431 withval=$with_isl_lib;
5213506e 8432fi
f8bf9252 8433
f8bf9252 8434
33ad93b9
RG
8435 # Check whether --enable-isl-version-check was given.
8436if test "${enable_isl_version_check+set}" = set; then :
8437 enableval=$enable_isl_version_check; ENABLE_ISL_CHECK=$enableval
8438else
8439 ENABLE_ISL_CHECK=yes
7d32a440
SP
8440fi
8441
8442
33ad93b9
RG
8443 # Initialize isllibs and islinc.
8444 case $with_isl in
8445 no)
8446 isllibs=
8447 islinc=
8448 ;;
8449 "" | yes)
8450 ;;
8451 *)
8452 isllibs="-L$with_isl/lib"
8453 islinc="-I$with_isl/include"
8454 ;;
8455 esac
8456 if test "x${with_isl_include}" != x ; then
8457 islinc="-I$with_isl_include"
8458 fi
8459 if test "x${with_isl_lib}" != x; then
8460 isllibs="-L$with_isl_lib"
8461 fi
8462 if test "x${islinc}" = x && test "x${isllibs}" = x \
8463 && test -d ${srcdir}/isl; then
8464 isllibs='-L$$r/$(HOST_SUBDIR)/isl/'"$lt_cv_objdir"' '
8465 islinc='-I$$r/$(HOST_SUBDIR)/isl/include -I$$s/isl/include'
8466 ENABLE_ISL_CHECK=no
560d18d3
AK
8467 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using in-tree isl, disabling version check" >&5
8468$as_echo "$as_me: WARNING: using in-tree isl, disabling version check" >&2;}
33ad93b9 8469 fi
7d32a440 8470
eae1a5d4
RG
8471 isllibs="${isllibs} -lisl"
8472
7d32a440 8473
7d32a440 8474
9847828b
RB
8475 if test "${ENABLE_ISL_CHECK}" = yes ; then
8476 _isl_saved_CFLAGS=$CFLAGS
8477 _isl_saved_LDFLAGS=$LDFLAGS
8478 _isl_saved_LIBS=$LIBS
8479
8480 CFLAGS="${_isl_saved_CFLAGS} ${islinc} ${gmpinc}"
70decafb
NS
8481 LDFLAGS="${_isl_saved_LDFLAGS} ${isllibs} ${gmplibs}"
8482 LIBS="${_isl_saved_LIBS} -lisl -lgmp"
9847828b 8483
f877b3ad
RB
8484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isl 0.15 or later" >&5
8485$as_echo_n "checking for isl 0.15 or later... " >&6; }
e0c0c325 8486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
622dbadf 8487/* end confdefs.h. */
f877b3ad 8488#include <isl/schedule.h>
622dbadf
BC
8489int
8490main ()
8491{
f877b3ad 8492isl_options_set_schedule_serialize_sccs (NULL, 0);
622dbadf
BC
8493 ;
8494 return 0;
8495}
8496_ACEOF
8497if ac_fn_c_try_link "$LINENO"; then :
9847828b 8498 gcc_cv_isl=yes
622dbadf
BC
8499else
8500 gcc_cv_isl=no
8501fi
8502rm -f core conftest.err conftest.$ac_objext \
8503 conftest$ac_exeext conftest.$ac_ext
9847828b
RB
8504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_isl" >&5
8505$as_echo "$gcc_cv_isl" >&6; }
8506
560d18d3 8507 if test "${gcc_cv_isl}" = no ; then
f877b3ad
RB
8508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: required isl version is 0.15 or later" >&5
8509$as_echo "required isl version is 0.15 or later" >&6; }
1e050c90
AK
8510 fi
8511
9847828b
RB
8512 CFLAGS=$_isl_saved_CFLAGS
8513 LDFLAGS=$_isl_saved_LDFLAGS
8514 LIBS=$_isl_saved_LIBS
8515 fi
8516
8517
f8bf9252 8518
f8bf9252 8519
33ad93b9
RG
8520
8521
33ad93b9
RG
8522 if test "x${with_isl}" = xno; then
8523 graphite_requested=no
8524 elif test "x${with_isl}" != x \
8525 || test "x${with_isl_include}" != x \
8526 || test "x${with_isl_lib}" != x ; then
8527 graphite_requested=yes
8528 else
8529 graphite_requested=no
7d32a440 8530 fi
d789184e 8531
d789184e
SP
8532
8533
33ad93b9
RG
8534 if test "${gcc_cv_isl}" = no ; then
8535 isllibs=
8536 islinc=
8537 fi
8538
8539 if test "${graphite_requested}" = yes \
8540 && test "x${isllibs}" = x \
8541 && test "x${islinc}" = x ; then
f8bf9252 8542
22e05272 8543 as_fn_error $? "Unable to find a usable isl. See config.log for details." "$LINENO" 5
33ad93b9 8544 fi
f8bf9252 8545
d32ef397 8546
d32ef397
AS
8547fi
8548
e357a5e0 8549# If the isl check failed, disable builds of in-tree variant of isl
625afa23 8550if test "x$with_isl" = xno ||
625afa23 8551 test "x$gcc_cv_isl" = xno; then
4a9bb2aa 8552 noconfigdirs="$noconfigdirs isl"
625afa23 8553 islinc=
32d024bf
RG
8554fi
8555
625afa23
RG
8556
8557
8558
d7f09764
DN
8559# Check for LTO support.
8560# Check whether --enable-lto was given.
8561if test "${enable_lto+set}" = set; then :
8562 enableval=$enable_lto; enable_lto=$enableval
8563else
8564 enable_lto=yes; default_enable_lto=yes
8565fi
8566
8567
7413962d 8568
9a02962b
DK
8569
8570
8571target_elf=no
8572case $target in
8573 *-darwin* | *-aix* | *-cygwin* | *-mingw* | *-aout* | *-*coff* | \
e44dbbe1 8574 *-msdosdjgpp* | *-vms* | *-wince* | *-*-pe* | \
8f56cb51 8575 alpha*-dec-osf* | *-interix* | hppa[12]*-*-hpux* | \
8ae12d71 8576 nvptx-*-none)
9a02962b
DK
8577 target_elf=no
8578 ;;
8579 *)
8580 target_elf=yes
8581 ;;
8582esac
8583
8584if test $target_elf = yes; then :
48215350
DK
8585 # ELF platforms build the lto-plugin always.
8586 build_lto_plugin=yes
9a02962b 8587
9a02962b
DK
8588else
8589 if test x"$default_enable_lto" = x"yes" ; then
bb79486c 8590 case $target in
deeba76a 8591 *-apple-darwin[912]* | *-cygwin* | *-mingw* | *djgpp*) ;;
48215350 8592 # On other non-ELF platforms, LTO has yet to be validated.
bb79486c
JH
8593 *) enable_lto=no ;;
8594 esac
9a02962b 8595 else
db50fe7d
IS
8596 # Apart from ELF platforms, only Windows and Darwin support LTO so far.
8597 # It would also be nice to check the binutils support, but we don't
9a02962b
DK
8598 # have gcc_GAS_CHECK_FEATURE available here. For now, we'll just
8599 # warn during gcc/ subconfigure; unless you're bootstrapping with
8600 # -flto it won't be needed until after installation anyway.
8601 case $target in
9e530bcd 8602 *-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
9a02962b 8603 *) if test x"$enable_lto" = x"yes"; then
22e05272 8604 as_fn_error $? "LTO support is not enabled for this target." "$LINENO" 5
9a02962b
DK
8605 fi
8606 ;;
8607 esac
8608 fi
1cd0b716 8609 # Among non-ELF, only Windows platforms support the lto-plugin so far.
48215350 8610 # Build it unless LTO was explicitly disabled.
1cd0b716 8611 case $target in
48215350 8612 *-cygwin* | *-mingw*) build_lto_plugin=$enable_lto ;;
1cd0b716
DK
8613 *) ;;
8614 esac
48215350 8615
9a02962b
DK
8616fi
8617
d7f09764 8618
45b3824d
TS
8619# Check whether --enable-linker-plugin-configure-flags was given.
8620if test "${enable_linker_plugin_configure_flags+set}" = set; then :
8621 enableval=$enable_linker_plugin_configure_flags; extra_linker_plugin_configure_flags=$enableval
8622else
8623 extra_linker_plugin_configure_flags=
8624fi
8625
8626
8627# Check whether --enable-linker-plugin-flags was given.
8628if test "${enable_linker_plugin_flags+set}" = set; then :
8629 enableval=$enable_linker_plugin_flags; extra_linker_plugin_flags=$enableval
8630else
8631 extra_linker_plugin_flags=
8632fi
8633
8634
8635
cdfee50a
NS
8636# Enable --enable-host-shared.
8637# Checked early to determine whether jit is an 'all' language
8638# Check whether --enable-host-shared was given.
8639if test "${enable_host_shared+set}" = set; then :
8640 enableval=$enable_host_shared; host_shared=$enableval
a1d2b162
IS
8641 case $target in
8642 x86_64-*-darwin* | aarch64-*-darwin*)
8643 if test x$host_shared != xyes ; then
8644 # PIC is the default, and actually cannot be switched off.
8645 echo configure.ac: warning: PIC code is required for the configured target, host-shared setting ignored. 1>&2
8646 host_shared=yes
8647 fi ;;
8648 *) ;;
8649 esac
cdfee50a 8650else
a1d2b162
IS
8651 case $target in
8652 x86_64-*-darwin* | aarch64-*-darwin*) host_shared=yes ;;
8653 *) host_shared=no ;;
8654 esac
cdfee50a
NS
8655fi
8656
8657
f8bf9252 8658
0823efed 8659# By default, C and C++ are the only stage 1 languages.
e1888513 8660stage1_languages=,c,
2805b53a 8661
00020c16 8662# Target libraries that we bootstrap.
ad1e5170 8663bootstrap_target_libs=,target-libgcc,
00020c16 8664
55ffb5ed
NN
8665# Figure out what language subdirectories are present.
8666# Look if the user specified --enable-languages="..."; if not, use
8667# the environment variable $LANGUAGES if defined. $LANGUAGES might
8668# go away some day.
8669# NB: embedded tabs in this IF block -- do not untabify
8670if test -d ${srcdir}/gcc; then
8671 if test x"${enable_languages+set}" != xset; then
8672 if test x"${LANGUAGES+set}" = xset; then
8673 enable_languages="${LANGUAGES}"
6b1786aa 8674 echo configure.ac: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
55ffb5ed 8675 else
cdfee50a 8676 enable_languages=default
55ffb5ed
NN
8677 fi
8678 else
8679 if test x"${enable_languages}" = x ||
8680 test x"${enable_languages}" = xyes;
8681 then
6b1786aa 8682 echo configure.ac: --enable-languages needs at least one language argument 1>&2
55ffb5ed
NN
8683 exit 1
8684 fi
8685 fi
8686 enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
8687
7f26dfa3
FXC
8688 # 'f95' is the old name for the 'fortran' language. We issue a warning
8689 # and make the substitution.
8690 case ,${enable_languages}, in
8691 *,f95,*)
6b1786aa 8692 echo configure.ac: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
7f26dfa3
FXC
8693 enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
8694 ;;
8695 esac
8696
0823efed
DN
8697 # If bootstrapping, C++ must be enabled.
8698 case ",$enable_languages,:$enable_bootstrap" in
8699 *,c++,*:*) ;;
8700 *:yes)
ff3ac0f4
ILT
8701 if test -f ${srcdir}/gcc/cp/config-lang.in; then
8702 enable_languages="${enable_languages},c++"
8703 else
22e05272 8704 as_fn_error $? "bootstrapping requires c++ sources" "$LINENO" 5
ff3ac0f4
ILT
8705 fi
8706 ;;
8707 esac
8708
55ffb5ed
NN
8709 # First scan to see if an enabled language requires some other language.
8710 # We assume that a given config-lang.in will list all the language
8711 # front ends it requires, even if some are required indirectly.
8712 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
8713 case ${lang_frag} in
8714 ..) ;;
8715 # The odd quoting in the next line works around
8716 # an apparent bug in bash 1.12 on linux.
8717 ${srcdir}/gcc/[*]/config-lang.in) ;;
8718 *)
69ecd18f
ILT
8719 # From the config-lang.in, get $language, $lang_requires, and
8720 # $lang_requires_boot_languages.
55ffb5ed
NN
8721 language=
8722 lang_requires=
69ecd18f 8723 lang_requires_boot_languages=
d4360477
NS
8724 # set srcdir during sourcing lang_frag to the gcc dir.
8725 # Sadly overriding srcdir on the . line doesn't work in plain sh as it
8726 # polutes this shell
8727 saved_srcdir=${srcdir}
8728 srcdir=${srcdir}/gcc . ${lang_frag}
8729 srcdir=${saved_srcdir}
69ecd18f 8730 for other in ${lang_requires} ${lang_requires_boot_languages}; do
55ffb5ed
NN
8731 case ,${enable_languages}, in
8732 *,$other,*) ;;
cdfee50a 8733 *,default,*) ;;
55ffb5ed
NN
8734 *,all,*) ;;
8735 *,$language,*)
8736 echo " \`$other' language required by \`$language'; enabling" 1>&2
8737 enable_languages="${enable_languages},${other}"
8738 ;;
8739 esac
8740 done
69ecd18f
ILT
8741 for other in ${lang_requires_boot_languages} ; do
8742 if test "$other" != "c"; then
8743 case ,${enable_stage1_languages}, in
8744 *,$other,*) ;;
cdfee50a 8745 *,default,*) ;;
69ecd18f
ILT
8746 *,all,*) ;;
8747 *)
8748 case ,${enable_languages}, in
8749 *,$language,*)
8750 echo " '$other' language required by '$language' in stage 1; enabling" 1>&2
8751 enable_stage1_languages="$enable_stage1_languages,${other}"
8752 ;;
8753 esac
8754 ;;
8755 esac
8756 fi
8757 done
55ffb5ed
NN
8758 ;;
8759 esac
8760 done
8761
e1888513 8762 new_enable_languages=,c,
d7f09764
DN
8763
8764 # If LTO is enabled, add the LTO front end.
d7f09764 8765 if test "$enable_lto" = "yes" ; then
e4c5bd48
RW
8766 case ,${enable_languages}, in
8767 *,lto,*) ;;
8768 *) enable_languages="${enable_languages},lto" ;;
8769 esac
1cd0b716 8770 if test "${build_lto_plugin}" = "yes" ; then
d7f09764 8771 configdirs="$configdirs lto-plugin"
d7f09764
DN
8772 fi
8773 fi
8774
426c1eb0
TS
8775 # If we're building an offloading compiler, add the LTO front end.
8776 if test x"$enable_as_accelerator_for" != x ; then
8777 case ,${enable_languages}, in
8778 *,lto,*) ;;
8779 *) enable_languages="${enable_languages},lto" ;;
8780 esac
8781 fi
8782
cdfee50a 8783 missing_languages=`echo ",$enable_languages," | sed -e s/,default,/,/ -e s/,all,/,/ -e s/,c,/,/ `
e1888513 8784 potential_languages=,c,
55ffb5ed 8785
4da3b0f8
ILT
8786 enabled_target_libs=
8787 disabled_target_libs=
8788
55ffb5ed
NN
8789 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
8790 case ${lang_frag} in
8791 ..) ;;
8792 # The odd quoting in the next line works around
8793 # an apparent bug in bash 1.12 on linux.
8794 ${srcdir}/gcc/[*]/config-lang.in) ;;
8795 *)
1c710c3c 8796 # From the config-lang.in, get $language, $target_libs,
2805b53a 8797 # $lang_dirs, $boot_language, and $build_by_default
55ffb5ed
NN
8798 language=
8799 target_libs=
8800 lang_dirs=
1546bb64 8801 subdir_requires=
e1888513
PB
8802 boot_language=no
8803 build_by_default=yes
d4360477
NS
8804 # set srcdir during sourcing. See above about save & restore
8805 saved_srcdir=${srcdir}
8806 srcdir=${srcdir}/gcc . ${lang_frag}
8807 srcdir=${saved_srcdir}
e1888513
PB
8808 if test x${language} = x; then
8809 echo "${lang_frag} doesn't set \$language." 1>&2
8810 exit 1
8811 fi
8812
78767fd9 8813 if test "$language" = "c++"; then
0823efed 8814 boot_language=yes
00020c16
ILT
8815 fi
8816
178f875a 8817 add_this_lang=no
cdfee50a
NS
8818 # C is always enabled, so no need to add it again
8819 if test "$language" != "c"; then
8820 case ,${enable_languages}, in
8821 *,${language},*)
8822 # Language was explicitly selected; include it
d4a10d0a 8823 add_this_lang=yes
cdfee50a
NS
8824 ;;
8825 *,all,*)
8826 # All languages are enabled
8827 add_this_lang=all
8828 ;;
8829 *,default,*)
8830 # 'default' was selected, select it if it is a default language
178f875a 8831 add_this_lang=${build_by_default}
cdfee50a
NS
8832 ;;
8833 esac
8834 fi
6de9cd9a 8835
1546bb64 8836 # Disable languages that need other directories if these aren't available.
95695ad3 8837 for i in $subdir_requires; do
b6348cb3 8838 test -f "$srcdir/gcc/$i/config-lang.in" && continue
cdfee50a
NS
8839 case ${add_this_lang} in
8840 yes)
1546bb64 8841 # Specifically requested language; tell them.
22e05272 8842 as_fn_error $? "The gcc/$i directory contains parts of $language but is missing" "$LINENO" 5
1546bb64 8843 ;;
cdfee50a
NS
8844 all)
8845 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The gcc/$i directory contains parts of $language but is missing" >&5
8846$as_echo "$as_me: WARNING: The gcc/$i directory contains parts of $language but is missing" >&2;}
8847 add_this_lang=unsupported
8848 ;;
1546bb64
PB
8849 *)
8850 # Silently disable.
e1888513 8851 add_this_lang=unsupported
1546bb64
PB
8852 ;;
8853 esac
8854 done
8855
e1888513 8856 # Disable Ada if no preexisting GNAT is available.
cdfee50a
NS
8857 case ${add_this_lang}:${language}:${have_gnat} in
8858 yes:ada:no)
e1888513 8859 # Specifically requested language; tell them.
22e05272 8860 as_fn_error $? "GNAT is required to build $language" "$LINENO" 5
e1888513 8861 ;;
cdfee50a
NS
8862 all:ada:no)
8863 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNAT is required to build $language" >&5
8864$as_echo "$as_me: WARNING: GNAT is required to build $language" >&2;}
8865 add_this_lang=unsupported
8866 ;;
e1888513
PB
8867 *:ada:no)
8868 # Silently disable.
8869 add_this_lang=unsupported
8870 ;;
8871 esac
8872
5fee5ec3
IB
8873 # Disable D if no preexisting GDC is available.
8874 case ${add_this_lang}:${language}:${have_gdc} in
8875 yes:d:no)
8876 # Specifically requested language; tell them.
8877 as_fn_error $? "GDC is required to build $language" "$LINENO" 5
8878 ;;
8879 all:d:no)
8880 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GDC is required to build $language" >&5
8881$as_echo "$as_me: WARNING: GDC is required to build $language" >&2;}
8882 add_this_lang=unsupported
8883 ;;
8884 *:d:no)
8885 # Silently disable.
8886 add_this_lang=unsupported
8887 ;;
8888 esac
8889
cdfee50a 8890 # Disable jit if -enable-host-shared not specified
ffac9597
JM
8891 # but not if building for Mingw. All code in Windows
8892 # is position independent code (PIC).
c83027f3
NB
8893 case $target in
8894 *mingw*) ;;
8895 *)
8896 case ${add_this_lang}:${language}:${host_shared} in
8897 yes:jit:no)
8898 # PR jit/64780: explicitly specify --enable-host-shared
22e05272 8899 as_fn_error $? "
cdfee50a
NS
8900Enabling language \"jit\" requires --enable-host-shared.
8901
8902--enable-host-shared typically slows the rest of the compiler down by
8903a few %, so you must explicitly enable it.
8904
8905If you want to build both the jit and the regular compiler, it is often
8906best to do this via two separate configure/builds, in separate
8907directories, to avoid imposing the performance cost of
8908--enable-host-shared on the regular compiler." "$LINENO" 5
c83027f3
NB
8909 ;;
8910 all:jit:no)
8911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-host-shared required to build $language" >&5
cdfee50a 8912$as_echo "$as_me: WARNING: --enable-host-shared required to build $language" >&2;}
c83027f3
NB
8913 add_this_lang=unsupported
8914 ;;
8915 *:jit:no)
8916 # Silently disable.
8917 add_this_lang=unsupported
8918 ;;
8919 esac
8920 ;;
8921 esac
cdfee50a
NS
8922
8923 # Disable a language that is unsupported by the target.
8924 case "${add_this_lang}: $unsupported_languages " in
8925 no:*) ;;
8926 unsupported:*) ;;
8927 *:*" $language "*)
8928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ${language} not supported for this target" >&5
8929$as_echo "$as_me: WARNING: ${language} not supported for this target" >&2;}
e1888513 8930 add_this_lang=unsupported
4fab7234
HPN
8931 ;;
8932 esac
8933
6de9cd9a 8934 case $add_this_lang in
e1888513 8935 unsupported)
55ffb5ed 8936 # Remove language-dependent dirs.
4da3b0f8
ILT
8937 disabled_target_libs="$disabled_target_libs $target_libs"
8938 noconfigdirs="$noconfigdirs $lang_dirs"
2805b53a 8939 ;;
e1888513
PB
8940 no)
8941 # Remove language-dependent dirs; still show language as supported.
4da3b0f8
ILT
8942 disabled_target_libs="$disabled_target_libs $target_libs"
8943 noconfigdirs="$noconfigdirs $lang_dirs"
e1888513
PB
8944 potential_languages="${potential_languages}${language},"
8945 ;;
cdfee50a 8946 all|yes)
e1888513
PB
8947 new_enable_languages="${new_enable_languages}${language},"
8948 potential_languages="${potential_languages}${language},"
2805b53a 8949 missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
4da3b0f8 8950 enabled_target_libs="$enabled_target_libs $target_libs"
ab9dcd0c
RW
8951 case "${boot_language}:,$enable_stage1_languages," in
8952 yes:* | *:*,$language,* | *:*,yes, | *:*,all,)
340de83f 8953 # Add to (comma-separated) list of stage 1 languages.
ab9dcd0c
RW
8954 case ",$stage1_languages," in
8955 *,$language,* | ,yes, | ,all,) ;;
8956 *) stage1_languages="${stage1_languages}${language}," ;;
8957 esac
00020c16 8958 # We need to bootstrap any supporting libraries.
5fee5ec3 8959 bootstrap_target_libs=`echo "${bootstrap_target_libs}${target_libs}," | sed "s/ /,/g"`
2805b53a
NN
8960 ;;
8961 esac
8962 ;;
55ffb5ed
NN
8963 esac
8964 ;;
8965 esac
8966 done
8967
4da3b0f8
ILT
8968 # Add target libraries which are only needed for disabled languages
8969 # to noconfigdirs.
8970 if test -n "$disabled_target_libs"; then
8971 for dir in $disabled_target_libs; do
8972 case " $enabled_target_libs " in
8973 *" ${dir} "*) ;;
8974 *) noconfigdirs="$noconfigdirs $dir" ;;
8975 esac
8976 done
8977 fi
8978
5213506e
RW
8979 # Check whether --enable-stage1-languages was given.
8980if test "${enable_stage1_languages+set}" = set; then :
8981 enableval=$enable_stage1_languages; case ,${enable_stage1_languages}, in
e1888513
PB
8982 ,no,|,,)
8983 # Set it to something that will have no effect in the loop below
8984 enable_stage1_languages=c ;;
8985 ,yes,)
8986 enable_stage1_languages=`echo $new_enable_languages | \
8987 sed -e "s/^,//" -e "s/,$//" ` ;;
8988 *,all,*)
8989 enable_stage1_languages=`echo ,$enable_stage1_languages, | \
8990 sed -e "s/,all,/$new_enable_languages/" -e "s/^,//" -e "s/,$//" ` ;;
8991 esac
8992
8993 # Add "good" languages from enable_stage1_languages to stage1_languages,
8994 # while "bad" languages go in missing_languages. Leave no duplicates.
8995 for i in `echo $enable_stage1_languages | sed 's/,/ /g' `; do
8996 case $potential_languages in
8997 *,$i,*)
8998 case $stage1_languages in
8999 *,$i,*) ;;
9000 *) stage1_languages="$stage1_languages$i," ;;
9001 esac ;;
9002 *)
9003 case $missing_languages in
9004 *,$i,*) ;;
9005 *) missing_languages="$missing_languages$i," ;;
9006 esac ;;
9007 esac
9008 done
5213506e
RW
9009fi
9010
e1888513
PB
9011
9012 # Remove leading/trailing commas that were added for simplicity
9013 potential_languages=`echo "$potential_languages" | sed -e "s/^,//" -e "s/,$//"`
79b4b7d2 9014 missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
e1888513
PB
9015 stage1_languages=`echo "$stage1_languages" | sed -e "s/^,//" -e "s/,$//"`
9016 new_enable_languages=`echo "$new_enable_languages" | sed -e "s/^,//" -e "s/,$//"`
9017
55ffb5ed 9018 if test "x$missing_languages" != x; then
22e05272 9019 as_fn_error $? "
0cf085e4 9020The following requested languages could not be built: ${missing_languages}
5213506e 9021Supported languages are: ${potential_languages}" "$LINENO" 5
55ffb5ed 9022 fi
55ffb5ed
NN
9023 if test "x$new_enable_languages" != "x$enable_languages"; then
9024 echo The following languages will be built: ${new_enable_languages}
e1888513 9025 enable_languages="$new_enable_languages"
55ffb5ed 9026 fi
e1888513 9027
1c710c3c 9028
b2eaac4a 9029 ac_configure_args=`echo " $ac_configure_args" | sed -e "s/ '--enable-languages=[^ ]*'//g" -e "s/$/ '--enable-languages="$enable_languages"'/" `
55ffb5ed
NN
9030fi
9031
27079765
AH
9032# Handle --disable-<component> generically.
9033for dir in $configdirs $build_configdirs $target_configdirs ; do
9034 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g -e s/-/_/g`
ac9e6043
RW
9035 varname=`echo $dirname | sed -e s/+/_/g`
9036 if eval test x\${enable_${varname}} "=" xno ; then
27079765
AH
9037 noconfigdirs="$noconfigdirs $dir"
9038 fi
9039done
9040
43c40f3e
RO
9041# Check for Boehm's garbage collector
9042# Check whether --enable-objc-gc was given.
9043if test "${enable_objc_gc+set}" = set; then :
114bf3f1
MK
9044 enableval=$enable_objc_gc;
9045fi
9046
9047
9048# Check whether --with-target-bdw-gc was given.
9049if test "${with_target_bdw_gc+set}" = set; then :
9050 withval=$with_target_bdw_gc;
9051fi
9052
9053
9054# Check whether --with-target-bdw-gc-include was given.
9055if test "${with_target_bdw_gc_include+set}" = set; then :
9056 withval=$with_target_bdw_gc_include;
9057fi
9058
9059
9060# Check whether --with-target-bdw-gc-lib was given.
9061if test "${with_target_bdw_gc_lib+set}" = set; then :
9062 withval=$with_target_bdw_gc_lib;
9063fi
9064
9065
9066case ,${enable_languages},:${enable_objc_gc} in *,objc,*:yes|*,objc,*:auto)
9067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bdw garbage collector" >&5
9068$as_echo_n "checking for bdw garbage collector... " >&6; }
9069 if test "x$with_target_bdw_gc$with_target_bdw_gc_include$with_target_bdw_gc_lib" = x; then
825fba52
MK
9070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: using bdw-gc in default locations" >&5
9071$as_echo "using bdw-gc in default locations" >&6; }
114bf3f1
MK
9072 else
9073 if test "x$with_target_bdw_gc_include" = x && test "x$with_target_bdw_gc_lib" != x; then
22e05272 9074 as_fn_error $? "found --with-target-bdw-gc-lib but --with-target-bdw-gc-include missing" "$LINENO" 5
114bf3f1 9075 elif test "x$with_target_bdw_gc_include" != x && test "x$with_target_bdw_gc_lib" = x; then
22e05272 9076 as_fn_error $? "found --with-target-bdw-gc-include but --with-target-bdw-gc-lib missing" "$LINENO" 5
114bf3f1
MK
9077 else
9078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: using paths configured with --with-target-bdw-gc options" >&5
9079$as_echo "using paths configured with --with-target-bdw-gc options" >&6; }
9080 fi
9081 fi
43c40f3e
RO
9082esac
9083
5e9d6aa4 9084# Disable libitm, libsanitizer, libvtv, liboffloadmic if we're not building C++
99776ebd 9085case ,${enable_languages}, in
1007a55c 9086 *,c++,*)
5e9d6aa4 9087 # Disable libitm, libsanitizer if we're not building libstdc++
1007a55c
JW
9088 case "${noconfigdirs}" in
9089 *target-libstdc++-v3*)
5e9d6aa4 9090 noconfigdirs="$noconfigdirs target-libitm target-libsanitizer"
1007a55c
JW
9091 ;;
9092 *) ;;
9093 esac
9094 ;;
99776ebd 9095 *)
5e9d6aa4 9096 noconfigdirs="$noconfigdirs target-liboffloadmic target-libitm target-libsanitizer target-libvtv"
99776ebd
RH
9097 ;;
9098esac
9099
dc614a83
AB
9100# If gcc/ is not in the source tree then we'll not be building a
9101# target compiler, assume in that case we don't want to build any
9102# target libraries or tools.
9103#
9104# This was added primarily for the benefit for binutils-gdb who reuse
9105# this configure script, but don't always have target tools available.
9106if test ! -d ${srcdir}/gcc; then
9107 skipdirs="${skipdirs} ${target_configdirs}"
9108fi
9109
ee6a22df
L
9110# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
9111# $build_configdirs and $target_configdirs.
55ffb5ed
NN
9112# If we have the source for $noconfigdirs entries, add them to $notsupp.
9113
9114notsupp=""
9115for dir in . $skipdirs $noconfigdirs ; do
ee6a22df 9116 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
55ffb5ed
NN
9117 if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9118 configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
9119 if test -r $srcdir/$dirname/configure ; then
9120 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9121 true
9122 else
9123 notsupp="$notsupp $dir"
9124 fi
9125 fi
9126 fi
ee6a22df
L
9127 if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9128 build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
9129 if test -r $srcdir/$dirname/configure ; then
9130 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9131 true
9132 else
9133 notsupp="$notsupp $dir"
9134 fi
9135 fi
9136 fi
55ffb5ed
NN
9137 if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9138 target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
9139 if test -r $srcdir/$dirname/configure ; then
9140 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9141 true
9142 else
9143 notsupp="$notsupp $dir"
9144 fi
9145 fi
9146 fi
9147done
9148
55ffb5ed
NN
9149# Quietly strip out all directories which aren't configurable in this tree.
9150# This relies on all configurable subdirectories being autoconfiscated, which
9151# is now the case.
23f6b2f9
PB
9152build_configdirs_all="$build_configdirs"
9153build_configdirs=
9154for i in ${build_configdirs_all} ; do
1c710c3c 9155 j=`echo $i | sed -e s/build-//g`
23f6b2f9
PB
9156 if test -f ${srcdir}/$j/configure ; then
9157 build_configdirs="${build_configdirs} $i"
9158 fi
9159done
9160
55ffb5ed
NN
9161configdirs_all="$configdirs"
9162configdirs=
9163for i in ${configdirs_all} ; do
9164 if test -f ${srcdir}/$i/configure ; then
9165 configdirs="${configdirs} $i"
9166 fi
9167done
23f6b2f9 9168
55ffb5ed
NN
9169target_configdirs_all="$target_configdirs"
9170target_configdirs=
9171for i in ${target_configdirs_all} ; do
1c710c3c 9172 j=`echo $i | sed -e s/target-//g`
55ffb5ed
NN
9173 if test -f ${srcdir}/$j/configure ; then
9174 target_configdirs="${target_configdirs} $i"
9175 fi
9176done
9177
45b3824d
TS
9178# libiberty-linker-plugin is special: it doesn't have its own source directory,
9179# so we have to add it after the preceding checks.
9180if test x"$extra_linker_plugin_flags$extra_linker_plugin_configure_flags" != x
9181then
9182 case " $configdirs " in
9183 *" libiberty "*)
9184 # If we can build libiberty, we can also build libiberty-linker-plugin.
9185 configdirs="$configdirs libiberty-linker-plugin"
9186 extra_linker_plugin_configure_flags="$extra_linker_plugin_configure_flags \
9187 --with-libiberty=../libiberty-linker-plugin";;
9188 *)
22e05272 9189 as_fn_error $? "libiberty missing" "$LINENO" 5;;
45b3824d
TS
9190 esac
9191fi
9192
fca38047
TS
9193# Sometimes we have special requirements for the host libiberty.
9194extra_host_libiberty_configure_flags=
1c01ebf6 9195extra_host_zlib_configure_flags=
fca38047
TS
9196case " $configdirs " in
9197 *" lto-plugin "* | *" libcc1 "*)
9198 # When these are to be built as shared libraries, the same applies to
9199 # libiberty.
9200 extra_host_libiberty_configure_flags=--enable-shared
9201 ;;
1c01ebf6
L
9202 *" bfd "*)
9203 # When bfd is to be built as a shared library, the same applies to
9204 # zlib.
9205 if test "$enable_shared" = "yes"; then
9206 extra_host_zlib_configure_flags=--enable-host-shared
9207 fi
9208 ;;
fca38047
TS
9209esac
9210
9211
1c01ebf6 9212
55ffb5ed
NN
9213# Produce a warning message for the subdirs we can't configure.
9214# This isn't especially interesting in the Cygnus tree, but in the individual
9215# FSF releases, it's important to let people know when their machine isn't
9216# supported by the one or two programs in a package.
9217
9218if test -n "${notsupp}" && test -z "${norecursion}" ; then
9219 # If $appdirs is non-empty, at least one of those directories must still
9220 # be configured, or we error out. (E.g., if the gas release supports a
9221 # specified target in some subdirs but not the gas subdir, we shouldn't
9222 # pretend that all is well.)
9223 if test -n "$appdirs" ; then
9224 for dir in $appdirs ; do
9225 if test -r $dir/Makefile.in ; then
9226 if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9227 appdirs=""
9228 break
9229 fi
23f6b2f9 9230 if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
55ffb5ed
NN
9231 appdirs=""
9232 break
9233 fi
9234 fi
9235 done
9236 if test -n "$appdirs" ; then
9237 echo "*** This configuration is not supported by this package." 1>&2
9238 exit 1
9239 fi
9240 fi
9241 # Okay, some application will build, or we don't care to check. Still
9242 # notify of subdirs not getting built.
9243 echo "*** This configuration is not supported in the following subdirectories:" 1>&2
9244 echo " ${notsupp}" 1>&2
9245 echo " (Any other directories should still work fine.)" 1>&2
9246fi
9247
9248case "$host" in
9249 *msdosdjgpp*)
9250 enable_gdbtk=no ;;
9251esac
9252
c3a86da9
DJ
9253# To find our prefix, in gcc_cv_tool_prefix.
9254
9255# The user is always right.
9256if test "${PATH_SEPARATOR+set}" != set; then
9257 echo "#! /bin/sh" >conf$$.sh
9258 echo "exit 0" >>conf$$.sh
9259 chmod +x conf$$.sh
9260 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
9261 PATH_SEPARATOR=';'
9262 else
9263 PATH_SEPARATOR=:
9264 fi
9265 rm -f conf$$.sh
9266fi
9267
9268
3c36aa6b
JJ
9269 get_gcc_base_ver="cat"
9270
9271# Check whether --with-gcc-major-version-only was given.
9272if test "${with_gcc_major_version_only+set}" = set; then :
9273 withval=$with_gcc_major_version_only; if test x$with_gcc_major_version_only = xyes ; then
31db0fe0 9274 get_gcc_base_ver="sed -e 's/^\([0-9]*\).*/\1/'"
3c36aa6b
JJ
9275 fi
9276
9277fi
9278
9279
9280
9281
9282
c3a86da9
DJ
9283
9284if test "x$exec_prefix" = xNONE; then
9285 if test "x$prefix" = xNONE; then
9286 gcc_cv_tool_prefix=$ac_default_prefix
9287 else
9288 gcc_cv_tool_prefix=$prefix
9289 fi
9290else
9291 gcc_cv_tool_prefix=$exec_prefix
9292fi
9293
9294# If there is no compiler in the tree, use the PATH only. In any
9295# case, if there is no compiler in the tree nobody should use
9296# AS_FOR_TARGET and LD_FOR_TARGET.
9297if test x$host = x$build && test -f $srcdir/gcc/BASE-VER; then
3c36aa6b
JJ
9298 if test x$with_gcc_major_version_only = xyes ; then
9299 gcc_version=`sed -e 's/^\([0-9]*\).*$/\1/' $srcdir/gcc/BASE-VER`
9300 else
9301 gcc_version=`cat $srcdir/gcc/BASE-VER`
9302 fi
c3a86da9
DJ
9303 gcc_cv_tool_dirs="$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
9304 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical$PATH_SEPARATOR"
9305 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
9306 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical$PATH_SEPARATOR"
9307 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
9308 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin$PATH_SEPARATOR"
9309else
9310 gcc_cv_tool_dirs=
9311fi
9312
9313if test x$build = x$target && test -n "$md_exec_prefix"; then
9314 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$md_exec_prefix$PATH_SEPARATOR"
9315fi
9316
9317
9318
55ffb5ed
NN
9319copy_dirs=
9320
1c710c3c 9321
5213506e
RW
9322# Check whether --with-build-sysroot was given.
9323if test "${with_build_sysroot+set}" = set; then :
9324 withval=$with_build_sysroot; if test x"$withval" != x ; then
526635cb
MM
9325 SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
9326 fi
9327else
9328 SYSROOT_CFLAGS_FOR_TARGET=
5213506e 9329fi
526635cb
MM
9330
9331
c8aea42c 9332
5213506e
RW
9333
9334# Check whether --with-debug-prefix-map was given.
9335if test "${with_debug_prefix_map+set}" = set; then :
9336 withval=$with_debug_prefix_map; if test x"$withval" != x; then
c8aea42c
PB
9337 DEBUG_PREFIX_CFLAGS_FOR_TARGET=
9338 for debug_map in $withval; do
9339 DEBUG_PREFIX_CFLAGS_FOR_TARGET="$DEBUG_PREFIX_CFLAGS_FOR_TARGET -fdebug-prefix-map=$debug_map"
9340 done
9341 fi
9342else
9343 DEBUG_PREFIX_CFLAGS_FOR_TARGET=
5213506e
RW
9344fi
9345
c8aea42c
PB
9346
9347
1c8bd6a3
PB
9348# During gcc bootstrap, if we use some random cc for stage1 then CFLAGS
9349# might be empty or "-g". We don't require a C++ compiler, so CXXFLAGS
9350# might also be empty (or "-g", if a non-GCC C++ compiler is in the path).
9351# We want to ensure that TARGET libraries (which we know are built with
9352# gcc) are built with "-O2 -g", so include those options when setting
9353# CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.
9354if test "x$CFLAGS_FOR_TARGET" = x; then
fc30054e
AH
9355 if test "x${is_cross_compiler}" = xyes; then
9356 CFLAGS_FOR_TARGET="-g -O2"
9357 else
9358 CFLAGS_FOR_TARGET=$CFLAGS
9359 case " $CFLAGS " in
9360 *" -O2 "*) ;;
9361 *) CFLAGS_FOR_TARGET="-O2 $CFLAGS_FOR_TARGET" ;;
9362 esac
9363 case " $CFLAGS " in
9364 *" -g "* | *" -g3 "*) ;;
9365 *) CFLAGS_FOR_TARGET="-g $CFLAGS_FOR_TARGET" ;;
9366 esac
9367 fi
1c8bd6a3
PB
9368fi
9369
9370
9371if test "x$CXXFLAGS_FOR_TARGET" = x; then
fc30054e
AH
9372 if test "x${is_cross_compiler}" = xyes; then
9373 CXXFLAGS_FOR_TARGET="-g -O2"
9374 else
9375 CXXFLAGS_FOR_TARGET=$CXXFLAGS
9376 case " $CXXFLAGS " in
9377 *" -O2 "*) ;;
9378 *) CXXFLAGS_FOR_TARGET="-O2 $CXXFLAGS_FOR_TARGET" ;;
9379 esac
9380 case " $CXXFLAGS " in
9381 *" -g "* | *" -g3 "*) ;;
9382 *) CXXFLAGS_FOR_TARGET="-g $CXXFLAGS_FOR_TARGET" ;;
9383 esac
9384 fi
1c8bd6a3
PB
9385fi
9386
9387
6f57bdf6
DK
9388
9389
55ffb5ed
NN
9390# Handle --with-headers=XXX. If the value is not "yes", the contents of
9391# the named directory are copied to $(tooldir)/sys-include.
9392if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
9393 if test x${is_cross_compiler} = xno ; then
9394 echo 1>&2 '***' --with-headers is only supported when cross compiling
9395 exit 1
9396 fi
9397 if test x"${with_headers}" != xyes ; then
c3a86da9 9398 x=${gcc_cv_tool_prefix}
1c710c3c 9399 copy_dirs="${copy_dirs} ${with_headers} $x/${target_noncanonical}/sys-include"
55ffb5ed
NN
9400 fi
9401fi
9402
9403# Handle --with-libs=XXX. If the value is not "yes", the contents of
9404# the name directories are copied to $(tooldir)/lib. Multiple directories
9405# are permitted.
9406if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
9407 if test x${is_cross_compiler} = xno ; then
9408 echo 1>&2 '***' --with-libs is only supported when cross compiling
9409 exit 1
9410 fi
9411 if test x"${with_libs}" != xyes ; then
9412 # Copy the libraries in reverse order, so that files in the first named
9413 # library override files in subsequent libraries.
c3a86da9 9414 x=${gcc_cv_tool_prefix}
55ffb5ed 9415 for l in ${with_libs}; do
1c710c3c 9416 copy_dirs="$l $x/${target_noncanonical}/lib ${copy_dirs}"
55ffb5ed
NN
9417 done
9418 fi
9419fi
9420
d7f09764 9421# Set with_gnu_as, with_gnu_ld, and with_system_zlib as appropriate.
e8b05380
PB
9422#
9423# This is done by determining whether or not the appropriate directory
9424# is available, and by checking whether or not specific configurations
9425# have requested that this magic not happen.
1c710c3c
DJ
9426#
9427# The command line options always override the explicit settings in
6b1786aa 9428# configure.ac, and the settings in configure.ac override this magic.
e8b05380 9429#
1c710c3c 9430# If the default for a toolchain is to use GNU as and ld, and you don't
e8b05380 9431# want to do that, then you should use the --without-gnu-as and
d7f09764
DN
9432# --without-gnu-ld options for the configure script. Similarly, if
9433# the default is to use the included zlib and you don't want to do that,
9434# you should use the --with-system-zlib option for the configure script.
e8b05380
PB
9435
9436if test x${use_gnu_as} = x &&
9437 echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
9438 with_gnu_as=yes
9439 extra_host_args="$extra_host_args --with-gnu-as"
9440fi
9441
9442if test x${use_gnu_ld} = x &&
5afab7ad 9443 echo " ${configdirs} " | egrep " (go)?ld " > /dev/null 2>&1 ; then
e8b05380
PB
9444 with_gnu_ld=yes
9445 extra_host_args="$extra_host_args --with-gnu-ld"
9446fi
9447
d7f09764
DN
9448if test x${use_included_zlib} = x &&
9449 echo " ${configdirs} " | grep " zlib " > /dev/null 2>&1 ; then
9450 :
9451else
9452 with_system_zlib=yes
9453 extra_host_args="$extra_host_args --with-system-zlib"
9454fi
9455
e8b05380
PB
9456# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
9457# can detect this case.
9458
9459if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
9460 with_newlib=yes
9461 extra_host_args="$extra_host_args --with-newlib"
9462fi
9463
55ffb5ed
NN
9464# Handle ${copy_dirs}
9465set fnord ${copy_dirs}
9466shift
9467while test $# != 0 ; do
9468 if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
9469 :
9470 else
9471 echo Copying $1 to $2
9472
9473 # Use the install script to create the directory and all required
9474 # parent directories.
9475 if test -d $2 ; then
9476 :
9477 else
9478 echo >config.temp
9479 ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
9480 fi
9481
9482 # Copy the directory, assuming we have tar.
9483 # FIXME: Should we use B in the second tar? Not all systems support it.
9484 (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
9485
9486 # It is the responsibility of the user to correctly adjust all
9487 # symlinks. If somebody can figure out how to handle them correctly
9488 # here, feel free to add the code.
9489
9490 echo $1 > $2/COPIED
9491 fi
9492 shift; shift
9493done
9494
e8b05380
PB
9495# Determine a target-dependent exec_prefix that the installed
9496# gcc will search in. Keep this list sorted by triplet, with
9497# the *-*-osname triplets last.
9498md_exec_prefix=
9499case "${target}" in
30b74385 9500 i[34567]86-pc-msdosdjgpp*)
e8b05380
PB
9501 md_exec_prefix=/dev/env/DJDIR/bin
9502 ;;
e8b05380 9503 *-*-hpux* | \
e8b05380 9504 *-*-nto-qnx* | \
6de66370 9505 *-*-solaris2*)
e8b05380
PB
9506 md_exec_prefix=/usr/ccs/bin
9507 ;;
9508esac
9509
671aa708
NN
9510extra_arflags_for_target=
9511extra_nmflags_for_target=
9512extra_ranlibflags_for_target=
9513target_makefile_frag=/dev/null
9514case "${target}" in
58e24147
AM
9515 spu-*-*)
9516 target_makefile_frag="config/mt-spu"
9517 ;;
d896cc4d 9518 mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
4bf6c438
RS
9519 target_makefile_frag="config/mt-sde"
9520 ;;
1ec3b87b
RS
9521 mipsisa*-*-elfoabi*)
9522 target_makefile_frag="config/mt-mips-elfoabi"
9523 ;;
08d0963a
RS
9524 mips*-*-*linux* | mips*-*-gnu*)
9525 target_makefile_frag="config/mt-mips-gnu"
9526 ;;
707f1839
SL
9527 nios2-*-elf*)
9528 target_makefile_frag="config/mt-nios2-elf"
9529 ;;
76052545
EB
9530 *-*-linux-android*)
9531 target_makefile_frag="config/mt-android"
9532 ;;
416ac4d4 9533 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
98a5bb3b 9534 target_makefile_frag="config/mt-gnu"
671aa708
NN
9535 ;;
9536 *-*-aix4.[3456789]* | *-*-aix[56789].*)
1c710c3c 9537 # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
671aa708
NN
9538 # commands to handle both 32-bit and 64-bit objects. These flags are
9539 # harmless if we're using GNU nm or ar.
9540 extra_arflags_for_target=" -X32_64"
9541 extra_nmflags_for_target=" -B -X32_64"
9542 ;;
671aa708
NN
9543esac
9544
9545alphaieee_frag=/dev/null
9546case $target in
9547 alpha*-*-*)
9548 # This just makes sure to use the -mieee option to build target libs.
9549 # This should probably be set individually by each library.
9550 alphaieee_frag="config/mt-alphaieee"
9551 ;;
9552esac
9553
9554# If --enable-target-optspace always use -Os instead of -O2 to build
9555# the target libraries, similarly if it is not specified, use -Os
9556# on selected platforms.
9557ospace_frag=/dev/null
9558case "${enable_target_optspace}:${target}" in
9559 yes:*)
9560 ospace_frag="config/mt-ospace"
9561 ;;
9562 :d30v-*)
9563 ospace_frag="config/mt-d30v"
9564 ;;
d9063947 9565 :m32r-* | :d10v-* | :fr30-* | :i?86*-*-elfiamcu)
671aa708
NN
9566 ospace_frag="config/mt-ospace"
9567 ;;
9568 no:* | :*)
9569 ;;
9570 *)
9571 echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
9572 ;;
9573esac
9574
671aa708
NN
9575# Some systems (e.g., one of the i386-aix systems the gas testers are
9576# using) don't handle "\$" correctly, so don't use it here.
1c710c3c 9577tooldir='${exec_prefix}'/${target_noncanonical}
671aa708
NN
9578build_tooldir=${tooldir}
9579
671aa708
NN
9580# Create a .gdbinit file which runs the one in srcdir
9581# and tells GDB to look there for source files.
9582
9583if test -r ${srcdir}/.gdbinit ; then
9584 case ${srcdir} in
9585 .) ;;
9586 *) cat > ./.gdbinit <<EOF
9587# ${NO_EDIT}
9588dir ${srcdir}
9589dir .
9590source ${srcdir}/.gdbinit
9591EOF
9592 ;;
9593 esac
9594fi
9595
671aa708
NN
9596# Make sure that the compiler is able to generate an executable. If it
9597# can't, we are probably in trouble. We don't care whether we can run the
9598# executable--we might be using a cross compiler--we only care whether it
9599# can be created. At this point the main configure script has set CC.
9600we_are_ok=no
9601echo "int main () { return 0; }" > conftest.c
9602${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
9603if test $? = 0 ; then
9604 if test -s conftest || test -s conftest.exe ; then
9605 we_are_ok=yes
9606 fi
1c710c3c 9607fi
671aa708
NN
9608case $we_are_ok in
9609 no)
9610 echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
9611 echo 1>&2 "*** You must set the environment variable CC to a working compiler."
9612 rm -f conftest*
9613 exit 1
9614 ;;
9615esac
9616rm -f conftest*
9617
d89f0ad6 9618# Decide which environment variable is used to find dynamic libraries.
671aa708
NN
9619case "${host}" in
9620 *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
111eeb6e 9621 *-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
d89f0ad6 9622 *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
671aa708
NN
9623 *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
9624esac
9625
d89f0ad6
AL
9626# On systems where the dynamic library environment variable is PATH,
9627# gcc/ will put dynamic libraries into a subdirectory to avoid adding
9628# built executables to PATH.
9629if test "$RPATH_ENVVAR" = PATH; then
9630 GCC_SHLIB_SUBDIR=/shlib
9631else
9632 GCC_SHLIB_SUBDIR=
9633fi
9634
beeda1d9
JJ
9635# Adjust the toplevel makefile according to whether bootstrap was selected.
9636case $enable_bootstrap in
9637 yes)
9638 bootstrap_suffix=bootstrap
9639 BUILD_CONFIG=bootstrap-debug
9640 ;;
9641 no)
9642 bootstrap_suffix=no-bootstrap
9643 BUILD_CONFIG=
9644 ;;
9645esac
9646
9647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default BUILD_CONFIG" >&5
9648$as_echo_n "checking for default BUILD_CONFIG... " >&6; }
9649
9650
9651# Check whether --with-build-config was given.
9652if test "${with_build_config+set}" = set; then :
9653 withval=$with_build_config; case $with_build_config in
9654 yes) with_build_config= ;;
9655 no) with_build_config= BUILD_CONFIG= ;;
9656 esac
9657fi
9658
9659
9660if test "x${with_build_config}" != x; then
9661 BUILD_CONFIG=$with_build_config
9662else
9663 case $BUILD_CONFIG in
9664 bootstrap-debug)
9665 if echo "int f (void) { return 0; }" > conftest.c &&
9666 ${CC} -c conftest.c &&
9667 mv conftest.o conftest.o.g0 &&
9668 ${CC} -c -g conftest.c &&
9669 mv conftest.o conftest.o.g &&
9670 ${srcdir}/contrib/compare-debug conftest.o.g0 conftest.o.g > /dev/null 2>&1; then
9671 :
9672 else
9673 BUILD_CONFIG=
9674 fi
9675 rm -f conftest.c conftest.o conftest.o.g0 conftest.o.g
9676 ;;
9677 esac
9678fi
9679{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CONFIG" >&5
9680$as_echo "$BUILD_CONFIG" >&6; }
9681
9682
9683# Use same top-level configure hooks in libgcc/libstdc++/libvtv.
9684{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-vtable-verify" >&5
9685$as_echo_n "checking for --enable-vtable-verify... " >&6; }
9686# Check whether --enable-vtable-verify was given.
9687if test "${enable_vtable_verify+set}" = set; then :
9688 enableval=$enable_vtable_verify; case "$enableval" in
9689 yes) enable_vtable_verify=yes ;;
9690 no) enable_vtable_verify=no ;;
9691 *) enable_vtable_verify=no;;
9692 esac
9693else
9694 enable_vtable_verify=no
9695fi
9696
9697{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_vtable_verify" >&5
9698$as_echo "$enable_vtable_verify" >&6; }
9699
671aa708
NN
9700# Record target_configdirs and the configure arguments for target and
9701# build configuration in Makefile.
9702target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
23f6b2f9 9703build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
9e1c8fc1 9704bootstrap_fixincludes=no
671aa708 9705
ad1e5170
JR
9706# If we are building libgomp, bootstrap it.
9707if echo " ${target_configdirs} " | grep " libgomp " > /dev/null 2>&1 ; then
9708 bootstrap_target_libs=${bootstrap_target_libs}target-libgomp,
9709fi
9710
beeda1d9
JJ
9711# If we are building libsanitizer and $BUILD_CONFIG contains bootstrap-asan
9712# or bootstrap-ubsan, bootstrap it.
9713if echo " ${target_configdirs} " | grep " libsanitizer " > /dev/null 2>&1; then
9714 case "$BUILD_CONFIG" in
170e618e 9715 *bootstrap-hwasan* | *bootstrap-asan* | *bootstrap-ubsan* )
beeda1d9 9716 bootstrap_target_libs=${bootstrap_target_libs}target-libsanitizer,
9e1c8fc1 9717 bootstrap_fixincludes=yes
beeda1d9
JJ
9718 ;;
9719 esac
ac8701fe
L
9720fi
9721
beeda1d9
JJ
9722# If we are building libvtv and --enable-vtable-verify, bootstrap it.
9723if echo " ${target_configdirs} " | grep " libvtv " > /dev/null 2>&1 &&
9724 test "$enable_vtable_verify" != no; then
2077db1b
CT
9725 bootstrap_target_libs=${bootstrap_target_libs}target-libvtv,
9726fi
9727
5fee5ec3
IB
9728# If we are building libatomic and the list of enabled languages includes the
9729# D frontend, bootstrap it.
9730if echo " ${target_configdirs} " | grep " libatomic " > /dev/null 2>&1; then
9731 case ,${enable_languages}, in
9732 *,d,*)
9733 bootstrap_target_libs=${bootstrap_target_libs}target-libatomic,
9734 ;;
9735 esac
9736fi
9737
671aa708
NN
9738# Determine whether gdb needs tk/tcl or not.
9739# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
9740# and in that case we want gdb to be built without tk. Ugh!
9741# In fact I believe gdb is the *only* package directly dependent on tk,
9742# so we should be able to put the 'maybe's in unconditionally and
9743# leave out the maybe dependencies when enable_gdbtk is false. I'm not
9744# 100% sure that that's safe though.
e914a571 9745
b4f96efe 9746gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
671aa708
NN
9747case "$enable_gdbtk" in
9748 no)
9749 GDB_TK="" ;;
e914a571
AC
9750 yes)
9751 GDB_TK="${gdb_tk}" ;;
671aa708 9752 *)
e914a571
AC
9753 # Only add the dependency on gdbtk when GDBtk is part of the gdb
9754 # distro. Eventually someone will fix this and move Insight, nee
9755 # gdbtk to a separate directory.
9756 if test -d ${srcdir}/gdb/gdbtk ; then
9757 GDB_TK="${gdb_tk}"
9758 else
9759 GDB_TK=""
9760 fi
9761 ;;
671aa708 9762esac
ef9db8d5
DJ
9763CONFIGURE_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-configure-/g`
9764INSTALL_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-install-/g`
671aa708 9765
f9d09df0
TT
9766# gdb and gdbserver depend on gnulib and gdbsupport, but as nothing
9767# else does, only include them if one of these is built. The Makefile
9768# provides the ordering, so it's enough here to add to the list.
9769case " ${configdirs} " in
9770 *\ gdb\ *)
9771 configdirs="${configdirs} gnulib gdbsupport"
9772 ;;
9773 *\ gdbserver\ *)
9774 configdirs="${configdirs} gnulib gdbsupport"
9775 ;;
f14c9bd4
MF
9776 *\ sim\ *)
9777 configdirs="${configdirs} gnulib"
9778 ;;
f9d09df0 9779esac
98e5be21 9780
60975492 9781# Strip out unwanted targets.
8b87bb96
NN
9782
9783# While at that, we remove Makefiles if we were started for recursive
9784# configuration, so that the top-level Makefile reconfigures them,
9785# like we used to do when configure itself was recursive.
8b87bb96 9786
3e54529c
RW
9787# Loop over modules. We used to use the "$extrasub" feature from Autoconf
9788# but now we're fixing up the Makefile ourselves with the additional
9789# commands passed to AC_CONFIG_FILES. Use separate variables
9790# extrasub-{build,host,target} not because there is any reason to split
9791# the substitutions up that way, but only to remain below the limit of
9792# 99 commands in a script, for HP-UX sed.
da34ca3f
AO
9793
9794# Do not nest @if/@endif or @unless/@endunless pairs, because
9795# configure will not warn you at all.
8b87bb96 9796
79cd2b23
RW
9797case "$enable_bootstrap:$ENABLE_GOLD: $configdirs :,$stage1_languages," in
9798 yes:yes:*\ gold\ *:*,c++,*) ;;
9799 yes:yes:*\ gold\ *:*)
22e05272 9800 as_fn_error $? "in a combined tree, bootstrapping with --enable-gold requires c++ in stage1_languages" "$LINENO" 5
79cd2b23
RW
9801 ;;
9802esac
9803
3e54529c 9804extrasub_build=
23f6b2f9 9805for module in ${build_configdirs} ; do
5607edfd
PB
9806 if test -z "${no_recursion}" \
9807 && test -f ${build_subdir}/${module}/Makefile; then
9808 echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
9809 rm -f ${build_subdir}/${module}/Makefile
9810 fi
3e54529c 9811 extrasub_build="$extrasub_build
5607edfd
PB
9812/^@if build-$module\$/d
9813/^@endif build-$module\$/d
da34ca3f 9814/^@unless build-$module\$/,/^@endunless build-$module\$/d
5607edfd 9815/^@if build-$module-$bootstrap_suffix\$/d
da34ca3f
AO
9816/^@endif build-$module-$bootstrap_suffix\$/d
9817/^@unless build-$module-$bootstrap_suffix\$/,/^@endunless build-$module-$bootstrap_suffix\$/d"
5607edfd 9818done
3e54529c 9819extrasub_host=
5607edfd 9820for module in ${configdirs} ; do
a6fbc1e2 9821 if test -z "${no_recursion}"; then
f063a9ed 9822 for file in stage*-${module}/Makefile prev-${module}/Makefile ${module}/Makefile; do
a6fbc1e2
AS
9823 if test -f ${file}; then
9824 echo 1>&2 "*** removing ${file} to force reconfigure"
9825 rm -f ${file}
9826 fi
9827 done
5607edfd 9828 fi
9e1c8fc1
JJ
9829 case ${module},${bootstrap_fixincludes} in
9830 fixincludes,no) host_bootstrap_suffix=no-bootstrap ;;
9831 *) host_bootstrap_suffix=$bootstrap_suffix ;;
9832 esac
3e54529c 9833 extrasub_host="$extrasub_host
5607edfd
PB
9834/^@if $module\$/d
9835/^@endif $module\$/d
da34ca3f 9836/^@unless $module\$/,/^@endunless $module\$/d
9e1c8fc1 9837/^@if $module-$host_bootstrap_suffix\$/d
da34ca3f
AO
9838/^@endif $module-$host_bootstrap_suffix\$/d
9839/^@unless $module-$host_bootstrap_suffix\$/,/^@endunless $module-$host_bootstrap_suffix\$/d"
5607edfd 9840done
3e54529c 9841extrasub_target=
5607edfd
PB
9842for module in ${target_configdirs} ; do
9843 if test -z "${no_recursion}" \
9844 && test -f ${target_subdir}/${module}/Makefile; then
9845 echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
9846 rm -f ${target_subdir}/${module}/Makefile
9847 fi
00020c16
ILT
9848
9849 # We only bootstrap target libraries listed in bootstrap_target_libs.
9850 case $bootstrap_target_libs in
9851 *,target-$module,*) target_bootstrap_suffix=$bootstrap_suffix ;;
9852 *) target_bootstrap_suffix=no-bootstrap ;;
9853 esac
9854
3e54529c 9855 extrasub_target="$extrasub_target
5607edfd
PB
9856/^@if target-$module\$/d
9857/^@endif target-$module\$/d
da34ca3f 9858/^@unless target-$module\$/,/^@endunless target-$module\$/d
00020c16 9859/^@if target-$module-$target_bootstrap_suffix\$/d
da34ca3f
AO
9860/^@endif target-$module-$target_bootstrap_suffix\$/d
9861/^@unless target-$module-$target_bootstrap_suffix\$/,/^@endunless target-$module-$target_bootstrap_suffix\$/d"
5607edfd
PB
9862done
9863
3e54529c
RW
9864# Do the final fixup along with target modules.
9865extrasub_target="$extrasub_target
da34ca3f
AO
9866/^@if /,/^@endif /d
9867/^@unless /d
9868/^@endunless /d"
671aa708 9869
4a5e71f2
L
9870if test "$enable_pgo_build" != "no"; then
9871 extrasub_build="$extrasub_build
9872/^@if pgo-build\$/d
9873/^@endif pgo-build\$/d"
9874fi
9875
671aa708
NN
9876# Create the serialization dependencies. This uses a temporary file.
9877
5213506e
RW
9878# Check whether --enable-serial-configure was given.
9879if test "${enable_serial_configure+set}" = set; then :
9880 enableval=$enable_serial_configure;
9881fi
ade82b16
AO
9882
9883
bf1d3e81
NN
9884case ${enable_serial_configure} in
9885 yes)
9886 enable_serial_build_configure=yes
9887 enable_serial_host_configure=yes
9888 enable_serial_target_configure=yes
9889 ;;
9890esac
9891
671aa708
NN
9892# These force 'configure's to be done one at a time, to avoid problems
9893# with contention over a shared config.cache.
9894rm -f serdep.tmp
ade82b16 9895echo '# serdep.tmp' > serdep.tmp
671aa708 9896olditem=
bf1d3e81 9897test "x${enable_serial_build_configure}" = xyes &&
671aa708
NN
9898for item in ${build_configdirs} ; do
9899 case ${olditem} in
9900 "") ;;
ade82b16 9901 *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
671aa708
NN
9902 esac
9903 olditem=${item}
9904done
9905olditem=
bf1d3e81 9906test "x${enable_serial_host_configure}" = xyes &&
671aa708
NN
9907for item in ${configdirs} ; do
9908 case ${olditem} in
9909 "") ;;
ade82b16 9910 *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
671aa708
NN
9911 esac
9912 olditem=${item}
9913done
9914olditem=
bf1d3e81 9915test "x${enable_serial_target_configure}" = xyes &&
671aa708
NN
9916for item in ${target_configdirs} ; do
9917 case ${olditem} in
9918 "") ;;
ade82b16 9919 *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
671aa708
NN
9920 esac
9921 olditem=${item}
9922done
9923serialization_dependencies=serdep.tmp
9924
9925
ade82b16 9926# Base args. Strip norecursion, cache-file, srcdir, host, build,
1c710c3c 9927# target, nonopt, and variable assignments. These are the ones we
f1a036e4
NC
9928# might not want to pass down to subconfigures. The exception being
9929# --cache-file=/dev/null, which is used to turn off the use of cache
9930# files altogether, and which should be passed on to subconfigures.
9931# Also strip program-prefix, program-suffix, and program-transform-name,
9932# so that we can pass down a consistent program-transform-name.
1c710c3c 9933baseargs=
29a63921 9934tbaseargs=
1c710c3c
DJ
9935keep_next=no
9936skip_next=no
9937eval "set -- $ac_configure_args"
44bfc3ac
DJ
9938for ac_arg
9939do
1c710c3c
DJ
9940 if test X"$skip_next" = X"yes"; then
9941 skip_next=no
9942 continue
9943 fi
9944 if test X"$keep_next" = X"yes"; then
9945 case $ac_arg in
9946 *\'*)
9947 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
9948 esac
9949 baseargs="$baseargs '$ac_arg'"
29a63921 9950 tbaseargs="$tbaseargs '$ac_arg'"
1c710c3c
DJ
9951 keep_next=no
9952 continue
9953 fi
9954
9955 # Handle separated arguments. Based on the logic generated by
9956 # autoconf 2.59.
9957 case $ac_arg in
9958 *=* | --config-cache | -C | -disable-* | --disable-* \
9959 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
9960 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
9961 | -with-* | --with-* | -without-* | --without-* | --x)
9962 separate_arg=no
9963 ;;
9964 -*)
9965 separate_arg=yes
9966 ;;
9967 *)
9968 separate_arg=no
9969 ;;
9970 esac
9971
29a63921
AO
9972 skip_targ=no
9973 case $ac_arg in
9974
9975 --with-* | --without-*)
9976 libopt=`echo "$ac_arg" | sed -e 's,^--[^-_]*[-_],,' -e 's,=.*$,,'`
9977
9978 case $libopt in
9979 *[-_]include)
9980 lib=`echo "$libopt" | sed 's,[-_]include$,,'`
9981 ;;
9982 *[-_]lib)
9983 lib=`echo "$libopt" | sed 's,[-_]lib$,,'`
9984 ;;
9985 *)
9986 lib=$libopt
9987 ;;
9988 esac
9989
9990
9991 case $lib in
4a9bb2aa 9992 mpc | mpfr | gmp | isl)
29a63921
AO
9993 # If we're processing --with-$lib, --with-$lib-include or
9994 # --with-$lib-lib, for one of the libs above, and target is
9995 # different from host, don't pass the current argument to any
9996 # target library's configure.
9997 if test x$is_cross_compiler = xyes; then
9998 skip_targ=yes
9999 fi
10000 ;;
10001 esac
10002 ;;
10003 esac
10004
1c710c3c 10005 case "$ac_arg" in
f1a036e4
NC
10006 --cache-file=/dev/null | \
10007 -cache-file=/dev/null )
10008 # Handled here to avoid the test to skip args below.
10009 baseargs="$baseargs '$ac_arg'"
29a63921 10010 tbaseargs="$tbaseargs '$ac_arg'"
f1a036e4
NC
10011 # Assert: $separate_arg should always be no.
10012 keep_next=$separate_arg
10013 ;;
1c710c3c
DJ
10014 --no*)
10015 continue
10016 ;;
10017 --c* | \
10018 --sr* | \
10019 --ho* | \
10020 --bu* | \
10021 --t* | \
10022 --program-* | \
10023 -cache_file* | \
10024 -srcdir* | \
10025 -host* | \
10026 -build* | \
10027 -target* | \
10028 -program-prefix* | \
10029 -program-suffix* | \
10030 -program-transform-name* )
10031 skip_next=$separate_arg
10032 continue
10033 ;;
10034 -*)
10035 # An option. Add it.
10036 case $ac_arg in
10037 *\'*)
10038 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
10039 esac
10040 baseargs="$baseargs '$ac_arg'"
29a63921
AO
10041 if test X"$skip_targ" = Xno; then
10042 tbaseargs="$tbaseargs '$ac_arg'"
10043 fi
1c710c3c
DJ
10044 keep_next=$separate_arg
10045 ;;
10046 *)
10047 # Either a variable assignment, or a nonopt (triplet). Don't
10048 # pass it down; let the Makefile handle this.
10049 continue
10050 ;;
10051 esac
10052done
10053# Remove the initial space we just introduced and, as these will be
10054# expanded by make, quote '$'.
10055baseargs=`echo "x$baseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
671aa708 10056
43bb47c2
DJ
10057# Add in --program-transform-name, after --program-prefix and
10058# --program-suffix have been applied to it. Autoconf has already
10059# doubled dollar signs and backslashes in program_transform_name; we want
10060# the backslashes un-doubled, and then the entire thing wrapped in single
1c710c3c 10061# quotes, because this will be expanded first by make and then by the shell.
43bb47c2
DJ
10062# Also, because we want to override the logic in subdir configure scripts to
10063# choose program_transform_name, replace any s,x,x, with s,y,y,.
10064sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
10065${program_transform_name}
10066EOF_SED
10067gcc_transform_name=`cat conftestsed.out`
10068rm -f conftestsed.out
10069baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
29a63921 10070tbaseargs="$tbaseargs --program-transform-name='${gcc_transform_name}'"
d9acb717
RW
10071if test "$silent" = yes; then
10072 baseargs="$baseargs --silent"
29a63921 10073 tbaseargs="$tbaseargs --silent"
d9acb717 10074fi
0115d4a3 10075baseargs="$baseargs --disable-option-checking"
29a63921 10076tbaseargs="$tbaseargs --disable-option-checking"
43bb47c2 10077
ffedf511
RW
10078# Record and document user additions to sub configure arguments.
10079
10080
10081
10082
671aa708
NN
10083# For the build-side libraries, we just need to pretend we're native,
10084# and not use the same cache file. Multilibs are neither needed nor
3d96b0d0
HPN
10085# desired. We can't even use the same cache file for all build-side
10086# libraries, as they're compiled differently; some with C, some with
10087# C++ or with different feature-enabling options.
10088build_configargs="$build_configargs --cache-file=./config.cache ${baseargs}"
671aa708
NN
10089
10090# For host modules, accept cache file option, or specification as blank.
10091case "${cache_file}" in
10092"") # empty
10093 cache_file_option="" ;;
10094/* | [A-Za-z]:[\\/]* ) # absolute path
10095 cache_file_option="--cache-file=${cache_file}" ;;
10096*) # relative path
10097 cache_file_option="--cache-file=../${cache_file}" ;;
10098esac
10099
09438bde
NN
10100# Host dirs don't like to share a cache file either, horribly enough.
10101# This seems to be due to autoconf 2.5x stupidity.
ffedf511 10102host_configargs="$host_configargs --cache-file=./config.cache ${extra_host_args} ${baseargs}"
671aa708 10103
29a63921 10104target_configargs="$target_configargs ${tbaseargs}"
671aa708
NN
10105
10106# Passing a --with-cross-host argument lets the target libraries know
10107# whether they are being built with a cross-compiler or being built
10108# native. However, it would be better to use other mechanisms to make the
10109# sorts of decisions they want to make on this basis. Please consider
10110# this option to be deprecated. FIXME.
10111if test x${is_cross_compiler} = xyes ; then
1c710c3c 10112 target_configargs="--with-cross-host=${host_noncanonical} ${target_configargs}"
671aa708
NN
10113fi
10114
79e0604d
FXC
10115# Special user-friendly check for native x86_64-linux build, if
10116# multilib is not explicitly enabled.
10117case "$target:$have_compiler:$host:$target:$enable_multilib" in
10118 x86_64-*linux*:yes:$build:$build:)
e640447c 10119 # Make sure we have a development environment that handles 32-bit
79e0604d
FXC
10120 dev64=no
10121 echo "int main () { return 0; }" > conftest.c
10122 ${CC} -m32 -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
10123 if test $? = 0 ; then
10124 if test -s conftest || test -s conftest.exe ; then
10125 dev64=yes
10126 fi
10127 fi
10128 rm -f conftest*
10129 if test x${dev64} != xyes ; then
22e05272 10130 as_fn_error $? "I suspect your system does not have 32-bit development libraries (libc and headers). If you have them, rerun configure with --enable-multilib. If you do not have them, and want to build a 64-bit-only compiler, rerun configure with --disable-multilib." "$LINENO" 5
79e0604d
FXC
10131 fi
10132 ;;
10133esac
10134
dc683a3f
RW
10135# Default to --enable-multilib.
10136if test x${enable_multilib} = x ; then
671aa708 10137 target_configargs="--enable-multilib ${target_configargs}"
dc683a3f 10138fi
671aa708
NN
10139
10140# Pass --with-newlib if appropriate. Note that target_configdirs has
10141# changed from the earlier setting of with_newlib.
10142if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
10143 target_configargs="--with-newlib ${target_configargs}"
10144fi
10145
6b9eb62c
NN
10146# Different target subdirs use different values of certain variables
10147# (notably CXX). Worse, multilibs use *lots* of different values.
10148# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
10149# it doesn't automatically accept command-line overrides of them.
10150# This means it's not safe for target subdirs to share a cache file,
10151# which is disgusting, but there you have it. Hopefully this can be
10152# fixed in future. It's still worthwhile to use a cache file for each
10153# directory. I think.
10154
bebcd931
MS
10155# Pass the appropriate --build, --host, --target and --cache-file arguments.
10156# We need to pass --target, as newer autoconf's requires consistency
10157# for target_alias and gcc doesn't manage it consistently.
e69bf64b 10158target_configargs="--cache-file=./config.cache ${target_configargs}"
671aa708 10159
671aa708
NN
10160FLAGS_FOR_TARGET=
10161case " $target_configdirs " in
10162 *" newlib "*)
10163 case " $target_configargs " in
10164 *" --with-newlib "*)
10165 case "$target" in
5d571eaa 10166 *-cygwin*)
443e6238 10167 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -isystem $$s/winsup/cygwin/include'
5d571eaa 10168 ;;
671aa708
NN
10169 esac
10170
10171 # If we're not building GCC, don't discard standard headers.
10172 if test -d ${srcdir}/gcc; then
10173 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
10174
10175 if test "${build}" != "${host}"; then
10176 # On Canadian crosses, CC_FOR_TARGET will have already been set
10177 # by `configure', so we won't have an opportunity to add -Bgcc/
10178 # to it. This is right: we don't want to search that directory
10179 # for binaries, but we want the header files in there, so add
10180 # them explicitly.
0463992b 10181 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include -isystem $$r/$(HOST_SUBDIR)/gcc/include-fixed'
671aa708
NN
10182
10183 # Someone might think of using the pre-installed headers on
10184 # Canadian crosses, in case the installed compiler is not fully
10185 # compatible with the compiler being built. In this case, it
10186 # would be better to flag an error than risking having
10187 # incompatible object files being constructed. We can't
10188 # guarantee that an error will be flagged, but let's hope the
10189 # compiler will do it, when presented with incompatible header
10190 # files.
10191 fi
10192 fi
10193
10194 case "${target}-${is_cross_compiler}" in
f2a0e225 10195 i[3456789]86-*-linux*-no)
671aa708
NN
10196 # Here host == target, so we don't need to build gcc,
10197 # so we don't want to discard standard headers.
10198 FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
10199 ;;
10200 *)
10201 # If we're building newlib, use its generic headers last, but search
10202 # for any libc-related directories first (so make it the last -B
10203 # switch).
10204 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
c03353e2
RIL
10205
10206 # If we're building libgloss, find the startup file, simulator library
10207 # and linker script.
10208 case " $target_configdirs " in
10209 *" libgloss "*)
10210 # Look for startup file, simulator library and maybe linker script.
10211 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/libgloss/'"$libgloss_dir"
10212 # Look for libnosys.a in case the target needs it.
10213 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/libnosys'
10214 # Most targets have the linker script in the source directory.
10215 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$s/libgloss/'"$libgloss_dir"
10216 ;;
10217 esac
671aa708
NN
10218 ;;
10219 esac
10220 ;;
10221 esac
10222 ;;
10223esac
5d571eaa 10224
b91f0a41 10225case "$target" in
5d571eaa
OS
10226 x86_64-*mingw* | *-w64-mingw*)
10227 # MinGW-w64 does not use newlib, nor does it use winsup. It may,
10228 # however, use a symlink named 'mingw' in ${prefix} .
10229 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L${prefix}/${target}/lib -L${prefix}/mingw/lib -isystem ${prefix}/${target}/include -isystem ${prefix}/mingw/include'
10230 ;;
10231 *-mingw*)
10232 # MinGW can't be handled as Cygwin above since it does not use newlib.
10233 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/mingw -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/mingw/include -isystem $$s/winsup/w32api/include'
10234 ;;
b91f0a41 10235esac
671aa708 10236
6691a79e
ME
10237# Allow the user to override the flags for
10238# our build compiler if desired.
f019adc1
MF
10239if test x"${build}" = x"${host}" ; then
10240 CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
84401ce5 10241 CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-${CPPFLAGS}}
f019adc1
MF
10242 CXXFLAGS_FOR_BUILD=${CXXFLAGS_FOR_BUILD-${CXXFLAGS}}
10243 LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-${LDFLAGS}}
10244fi
6691a79e 10245
671aa708
NN
10246# On Canadian crosses, we'll be searching the right directories for
10247# the previously-installed cross compiler, so don't bother to add
10248# flags for directories within the install tree of the compiler
10249# being built; programs in there won't even run.
10250if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
10251 # Search for pre-installed headers if nothing else fits.
9124bc53 10252 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
671aa708
NN
10253fi
10254
10255if test "x${use_gnu_ld}" = x &&
10256 echo " ${configdirs} " | grep " ld " > /dev/null ; then
10257 # Arrange for us to find uninstalled linker scripts.
215c351a 10258 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
671aa708
NN
10259fi
10260
e88a2c09
DD
10261# Search for other target-specific linker scripts and such.
10262case "${target}" in
3e19841a
PB
10263 mep*)
10264 FLAGS_FOR_TARGET="$FLAGS_FOR_TARGET -mlibrary"
10265 ;;
e88a2c09
DD
10266esac
10267
671aa708 10268# Makefile fragments.
7b61653a
PE
10269for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
10270do
10271 eval fragval=\$$frag
10272 if test $fragval != /dev/null; then
10273 eval $frag=${srcdir}/$fragval
10274 fi
10275done
671aa708
NN
10276
10277
10278
10279
10280
10281# Miscellanea: directories, flags, etc.
10282
10283
10284
10285
10286
10287
10288
d89f0ad6 10289
23f6b2f9 10290# Build module lists & subconfigure args.
671aa708
NN
10291
10292
10293
2abefe3d
PB
10294# Host module lists & subconfigure args.
10295
10296
10297
aae29963 10298
2abefe3d
PB
10299# Target module lists & subconfigure args.
10300
10301
10302
10303# Build tools.
10304
10305
10306
0999159b
PB
10307
10308
10309
10310
10311
10312
10313
10314
10315
10316
10317
10318
10319
b4c522fa 10320
3b5e8ee4 10321
a1d2b162
IS
10322
10323
2abefe3d
PB
10324# Generate default definitions for YACC, M4, LEX and other programs that run
10325# on the build machine. These are used if the Makefile can't locate these
10326# programs in objdir.
10327MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
10328
10329for ac_prog in 'bison -y' byacc yacc
10330do
1c710c3c 10331 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10332set dummy $ac_prog; ac_word=$2
5213506e
RW
10333{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10334$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10335if ${ac_cv_prog_YACC+:} false; then :
5213506e 10336 $as_echo_n "(cached) " >&6
2abefe3d
PB
10337else
10338 if test -n "$YACC"; then
10339 ac_cv_prog_YACC="$YACC" # Let the user override the test.
10340else
1c710c3c
DJ
10341as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10342for as_dir in $PATH
10343do
10344 IFS=$as_save_IFS
10345 test -z "$as_dir" && as_dir=.
5213506e 10346 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10347 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10348 ac_cv_prog_YACC="$ac_prog"
5213506e 10349 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10350 break 2
10351 fi
10352done
5213506e
RW
10353 done
10354IFS=$as_save_IFS
1c710c3c 10355
2abefe3d
PB
10356fi
10357fi
1c710c3c 10358YACC=$ac_cv_prog_YACC
2abefe3d 10359if test -n "$YACC"; then
5213506e
RW
10360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
10361$as_echo "$YACC" >&6; }
2abefe3d 10362else
5213506e
RW
10363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10364$as_echo "no" >&6; }
2abefe3d
PB
10365fi
10366
5213506e 10367
1c710c3c 10368 test -n "$YACC" && break
2abefe3d
PB
10369done
10370test -n "$YACC" || YACC="$MISSING bison -y"
10371
10372case " $build_configdirs " in
10373 *" bison "*) YACC='$$r/$(BUILD_SUBDIR)/bison/tests/bison -y' ;;
2abefe3d
PB
10374esac
10375
10376for ac_prog in bison
10377do
1c710c3c 10378 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10379set dummy $ac_prog; ac_word=$2
5213506e
RW
10380{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10381$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10382if ${ac_cv_prog_BISON+:} false; then :
5213506e 10383 $as_echo_n "(cached) " >&6
2abefe3d
PB
10384else
10385 if test -n "$BISON"; then
10386 ac_cv_prog_BISON="$BISON" # Let the user override the test.
10387else
1c710c3c
DJ
10388as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10389for as_dir in $PATH
10390do
10391 IFS=$as_save_IFS
10392 test -z "$as_dir" && as_dir=.
5213506e 10393 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10394 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10395 ac_cv_prog_BISON="$ac_prog"
5213506e 10396 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10397 break 2
10398 fi
10399done
5213506e
RW
10400 done
10401IFS=$as_save_IFS
1c710c3c 10402
2abefe3d
PB
10403fi
10404fi
1c710c3c 10405BISON=$ac_cv_prog_BISON
2abefe3d 10406if test -n "$BISON"; then
5213506e
RW
10407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
10408$as_echo "$BISON" >&6; }
2abefe3d 10409else
5213506e
RW
10410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10411$as_echo "no" >&6; }
2abefe3d
PB
10412fi
10413
5213506e 10414
1c710c3c 10415 test -n "$BISON" && break
2abefe3d
PB
10416done
10417test -n "$BISON" || BISON="$MISSING bison"
10418
10419case " $build_configdirs " in
10420 *" bison "*) BISON='$$r/$(BUILD_SUBDIR)/bison/tests/bison' ;;
10421esac
10422
10423for ac_prog in gm4 gnum4 m4
10424do
1c710c3c 10425 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10426set dummy $ac_prog; ac_word=$2
5213506e
RW
10427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10428$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10429if ${ac_cv_prog_M4+:} false; then :
5213506e 10430 $as_echo_n "(cached) " >&6
2abefe3d
PB
10431else
10432 if test -n "$M4"; then
10433 ac_cv_prog_M4="$M4" # Let the user override the test.
10434else
1c710c3c
DJ
10435as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10436for as_dir in $PATH
10437do
10438 IFS=$as_save_IFS
10439 test -z "$as_dir" && as_dir=.
5213506e 10440 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10441 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10442 ac_cv_prog_M4="$ac_prog"
5213506e 10443 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10444 break 2
10445 fi
10446done
5213506e
RW
10447 done
10448IFS=$as_save_IFS
1c710c3c 10449
2abefe3d
PB
10450fi
10451fi
1c710c3c 10452M4=$ac_cv_prog_M4
2abefe3d 10453if test -n "$M4"; then
5213506e
RW
10454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M4" >&5
10455$as_echo "$M4" >&6; }
2abefe3d 10456else
5213506e
RW
10457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10458$as_echo "no" >&6; }
2abefe3d
PB
10459fi
10460
5213506e 10461
1c710c3c 10462 test -n "$M4" && break
2abefe3d
PB
10463done
10464test -n "$M4" || M4="$MISSING m4"
10465
10466case " $build_configdirs " in
10467 *" m4 "*) M4='$$r/$(BUILD_SUBDIR)/m4/m4' ;;
10468esac
10469
10470for ac_prog in flex lex
10471do
1c710c3c 10472 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10473set dummy $ac_prog; ac_word=$2
5213506e
RW
10474{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10475$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10476if ${ac_cv_prog_LEX+:} false; then :
5213506e 10477 $as_echo_n "(cached) " >&6
2abefe3d
PB
10478else
10479 if test -n "$LEX"; then
10480 ac_cv_prog_LEX="$LEX" # Let the user override the test.
10481else
1c710c3c
DJ
10482as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10483for as_dir in $PATH
10484do
10485 IFS=$as_save_IFS
10486 test -z "$as_dir" && as_dir=.
5213506e 10487 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10488 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10489 ac_cv_prog_LEX="$ac_prog"
5213506e 10490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10491 break 2
10492 fi
10493done
5213506e
RW
10494 done
10495IFS=$as_save_IFS
1c710c3c 10496
2abefe3d
PB
10497fi
10498fi
1c710c3c 10499LEX=$ac_cv_prog_LEX
2abefe3d 10500if test -n "$LEX"; then
5213506e
RW
10501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
10502$as_echo "$LEX" >&6; }
2abefe3d 10503else
5213506e
RW
10504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10505$as_echo "no" >&6; }
2abefe3d
PB
10506fi
10507
5213506e 10508
1c710c3c 10509 test -n "$LEX" && break
2abefe3d
PB
10510done
10511test -n "$LEX" || LEX="$MISSING flex"
10512
10513case " $build_configdirs " in
10514 *" flex "*) LEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
10515 *" lex "*) LEX='$$r/$(BUILD_SUBDIR)/lex/lex' ;;
10516esac
10517
10518for ac_prog in flex
10519do
1c710c3c 10520 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10521set dummy $ac_prog; ac_word=$2
5213506e
RW
10522{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10523$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10524if ${ac_cv_prog_FLEX+:} false; then :
5213506e 10525 $as_echo_n "(cached) " >&6
2abefe3d
PB
10526else
10527 if test -n "$FLEX"; then
10528 ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
10529else
1c710c3c
DJ
10530as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10531for as_dir in $PATH
10532do
10533 IFS=$as_save_IFS
10534 test -z "$as_dir" && as_dir=.
5213506e 10535 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10536 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10537 ac_cv_prog_FLEX="$ac_prog"
5213506e 10538 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10539 break 2
10540 fi
10541done
5213506e
RW
10542 done
10543IFS=$as_save_IFS
1c710c3c 10544
2abefe3d
PB
10545fi
10546fi
1c710c3c 10547FLEX=$ac_cv_prog_FLEX
2abefe3d 10548if test -n "$FLEX"; then
5213506e
RW
10549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLEX" >&5
10550$as_echo "$FLEX" >&6; }
2abefe3d 10551else
5213506e
RW
10552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10553$as_echo "no" >&6; }
2abefe3d
PB
10554fi
10555
5213506e 10556
1c710c3c 10557 test -n "$FLEX" && break
2abefe3d
PB
10558done
10559test -n "$FLEX" || FLEX="$MISSING flex"
10560
10561case " $build_configdirs " in
10562 *" flex "*) FLEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
10563esac
10564
10565for ac_prog in makeinfo
10566do
1c710c3c 10567 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10568set dummy $ac_prog; ac_word=$2
5213506e
RW
10569{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10570$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10571if ${ac_cv_prog_MAKEINFO+:} false; then :
5213506e 10572 $as_echo_n "(cached) " >&6
2abefe3d
PB
10573else
10574 if test -n "$MAKEINFO"; then
10575 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
10576else
1c710c3c
DJ
10577as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10578for as_dir in $PATH
10579do
10580 IFS=$as_save_IFS
10581 test -z "$as_dir" && as_dir=.
5213506e 10582 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10584 ac_cv_prog_MAKEINFO="$ac_prog"
5213506e 10585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10586 break 2
10587 fi
10588done
5213506e
RW
10589 done
10590IFS=$as_save_IFS
1c710c3c 10591
2abefe3d
PB
10592fi
10593fi
1c710c3c 10594MAKEINFO=$ac_cv_prog_MAKEINFO
2abefe3d 10595if test -n "$MAKEINFO"; then
5213506e
RW
10596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
10597$as_echo "$MAKEINFO" >&6; }
2abefe3d 10598else
5213506e
RW
10599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10600$as_echo "no" >&6; }
2abefe3d
PB
10601fi
10602
5213506e 10603
1c710c3c 10604 test -n "$MAKEINFO" && break
2abefe3d
PB
10605done
10606test -n "$MAKEINFO" || MAKEINFO="$MISSING makeinfo"
10607
10608case " $build_configdirs " in
10609 *" texinfo "*) MAKEINFO='$$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo' ;;
10610 *)
10611
d18ff35a 10612 # For an installed makeinfo, we require it to be from texinfo 4.7 or
2abefe3d
PB
10613 # higher, else we use the "missing" dummy.
10614 if ${MAKEINFO} --version \
d18ff35a 10615 | egrep 'texinfo[^0-9]*(4\.([7-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
2abefe3d
PB
10616 :
10617 else
10618 MAKEINFO="$MISSING makeinfo"
10619 fi
10620 ;;
10621
10622esac
671aa708 10623
2abefe3d 10624# FIXME: expect and dejagnu may become build tools?
671aa708 10625
2abefe3d
PB
10626for ac_prog in expect
10627do
1c710c3c 10628 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10629set dummy $ac_prog; ac_word=$2
5213506e
RW
10630{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10631$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10632if ${ac_cv_prog_EXPECT+:} false; then :
5213506e 10633 $as_echo_n "(cached) " >&6
2abefe3d
PB
10634else
10635 if test -n "$EXPECT"; then
10636 ac_cv_prog_EXPECT="$EXPECT" # Let the user override the test.
10637else
1c710c3c
DJ
10638as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10639for as_dir in $PATH
10640do
10641 IFS=$as_save_IFS
10642 test -z "$as_dir" && as_dir=.
5213506e 10643 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10644 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10645 ac_cv_prog_EXPECT="$ac_prog"
5213506e 10646 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10647 break 2
10648 fi
10649done
5213506e
RW
10650 done
10651IFS=$as_save_IFS
1c710c3c 10652
2abefe3d
PB
10653fi
10654fi
1c710c3c 10655EXPECT=$ac_cv_prog_EXPECT
2abefe3d 10656if test -n "$EXPECT"; then
5213506e
RW
10657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPECT" >&5
10658$as_echo "$EXPECT" >&6; }
2abefe3d 10659else
5213506e
RW
10660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10661$as_echo "no" >&6; }
2abefe3d 10662fi
671aa708 10663
5213506e 10664
1c710c3c 10665 test -n "$EXPECT" && break
2abefe3d
PB
10666done
10667test -n "$EXPECT" || EXPECT="expect"
671aa708 10668
2abefe3d
PB
10669case " $configdirs " in
10670 *" expect "*)
10671 test $host = $build && EXPECT='$$r/$(HOST_SUBDIR)/expect/expect'
10672 ;;
10673esac
671aa708 10674
2abefe3d
PB
10675for ac_prog in runtest
10676do
1c710c3c 10677 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10678set dummy $ac_prog; ac_word=$2
5213506e
RW
10679{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10680$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10681if ${ac_cv_prog_RUNTEST+:} false; then :
5213506e 10682 $as_echo_n "(cached) " >&6
2abefe3d
PB
10683else
10684 if test -n "$RUNTEST"; then
10685 ac_cv_prog_RUNTEST="$RUNTEST" # Let the user override the test.
fb0103e5 10686else
1c710c3c
DJ
10687as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10688for as_dir in $PATH
10689do
10690 IFS=$as_save_IFS
10691 test -z "$as_dir" && as_dir=.
5213506e 10692 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10693 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10694 ac_cv_prog_RUNTEST="$ac_prog"
5213506e 10695 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10696 break 2
10697 fi
10698done
5213506e
RW
10699 done
10700IFS=$as_save_IFS
1c710c3c 10701
2abefe3d
PB
10702fi
10703fi
1c710c3c 10704RUNTEST=$ac_cv_prog_RUNTEST
2abefe3d 10705if test -n "$RUNTEST"; then
5213506e
RW
10706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUNTEST" >&5
10707$as_echo "$RUNTEST" >&6; }
2abefe3d 10708else
5213506e
RW
10709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10710$as_echo "no" >&6; }
2abefe3d 10711fi
671aa708 10712
5213506e 10713
1c710c3c 10714 test -n "$RUNTEST" && break
2abefe3d
PB
10715done
10716test -n "$RUNTEST" || RUNTEST="runtest"
671aa708 10717
2abefe3d
PB
10718case " $configdirs " in
10719 *" dejagnu "*)
c394e891 10720 test $host = $build && RUNTEST='$$s/$(HOST_SUBDIR)/dejagnu/runtest'
2abefe3d
PB
10721 ;;
10722esac
671aa708
NN
10723
10724
671aa708 10725# Host tools.
ca9f4b81
AO
10726ncn_tool_prefix=
10727test -n "$host_alias" && ncn_tool_prefix=$host_alias-
10728ncn_target_tool_prefix=
10729test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
10730
278a7a38
AO
10731
10732
10733if test -n "$AR"; then
10734 ac_cv_prog_AR=$AR
10735elif test -n "$ac_cv_prog_AR"; then
10736 AR=$ac_cv_prog_AR
10737fi
10738
10739if test -n "$ac_cv_prog_AR"; then
10740 for ncn_progname in ar; do
10741 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
10742set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
10743{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10744$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10745if ${ac_cv_prog_AR+:} false; then :
5213506e 10746 $as_echo_n "(cached) " >&6
278a7a38
AO
10747else
10748 if test -n "$AR"; then
10749 ac_cv_prog_AR="$AR" # Let the user override the test.
10750else
10751as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10752for as_dir in $PATH
10753do
10754 IFS=$as_save_IFS
10755 test -z "$as_dir" && as_dir=.
5213506e 10756 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10757 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 10758 ac_cv_prog_AR="${ncn_progname}"
5213506e 10759 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
10760 break 2
10761 fi
10762done
5213506e
RW
10763 done
10764IFS=$as_save_IFS
278a7a38
AO
10765
10766fi
10767fi
10768AR=$ac_cv_prog_AR
10769if test -n "$AR"; then
5213506e
RW
10770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
10771$as_echo "$AR" >&6; }
278a7a38 10772else
5213506e
RW
10773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10774$as_echo "no" >&6; }
278a7a38
AO
10775fi
10776
5213506e 10777
278a7a38
AO
10778 done
10779fi
10780
10781for ncn_progname in ar; do
2693c0b0
PB
10782 if test -n "$ncn_tool_prefix"; then
10783 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
10784set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
10785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10786$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10787if ${ac_cv_prog_AR+:} false; then :
5213506e 10788 $as_echo_n "(cached) " >&6
ca9f4b81
AO
10789else
10790 if test -n "$AR"; then
10791 ac_cv_prog_AR="$AR" # Let the user override the test.
10792else
1c710c3c
DJ
10793as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10794for as_dir in $PATH
10795do
10796 IFS=$as_save_IFS
10797 test -z "$as_dir" && as_dir=.
5213506e 10798 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10799 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10800 ac_cv_prog_AR="${ncn_tool_prefix}${ncn_progname}"
5213506e 10801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10802 break 2
10803 fi
10804done
5213506e
RW
10805 done
10806IFS=$as_save_IFS
1c710c3c 10807
ca9f4b81
AO
10808fi
10809fi
1c710c3c 10810AR=$ac_cv_prog_AR
ca9f4b81 10811if test -n "$AR"; then
5213506e
RW
10812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
10813$as_echo "$AR" >&6; }
ca9f4b81 10814else
5213506e
RW
10815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10816$as_echo "no" >&6; }
ca9f4b81
AO
10817fi
10818
5213506e 10819
2693c0b0
PB
10820 fi
10821 if test -z "$ac_cv_prog_AR" && test $build = $host ; then
10822 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
10823set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
10824{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10825$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10826if ${ac_cv_prog_AR+:} false; then :
5213506e 10827 $as_echo_n "(cached) " >&6
ca9f4b81 10828else
2693c0b0 10829 if test -n "$AR"; then
af71363e
AS
10830 ac_cv_prog_AR="$AR" # Let the user override the test.
10831else
1c710c3c
DJ
10832as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10833for as_dir in $PATH
10834do
10835 IFS=$as_save_IFS
10836 test -z "$as_dir" && as_dir=.
5213506e 10837 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10838 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10839 ac_cv_prog_AR="${ncn_progname}"
5213506e 10840 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10841 break 2
10842 fi
10843done
5213506e
RW
10844 done
10845IFS=$as_save_IFS
1c710c3c 10846
ca9f4b81
AO
10847fi
10848fi
1c710c3c 10849AR=$ac_cv_prog_AR
2693c0b0 10850if test -n "$AR"; then
5213506e
RW
10851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
10852$as_echo "$AR" >&6; }
ca9f4b81 10853else
5213506e
RW
10854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10855$as_echo "no" >&6; }
ca9f4b81 10856fi
1c710c3c 10857
5213506e 10858
2693c0b0
PB
10859 fi
10860 test -n "$ac_cv_prog_AR" && break
10861done
10862
10863if test -z "$ac_cv_prog_AR" ; then
10864 set dummy ar
10865 if test $build = $host ; then
10866 AR="$2"
ca9f4b81 10867 else
2693c0b0 10868 AR="${ncn_tool_prefix}$2"
ca9f4b81 10869 fi
ca9f4b81
AO
10870fi
10871
278a7a38
AO
10872
10873
10874if test -n "$AS"; then
10875 ac_cv_prog_AS=$AS
10876elif test -n "$ac_cv_prog_AS"; then
10877 AS=$ac_cv_prog_AS
10878fi
10879
10880if test -n "$ac_cv_prog_AS"; then
10881 for ncn_progname in as; do
10882 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
10883set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
10884{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10885$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10886if ${ac_cv_prog_AS+:} false; then :
5213506e 10887 $as_echo_n "(cached) " >&6
278a7a38
AO
10888else
10889 if test -n "$AS"; then
10890 ac_cv_prog_AS="$AS" # Let the user override the test.
10891else
10892as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10893for as_dir in $PATH
10894do
10895 IFS=$as_save_IFS
10896 test -z "$as_dir" && as_dir=.
5213506e 10897 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10898 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 10899 ac_cv_prog_AS="${ncn_progname}"
5213506e 10900 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
10901 break 2
10902 fi
10903done
5213506e
RW
10904 done
10905IFS=$as_save_IFS
278a7a38
AO
10906
10907fi
10908fi
10909AS=$ac_cv_prog_AS
10910if test -n "$AS"; then
5213506e
RW
10911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
10912$as_echo "$AS" >&6; }
278a7a38 10913else
5213506e
RW
10914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10915$as_echo "no" >&6; }
278a7a38
AO
10916fi
10917
5213506e 10918
278a7a38
AO
10919 done
10920fi
10921
10922for ncn_progname in as; do
2693c0b0
PB
10923 if test -n "$ncn_tool_prefix"; then
10924 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
10925set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
10926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10927$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10928if ${ac_cv_prog_AS+:} false; then :
5213506e 10929 $as_echo_n "(cached) " >&6
ca9f4b81
AO
10930else
10931 if test -n "$AS"; then
10932 ac_cv_prog_AS="$AS" # Let the user override the test.
0b0dc272 10933else
1c710c3c
DJ
10934as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10935for as_dir in $PATH
10936do
10937 IFS=$as_save_IFS
10938 test -z "$as_dir" && as_dir=.
5213506e 10939 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10940 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10941 ac_cv_prog_AS="${ncn_tool_prefix}${ncn_progname}"
5213506e 10942 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10943 break 2
10944 fi
10945done
5213506e
RW
10946 done
10947IFS=$as_save_IFS
1c710c3c 10948
ca9f4b81
AO
10949fi
10950fi
1c710c3c 10951AS=$ac_cv_prog_AS
ca9f4b81 10952if test -n "$AS"; then
5213506e
RW
10953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
10954$as_echo "$AS" >&6; }
ca9f4b81 10955else
5213506e
RW
10956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10957$as_echo "no" >&6; }
ca9f4b81
AO
10958fi
10959
5213506e 10960
2693c0b0
PB
10961 fi
10962 if test -z "$ac_cv_prog_AS" && test $build = $host ; then
10963 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
10964set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
10965{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10966$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10967if ${ac_cv_prog_AS+:} false; then :
5213506e 10968 $as_echo_n "(cached) " >&6
ca9f4b81 10969else
2693c0b0
PB
10970 if test -n "$AS"; then
10971 ac_cv_prog_AS="$AS" # Let the user override the test.
ca9f4b81 10972else
1c710c3c
DJ
10973as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10974for as_dir in $PATH
10975do
10976 IFS=$as_save_IFS
10977 test -z "$as_dir" && as_dir=.
5213506e 10978 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10979 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10980 ac_cv_prog_AS="${ncn_progname}"
5213506e 10981 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10982 break 2
10983 fi
10984done
5213506e
RW
10985 done
10986IFS=$as_save_IFS
1c710c3c 10987
ca9f4b81
AO
10988fi
10989fi
1c710c3c 10990AS=$ac_cv_prog_AS
2693c0b0 10991if test -n "$AS"; then
5213506e
RW
10992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
10993$as_echo "$AS" >&6; }
ca9f4b81 10994else
5213506e
RW
10995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10996$as_echo "no" >&6; }
ca9f4b81 10997fi
1c710c3c 10998
5213506e 10999
2693c0b0
PB
11000 fi
11001 test -n "$ac_cv_prog_AS" && break
11002done
11003
11004if test -z "$ac_cv_prog_AS" ; then
11005 set dummy as
11006 if test $build = $host ; then
11007 AS="$2"
ca9f4b81 11008 else
2693c0b0 11009 AS="${ncn_tool_prefix}$2"
ca9f4b81 11010 fi
ca9f4b81
AO
11011fi
11012
278a7a38
AO
11013
11014
11015if test -n "$DLLTOOL"; then
11016 ac_cv_prog_DLLTOOL=$DLLTOOL
11017elif test -n "$ac_cv_prog_DLLTOOL"; then
11018 DLLTOOL=$ac_cv_prog_DLLTOOL
11019fi
11020
11021if test -n "$ac_cv_prog_DLLTOOL"; then
11022 for ncn_progname in dlltool; do
11023 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11024set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11025{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11026$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11027if ${ac_cv_prog_DLLTOOL+:} false; then :
5213506e 11028 $as_echo_n "(cached) " >&6
278a7a38
AO
11029else
11030 if test -n "$DLLTOOL"; then
11031 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
11032else
11033as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11034for as_dir in $PATH
11035do
11036 IFS=$as_save_IFS
11037 test -z "$as_dir" && as_dir=.
5213506e 11038 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11039 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11040 ac_cv_prog_DLLTOOL="${ncn_progname}"
5213506e 11041 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11042 break 2
11043 fi
11044done
5213506e
RW
11045 done
11046IFS=$as_save_IFS
278a7a38
AO
11047
11048fi
11049fi
11050DLLTOOL=$ac_cv_prog_DLLTOOL
11051if test -n "$DLLTOOL"; then
5213506e
RW
11052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11053$as_echo "$DLLTOOL" >&6; }
278a7a38 11054else
5213506e
RW
11055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11056$as_echo "no" >&6; }
278a7a38
AO
11057fi
11058
5213506e 11059
278a7a38
AO
11060 done
11061fi
11062
11063for ncn_progname in dlltool; do
2693c0b0
PB
11064 if test -n "$ncn_tool_prefix"; then
11065 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11066set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11067{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11068$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11069if ${ac_cv_prog_DLLTOOL+:} false; then :
5213506e 11070 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11071else
11072 if test -n "$DLLTOOL"; then
11073 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
11074else
1c710c3c
DJ
11075as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11076for as_dir in $PATH
11077do
11078 IFS=$as_save_IFS
11079 test -z "$as_dir" && as_dir=.
5213506e 11080 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11082 ac_cv_prog_DLLTOOL="${ncn_tool_prefix}${ncn_progname}"
5213506e 11083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11084 break 2
11085 fi
11086done
5213506e
RW
11087 done
11088IFS=$as_save_IFS
1c710c3c 11089
ca9f4b81
AO
11090fi
11091fi
1c710c3c 11092DLLTOOL=$ac_cv_prog_DLLTOOL
ca9f4b81 11093if test -n "$DLLTOOL"; then
5213506e
RW
11094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11095$as_echo "$DLLTOOL" >&6; }
ca9f4b81 11096else
5213506e
RW
11097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11098$as_echo "no" >&6; }
ca9f4b81
AO
11099fi
11100
5213506e 11101
2693c0b0
PB
11102 fi
11103 if test -z "$ac_cv_prog_DLLTOOL" && test $build = $host ; then
11104 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11105set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11106{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11107$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11108if ${ac_cv_prog_DLLTOOL+:} false; then :
5213506e 11109 $as_echo_n "(cached) " >&6
ca9f4b81 11110else
2693c0b0
PB
11111 if test -n "$DLLTOOL"; then
11112 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
ca9f4b81 11113else
1c710c3c
DJ
11114as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11115for as_dir in $PATH
11116do
11117 IFS=$as_save_IFS
11118 test -z "$as_dir" && as_dir=.
5213506e 11119 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11120 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11121 ac_cv_prog_DLLTOOL="${ncn_progname}"
5213506e 11122 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11123 break 2
11124 fi
11125done
5213506e
RW
11126 done
11127IFS=$as_save_IFS
1c710c3c 11128
ca9f4b81
AO
11129fi
11130fi
1c710c3c 11131DLLTOOL=$ac_cv_prog_DLLTOOL
2693c0b0 11132if test -n "$DLLTOOL"; then
5213506e
RW
11133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11134$as_echo "$DLLTOOL" >&6; }
ca9f4b81 11135else
5213506e
RW
11136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11137$as_echo "no" >&6; }
ca9f4b81 11138fi
1c710c3c 11139
5213506e 11140
2693c0b0
PB
11141 fi
11142 test -n "$ac_cv_prog_DLLTOOL" && break
11143done
11144
11145if test -z "$ac_cv_prog_DLLTOOL" ; then
11146 set dummy dlltool
11147 if test $build = $host ; then
11148 DLLTOOL="$2"
ca9f4b81 11149 else
2693c0b0 11150 DLLTOOL="${ncn_tool_prefix}$2"
ca9f4b81 11151 fi
ca9f4b81
AO
11152fi
11153
278a7a38
AO
11154
11155
3b5e8ee4
IS
11156if test -n "$DSYMUTIL"; then
11157 ac_cv_prog_DSYMUTIL=$DSYMUTIL
11158elif test -n "$ac_cv_prog_DSYMUTIL"; then
11159 DSYMUTIL=$ac_cv_prog_DSYMUTIL
11160fi
11161
11162if test -n "$ac_cv_prog_DSYMUTIL"; then
11163 for ncn_progname in dsymutil; do
11164 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11165set dummy ${ncn_progname}; ac_word=$2
11166{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11167$as_echo_n "checking for $ac_word... " >&6; }
11168if ${ac_cv_prog_DSYMUTIL+:} false; then :
11169 $as_echo_n "(cached) " >&6
11170else
11171 if test -n "$DSYMUTIL"; then
11172 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
11173else
11174as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11175for as_dir in $PATH
11176do
11177 IFS=$as_save_IFS
11178 test -z "$as_dir" && as_dir=.
11179 for ac_exec_ext in '' $ac_executable_extensions; do
11180 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11181 ac_cv_prog_DSYMUTIL="${ncn_progname}"
11182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11183 break 2
11184 fi
11185done
11186 done
11187IFS=$as_save_IFS
11188
11189fi
11190fi
11191DSYMUTIL=$ac_cv_prog_DSYMUTIL
11192if test -n "$DSYMUTIL"; then
11193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
11194$as_echo "$DSYMUTIL" >&6; }
11195else
11196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11197$as_echo "no" >&6; }
11198fi
11199
11200
11201 done
11202fi
11203
11204for ncn_progname in dsymutil; do
11205 if test -n "$ncn_tool_prefix"; then
11206 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11207set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
11208{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11209$as_echo_n "checking for $ac_word... " >&6; }
11210if ${ac_cv_prog_DSYMUTIL+:} false; then :
11211 $as_echo_n "(cached) " >&6
11212else
11213 if test -n "$DSYMUTIL"; then
11214 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
11215else
11216as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11217for as_dir in $PATH
11218do
11219 IFS=$as_save_IFS
11220 test -z "$as_dir" && as_dir=.
11221 for ac_exec_ext in '' $ac_executable_extensions; do
11222 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11223 ac_cv_prog_DSYMUTIL="${ncn_tool_prefix}${ncn_progname}"
11224 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11225 break 2
11226 fi
11227done
11228 done
11229IFS=$as_save_IFS
11230
11231fi
11232fi
11233DSYMUTIL=$ac_cv_prog_DSYMUTIL
11234if test -n "$DSYMUTIL"; then
11235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
11236$as_echo "$DSYMUTIL" >&6; }
11237else
11238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11239$as_echo "no" >&6; }
11240fi
11241
11242
11243 fi
11244 if test -z "$ac_cv_prog_DSYMUTIL" && test $build = $host ; then
11245 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11246set dummy ${ncn_progname}; ac_word=$2
11247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11248$as_echo_n "checking for $ac_word... " >&6; }
11249if ${ac_cv_prog_DSYMUTIL+:} false; then :
11250 $as_echo_n "(cached) " >&6
11251else
11252 if test -n "$DSYMUTIL"; then
11253 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
11254else
11255as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11256for as_dir in $PATH
11257do
11258 IFS=$as_save_IFS
11259 test -z "$as_dir" && as_dir=.
11260 for ac_exec_ext in '' $ac_executable_extensions; do
11261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11262 ac_cv_prog_DSYMUTIL="${ncn_progname}"
11263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11264 break 2
11265 fi
11266done
11267 done
11268IFS=$as_save_IFS
11269
11270fi
11271fi
11272DSYMUTIL=$ac_cv_prog_DSYMUTIL
11273if test -n "$DSYMUTIL"; then
11274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
11275$as_echo "$DSYMUTIL" >&6; }
11276else
11277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11278$as_echo "no" >&6; }
11279fi
11280
11281
11282 fi
11283 test -n "$ac_cv_prog_DSYMUTIL" && break
11284done
11285
11286if test -z "$ac_cv_prog_DSYMUTIL" ; then
11287 set dummy dsymutil
11288 if test $build = $host ; then
11289 DSYMUTIL="$2"
11290 else
11291 DSYMUTIL="${ncn_tool_prefix}$2"
11292 fi
11293fi
11294
11295
11296
278a7a38
AO
11297if test -n "$LD"; then
11298 ac_cv_prog_LD=$LD
11299elif test -n "$ac_cv_prog_LD"; then
11300 LD=$ac_cv_prog_LD
11301fi
11302
11303if test -n "$ac_cv_prog_LD"; then
11304 for ncn_progname in ld; do
11305 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11306set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11307{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11308$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11309if ${ac_cv_prog_LD+:} false; then :
5213506e 11310 $as_echo_n "(cached) " >&6
278a7a38
AO
11311else
11312 if test -n "$LD"; then
11313 ac_cv_prog_LD="$LD" # Let the user override the test.
11314else
11315as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11316for as_dir in $PATH
11317do
11318 IFS=$as_save_IFS
11319 test -z "$as_dir" && as_dir=.
5213506e 11320 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11321 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11322 ac_cv_prog_LD="${ncn_progname}"
5213506e 11323 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11324 break 2
11325 fi
11326done
5213506e
RW
11327 done
11328IFS=$as_save_IFS
278a7a38
AO
11329
11330fi
11331fi
11332LD=$ac_cv_prog_LD
11333if test -n "$LD"; then
5213506e
RW
11334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
11335$as_echo "$LD" >&6; }
278a7a38 11336else
5213506e
RW
11337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11338$as_echo "no" >&6; }
278a7a38
AO
11339fi
11340
5213506e 11341
278a7a38
AO
11342 done
11343fi
11344
11345for ncn_progname in ld; do
2693c0b0
PB
11346 if test -n "$ncn_tool_prefix"; then
11347 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11348set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11349{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11350$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11351if ${ac_cv_prog_LD+:} false; then :
5213506e 11352 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11353else
11354 if test -n "$LD"; then
11355 ac_cv_prog_LD="$LD" # Let the user override the test.
11356else
1c710c3c
DJ
11357as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11358for as_dir in $PATH
11359do
11360 IFS=$as_save_IFS
11361 test -z "$as_dir" && as_dir=.
5213506e 11362 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11363 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11364 ac_cv_prog_LD="${ncn_tool_prefix}${ncn_progname}"
5213506e 11365 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11366 break 2
11367 fi
11368done
5213506e
RW
11369 done
11370IFS=$as_save_IFS
1c710c3c 11371
ca9f4b81
AO
11372fi
11373fi
1c710c3c 11374LD=$ac_cv_prog_LD
ca9f4b81 11375if test -n "$LD"; then
5213506e
RW
11376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
11377$as_echo "$LD" >&6; }
ca9f4b81 11378else
5213506e
RW
11379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11380$as_echo "no" >&6; }
ca9f4b81
AO
11381fi
11382
5213506e 11383
2693c0b0
PB
11384 fi
11385 if test -z "$ac_cv_prog_LD" && test $build = $host ; then
11386 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11387set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11388{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11389$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11390if ${ac_cv_prog_LD+:} false; then :
5213506e 11391 $as_echo_n "(cached) " >&6
ca9f4b81 11392else
2693c0b0
PB
11393 if test -n "$LD"; then
11394 ac_cv_prog_LD="$LD" # Let the user override the test.
6b65a26d 11395else
1c710c3c
DJ
11396as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11397for as_dir in $PATH
11398do
11399 IFS=$as_save_IFS
11400 test -z "$as_dir" && as_dir=.
5213506e 11401 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11402 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11403 ac_cv_prog_LD="${ncn_progname}"
5213506e 11404 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11405 break 2
11406 fi
11407done
5213506e
RW
11408 done
11409IFS=$as_save_IFS
1c710c3c 11410
ca9f4b81
AO
11411fi
11412fi
1c710c3c 11413LD=$ac_cv_prog_LD
2693c0b0 11414if test -n "$LD"; then
5213506e
RW
11415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
11416$as_echo "$LD" >&6; }
ca9f4b81 11417else
5213506e
RW
11418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11419$as_echo "no" >&6; }
ca9f4b81 11420fi
1c710c3c 11421
5213506e 11422
2693c0b0
PB
11423 fi
11424 test -n "$ac_cv_prog_LD" && break
11425done
11426
11427if test -z "$ac_cv_prog_LD" ; then
11428 set dummy ld
11429 if test $build = $host ; then
11430 LD="$2"
ca9f4b81 11431 else
2693c0b0 11432 LD="${ncn_tool_prefix}$2"
ca9f4b81 11433 fi
ca9f4b81
AO
11434fi
11435
278a7a38
AO
11436
11437
11438if test -n "$LIPO"; then
11439 ac_cv_prog_LIPO=$LIPO
11440elif test -n "$ac_cv_prog_LIPO"; then
11441 LIPO=$ac_cv_prog_LIPO
11442fi
11443
11444if test -n "$ac_cv_prog_LIPO"; then
11445 for ncn_progname in lipo; do
11446 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11447set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11448{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11449$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11450if ${ac_cv_prog_LIPO+:} false; then :
5213506e 11451 $as_echo_n "(cached) " >&6
278a7a38
AO
11452else
11453 if test -n "$LIPO"; then
11454 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
11455else
11456as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11457for as_dir in $PATH
11458do
11459 IFS=$as_save_IFS
11460 test -z "$as_dir" && as_dir=.
5213506e 11461 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11463 ac_cv_prog_LIPO="${ncn_progname}"
5213506e 11464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11465 break 2
11466 fi
11467done
5213506e
RW
11468 done
11469IFS=$as_save_IFS
278a7a38
AO
11470
11471fi
11472fi
11473LIPO=$ac_cv_prog_LIPO
11474if test -n "$LIPO"; then
5213506e
RW
11475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
11476$as_echo "$LIPO" >&6; }
278a7a38 11477else
5213506e
RW
11478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11479$as_echo "no" >&6; }
278a7a38
AO
11480fi
11481
5213506e 11482
278a7a38
AO
11483 done
11484fi
11485
11486for ncn_progname in lipo; do
2abefe3d
PB
11487 if test -n "$ncn_tool_prefix"; then
11488 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11489set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11490{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11491$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11492if ${ac_cv_prog_LIPO+:} false; then :
5213506e 11493 $as_echo_n "(cached) " >&6
2abefe3d
PB
11494else
11495 if test -n "$LIPO"; then
11496 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
11497else
1c710c3c
DJ
11498as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11499for as_dir in $PATH
11500do
11501 IFS=$as_save_IFS
11502 test -z "$as_dir" && as_dir=.
5213506e 11503 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11504 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11505 ac_cv_prog_LIPO="${ncn_tool_prefix}${ncn_progname}"
5213506e 11506 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11507 break 2
11508 fi
11509done
5213506e
RW
11510 done
11511IFS=$as_save_IFS
1c710c3c 11512
2abefe3d
PB
11513fi
11514fi
1c710c3c 11515LIPO=$ac_cv_prog_LIPO
2abefe3d 11516if test -n "$LIPO"; then
5213506e
RW
11517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
11518$as_echo "$LIPO" >&6; }
2abefe3d 11519else
5213506e
RW
11520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11521$as_echo "no" >&6; }
2abefe3d
PB
11522fi
11523
5213506e 11524
2abefe3d
PB
11525 fi
11526 if test -z "$ac_cv_prog_LIPO" && test $build = $host ; then
11527 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11528set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11530$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11531if ${ac_cv_prog_LIPO+:} false; then :
5213506e 11532 $as_echo_n "(cached) " >&6
2abefe3d
PB
11533else
11534 if test -n "$LIPO"; then
11535 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
11536else
1c710c3c
DJ
11537as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11538for as_dir in $PATH
11539do
11540 IFS=$as_save_IFS
11541 test -z "$as_dir" && as_dir=.
5213506e 11542 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11544 ac_cv_prog_LIPO="${ncn_progname}"
5213506e 11545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11546 break 2
11547 fi
11548done
5213506e
RW
11549 done
11550IFS=$as_save_IFS
1c710c3c 11551
2abefe3d
PB
11552fi
11553fi
1c710c3c 11554LIPO=$ac_cv_prog_LIPO
2abefe3d 11555if test -n "$LIPO"; then
5213506e
RW
11556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
11557$as_echo "$LIPO" >&6; }
2abefe3d 11558else
5213506e
RW
11559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11560$as_echo "no" >&6; }
2abefe3d 11561fi
1c710c3c 11562
5213506e 11563
2abefe3d
PB
11564 fi
11565 test -n "$ac_cv_prog_LIPO" && break
11566done
11567
11568if test -z "$ac_cv_prog_LIPO" ; then
11569 set dummy lipo
11570 if test $build = $host ; then
11571 LIPO="$2"
11572 else
11573 LIPO="${ncn_tool_prefix}$2"
11574 fi
11575fi
11576
278a7a38
AO
11577
11578
11579if test -n "$NM"; then
11580 ac_cv_prog_NM=$NM
11581elif test -n "$ac_cv_prog_NM"; then
11582 NM=$ac_cv_prog_NM
11583fi
11584
11585if test -n "$ac_cv_prog_NM"; then
11586 for ncn_progname in nm; do
11587 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11588set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11589{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11590$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11591if ${ac_cv_prog_NM+:} false; then :
5213506e 11592 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11593else
11594 if test -n "$NM"; then
11595 ac_cv_prog_NM="$NM" # Let the user override the test.
11596else
1c710c3c
DJ
11597as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11598for as_dir in $PATH
11599do
11600 IFS=$as_save_IFS
11601 test -z "$as_dir" && as_dir=.
5213506e 11602 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11603 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11604 ac_cv_prog_NM="${ncn_progname}"
5213506e 11605 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11606 break 2
11607 fi
11608done
5213506e
RW
11609 done
11610IFS=$as_save_IFS
1c710c3c 11611
ca9f4b81
AO
11612fi
11613fi
1c710c3c 11614NM=$ac_cv_prog_NM
ca9f4b81 11615if test -n "$NM"; then
5213506e
RW
11616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
11617$as_echo "$NM" >&6; }
ca9f4b81 11618else
5213506e
RW
11619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11620$as_echo "no" >&6; }
ca9f4b81
AO
11621fi
11622
5213506e 11623
278a7a38
AO
11624 done
11625fi
11626
11627for ncn_progname in nm; do
11628 if test -n "$ncn_tool_prefix"; then
11629 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11630set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11631{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11632$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11633if ${ac_cv_prog_NM+:} false; then :
5213506e 11634 $as_echo_n "(cached) " >&6
ca9f4b81 11635else
2693c0b0
PB
11636 if test -n "$NM"; then
11637 ac_cv_prog_NM="$NM" # Let the user override the test.
ca9f4b81 11638else
1c710c3c
DJ
11639as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11640for as_dir in $PATH
11641do
11642 IFS=$as_save_IFS
11643 test -z "$as_dir" && as_dir=.
5213506e 11644 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11645 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11646 ac_cv_prog_NM="${ncn_tool_prefix}${ncn_progname}"
5213506e 11647 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11648 break 2
11649 fi
11650done
5213506e
RW
11651 done
11652IFS=$as_save_IFS
1c710c3c 11653
ca9f4b81
AO
11654fi
11655fi
1c710c3c 11656NM=$ac_cv_prog_NM
2693c0b0 11657if test -n "$NM"; then
5213506e
RW
11658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
11659$as_echo "$NM" >&6; }
ca9f4b81 11660else
5213506e
RW
11661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11662$as_echo "no" >&6; }
ca9f4b81 11663fi
1c710c3c 11664
5213506e 11665
2693c0b0 11666 fi
278a7a38
AO
11667 if test -z "$ac_cv_prog_NM" && test $build = $host ; then
11668 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11669set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11670{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11671$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11672if ${ac_cv_prog_NM+:} false; then :
5213506e 11673 $as_echo_n "(cached) " >&6
278a7a38
AO
11674else
11675 if test -n "$NM"; then
11676 ac_cv_prog_NM="$NM" # Let the user override the test.
11677else
11678as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11679for as_dir in $PATH
11680do
11681 IFS=$as_save_IFS
11682 test -z "$as_dir" && as_dir=.
5213506e 11683 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11684 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11685 ac_cv_prog_NM="${ncn_progname}"
5213506e 11686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11687 break 2
11688 fi
11689done
5213506e
RW
11690 done
11691IFS=$as_save_IFS
278a7a38
AO
11692
11693fi
11694fi
11695NM=$ac_cv_prog_NM
11696if test -n "$NM"; then
5213506e
RW
11697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
11698$as_echo "$NM" >&6; }
278a7a38 11699else
5213506e
RW
11700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11701$as_echo "no" >&6; }
278a7a38
AO
11702fi
11703
5213506e 11704
278a7a38
AO
11705 fi
11706 test -n "$ac_cv_prog_NM" && break
11707done
11708
11709if test -z "$ac_cv_prog_NM" ; then
11710 set dummy nm
11711 if test $build = $host ; then
11712 NM="$2"
11713 else
11714 NM="${ncn_tool_prefix}$2"
11715 fi
11716fi
11717
11718
11719
11720if test -n "$RANLIB"; then
11721 ac_cv_prog_RANLIB=$RANLIB
11722elif test -n "$ac_cv_prog_RANLIB"; then
11723 RANLIB=$ac_cv_prog_RANLIB
11724fi
11725
11726if test -n "$ac_cv_prog_RANLIB"; then
11727 for ncn_progname in ranlib; do
11728 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11729set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11730{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11731$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11732if ${ac_cv_prog_RANLIB+:} false; then :
5213506e 11733 $as_echo_n "(cached) " >&6
278a7a38
AO
11734else
11735 if test -n "$RANLIB"; then
11736 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
11737else
11738as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11739for as_dir in $PATH
11740do
11741 IFS=$as_save_IFS
11742 test -z "$as_dir" && as_dir=.
5213506e 11743 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11744 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11745 ac_cv_prog_RANLIB="${ncn_progname}"
5213506e 11746 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11747 break 2
11748 fi
11749done
5213506e
RW
11750 done
11751IFS=$as_save_IFS
278a7a38
AO
11752
11753fi
11754fi
11755RANLIB=$ac_cv_prog_RANLIB
11756if test -n "$RANLIB"; then
5213506e
RW
11757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
11758$as_echo "$RANLIB" >&6; }
278a7a38 11759else
5213506e
RW
11760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11761$as_echo "no" >&6; }
278a7a38
AO
11762fi
11763
5213506e 11764
278a7a38
AO
11765 done
11766fi
ca9f4b81 11767
278a7a38 11768for ncn_progname in ranlib; do
2693c0b0
PB
11769 if test -n "$ncn_tool_prefix"; then
11770 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11771set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11772{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11773$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11774if ${ac_cv_prog_RANLIB+:} false; then :
5213506e 11775 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11776else
11777 if test -n "$RANLIB"; then
11778 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
11779else
1c710c3c
DJ
11780as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11781for as_dir in $PATH
11782do
11783 IFS=$as_save_IFS
11784 test -z "$as_dir" && as_dir=.
5213506e 11785 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11786 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11787 ac_cv_prog_RANLIB="${ncn_tool_prefix}${ncn_progname}"
5213506e 11788 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11789 break 2
11790 fi
11791done
5213506e
RW
11792 done
11793IFS=$as_save_IFS
1c710c3c 11794
ca9f4b81
AO
11795fi
11796fi
1c710c3c 11797RANLIB=$ac_cv_prog_RANLIB
ca9f4b81 11798if test -n "$RANLIB"; then
5213506e
RW
11799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
11800$as_echo "$RANLIB" >&6; }
ca9f4b81 11801else
5213506e
RW
11802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11803$as_echo "no" >&6; }
ca9f4b81
AO
11804fi
11805
5213506e 11806
2693c0b0
PB
11807 fi
11808 if test -z "$ac_cv_prog_RANLIB" && test $build = $host ; then
11809 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11810set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11811{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11812$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11813if ${ac_cv_prog_RANLIB+:} false; then :
5213506e 11814 $as_echo_n "(cached) " >&6
ca9f4b81 11815else
2693c0b0
PB
11816 if test -n "$RANLIB"; then
11817 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
ca9f4b81 11818else
1c710c3c
DJ
11819as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11820for as_dir in $PATH
11821do
11822 IFS=$as_save_IFS
11823 test -z "$as_dir" && as_dir=.
5213506e 11824 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11825 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11826 ac_cv_prog_RANLIB="${ncn_progname}"
5213506e 11827 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11828 break 2
11829 fi
11830done
5213506e
RW
11831 done
11832IFS=$as_save_IFS
1c710c3c 11833
ca9f4b81
AO
11834fi
11835fi
1c710c3c 11836RANLIB=$ac_cv_prog_RANLIB
2693c0b0 11837if test -n "$RANLIB"; then
5213506e
RW
11838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
11839$as_echo "$RANLIB" >&6; }
ca9f4b81 11840else
5213506e
RW
11841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11842$as_echo "no" >&6; }
ca9f4b81 11843fi
1c710c3c 11844
5213506e 11845
ca9f4b81 11846 fi
2693c0b0
PB
11847 test -n "$ac_cv_prog_RANLIB" && break
11848done
11849
11850if test -z "$ac_cv_prog_RANLIB" ; then
8927b7c0 11851 RANLIB="true"
ca9f4b81
AO
11852fi
11853
278a7a38
AO
11854
11855
11856if test -n "$STRIP"; then
11857 ac_cv_prog_STRIP=$STRIP
11858elif test -n "$ac_cv_prog_STRIP"; then
11859 STRIP=$ac_cv_prog_STRIP
11860fi
11861
11862if test -n "$ac_cv_prog_STRIP"; then
11863 for ncn_progname in strip; do
11864 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11865set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11866{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11867$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11868if ${ac_cv_prog_STRIP+:} false; then :
5213506e 11869 $as_echo_n "(cached) " >&6
278a7a38
AO
11870else
11871 if test -n "$STRIP"; then
11872 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
11873else
11874as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11875for as_dir in $PATH
11876do
11877 IFS=$as_save_IFS
11878 test -z "$as_dir" && as_dir=.
5213506e 11879 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11880 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11881 ac_cv_prog_STRIP="${ncn_progname}"
5213506e 11882 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11883 break 2
11884 fi
11885done
5213506e
RW
11886 done
11887IFS=$as_save_IFS
278a7a38
AO
11888
11889fi
11890fi
11891STRIP=$ac_cv_prog_STRIP
11892if test -n "$STRIP"; then
5213506e
RW
11893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
11894$as_echo "$STRIP" >&6; }
278a7a38 11895else
5213506e
RW
11896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11897$as_echo "no" >&6; }
278a7a38
AO
11898fi
11899
5213506e 11900
278a7a38
AO
11901 done
11902fi
11903
11904for ncn_progname in strip; do
2abefe3d
PB
11905 if test -n "$ncn_tool_prefix"; then
11906 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11907set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11909$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11910if ${ac_cv_prog_STRIP+:} false; then :
5213506e 11911 $as_echo_n "(cached) " >&6
2abefe3d
PB
11912else
11913 if test -n "$STRIP"; then
11914 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
11915else
1c710c3c
DJ
11916as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11917for as_dir in $PATH
11918do
11919 IFS=$as_save_IFS
11920 test -z "$as_dir" && as_dir=.
5213506e 11921 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11922 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11923 ac_cv_prog_STRIP="${ncn_tool_prefix}${ncn_progname}"
5213506e 11924 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11925 break 2
11926 fi
11927done
5213506e
RW
11928 done
11929IFS=$as_save_IFS
1c710c3c 11930
2abefe3d
PB
11931fi
11932fi
1c710c3c 11933STRIP=$ac_cv_prog_STRIP
2abefe3d 11934if test -n "$STRIP"; then
5213506e
RW
11935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
11936$as_echo "$STRIP" >&6; }
2abefe3d 11937else
5213506e
RW
11938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11939$as_echo "no" >&6; }
2abefe3d
PB
11940fi
11941
5213506e 11942
2abefe3d
PB
11943 fi
11944 if test -z "$ac_cv_prog_STRIP" && test $build = $host ; then
11945 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11946set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11947{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11948$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11949if ${ac_cv_prog_STRIP+:} false; then :
5213506e 11950 $as_echo_n "(cached) " >&6
2abefe3d
PB
11951else
11952 if test -n "$STRIP"; then
11953 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
11954else
1c710c3c
DJ
11955as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11956for as_dir in $PATH
11957do
11958 IFS=$as_save_IFS
11959 test -z "$as_dir" && as_dir=.
5213506e 11960 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11961 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11962 ac_cv_prog_STRIP="${ncn_progname}"
5213506e 11963 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11964 break 2
11965 fi
11966done
5213506e
RW
11967 done
11968IFS=$as_save_IFS
1c710c3c 11969
2abefe3d
PB
11970fi
11971fi
1c710c3c 11972STRIP=$ac_cv_prog_STRIP
2abefe3d 11973if test -n "$STRIP"; then
5213506e
RW
11974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
11975$as_echo "$STRIP" >&6; }
2abefe3d 11976else
5213506e
RW
11977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11978$as_echo "no" >&6; }
2abefe3d 11979fi
1c710c3c 11980
5213506e 11981
2abefe3d
PB
11982 fi
11983 test -n "$ac_cv_prog_STRIP" && break
11984done
11985
11986if test -z "$ac_cv_prog_STRIP" ; then
8927b7c0 11987 STRIP="true"
2abefe3d
PB
11988fi
11989
278a7a38
AO
11990
11991
11992if test -n "$WINDRES"; then
11993 ac_cv_prog_WINDRES=$WINDRES
11994elif test -n "$ac_cv_prog_WINDRES"; then
11995 WINDRES=$ac_cv_prog_WINDRES
11996fi
11997
11998if test -n "$ac_cv_prog_WINDRES"; then
11999 for ncn_progname in windres; do
12000 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12001set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12002{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12003$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12004if ${ac_cv_prog_WINDRES+:} false; then :
5213506e 12005 $as_echo_n "(cached) " >&6
278a7a38
AO
12006else
12007 if test -n "$WINDRES"; then
12008 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
12009else
12010as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12011for as_dir in $PATH
12012do
12013 IFS=$as_save_IFS
12014 test -z "$as_dir" && as_dir=.
5213506e 12015 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12016 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12017 ac_cv_prog_WINDRES="${ncn_progname}"
5213506e 12018 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12019 break 2
12020 fi
12021done
5213506e
RW
12022 done
12023IFS=$as_save_IFS
278a7a38
AO
12024
12025fi
12026fi
12027WINDRES=$ac_cv_prog_WINDRES
12028if test -n "$WINDRES"; then
5213506e
RW
12029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
12030$as_echo "$WINDRES" >&6; }
278a7a38 12031else
5213506e
RW
12032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12033$as_echo "no" >&6; }
278a7a38
AO
12034fi
12035
5213506e 12036
278a7a38
AO
12037 done
12038fi
12039
12040for ncn_progname in windres; do
2693c0b0
PB
12041 if test -n "$ncn_tool_prefix"; then
12042 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12043set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12044{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12045$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12046if ${ac_cv_prog_WINDRES+:} false; then :
5213506e 12047 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12048else
12049 if test -n "$WINDRES"; then
12050 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
12051else
1c710c3c
DJ
12052as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12053for as_dir in $PATH
12054do
12055 IFS=$as_save_IFS
12056 test -z "$as_dir" && as_dir=.
5213506e 12057 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12058 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12059 ac_cv_prog_WINDRES="${ncn_tool_prefix}${ncn_progname}"
5213506e 12060 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12061 break 2
12062 fi
12063done
5213506e
RW
12064 done
12065IFS=$as_save_IFS
1c710c3c 12066
ca9f4b81
AO
12067fi
12068fi
1c710c3c 12069WINDRES=$ac_cv_prog_WINDRES
ca9f4b81 12070if test -n "$WINDRES"; then
5213506e
RW
12071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
12072$as_echo "$WINDRES" >&6; }
ca9f4b81 12073else
5213506e
RW
12074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12075$as_echo "no" >&6; }
ca9f4b81
AO
12076fi
12077
5213506e 12078
2693c0b0
PB
12079 fi
12080 if test -z "$ac_cv_prog_WINDRES" && test $build = $host ; then
12081 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12082set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12083{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12084$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12085if ${ac_cv_prog_WINDRES+:} false; then :
5213506e 12086 $as_echo_n "(cached) " >&6
ca9f4b81 12087else
2693c0b0
PB
12088 if test -n "$WINDRES"; then
12089 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
ca9f4b81 12090else
1c710c3c
DJ
12091as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12092for as_dir in $PATH
12093do
12094 IFS=$as_save_IFS
12095 test -z "$as_dir" && as_dir=.
5213506e 12096 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12098 ac_cv_prog_WINDRES="${ncn_progname}"
5213506e 12099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12100 break 2
12101 fi
12102done
5213506e
RW
12103 done
12104IFS=$as_save_IFS
1c710c3c 12105
ca9f4b81
AO
12106fi
12107fi
1c710c3c 12108WINDRES=$ac_cv_prog_WINDRES
2693c0b0 12109if test -n "$WINDRES"; then
5213506e
RW
12110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
12111$as_echo "$WINDRES" >&6; }
ca9f4b81 12112else
5213506e
RW
12113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12114$as_echo "no" >&6; }
ca9f4b81 12115fi
1c710c3c 12116
5213506e 12117
2693c0b0
PB
12118 fi
12119 test -n "$ac_cv_prog_WINDRES" && break
12120done
12121
12122if test -z "$ac_cv_prog_WINDRES" ; then
12123 set dummy windres
12124 if test $build = $host ; then
12125 WINDRES="$2"
ca9f4b81 12126 else
2693c0b0 12127 WINDRES="${ncn_tool_prefix}$2"
ca9f4b81 12128 fi
ca9f4b81
AO
12129fi
12130
278a7a38
AO
12131
12132
901119ae
KT
12133if test -n "$WINDMC"; then
12134 ac_cv_prog_WINDMC=$WINDMC
12135elif test -n "$ac_cv_prog_WINDMC"; then
12136 WINDMC=$ac_cv_prog_WINDMC
12137fi
12138
12139if test -n "$ac_cv_prog_WINDMC"; then
12140 for ncn_progname in windmc; do
12141 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12142set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12143{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12144$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12145if ${ac_cv_prog_WINDMC+:} false; then :
5213506e 12146 $as_echo_n "(cached) " >&6
901119ae
KT
12147else
12148 if test -n "$WINDMC"; then
12149 ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
12150else
12151as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12152for as_dir in $PATH
12153do
12154 IFS=$as_save_IFS
12155 test -z "$as_dir" && as_dir=.
5213506e 12156 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12157 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 12158 ac_cv_prog_WINDMC="${ncn_progname}"
5213506e 12159 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
12160 break 2
12161 fi
12162done
5213506e
RW
12163 done
12164IFS=$as_save_IFS
901119ae
KT
12165
12166fi
12167fi
12168WINDMC=$ac_cv_prog_WINDMC
12169if test -n "$WINDMC"; then
5213506e
RW
12170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
12171$as_echo "$WINDMC" >&6; }
901119ae 12172else
5213506e
RW
12173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12174$as_echo "no" >&6; }
901119ae
KT
12175fi
12176
5213506e 12177
901119ae
KT
12178 done
12179fi
12180
12181for ncn_progname in windmc; do
12182 if test -n "$ncn_tool_prefix"; then
12183 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12184set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12185{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12186$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12187if ${ac_cv_prog_WINDMC+:} false; then :
5213506e 12188 $as_echo_n "(cached) " >&6
901119ae
KT
12189else
12190 if test -n "$WINDMC"; then
12191 ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
12192else
12193as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12194for as_dir in $PATH
12195do
12196 IFS=$as_save_IFS
12197 test -z "$as_dir" && as_dir=.
5213506e 12198 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12199 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 12200 ac_cv_prog_WINDMC="${ncn_tool_prefix}${ncn_progname}"
5213506e 12201 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
12202 break 2
12203 fi
12204done
5213506e
RW
12205 done
12206IFS=$as_save_IFS
901119ae
KT
12207
12208fi
12209fi
12210WINDMC=$ac_cv_prog_WINDMC
12211if test -n "$WINDMC"; then
5213506e
RW
12212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
12213$as_echo "$WINDMC" >&6; }
901119ae 12214else
5213506e
RW
12215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12216$as_echo "no" >&6; }
901119ae
KT
12217fi
12218
5213506e 12219
901119ae
KT
12220 fi
12221 if test -z "$ac_cv_prog_WINDMC" && test $build = $host ; then
12222 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12223set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12224{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12225$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12226if ${ac_cv_prog_WINDMC+:} false; then :
5213506e 12227 $as_echo_n "(cached) " >&6
901119ae
KT
12228else
12229 if test -n "$WINDMC"; then
12230 ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
12231else
12232as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12233for as_dir in $PATH
12234do
12235 IFS=$as_save_IFS
12236 test -z "$as_dir" && as_dir=.
5213506e 12237 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12238 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 12239 ac_cv_prog_WINDMC="${ncn_progname}"
5213506e 12240 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
12241 break 2
12242 fi
12243done
5213506e
RW
12244 done
12245IFS=$as_save_IFS
901119ae
KT
12246
12247fi
12248fi
12249WINDMC=$ac_cv_prog_WINDMC
12250if test -n "$WINDMC"; then
5213506e
RW
12251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
12252$as_echo "$WINDMC" >&6; }
901119ae 12253else
5213506e
RW
12254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12255$as_echo "no" >&6; }
901119ae
KT
12256fi
12257
5213506e 12258
901119ae
KT
12259 fi
12260 test -n "$ac_cv_prog_WINDMC" && break
12261done
12262
12263if test -z "$ac_cv_prog_WINDMC" ; then
12264 set dummy windmc
12265 if test $build = $host ; then
12266 WINDMC="$2"
12267 else
12268 WINDMC="${ncn_tool_prefix}$2"
12269 fi
12270fi
12271
12272
12273
278a7a38
AO
12274if test -n "$OBJCOPY"; then
12275 ac_cv_prog_OBJCOPY=$OBJCOPY
12276elif test -n "$ac_cv_prog_OBJCOPY"; then
12277 OBJCOPY=$ac_cv_prog_OBJCOPY
12278fi
12279
12280if test -n "$ac_cv_prog_OBJCOPY"; then
12281 for ncn_progname in objcopy; do
12282 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12283set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12284{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12285$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12286if ${ac_cv_prog_OBJCOPY+:} false; then :
5213506e 12287 $as_echo_n "(cached) " >&6
278a7a38
AO
12288else
12289 if test -n "$OBJCOPY"; then
12290 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
12291else
12292as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12293for as_dir in $PATH
12294do
12295 IFS=$as_save_IFS
12296 test -z "$as_dir" && as_dir=.
5213506e 12297 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12298 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12299 ac_cv_prog_OBJCOPY="${ncn_progname}"
5213506e 12300 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12301 break 2
12302 fi
12303done
5213506e
RW
12304 done
12305IFS=$as_save_IFS
278a7a38
AO
12306
12307fi
12308fi
12309OBJCOPY=$ac_cv_prog_OBJCOPY
12310if test -n "$OBJCOPY"; then
5213506e
RW
12311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
12312$as_echo "$OBJCOPY" >&6; }
278a7a38 12313else
5213506e
RW
12314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12315$as_echo "no" >&6; }
278a7a38
AO
12316fi
12317
5213506e 12318
278a7a38
AO
12319 done
12320fi
12321
12322for ncn_progname in objcopy; do
2693c0b0
PB
12323 if test -n "$ncn_tool_prefix"; then
12324 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12325set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12326{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12327$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12328if ${ac_cv_prog_OBJCOPY+:} false; then :
5213506e 12329 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12330else
12331 if test -n "$OBJCOPY"; then
12332 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
12333else
1c710c3c
DJ
12334as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12335for as_dir in $PATH
12336do
12337 IFS=$as_save_IFS
12338 test -z "$as_dir" && as_dir=.
5213506e 12339 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12340 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12341 ac_cv_prog_OBJCOPY="${ncn_tool_prefix}${ncn_progname}"
5213506e 12342 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12343 break 2
12344 fi
12345done
5213506e
RW
12346 done
12347IFS=$as_save_IFS
1c710c3c 12348
ca9f4b81
AO
12349fi
12350fi
1c710c3c 12351OBJCOPY=$ac_cv_prog_OBJCOPY
ca9f4b81 12352if test -n "$OBJCOPY"; then
5213506e
RW
12353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
12354$as_echo "$OBJCOPY" >&6; }
ca9f4b81 12355else
5213506e
RW
12356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12357$as_echo "no" >&6; }
ca9f4b81
AO
12358fi
12359
5213506e 12360
2693c0b0
PB
12361 fi
12362 if test -z "$ac_cv_prog_OBJCOPY" && test $build = $host ; then
12363 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12364set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12365{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12366$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12367if ${ac_cv_prog_OBJCOPY+:} false; then :
5213506e 12368 $as_echo_n "(cached) " >&6
ca9f4b81 12369else
2693c0b0
PB
12370 if test -n "$OBJCOPY"; then
12371 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
ca9f4b81 12372else
1c710c3c
DJ
12373as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12374for as_dir in $PATH
12375do
12376 IFS=$as_save_IFS
12377 test -z "$as_dir" && as_dir=.
5213506e 12378 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12379 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12380 ac_cv_prog_OBJCOPY="${ncn_progname}"
5213506e 12381 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12382 break 2
12383 fi
12384done
5213506e
RW
12385 done
12386IFS=$as_save_IFS
1c710c3c 12387
ca9f4b81
AO
12388fi
12389fi
1c710c3c 12390OBJCOPY=$ac_cv_prog_OBJCOPY
2693c0b0 12391if test -n "$OBJCOPY"; then
5213506e
RW
12392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
12393$as_echo "$OBJCOPY" >&6; }
ca9f4b81 12394else
5213506e
RW
12395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12396$as_echo "no" >&6; }
ca9f4b81 12397fi
1c710c3c 12398
5213506e 12399
2693c0b0
PB
12400 fi
12401 test -n "$ac_cv_prog_OBJCOPY" && break
12402done
12403
12404if test -z "$ac_cv_prog_OBJCOPY" ; then
12405 set dummy objcopy
12406 if test $build = $host ; then
12407 OBJCOPY="$2"
ca9f4b81 12408 else
2693c0b0 12409 OBJCOPY="${ncn_tool_prefix}$2"
ca9f4b81 12410 fi
ca9f4b81
AO
12411fi
12412
278a7a38
AO
12413
12414
12415if test -n "$OBJDUMP"; then
12416 ac_cv_prog_OBJDUMP=$OBJDUMP
12417elif test -n "$ac_cv_prog_OBJDUMP"; then
12418 OBJDUMP=$ac_cv_prog_OBJDUMP
12419fi
12420
12421if test -n "$ac_cv_prog_OBJDUMP"; then
12422 for ncn_progname in objdump; do
12423 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12424set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12425{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12426$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12427if ${ac_cv_prog_OBJDUMP+:} false; then :
5213506e 12428 $as_echo_n "(cached) " >&6
278a7a38
AO
12429else
12430 if test -n "$OBJDUMP"; then
12431 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
12432else
12433as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12434for as_dir in $PATH
12435do
12436 IFS=$as_save_IFS
12437 test -z "$as_dir" && as_dir=.
5213506e 12438 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12439 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12440 ac_cv_prog_OBJDUMP="${ncn_progname}"
5213506e 12441 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12442 break 2
12443 fi
12444done
5213506e
RW
12445 done
12446IFS=$as_save_IFS
278a7a38
AO
12447
12448fi
12449fi
12450OBJDUMP=$ac_cv_prog_OBJDUMP
12451if test -n "$OBJDUMP"; then
5213506e
RW
12452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
12453$as_echo "$OBJDUMP" >&6; }
278a7a38 12454else
5213506e
RW
12455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12456$as_echo "no" >&6; }
278a7a38
AO
12457fi
12458
5213506e 12459
278a7a38
AO
12460 done
12461fi
12462
12463for ncn_progname in objdump; do
2693c0b0
PB
12464 if test -n "$ncn_tool_prefix"; then
12465 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12466set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12467{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12468$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12469if ${ac_cv_prog_OBJDUMP+:} false; then :
5213506e 12470 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12471else
12472 if test -n "$OBJDUMP"; then
12473 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
12474else
1c710c3c
DJ
12475as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12476for as_dir in $PATH
12477do
12478 IFS=$as_save_IFS
12479 test -z "$as_dir" && as_dir=.
5213506e 12480 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12481 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12482 ac_cv_prog_OBJDUMP="${ncn_tool_prefix}${ncn_progname}"
5213506e 12483 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12484 break 2
12485 fi
12486done
5213506e
RW
12487 done
12488IFS=$as_save_IFS
1c710c3c 12489
ca9f4b81
AO
12490fi
12491fi
1c710c3c 12492OBJDUMP=$ac_cv_prog_OBJDUMP
ca9f4b81 12493if test -n "$OBJDUMP"; then
5213506e
RW
12494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
12495$as_echo "$OBJDUMP" >&6; }
ca9f4b81 12496else
5213506e
RW
12497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12498$as_echo "no" >&6; }
ca9f4b81
AO
12499fi
12500
5213506e 12501
2693c0b0
PB
12502 fi
12503 if test -z "$ac_cv_prog_OBJDUMP" && test $build = $host ; then
12504 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12505set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12506{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12507$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12508if ${ac_cv_prog_OBJDUMP+:} false; then :
5213506e 12509 $as_echo_n "(cached) " >&6
ca9f4b81 12510else
2693c0b0
PB
12511 if test -n "$OBJDUMP"; then
12512 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
ca9f4b81 12513else
1c710c3c
DJ
12514as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12515for as_dir in $PATH
12516do
12517 IFS=$as_save_IFS
12518 test -z "$as_dir" && as_dir=.
5213506e 12519 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12520 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12521 ac_cv_prog_OBJDUMP="${ncn_progname}"
5213506e 12522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12523 break 2
12524 fi
12525done
5213506e
RW
12526 done
12527IFS=$as_save_IFS
1c710c3c 12528
ca9f4b81
AO
12529fi
12530fi
1c710c3c 12531OBJDUMP=$ac_cv_prog_OBJDUMP
2693c0b0 12532if test -n "$OBJDUMP"; then
5213506e
RW
12533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
12534$as_echo "$OBJDUMP" >&6; }
ca9f4b81 12535else
5213506e
RW
12536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12537$as_echo "no" >&6; }
ca9f4b81 12538fi
1c710c3c 12539
5213506e 12540
2693c0b0
PB
12541 fi
12542 test -n "$ac_cv_prog_OBJDUMP" && break
12543done
12544
12545if test -z "$ac_cv_prog_OBJDUMP" ; then
12546 set dummy objdump
12547 if test $build = $host ; then
12548 OBJDUMP="$2"
ca9f4b81 12549 else
2693c0b0 12550 OBJDUMP="${ncn_tool_prefix}$2"
ca9f4b81 12551 fi
ca9f4b81
AO
12552fi
12553
671aa708
NN
12554
12555
e4a9a572
IS
12556if test -n "$OTOOL"; then
12557 ac_cv_prog_OTOOL=$OTOOL
12558elif test -n "$ac_cv_prog_OTOOL"; then
12559 OTOOL=$ac_cv_prog_OTOOL
12560fi
12561
12562if test -n "$ac_cv_prog_OTOOL"; then
12563 for ncn_progname in otool; do
12564 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12565set dummy ${ncn_progname}; ac_word=$2
12566{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12567$as_echo_n "checking for $ac_word... " >&6; }
12568if ${ac_cv_prog_OTOOL+:} false; then :
12569 $as_echo_n "(cached) " >&6
12570else
12571 if test -n "$OTOOL"; then
12572 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
12573else
12574as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12575for as_dir in $PATH
12576do
12577 IFS=$as_save_IFS
12578 test -z "$as_dir" && as_dir=.
12579 for ac_exec_ext in '' $ac_executable_extensions; do
12580 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12581 ac_cv_prog_OTOOL="${ncn_progname}"
12582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12583 break 2
12584 fi
12585done
12586 done
12587IFS=$as_save_IFS
12588
12589fi
12590fi
12591OTOOL=$ac_cv_prog_OTOOL
12592if test -n "$OTOOL"; then
12593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
12594$as_echo "$OTOOL" >&6; }
12595else
12596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12597$as_echo "no" >&6; }
12598fi
12599
12600
12601 done
12602fi
12603
12604for ncn_progname in otool; do
12605 if test -n "$ncn_tool_prefix"; then
12606 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12607set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
12608{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12609$as_echo_n "checking for $ac_word... " >&6; }
12610if ${ac_cv_prog_OTOOL+:} false; then :
12611 $as_echo_n "(cached) " >&6
12612else
12613 if test -n "$OTOOL"; then
12614 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
12615else
12616as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12617for as_dir in $PATH
12618do
12619 IFS=$as_save_IFS
12620 test -z "$as_dir" && as_dir=.
12621 for ac_exec_ext in '' $ac_executable_extensions; do
12622 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12623 ac_cv_prog_OTOOL="${ncn_tool_prefix}${ncn_progname}"
12624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12625 break 2
12626 fi
12627done
12628 done
12629IFS=$as_save_IFS
12630
12631fi
12632fi
12633OTOOL=$ac_cv_prog_OTOOL
12634if test -n "$OTOOL"; then
12635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
12636$as_echo "$OTOOL" >&6; }
12637else
12638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12639$as_echo "no" >&6; }
12640fi
12641
12642
12643 fi
12644 if test -z "$ac_cv_prog_OTOOL" && test $build = $host ; then
12645 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12646set dummy ${ncn_progname}; ac_word=$2
12647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12648$as_echo_n "checking for $ac_word... " >&6; }
12649if ${ac_cv_prog_OTOOL+:} false; then :
12650 $as_echo_n "(cached) " >&6
12651else
12652 if test -n "$OTOOL"; then
12653 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
12654else
12655as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12656for as_dir in $PATH
12657do
12658 IFS=$as_save_IFS
12659 test -z "$as_dir" && as_dir=.
12660 for ac_exec_ext in '' $ac_executable_extensions; do
12661 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12662 ac_cv_prog_OTOOL="${ncn_progname}"
12663 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12664 break 2
12665 fi
12666done
12667 done
12668IFS=$as_save_IFS
12669
12670fi
12671fi
12672OTOOL=$ac_cv_prog_OTOOL
12673if test -n "$OTOOL"; then
12674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
12675$as_echo "$OTOOL" >&6; }
12676else
12677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12678$as_echo "no" >&6; }
12679fi
12680
12681
12682 fi
12683 test -n "$ac_cv_prog_OTOOL" && break
12684done
12685
12686if test -z "$ac_cv_prog_OTOOL" ; then
12687 set dummy otool
12688 if test $build = $host ; then
12689 OTOOL="$2"
12690 else
12691 OTOOL="${ncn_tool_prefix}$2"
12692 fi
12693fi
12694
12695
12696
e7a82751
RM
12697if test -n "$READELF"; then
12698 ac_cv_prog_READELF=$READELF
12699elif test -n "$ac_cv_prog_READELF"; then
12700 READELF=$ac_cv_prog_READELF
12701fi
12702
12703if test -n "$ac_cv_prog_READELF"; then
12704 for ncn_progname in readelf; do
12705 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12706set dummy ${ncn_progname}; ac_word=$2
12707{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12708$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12709if ${ac_cv_prog_READELF+:} false; then :
e7a82751
RM
12710 $as_echo_n "(cached) " >&6
12711else
12712 if test -n "$READELF"; then
12713 ac_cv_prog_READELF="$READELF" # Let the user override the test.
12714else
12715as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12716for as_dir in $PATH
12717do
12718 IFS=$as_save_IFS
12719 test -z "$as_dir" && as_dir=.
12720 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12721 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
12722 ac_cv_prog_READELF="${ncn_progname}"
12723 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12724 break 2
12725 fi
12726done
12727 done
12728IFS=$as_save_IFS
12729
12730fi
12731fi
12732READELF=$ac_cv_prog_READELF
12733if test -n "$READELF"; then
12734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
12735$as_echo "$READELF" >&6; }
12736else
12737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12738$as_echo "no" >&6; }
12739fi
12740
12741
12742 done
12743fi
12744
12745for ncn_progname in readelf; do
12746 if test -n "$ncn_tool_prefix"; then
12747 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12748set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
12749{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12750$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12751if ${ac_cv_prog_READELF+:} false; then :
e7a82751
RM
12752 $as_echo_n "(cached) " >&6
12753else
12754 if test -n "$READELF"; then
12755 ac_cv_prog_READELF="$READELF" # Let the user override the test.
12756else
12757as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12758for as_dir in $PATH
12759do
12760 IFS=$as_save_IFS
12761 test -z "$as_dir" && as_dir=.
12762 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12763 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
12764 ac_cv_prog_READELF="${ncn_tool_prefix}${ncn_progname}"
12765 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12766 break 2
12767 fi
12768done
12769 done
12770IFS=$as_save_IFS
12771
12772fi
12773fi
12774READELF=$ac_cv_prog_READELF
12775if test -n "$READELF"; then
12776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
12777$as_echo "$READELF" >&6; }
12778else
12779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12780$as_echo "no" >&6; }
12781fi
12782
12783
12784 fi
12785 if test -z "$ac_cv_prog_READELF" && test $build = $host ; then
12786 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12787set dummy ${ncn_progname}; ac_word=$2
12788{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12789$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12790if ${ac_cv_prog_READELF+:} false; then :
e7a82751
RM
12791 $as_echo_n "(cached) " >&6
12792else
12793 if test -n "$READELF"; then
12794 ac_cv_prog_READELF="$READELF" # Let the user override the test.
12795else
12796as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12797for as_dir in $PATH
12798do
12799 IFS=$as_save_IFS
12800 test -z "$as_dir" && as_dir=.
12801 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12802 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
12803 ac_cv_prog_READELF="${ncn_progname}"
12804 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12805 break 2
12806 fi
12807done
12808 done
12809IFS=$as_save_IFS
12810
12811fi
12812fi
12813READELF=$ac_cv_prog_READELF
12814if test -n "$READELF"; then
12815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
12816$as_echo "$READELF" >&6; }
12817else
12818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12819$as_echo "no" >&6; }
12820fi
12821
12822
12823 fi
12824 test -n "$ac_cv_prog_READELF" && break
12825done
12826
12827if test -z "$ac_cv_prog_READELF" ; then
12828 set dummy readelf
12829 if test $build = $host ; then
12830 READELF="$2"
12831 else
12832 READELF="${ncn_tool_prefix}$2"
12833 fi
12834fi
12835
12836
12837
671aa708
NN
12838
12839
12840
5fee5ec3
IB
12841
12842
2abefe3d 12843# Target tools.
1c710c3c 12844
5213506e
RW
12845# Check whether --with-build-time-tools was given.
12846if test "${with_build_time_tools+set}" = set; then :
12847 withval=$with_build_time_tools; case x"$withval" in
e8b05380
PB
12848 x/*) ;;
12849 *)
12850 with_build_time_tools=
5213506e
RW
12851 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: argument to --with-build-time-tools must be an absolute path" >&5
12852$as_echo "$as_me: WARNING: argument to --with-build-time-tools must be an absolute path" >&2;}
e8b05380
PB
12853 ;;
12854 esac
ca9f4b81 12855else
e8b05380 12856 with_build_time_tools=
5213506e
RW
12857fi
12858
ca9f4b81 12859
278a7a38
AO
12860
12861
12862if test -n "$CC_FOR_TARGET"; then
12863 ac_cv_prog_CC_FOR_TARGET=$CC_FOR_TARGET
12864elif test -n "$ac_cv_prog_CC_FOR_TARGET"; then
12865 CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
12866fi
12867
12868if test -n "$ac_cv_prog_CC_FOR_TARGET"; then
12869 for ncn_progname in cc gcc; do
12870 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12871set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12872{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12873$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12874if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
5213506e 12875 $as_echo_n "(cached) " >&6
278a7a38
AO
12876else
12877 if test -n "$CC_FOR_TARGET"; then
12878 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
12879else
12880as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12881for as_dir in $PATH
12882do
12883 IFS=$as_save_IFS
12884 test -z "$as_dir" && as_dir=.
5213506e 12885 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12886 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12887 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
5213506e 12888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12889 break 2
12890 fi
12891done
5213506e
RW
12892 done
12893IFS=$as_save_IFS
278a7a38
AO
12894
12895fi
12896fi
12897CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
12898if test -n "$CC_FOR_TARGET"; then
5213506e
RW
12899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
12900$as_echo "$CC_FOR_TARGET" >&6; }
278a7a38 12901else
5213506e
RW
12902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12903$as_echo "no" >&6; }
278a7a38
AO
12904fi
12905
5213506e 12906
278a7a38
AO
12907 done
12908fi
12909
12910if test -z "$ac_cv_prog_CC_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 12911 for ncn_progname in cc gcc; do
5213506e
RW
12912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
12913$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
12914 if test -x $with_build_time_tools/${ncn_progname}; then
12915 ac_cv_prog_CC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
12916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12917$as_echo "yes" >&6; }
72a7ab82 12918 break
e8b05380 12919 else
5213506e
RW
12920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12921$as_echo "no" >&6; }
72a7ab82
AP
12922 fi
12923 done
4de997d1
PB
12924fi
12925
e8b05380
PB
12926if test -z "$ac_cv_prog_CC_FOR_TARGET"; then
12927 for ncn_progname in cc gcc; do
12928 if test -n "$ncn_target_tool_prefix"; then
12929 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 12930set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12932$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12933if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
5213506e 12934 $as_echo_n "(cached) " >&6
4de997d1
PB
12935else
12936 if test -n "$CC_FOR_TARGET"; then
12937 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
12938else
1c710c3c
DJ
12939as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12940for as_dir in $PATH
12941do
12942 IFS=$as_save_IFS
12943 test -z "$as_dir" && as_dir=.
5213506e 12944 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12945 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12946 ac_cv_prog_CC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 12947 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12948 break 2
12949 fi
12950done
5213506e
RW
12951 done
12952IFS=$as_save_IFS
1c710c3c 12953
4de997d1
PB
12954fi
12955fi
1c710c3c 12956CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
4de997d1 12957if test -n "$CC_FOR_TARGET"; then
5213506e
RW
12958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
12959$as_echo "$CC_FOR_TARGET" >&6; }
4de997d1 12960else
5213506e
RW
12961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12962$as_echo "no" >&6; }
4de997d1
PB
12963fi
12964
5213506e 12965
e8b05380
PB
12966 fi
12967 if test -z "$ac_cv_prog_CC_FOR_TARGET" && test $build = $target ; then
12968 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 12969set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12970{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12971$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12972if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
5213506e 12973 $as_echo_n "(cached) " >&6
4de997d1 12974else
2693c0b0
PB
12975 if test -n "$CC_FOR_TARGET"; then
12976 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4de997d1 12977else
1c710c3c
DJ
12978as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12979for as_dir in $PATH
12980do
12981 IFS=$as_save_IFS
12982 test -z "$as_dir" && as_dir=.
5213506e 12983 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12984 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12985 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
5213506e 12986 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12987 break 2
12988 fi
12989done
5213506e
RW
12990 done
12991IFS=$as_save_IFS
1c710c3c 12992
4de997d1
PB
12993fi
12994fi
1c710c3c 12995CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
2693c0b0 12996if test -n "$CC_FOR_TARGET"; then
5213506e
RW
12997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
12998$as_echo "$CC_FOR_TARGET" >&6; }
4de997d1 12999else
5213506e
RW
13000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13001$as_echo "no" >&6; }
4de997d1 13002fi
1c710c3c 13003
5213506e 13004
e8b05380
PB
13005 fi
13006 test -n "$ac_cv_prog_CC_FOR_TARGET" && break
13007 done
13008fi
1c710c3c 13009
2693c0b0
PB
13010if test -z "$ac_cv_prog_CC_FOR_TARGET" ; then
13011 set dummy cc gcc
13012 if test $build = $target ; then
13013 CC_FOR_TARGET="$2"
4de997d1 13014 else
2693c0b0 13015 CC_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 13016 fi
1c00b503
PB
13017else
13018 CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
4de997d1
PB
13019fi
13020
278a7a38
AO
13021
13022
13023if test -n "$CXX_FOR_TARGET"; then
13024 ac_cv_prog_CXX_FOR_TARGET=$CXX_FOR_TARGET
13025elif test -n "$ac_cv_prog_CXX_FOR_TARGET"; then
13026 CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
13027fi
13028
13029if test -n "$ac_cv_prog_CXX_FOR_TARGET"; then
13030 for ncn_progname in c++ g++ cxx gxx; do
13031 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13032set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13034$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13035if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
5213506e 13036 $as_echo_n "(cached) " >&6
278a7a38
AO
13037else
13038 if test -n "$CXX_FOR_TARGET"; then
13039 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
13040else
13041as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13042for as_dir in $PATH
13043do
13044 IFS=$as_save_IFS
13045 test -z "$as_dir" && as_dir=.
5213506e 13046 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13047 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13048 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
5213506e 13049 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
13050 break 2
13051 fi
13052done
5213506e
RW
13053 done
13054IFS=$as_save_IFS
278a7a38
AO
13055
13056fi
13057fi
13058CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
13059if test -n "$CXX_FOR_TARGET"; then
5213506e
RW
13060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
13061$as_echo "$CXX_FOR_TARGET" >&6; }
278a7a38 13062else
5213506e
RW
13063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13064$as_echo "no" >&6; }
278a7a38
AO
13065fi
13066
5213506e 13067
278a7a38
AO
13068 done
13069fi
13070
13071if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13072 for ncn_progname in c++ g++ cxx gxx; do
5213506e
RW
13073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13074$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13075 if test -x $with_build_time_tools/${ncn_progname}; then
13076 ac_cv_prog_CXX_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13078$as_echo "yes" >&6; }
e8b05380
PB
13079 break
13080 else
5213506e
RW
13081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13082$as_echo "no" >&6; }
e8b05380
PB
13083 fi
13084 done
13085fi
13086
13087if test -z "$ac_cv_prog_CXX_FOR_TARGET"; then
13088 for ncn_progname in c++ g++ cxx gxx; do
13089 if test -n "$ncn_target_tool_prefix"; then
13090 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 13091set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13092{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13093$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13094if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
5213506e 13095 $as_echo_n "(cached) " >&6
4de997d1
PB
13096else
13097 if test -n "$CXX_FOR_TARGET"; then
13098 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
13099else
1c710c3c
DJ
13100as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13101for as_dir in $PATH
13102do
13103 IFS=$as_save_IFS
13104 test -z "$as_dir" && as_dir=.
5213506e 13105 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13106 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13107 ac_cv_prog_CXX_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13108 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13109 break 2
13110 fi
13111done
5213506e
RW
13112 done
13113IFS=$as_save_IFS
1c710c3c 13114
4de997d1
PB
13115fi
13116fi
1c710c3c 13117CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
4de997d1 13118if test -n "$CXX_FOR_TARGET"; then
5213506e
RW
13119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
13120$as_echo "$CXX_FOR_TARGET" >&6; }
4de997d1 13121else
5213506e
RW
13122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13123$as_echo "no" >&6; }
4de997d1
PB
13124fi
13125
5213506e 13126
e8b05380
PB
13127 fi
13128 if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test $build = $target ; then
13129 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 13130set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13131{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13132$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13133if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
5213506e 13134 $as_echo_n "(cached) " >&6
4de997d1 13135else
2693c0b0
PB
13136 if test -n "$CXX_FOR_TARGET"; then
13137 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4de997d1 13138else
1c710c3c
DJ
13139as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13140for as_dir in $PATH
13141do
13142 IFS=$as_save_IFS
13143 test -z "$as_dir" && as_dir=.
5213506e 13144 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13145 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13146 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
5213506e 13147 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13148 break 2
13149 fi
13150done
5213506e
RW
13151 done
13152IFS=$as_save_IFS
1c710c3c 13153
4de997d1
PB
13154fi
13155fi
1c710c3c 13156CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
2693c0b0 13157if test -n "$CXX_FOR_TARGET"; then
5213506e
RW
13158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
13159$as_echo "$CXX_FOR_TARGET" >&6; }
4de997d1 13160else
5213506e
RW
13161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13162$as_echo "no" >&6; }
4de997d1 13163fi
1c710c3c 13164
5213506e 13165
e8b05380
PB
13166 fi
13167 test -n "$ac_cv_prog_CXX_FOR_TARGET" && break
13168 done
13169fi
1c710c3c 13170
2693c0b0
PB
13171if test -z "$ac_cv_prog_CXX_FOR_TARGET" ; then
13172 set dummy c++ g++ cxx gxx
13173 if test $build = $target ; then
13174 CXX_FOR_TARGET="$2"
4de997d1 13175 else
2693c0b0 13176 CXX_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 13177 fi
1c00b503
PB
13178else
13179 CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
ca9f4b81
AO
13180fi
13181
278a7a38
AO
13182
13183
13184if test -n "$GCC_FOR_TARGET"; then
13185 ac_cv_prog_GCC_FOR_TARGET=$GCC_FOR_TARGET
13186elif test -n "$ac_cv_prog_GCC_FOR_TARGET"; then
13187 GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
13188fi
13189
13190if test -n "$ac_cv_prog_GCC_FOR_TARGET"; then
13191 for ncn_progname in gcc; do
13192 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13193set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13194{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13195$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13196if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
5213506e 13197 $as_echo_n "(cached) " >&6
278a7a38
AO
13198else
13199 if test -n "$GCC_FOR_TARGET"; then
13200 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
13201else
13202as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13203for as_dir in $PATH
13204do
13205 IFS=$as_save_IFS
13206 test -z "$as_dir" && as_dir=.
5213506e 13207 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13208 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13209 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
5213506e 13210 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
13211 break 2
13212 fi
13213done
5213506e
RW
13214 done
13215IFS=$as_save_IFS
278a7a38
AO
13216
13217fi
13218fi
13219GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
13220if test -n "$GCC_FOR_TARGET"; then
5213506e
RW
13221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
13222$as_echo "$GCC_FOR_TARGET" >&6; }
278a7a38 13223else
5213506e
RW
13224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13225$as_echo "no" >&6; }
278a7a38
AO
13226fi
13227
5213506e 13228
278a7a38
AO
13229 done
13230fi
13231
13232if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13233 for ncn_progname in gcc; do
5213506e
RW
13234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13235$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13236 if test -x $with_build_time_tools/${ncn_progname}; then
13237 ac_cv_prog_GCC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13239$as_echo "yes" >&6; }
e8b05380
PB
13240 break
13241 else
5213506e
RW
13242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13243$as_echo "no" >&6; }
e8b05380
PB
13244 fi
13245 done
13246fi
13247
13248if test -z "$ac_cv_prog_GCC_FOR_TARGET"; then
13249 for ncn_progname in gcc; do
13250 if test -n "$ncn_target_tool_prefix"; then
13251 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 13252set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13253{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13254$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13255if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
5213506e 13256 $as_echo_n "(cached) " >&6
ca9f4b81 13257else
e8b05380
PB
13258 if test -n "$GCC_FOR_TARGET"; then
13259 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 13260else
1c710c3c
DJ
13261as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13262for as_dir in $PATH
13263do
13264 IFS=$as_save_IFS
13265 test -z "$as_dir" && as_dir=.
5213506e 13266 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13267 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13268 ac_cv_prog_GCC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13269 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13270 break 2
13271 fi
13272done
5213506e
RW
13273 done
13274IFS=$as_save_IFS
1c710c3c 13275
ca9f4b81
AO
13276fi
13277fi
1c710c3c 13278GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
e8b05380 13279if test -n "$GCC_FOR_TARGET"; then
5213506e
RW
13280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
13281$as_echo "$GCC_FOR_TARGET" >&6; }
ca9f4b81 13282else
5213506e
RW
13283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13284$as_echo "no" >&6; }
ca9f4b81
AO
13285fi
13286
5213506e 13287
e8b05380
PB
13288 fi
13289 if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test $build = $target ; then
13290 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 13291set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13292{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13293$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13294if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
5213506e 13295 $as_echo_n "(cached) " >&6
ca9f4b81 13296else
e8b05380
PB
13297 if test -n "$GCC_FOR_TARGET"; then
13298 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 13299else
1c710c3c
DJ
13300as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13301for as_dir in $PATH
13302do
13303 IFS=$as_save_IFS
13304 test -z "$as_dir" && as_dir=.
5213506e 13305 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13306 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13307 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
5213506e 13308 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13309 break 2
13310 fi
13311done
5213506e
RW
13312 done
13313IFS=$as_save_IFS
1c710c3c 13314
ca9f4b81
AO
13315fi
13316fi
1c710c3c 13317GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
e8b05380 13318if test -n "$GCC_FOR_TARGET"; then
5213506e
RW
13319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
13320$as_echo "$GCC_FOR_TARGET" >&6; }
ca9f4b81 13321else
5213506e
RW
13322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13323$as_echo "no" >&6; }
ca9f4b81 13324fi
1c710c3c 13325
5213506e 13326
e8b05380
PB
13327 fi
13328 test -n "$ac_cv_prog_GCC_FOR_TARGET" && break
13329 done
13330fi
1c710c3c 13331
e8b05380
PB
13332if test -z "$ac_cv_prog_GCC_FOR_TARGET" ; then
13333 GCC_FOR_TARGET="${CC_FOR_TARGET}"
1c00b503
PB
13334else
13335 GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
e8b05380
PB
13336fi
13337
278a7a38
AO
13338
13339
278a7a38
AO
13340if test -n "$GFORTRAN_FOR_TARGET"; then
13341 ac_cv_prog_GFORTRAN_FOR_TARGET=$GFORTRAN_FOR_TARGET
13342elif test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
13343 GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
e8b05380
PB
13344fi
13345
278a7a38
AO
13346if test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
13347 for ncn_progname in gfortran; do
13348 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
e8b05380 13349set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13350{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13351$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13352if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
5213506e 13353 $as_echo_n "(cached) " >&6
e8b05380 13354else
278a7a38
AO
13355 if test -n "$GFORTRAN_FOR_TARGET"; then
13356 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
e8b05380 13357else
1c710c3c
DJ
13358as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13359for as_dir in $PATH
13360do
13361 IFS=$as_save_IFS
13362 test -z "$as_dir" && as_dir=.
5213506e 13363 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13365 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
5213506e 13366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13367 break 2
13368 fi
13369done
5213506e
RW
13370 done
13371IFS=$as_save_IFS
1c710c3c 13372
e8b05380
PB
13373fi
13374fi
278a7a38
AO
13375GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
13376if test -n "$GFORTRAN_FOR_TARGET"; then
5213506e
RW
13377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
13378$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
e8b05380 13379else
5213506e
RW
13380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13381$as_echo "no" >&6; }
e8b05380 13382fi
1c710c3c 13383
5213506e 13384
e8b05380
PB
13385 done
13386fi
1c710c3c 13387
278a7a38 13388if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13389 for ncn_progname in gfortran; do
5213506e
RW
13390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13391$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13392 if test -x $with_build_time_tools/${ncn_progname}; then
13393 ac_cv_prog_GFORTRAN_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13395$as_echo "yes" >&6; }
e8b05380
PB
13396 break
13397 else
5213506e
RW
13398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13399$as_echo "no" >&6; }
e8b05380
PB
13400 fi
13401 done
13402fi
13403
13404if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
13405 for ncn_progname in gfortran; do
13406 if test -n "$ncn_target_tool_prefix"; then
13407 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
13408set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13409{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13410$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13411if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
5213506e 13412 $as_echo_n "(cached) " >&6
e8b05380
PB
13413else
13414 if test -n "$GFORTRAN_FOR_TARGET"; then
1c710c3c
DJ
13415 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
13416else
13417as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13418for as_dir in $PATH
13419do
13420 IFS=$as_save_IFS
13421 test -z "$as_dir" && as_dir=.
5213506e 13422 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13423 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13424 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13425 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13426 break 2
13427 fi
13428done
5213506e
RW
13429 done
13430IFS=$as_save_IFS
1c710c3c 13431
e8b05380
PB
13432fi
13433fi
1c710c3c 13434GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
e8b05380 13435if test -n "$GFORTRAN_FOR_TARGET"; then
5213506e
RW
13436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
13437$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
e8b05380 13438else
5213506e
RW
13439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13440$as_echo "no" >&6; }
e8b05380
PB
13441fi
13442
5213506e 13443
e8b05380
PB
13444 fi
13445 if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test $build = $target ; then
13446 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13447set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13448{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13449$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13450if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
5213506e 13451 $as_echo_n "(cached) " >&6
e8b05380
PB
13452else
13453 if test -n "$GFORTRAN_FOR_TARGET"; then
13454 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
13455else
1c710c3c
DJ
13456as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13457for as_dir in $PATH
13458do
13459 IFS=$as_save_IFS
13460 test -z "$as_dir" && as_dir=.
5213506e 13461 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13463 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
5213506e 13464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13465 break 2
13466 fi
13467done
5213506e
RW
13468 done
13469IFS=$as_save_IFS
1c710c3c 13470
e8b05380
PB
13471fi
13472fi
1c710c3c 13473GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
e8b05380 13474if test -n "$GFORTRAN_FOR_TARGET"; then
5213506e
RW
13475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
13476$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
e8b05380 13477else
5213506e
RW
13478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13479$as_echo "no" >&6; }
e8b05380 13480fi
1c710c3c 13481
5213506e 13482
e8b05380
PB
13483 fi
13484 test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET" && break
13485 done
13486fi
1c710c3c 13487
e8b05380
PB
13488if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" ; then
13489 set dummy gfortran
2693c0b0 13490 if test $build = $target ; then
e8b05380 13491 GFORTRAN_FOR_TARGET="$2"
ca9f4b81 13492 else
e8b05380
PB
13493 GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}$2"
13494 fi
1c00b503
PB
13495else
13496 GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
e8b05380
PB
13497fi
13498
13499
13500
632e2a07
ILT
13501if test -n "$GOC_FOR_TARGET"; then
13502 ac_cv_prog_GOC_FOR_TARGET=$GOC_FOR_TARGET
13503elif test -n "$ac_cv_prog_GOC_FOR_TARGET"; then
13504 GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
13505fi
13506
13507if test -n "$ac_cv_prog_GOC_FOR_TARGET"; then
13508 for ncn_progname in gccgo; do
13509 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13510set dummy ${ncn_progname}; ac_word=$2
13511{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13512$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13513if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
632e2a07
ILT
13514 $as_echo_n "(cached) " >&6
13515else
13516 if test -n "$GOC_FOR_TARGET"; then
13517 ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
13518else
13519as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13520for as_dir in $PATH
13521do
13522 IFS=$as_save_IFS
13523 test -z "$as_dir" && as_dir=.
13524 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
632e2a07
ILT
13526 ac_cv_prog_GOC_FOR_TARGET="${ncn_progname}"
13527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13528 break 2
13529 fi
13530done
13531 done
13532IFS=$as_save_IFS
13533
13534fi
13535fi
13536GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
13537if test -n "$GOC_FOR_TARGET"; then
13538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
13539$as_echo "$GOC_FOR_TARGET" >&6; }
13540else
13541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13542$as_echo "no" >&6; }
13543fi
13544
13545
13546 done
13547fi
13548
13549if test -z "$ac_cv_prog_GOC_FOR_TARGET" && test -n "$with_build_time_tools"; then
13550 for ncn_progname in gccgo; do
13551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13552$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
13553 if test -x $with_build_time_tools/${ncn_progname}; then
13554 ac_cv_prog_GOC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
13555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13556$as_echo "yes" >&6; }
13557 break
13558 else
13559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13560$as_echo "no" >&6; }
13561 fi
13562 done
13563fi
13564
13565if test -z "$ac_cv_prog_GOC_FOR_TARGET"; then
13566 for ncn_progname in gccgo; do
13567 if test -n "$ncn_target_tool_prefix"; then
13568 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
13569set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
13570{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13571$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13572if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
632e2a07
ILT
13573 $as_echo_n "(cached) " >&6
13574else
13575 if test -n "$GOC_FOR_TARGET"; then
13576 ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
13577else
13578as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13579for as_dir in $PATH
13580do
13581 IFS=$as_save_IFS
13582 test -z "$as_dir" && as_dir=.
13583 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13584 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
632e2a07
ILT
13585 ac_cv_prog_GOC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
13586 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13587 break 2
13588 fi
13589done
13590 done
13591IFS=$as_save_IFS
13592
13593fi
13594fi
13595GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
13596if test -n "$GOC_FOR_TARGET"; then
13597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
13598$as_echo "$GOC_FOR_TARGET" >&6; }
13599else
13600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13601$as_echo "no" >&6; }
13602fi
13603
13604
13605 fi
13606 if test -z "$ac_cv_prog_GOC_FOR_TARGET" && test $build = $target ; then
13607 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13608set dummy ${ncn_progname}; ac_word=$2
13609{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13610$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13611if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
632e2a07
ILT
13612 $as_echo_n "(cached) " >&6
13613else
13614 if test -n "$GOC_FOR_TARGET"; then
13615 ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
13616else
13617as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13618for as_dir in $PATH
13619do
13620 IFS=$as_save_IFS
13621 test -z "$as_dir" && as_dir=.
13622 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13623 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
632e2a07
ILT
13624 ac_cv_prog_GOC_FOR_TARGET="${ncn_progname}"
13625 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13626 break 2
13627 fi
13628done
13629 done
13630IFS=$as_save_IFS
13631
13632fi
13633fi
13634GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
13635if test -n "$GOC_FOR_TARGET"; then
13636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
13637$as_echo "$GOC_FOR_TARGET" >&6; }
13638else
13639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13640$as_echo "no" >&6; }
13641fi
13642
13643
13644 fi
13645 test -n "$ac_cv_prog_GOC_FOR_TARGET" && break
13646 done
13647fi
13648
13649if test -z "$ac_cv_prog_GOC_FOR_TARGET" ; then
13650 set dummy gccgo
13651 if test $build = $target ; then
13652 GOC_FOR_TARGET="$2"
13653 else
13654 GOC_FOR_TARGET="${ncn_target_tool_prefix}$2"
13655 fi
13656else
13657 GOC_FOR_TARGET="$ac_cv_prog_GOC_FOR_TARGET"
13658fi
13659
13660
13661
b4c522fa
IB
13662if test -n "$GDC_FOR_TARGET"; then
13663 ac_cv_prog_GDC_FOR_TARGET=$GDC_FOR_TARGET
13664elif test -n "$ac_cv_prog_GDC_FOR_TARGET"; then
13665 GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
13666fi
13667
13668if test -n "$ac_cv_prog_GDC_FOR_TARGET"; then
13669 for ncn_progname in gdc; do
13670 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13671set dummy ${ncn_progname}; ac_word=$2
13672{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13673$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13674if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
b4c522fa
IB
13675 $as_echo_n "(cached) " >&6
13676else
13677 if test -n "$GDC_FOR_TARGET"; then
13678 ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
13679else
13680as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13681for as_dir in $PATH
13682do
13683 IFS=$as_save_IFS
13684 test -z "$as_dir" && as_dir=.
13685 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b4c522fa
IB
13687 ac_cv_prog_GDC_FOR_TARGET="${ncn_progname}"
13688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13689 break 2
13690 fi
13691done
13692 done
13693IFS=$as_save_IFS
13694
13695fi
13696fi
13697GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
13698if test -n "$GDC_FOR_TARGET"; then
13699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
13700$as_echo "$GDC_FOR_TARGET" >&6; }
13701else
13702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13703$as_echo "no" >&6; }
13704fi
13705
13706
13707 done
13708fi
13709
13710if test -z "$ac_cv_prog_GDC_FOR_TARGET" && test -n "$with_build_time_tools"; then
13711 for ncn_progname in gdc; do
13712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13713$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
13714 if test -x $with_build_time_tools/${ncn_progname}; then
13715 ac_cv_prog_GDC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
13716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13717$as_echo "yes" >&6; }
13718 break
13719 else
13720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13721$as_echo "no" >&6; }
13722 fi
13723 done
13724fi
13725
13726if test -z "$ac_cv_prog_GDC_FOR_TARGET"; then
13727 for ncn_progname in gdc; do
13728 if test -n "$ncn_target_tool_prefix"; then
13729 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
13730set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
13731{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13732$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13733if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
b4c522fa
IB
13734 $as_echo_n "(cached) " >&6
13735else
13736 if test -n "$GDC_FOR_TARGET"; then
13737 ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
13738else
13739as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13740for as_dir in $PATH
13741do
13742 IFS=$as_save_IFS
13743 test -z "$as_dir" && as_dir=.
13744 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13745 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b4c522fa
IB
13746 ac_cv_prog_GDC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
13747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13748 break 2
13749 fi
13750done
13751 done
13752IFS=$as_save_IFS
13753
13754fi
13755fi
13756GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
13757if test -n "$GDC_FOR_TARGET"; then
13758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
13759$as_echo "$GDC_FOR_TARGET" >&6; }
13760else
13761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13762$as_echo "no" >&6; }
13763fi
13764
13765
13766 fi
13767 if test -z "$ac_cv_prog_GDC_FOR_TARGET" && test $build = $target ; then
13768 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13769set dummy ${ncn_progname}; ac_word=$2
13770{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13771$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13772if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
b4c522fa
IB
13773 $as_echo_n "(cached) " >&6
13774else
13775 if test -n "$GDC_FOR_TARGET"; then
13776 ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
13777else
13778as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13779for as_dir in $PATH
13780do
13781 IFS=$as_save_IFS
13782 test -z "$as_dir" && as_dir=.
13783 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13784 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b4c522fa
IB
13785 ac_cv_prog_GDC_FOR_TARGET="${ncn_progname}"
13786 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13787 break 2
13788 fi
13789done
13790 done
13791IFS=$as_save_IFS
13792
13793fi
13794fi
13795GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
13796if test -n "$GDC_FOR_TARGET"; then
13797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
13798$as_echo "$GDC_FOR_TARGET" >&6; }
13799else
13800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13801$as_echo "no" >&6; }
13802fi
13803
13804
13805 fi
13806 test -n "$ac_cv_prog_GDC_FOR_TARGET" && break
13807 done
13808fi
13809
13810if test -z "$ac_cv_prog_GDC_FOR_TARGET" ; then
13811 set dummy gdc
13812 if test $build = $target ; then
13813 GDC_FOR_TARGET="$2"
13814 else
13815 GDC_FOR_TARGET="${ncn_target_tool_prefix}$2"
13816 fi
13817else
13818 GDC_FOR_TARGET="$ac_cv_prog_GDC_FOR_TARGET"
13819fi
13820
13821
13822
e8b05380
PB
13823cat > conftest.c << \EOF
13824#ifdef __GNUC__
13825 gcc_yay;
13826#endif
13827EOF
13828if ($GCC_FOR_TARGET -E conftest.c | grep gcc_yay) > /dev/null 2>&1; then
13829 have_gcc_for_target=yes
13830else
13831 GCC_FOR_TARGET=${ncn_target_tool_prefix}gcc
13832 have_gcc_for_target=no
13833fi
13834rm conftest.c
13835
13836
13837
13838
13839if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
13840 if test -n "$with_build_time_tools"; then
5213506e
RW
13841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ar in $with_build_time_tools" >&5
13842$as_echo_n "checking for ar in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13843 if test -x $with_build_time_tools/ar; then
13844 AR_FOR_TARGET=`cd $with_build_time_tools && pwd`/ar
13845 ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
5213506e
RW
13846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_AR_FOR_TARGET" >&5
13847$as_echo "$ac_cv_path_AR_FOR_TARGET" >&6; }
d1f8db0c 13848 else
5213506e
RW
13849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13850$as_echo "no" >&6; }
d1f8db0c 13851 fi
e8b05380
PB
13852 elif test $build != $host && test $have_gcc_for_target = yes; then
13853 AR_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ar`
1c00b503
PB
13854 test $AR_FOR_TARGET = ar && AR_FOR_TARGET=
13855 test -n "$AR_FOR_TARGET" && ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
e8b05380
PB
13856 fi
13857fi
3e19841a 13858if test -z "$ac_cv_path_AR_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
13859 # Extract the first word of "ar", so it can be a program name with args.
13860set dummy ar; ac_word=$2
5213506e
RW
13861{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13862$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13863if ${ac_cv_path_AR_FOR_TARGET+:} false; then :
5213506e 13864 $as_echo_n "(cached) " >&6
e8b05380 13865else
1c710c3c
DJ
13866 case $AR_FOR_TARGET in
13867 [\\/]* | ?:[\\/]*)
e8b05380
PB
13868 ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
13869 ;;
e8b05380 13870 *)
1c710c3c
DJ
13871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13872for as_dir in $gcc_cv_tool_dirs
13873do
13874 IFS=$as_save_IFS
13875 test -z "$as_dir" && as_dir=.
5213506e 13876 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13877 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13878 ac_cv_path_AR_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 13879 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13880 break 2
13881 fi
13882done
5213506e
RW
13883 done
13884IFS=$as_save_IFS
1c710c3c 13885
e8b05380
PB
13886 ;;
13887esac
13888fi
1c710c3c 13889AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
e8b05380 13890if test -n "$AR_FOR_TARGET"; then
5213506e
RW
13891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
13892$as_echo "$AR_FOR_TARGET" >&6; }
e8b05380 13893else
5213506e
RW
13894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13895$as_echo "no" >&6; }
4de997d1
PB
13896fi
13897
5213506e 13898
e8b05380
PB
13899fi
13900if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
278a7a38
AO
13901
13902
13903if test -n "$AR_FOR_TARGET"; then
13904 ac_cv_prog_AR_FOR_TARGET=$AR_FOR_TARGET
13905elif test -n "$ac_cv_prog_AR_FOR_TARGET"; then
13906 AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
13907fi
13908
13909if test -n "$ac_cv_prog_AR_FOR_TARGET"; then
13910 for ncn_progname in ar; do
13911 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13912set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13913{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13914$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13915if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
5213506e 13916 $as_echo_n "(cached) " >&6
278a7a38
AO
13917else
13918 if test -n "$AR_FOR_TARGET"; then
13919 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
13920else
13921as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13922for as_dir in $PATH
13923do
13924 IFS=$as_save_IFS
13925 test -z "$as_dir" && as_dir=.
5213506e 13926 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13928 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
5213506e 13929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
13930 break 2
13931 fi
13932done
5213506e
RW
13933 done
13934IFS=$as_save_IFS
278a7a38
AO
13935
13936fi
13937fi
13938AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
13939if test -n "$AR_FOR_TARGET"; then
5213506e
RW
13940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
13941$as_echo "$AR_FOR_TARGET" >&6; }
278a7a38 13942else
5213506e
RW
13943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13944$as_echo "no" >&6; }
278a7a38
AO
13945fi
13946
5213506e 13947
278a7a38
AO
13948 done
13949fi
13950
13951if test -z "$ac_cv_prog_AR_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13952 for ncn_progname in ar; do
5213506e
RW
13953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13954$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13955 if test -x $with_build_time_tools/${ncn_progname}; then
13956 ac_cv_prog_AR_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13958$as_echo "yes" >&6; }
e8b05380
PB
13959 break
13960 else
5213506e
RW
13961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13962$as_echo "no" >&6; }
e8b05380
PB
13963 fi
13964 done
13965fi
13966
13967if test -z "$ac_cv_prog_AR_FOR_TARGET"; then
13968 for ncn_progname in ar; do
13969 if test -n "$ncn_target_tool_prefix"; then
13970 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 13971set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13972{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13973$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13974if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
5213506e 13975 $as_echo_n "(cached) " >&6
4de997d1 13976else
e8b05380
PB
13977 if test -n "$AR_FOR_TARGET"; then
13978 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
4de997d1 13979else
1c710c3c
DJ
13980as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13981for as_dir in $PATH
13982do
13983 IFS=$as_save_IFS
13984 test -z "$as_dir" && as_dir=.
5213506e 13985 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13986 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13987 ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13988 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13989 break 2
13990 fi
13991done
5213506e
RW
13992 done
13993IFS=$as_save_IFS
1c710c3c 13994
4de997d1
PB
13995fi
13996fi
1c710c3c 13997AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
e8b05380 13998if test -n "$AR_FOR_TARGET"; then
5213506e
RW
13999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
14000$as_echo "$AR_FOR_TARGET" >&6; }
4de997d1 14001else
5213506e
RW
14002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14003$as_echo "no" >&6; }
4de997d1
PB
14004fi
14005
5213506e 14006
e8b05380
PB
14007 fi
14008 if test -z "$ac_cv_prog_AR_FOR_TARGET" && test $build = $target ; then
14009 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14010set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14011{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14012$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14013if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
5213506e 14014 $as_echo_n "(cached) " >&6
e8b05380
PB
14015else
14016 if test -n "$AR_FOR_TARGET"; then
14017 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
14018else
1c710c3c
DJ
14019as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14020for as_dir in $PATH
14021do
14022 IFS=$as_save_IFS
14023 test -z "$as_dir" && as_dir=.
5213506e 14024 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14025 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14026 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
5213506e 14027 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14028 break 2
14029 fi
14030done
5213506e
RW
14031 done
14032IFS=$as_save_IFS
1c710c3c 14033
e8b05380
PB
14034fi
14035fi
1c710c3c 14036AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
e8b05380 14037if test -n "$AR_FOR_TARGET"; then
5213506e
RW
14038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
14039$as_echo "$AR_FOR_TARGET" >&6; }
e8b05380 14040else
5213506e
RW
14041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14042$as_echo "no" >&6; }
e8b05380 14043fi
1c710c3c 14044
5213506e 14045
e8b05380
PB
14046 fi
14047 test -n "$ac_cv_prog_AR_FOR_TARGET" && break
14048 done
14049fi
1c710c3c 14050
e8b05380
PB
14051if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
14052 set dummy ar
14053 if test $build = $target ; then
14054 AR_FOR_TARGET="$2"
14055 else
14056 AR_FOR_TARGET="${ncn_target_tool_prefix}$2"
2693c0b0 14057 fi
1c00b503
PB
14058else
14059 AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
e8b05380
PB
14060fi
14061
d1f8db0c
PB
14062else
14063 AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
e8b05380
PB
14064fi
14065
14066
14067
14068
14069if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
14070 if test -n "$with_build_time_tools"; then
5213506e
RW
14071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for as in $with_build_time_tools" >&5
14072$as_echo_n "checking for as in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14073 if test -x $with_build_time_tools/as; then
14074 AS_FOR_TARGET=`cd $with_build_time_tools && pwd`/as
14075 ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
5213506e
RW
14076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_AS_FOR_TARGET" >&5
14077$as_echo "$ac_cv_path_AS_FOR_TARGET" >&6; }
d1f8db0c 14078 else
5213506e
RW
14079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14080$as_echo "no" >&6; }
d1f8db0c 14081 fi
e8b05380
PB
14082 elif test $build != $host && test $have_gcc_for_target = yes; then
14083 AS_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=as`
1c00b503
PB
14084 test $AS_FOR_TARGET = as && AS_FOR_TARGET=
14085 test -n "$AS_FOR_TARGET" && ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
e8b05380
PB
14086 fi
14087fi
3e19841a 14088if test -z "$ac_cv_path_AS_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
14089 # Extract the first word of "as", so it can be a program name with args.
14090set dummy as; ac_word=$2
5213506e
RW
14091{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14092$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14093if ${ac_cv_path_AS_FOR_TARGET+:} false; then :
5213506e 14094 $as_echo_n "(cached) " >&6
e8b05380 14095else
1c710c3c
DJ
14096 case $AS_FOR_TARGET in
14097 [\\/]* | ?:[\\/]*)
e8b05380
PB
14098 ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
14099 ;;
e8b05380 14100 *)
1c710c3c
DJ
14101 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14102for as_dir in $gcc_cv_tool_dirs
14103do
14104 IFS=$as_save_IFS
14105 test -z "$as_dir" && as_dir=.
5213506e 14106 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14107 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14108 ac_cv_path_AS_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 14109 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14110 break 2
14111 fi
14112done
5213506e
RW
14113 done
14114IFS=$as_save_IFS
1c710c3c 14115
e8b05380
PB
14116 ;;
14117esac
14118fi
1c710c3c 14119AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
e8b05380 14120if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14122$as_echo "$AS_FOR_TARGET" >&6; }
e8b05380 14123else
5213506e
RW
14124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14125$as_echo "no" >&6; }
e8b05380
PB
14126fi
14127
5213506e 14128
e8b05380
PB
14129fi
14130if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
278a7a38
AO
14131
14132
14133if test -n "$AS_FOR_TARGET"; then
14134 ac_cv_prog_AS_FOR_TARGET=$AS_FOR_TARGET
14135elif test -n "$ac_cv_prog_AS_FOR_TARGET"; then
14136 AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
14137fi
14138
14139if test -n "$ac_cv_prog_AS_FOR_TARGET"; then
14140 for ncn_progname in as; do
14141 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14142set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14143{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14144$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14145if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
5213506e 14146 $as_echo_n "(cached) " >&6
278a7a38
AO
14147else
14148 if test -n "$AS_FOR_TARGET"; then
14149 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
14150else
14151as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14152for as_dir in $PATH
14153do
14154 IFS=$as_save_IFS
14155 test -z "$as_dir" && as_dir=.
5213506e 14156 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14157 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 14158 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
5213506e 14159 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
14160 break 2
14161 fi
14162done
5213506e
RW
14163 done
14164IFS=$as_save_IFS
278a7a38
AO
14165
14166fi
14167fi
14168AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
14169if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14171$as_echo "$AS_FOR_TARGET" >&6; }
278a7a38 14172else
5213506e
RW
14173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14174$as_echo "no" >&6; }
278a7a38
AO
14175fi
14176
5213506e 14177
278a7a38
AO
14178 done
14179fi
14180
14181if test -z "$ac_cv_prog_AS_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 14182 for ncn_progname in as; do
5213506e
RW
14183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14184$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14185 if test -x $with_build_time_tools/${ncn_progname}; then
14186 ac_cv_prog_AS_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
14187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14188$as_echo "yes" >&6; }
e8b05380
PB
14189 break
14190 else
5213506e
RW
14191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14192$as_echo "no" >&6; }
e8b05380
PB
14193 fi
14194 done
14195fi
14196
14197if test -z "$ac_cv_prog_AS_FOR_TARGET"; then
14198 for ncn_progname in as; do
14199 if test -n "$ncn_target_tool_prefix"; then
14200 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14201set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
14202{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14203$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14204if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
5213506e 14205 $as_echo_n "(cached) " >&6
e8b05380
PB
14206else
14207 if test -n "$AS_FOR_TARGET"; then
14208 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
14209else
1c710c3c
DJ
14210as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14211for as_dir in $PATH
14212do
14213 IFS=$as_save_IFS
14214 test -z "$as_dir" && as_dir=.
5213506e 14215 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14216 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14217 ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 14218 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14219 break 2
14220 fi
14221done
5213506e
RW
14222 done
14223IFS=$as_save_IFS
1c710c3c 14224
e8b05380
PB
14225fi
14226fi
1c710c3c 14227AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
e8b05380 14228if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14230$as_echo "$AS_FOR_TARGET" >&6; }
e8b05380 14231else
5213506e
RW
14232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14233$as_echo "no" >&6; }
e8b05380
PB
14234fi
14235
5213506e 14236
e8b05380
PB
14237 fi
14238 if test -z "$ac_cv_prog_AS_FOR_TARGET" && test $build = $target ; then
14239 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 14240set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14241{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14242$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14243if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
5213506e 14244 $as_echo_n "(cached) " >&6
4de997d1 14245else
e8b05380
PB
14246 if test -n "$AS_FOR_TARGET"; then
14247 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
4de997d1 14248else
1c710c3c
DJ
14249as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14250for as_dir in $PATH
14251do
14252 IFS=$as_save_IFS
14253 test -z "$as_dir" && as_dir=.
5213506e 14254 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14255 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14256 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
5213506e 14257 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14258 break 2
14259 fi
14260done
5213506e
RW
14261 done
14262IFS=$as_save_IFS
1c710c3c 14263
4de997d1
PB
14264fi
14265fi
1c710c3c 14266AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
e8b05380 14267if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14269$as_echo "$AS_FOR_TARGET" >&6; }
4de997d1 14270else
5213506e
RW
14271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14272$as_echo "no" >&6; }
4de997d1 14273fi
1c710c3c 14274
5213506e 14275
e8b05380
PB
14276 fi
14277 test -n "$ac_cv_prog_AS_FOR_TARGET" && break
14278 done
14279fi
1c710c3c 14280
e8b05380
PB
14281if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
14282 set dummy as
14283 if test $build = $target ; then
14284 AS_FOR_TARGET="$2"
14285 else
14286 AS_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 14287 fi
1c00b503
PB
14288else
14289 AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
e8b05380 14290fi
2693c0b0 14291
d1f8db0c
PB
14292else
14293 AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
4de997d1
PB
14294fi
14295
e8b05380
PB
14296
14297
14298
14299if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
14300 if test -n "$with_build_time_tools"; then
5213506e
RW
14301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlltool in $with_build_time_tools" >&5
14302$as_echo_n "checking for dlltool in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14303 if test -x $with_build_time_tools/dlltool; then
14304 DLLTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dlltool
14305 ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
5213506e
RW
14306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DLLTOOL_FOR_TARGET" >&5
14307$as_echo "$ac_cv_path_DLLTOOL_FOR_TARGET" >&6; }
d1f8db0c 14308 else
5213506e
RW
14309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14310$as_echo "no" >&6; }
d1f8db0c 14311 fi
e8b05380
PB
14312 elif test $build != $host && test $have_gcc_for_target = yes; then
14313 DLLTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dlltool`
1c00b503
PB
14314 test $DLLTOOL_FOR_TARGET = dlltool && DLLTOOL_FOR_TARGET=
14315 test -n "$DLLTOOL_FOR_TARGET" && ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
e8b05380
PB
14316 fi
14317fi
3e19841a 14318if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
14319 # Extract the first word of "dlltool", so it can be a program name with args.
14320set dummy dlltool; ac_word=$2
5213506e
RW
14321{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14322$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14323if ${ac_cv_path_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 14324 $as_echo_n "(cached) " >&6
4de997d1 14325else
1c710c3c
DJ
14326 case $DLLTOOL_FOR_TARGET in
14327 [\\/]* | ?:[\\/]*)
e8b05380
PB
14328 ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a path.
14329 ;;
e8b05380 14330 *)
1c710c3c
DJ
14331 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14332for as_dir in $gcc_cv_tool_dirs
14333do
14334 IFS=$as_save_IFS
14335 test -z "$as_dir" && as_dir=.
5213506e 14336 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14337 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14338 ac_cv_path_DLLTOOL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 14339 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14340 break 2
14341 fi
14342done
5213506e
RW
14343 done
14344IFS=$as_save_IFS
1c710c3c 14345
e8b05380
PB
14346 ;;
14347esac
4de997d1 14348fi
1c710c3c 14349DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
e8b05380 14350if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
14351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
14352$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
4de997d1 14353else
5213506e
RW
14354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14355$as_echo "no" >&6; }
4de997d1
PB
14356fi
14357
5213506e 14358
e8b05380
PB
14359fi
14360if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
278a7a38
AO
14361
14362
14363if test -n "$DLLTOOL_FOR_TARGET"; then
14364 ac_cv_prog_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
14365elif test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
14366 DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
14367fi
14368
14369if test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
14370 for ncn_progname in dlltool; do
14371 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14372set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14373{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14374$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14375if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 14376 $as_echo_n "(cached) " >&6
278a7a38
AO
14377else
14378 if test -n "$DLLTOOL_FOR_TARGET"; then
14379 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
14380else
14381as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14382for as_dir in $PATH
14383do
14384 IFS=$as_save_IFS
14385 test -z "$as_dir" && as_dir=.
5213506e 14386 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14387 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 14388 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
5213506e 14389 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
14390 break 2
14391 fi
14392done
5213506e
RW
14393 done
14394IFS=$as_save_IFS
278a7a38
AO
14395
14396fi
14397fi
14398DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
14399if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
14400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
14401$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
278a7a38 14402else
5213506e
RW
14403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14404$as_echo "no" >&6; }
278a7a38
AO
14405fi
14406
5213506e 14407
278a7a38
AO
14408 done
14409fi
14410
14411if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 14412 for ncn_progname in dlltool; do
5213506e
RW
14413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14414$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14415 if test -x $with_build_time_tools/${ncn_progname}; then
14416 ac_cv_prog_DLLTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
14417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14418$as_echo "yes" >&6; }
e8b05380
PB
14419 break
14420 else
5213506e
RW
14421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14422$as_echo "no" >&6; }
e8b05380
PB
14423 fi
14424 done
14425fi
14426
14427if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
14428 for ncn_progname in dlltool; do
14429 if test -n "$ncn_target_tool_prefix"; then
14430 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14431set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
14432{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14433$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14434if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 14435 $as_echo_n "(cached) " >&6
4de997d1 14436else
e8b05380
PB
14437 if test -n "$DLLTOOL_FOR_TARGET"; then
14438 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 14439else
1c710c3c
DJ
14440as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14441for as_dir in $PATH
14442do
14443 IFS=$as_save_IFS
14444 test -z "$as_dir" && as_dir=.
5213506e 14445 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14446 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14447 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 14448 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14449 break 2
14450 fi
14451done
5213506e
RW
14452 done
14453IFS=$as_save_IFS
1c710c3c 14454
4de997d1
PB
14455fi
14456fi
1c710c3c 14457DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
e8b05380 14458if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
14459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
14460$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
4de997d1 14461else
5213506e
RW
14462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14463$as_echo "no" >&6; }
4de997d1 14464fi
4de997d1 14465
5213506e 14466
e8b05380
PB
14467 fi
14468 if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test $build = $target ; then
14469 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14470set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14472$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14473if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 14474 $as_echo_n "(cached) " >&6
4de997d1 14475else
e8b05380
PB
14476 if test -n "$DLLTOOL_FOR_TARGET"; then
14477 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 14478else
1c710c3c
DJ
14479as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14480for as_dir in $PATH
14481do
14482 IFS=$as_save_IFS
14483 test -z "$as_dir" && as_dir=.
5213506e 14484 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14485 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14486 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
5213506e 14487 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14488 break 2
14489 fi
14490done
5213506e
RW
14491 done
14492IFS=$as_save_IFS
1c710c3c 14493
4de997d1
PB
14494fi
14495fi
1c710c3c 14496DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
e8b05380 14497if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
14498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
14499$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
4de997d1 14500else
5213506e
RW
14501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14502$as_echo "no" >&6; }
4de997d1 14503fi
1c710c3c 14504
5213506e 14505
e8b05380
PB
14506 fi
14507 test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET" && break
14508 done
14509fi
1c710c3c 14510
e8b05380
PB
14511if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
14512 set dummy dlltool
14513 if test $build = $target ; then
14514 DLLTOOL_FOR_TARGET="$2"
14515 else
14516 DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
14517 fi
1c00b503
PB
14518else
14519 DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
e8b05380
PB
14520fi
14521
d1f8db0c
PB
14522else
14523 DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
e8b05380
PB
14524fi
14525
4de997d1 14526
e8b05380
PB
14527
14528
3b5e8ee4
IS
14529if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
14530 if test -n "$with_build_time_tools"; then
14531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dsymutil in $with_build_time_tools" >&5
14532$as_echo_n "checking for dsymutil in $with_build_time_tools... " >&6; }
14533 if test -x $with_build_time_tools/dsymutil; then
14534 DSYMUTIL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dsymutil
14535 ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
14536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DSYMUTIL_FOR_TARGET" >&5
14537$as_echo "$ac_cv_path_DSYMUTIL_FOR_TARGET" >&6; }
14538 else
14539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14540$as_echo "no" >&6; }
14541 fi
14542 elif test $build != $host && test $have_gcc_for_target = yes; then
14543 DSYMUTIL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dsymutil`
14544 test $DSYMUTIL_FOR_TARGET = dsymutil && DSYMUTIL_FOR_TARGET=
14545 test -n "$DSYMUTIL_FOR_TARGET" && ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
14546 fi
14547fi
14548if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
14549 # Extract the first word of "dsymutil", so it can be a program name with args.
14550set dummy dsymutil; ac_word=$2
14551{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14552$as_echo_n "checking for $ac_word... " >&6; }
14553if ${ac_cv_path_DSYMUTIL_FOR_TARGET+:} false; then :
14554 $as_echo_n "(cached) " >&6
14555else
14556 case $DSYMUTIL_FOR_TARGET in
14557 [\\/]* | ?:[\\/]*)
14558 ac_cv_path_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test with a path.
14559 ;;
14560 *)
14561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14562for as_dir in $gcc_cv_tool_dirs
14563do
14564 IFS=$as_save_IFS
14565 test -z "$as_dir" && as_dir=.
14566 for ac_exec_ext in '' $ac_executable_extensions; do
14567 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14568 ac_cv_path_DSYMUTIL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
14569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14570 break 2
14571 fi
14572done
14573 done
14574IFS=$as_save_IFS
14575
14576 ;;
14577esac
14578fi
14579DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
14580if test -n "$DSYMUTIL_FOR_TARGET"; then
14581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
14582$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
14583else
14584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14585$as_echo "no" >&6; }
14586fi
14587
14588
14589fi
14590if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
14591
14592
14593if test -n "$DSYMUTIL_FOR_TARGET"; then
14594 ac_cv_prog_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
14595elif test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
14596 DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
14597fi
14598
14599if test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
14600 for ncn_progname in dsymutil; do
14601 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14602set dummy ${ncn_progname}; ac_word=$2
14603{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14604$as_echo_n "checking for $ac_word... " >&6; }
14605if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
14606 $as_echo_n "(cached) " >&6
14607else
14608 if test -n "$DSYMUTIL_FOR_TARGET"; then
14609 ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
14610else
14611as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14612for as_dir in $PATH
14613do
14614 IFS=$as_save_IFS
14615 test -z "$as_dir" && as_dir=.
14616 for ac_exec_ext in '' $ac_executable_extensions; do
14617 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14618 ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
14619 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14620 break 2
14621 fi
14622done
14623 done
14624IFS=$as_save_IFS
14625
14626fi
14627fi
14628DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
14629if test -n "$DSYMUTIL_FOR_TARGET"; then
14630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
14631$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
14632else
14633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14634$as_echo "no" >&6; }
14635fi
14636
14637
14638 done
14639fi
14640
14641if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test -n "$with_build_time_tools"; then
14642 for ncn_progname in dsymutil; do
14643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14644$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
14645 if test -x $with_build_time_tools/${ncn_progname}; then
14646 ac_cv_prog_DSYMUTIL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
14647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14648$as_echo "yes" >&6; }
14649 break
14650 else
14651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14652$as_echo "no" >&6; }
14653 fi
14654 done
14655fi
14656
14657if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
14658 for ncn_progname in dsymutil; do
14659 if test -n "$ncn_target_tool_prefix"; then
14660 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14661set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
14662{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14663$as_echo_n "checking for $ac_word... " >&6; }
14664if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
14665 $as_echo_n "(cached) " >&6
14666else
14667 if test -n "$DSYMUTIL_FOR_TARGET"; then
14668 ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
14669else
14670as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14671for as_dir in $PATH
14672do
14673 IFS=$as_save_IFS
14674 test -z "$as_dir" && as_dir=.
14675 for ac_exec_ext in '' $ac_executable_extensions; do
14676 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14677 ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
14678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14679 break 2
14680 fi
14681done
14682 done
14683IFS=$as_save_IFS
14684
14685fi
14686fi
14687DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
14688if test -n "$DSYMUTIL_FOR_TARGET"; then
14689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
14690$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
14691else
14692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14693$as_echo "no" >&6; }
14694fi
14695
14696
14697 fi
14698 if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test $build = $target ; then
14699 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14700set dummy ${ncn_progname}; ac_word=$2
14701{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14702$as_echo_n "checking for $ac_word... " >&6; }
14703if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
14704 $as_echo_n "(cached) " >&6
14705else
14706 if test -n "$DSYMUTIL_FOR_TARGET"; then
14707 ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
14708else
14709as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14710for as_dir in $PATH
14711do
14712 IFS=$as_save_IFS
14713 test -z "$as_dir" && as_dir=.
14714 for ac_exec_ext in '' $ac_executable_extensions; do
14715 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14716 ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
14717 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14718 break 2
14719 fi
14720done
14721 done
14722IFS=$as_save_IFS
14723
14724fi
14725fi
14726DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
14727if test -n "$DSYMUTIL_FOR_TARGET"; then
14728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
14729$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
14730else
14731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14732$as_echo "no" >&6; }
14733fi
14734
14735
14736 fi
14737 test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && break
14738 done
14739fi
14740
14741if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" ; then
14742 set dummy dsymutil
14743 if test $build = $target ; then
14744 DSYMUTIL_FOR_TARGET="$2"
14745 else
14746 DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}$2"
14747 fi
14748else
14749 DSYMUTIL_FOR_TARGET="$ac_cv_prog_DSYMUTIL_FOR_TARGET"
14750fi
14751
14752else
14753 DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
14754fi
14755
14756
14757
14758
e8b05380
PB
14759if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
14760 if test -n "$with_build_time_tools"; then
5213506e
RW
14761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld in $with_build_time_tools" >&5
14762$as_echo_n "checking for ld in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14763 if test -x $with_build_time_tools/ld; then
14764 LD_FOR_TARGET=`cd $with_build_time_tools && pwd`/ld
14765 ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
5213506e
RW
14766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_LD_FOR_TARGET" >&5
14767$as_echo "$ac_cv_path_LD_FOR_TARGET" >&6; }
d1f8db0c 14768 else
5213506e
RW
14769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14770$as_echo "no" >&6; }
d1f8db0c 14771 fi
e8b05380
PB
14772 elif test $build != $host && test $have_gcc_for_target = yes; then
14773 LD_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ld`
1c00b503
PB
14774 test $LD_FOR_TARGET = ld && LD_FOR_TARGET=
14775 test -n "$LD_FOR_TARGET" && ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
2693c0b0 14776 fi
e8b05380 14777fi
3e19841a 14778if test -z "$ac_cv_path_LD_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
14779 # Extract the first word of "ld", so it can be a program name with args.
14780set dummy ld; ac_word=$2
5213506e
RW
14781{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14782$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14783if ${ac_cv_path_LD_FOR_TARGET+:} false; then :
5213506e 14784 $as_echo_n "(cached) " >&6
4de997d1 14785else
1c710c3c
DJ
14786 case $LD_FOR_TARGET in
14787 [\\/]* | ?:[\\/]*)
e8b05380
PB
14788 ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
14789 ;;
e8b05380 14790 *)
1c710c3c
DJ
14791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14792for as_dir in $gcc_cv_tool_dirs
14793do
14794 IFS=$as_save_IFS
14795 test -z "$as_dir" && as_dir=.
5213506e 14796 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14797 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14798 ac_cv_path_LD_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 14799 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14800 break 2
14801 fi
14802done
5213506e
RW
14803 done
14804IFS=$as_save_IFS
1c710c3c 14805
e8b05380
PB
14806 ;;
14807esac
4de997d1 14808fi
1c710c3c 14809LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
e8b05380 14810if test -n "$LD_FOR_TARGET"; then
5213506e
RW
14811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
14812$as_echo "$LD_FOR_TARGET" >&6; }
4de997d1 14813else
5213506e
RW
14814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14815$as_echo "no" >&6; }
4de997d1 14816fi
2693c0b0 14817
5213506e 14818
e8b05380
PB
14819fi
14820if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
278a7a38
AO
14821
14822
14823if test -n "$LD_FOR_TARGET"; then
14824 ac_cv_prog_LD_FOR_TARGET=$LD_FOR_TARGET
14825elif test -n "$ac_cv_prog_LD_FOR_TARGET"; then
14826 LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
14827fi
14828
14829if test -n "$ac_cv_prog_LD_FOR_TARGET"; then
14830 for ncn_progname in ld; do
14831 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14832set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14833{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14834$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14835if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
5213506e 14836 $as_echo_n "(cached) " >&6
278a7a38
AO
14837else
14838 if test -n "$LD_FOR_TARGET"; then
14839 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
14840else
14841as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14842for as_dir in $PATH
14843do
14844 IFS=$as_save_IFS
14845 test -z "$as_dir" && as_dir=.
5213506e 14846 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14847 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 14848 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
5213506e 14849 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
14850 break 2
14851 fi
14852done
5213506e
RW
14853 done
14854IFS=$as_save_IFS
278a7a38
AO
14855
14856fi
14857fi
14858LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
14859if test -n "$LD_FOR_TARGET"; then
5213506e
RW
14860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
14861$as_echo "$LD_FOR_TARGET" >&6; }
278a7a38 14862else
5213506e
RW
14863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14864$as_echo "no" >&6; }
278a7a38
AO
14865fi
14866
5213506e 14867
278a7a38
AO
14868 done
14869fi
14870
14871if test -z "$ac_cv_prog_LD_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 14872 for ncn_progname in ld; do
5213506e
RW
14873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14874$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14875 if test -x $with_build_time_tools/${ncn_progname}; then
14876 ac_cv_prog_LD_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
14877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14878$as_echo "yes" >&6; }
e8b05380
PB
14879 break
14880 else
5213506e
RW
14881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14882$as_echo "no" >&6; }
e8b05380
PB
14883 fi
14884 done
ca9f4b81
AO
14885fi
14886
e8b05380
PB
14887if test -z "$ac_cv_prog_LD_FOR_TARGET"; then
14888 for ncn_progname in ld; do
14889 if test -n "$ncn_target_tool_prefix"; then
14890 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 14891set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
14892{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14893$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14894if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
5213506e 14895 $as_echo_n "(cached) " >&6
ca9f4b81 14896else
4de997d1
PB
14897 if test -n "$LD_FOR_TARGET"; then
14898 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 14899else
1c710c3c
DJ
14900as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14901for as_dir in $PATH
14902do
14903 IFS=$as_save_IFS
14904 test -z "$as_dir" && as_dir=.
5213506e 14905 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14906 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14907 ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 14908 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14909 break 2
14910 fi
14911done
5213506e
RW
14912 done
14913IFS=$as_save_IFS
1c710c3c 14914
ca9f4b81
AO
14915fi
14916fi
1c710c3c 14917LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
4de997d1 14918if test -n "$LD_FOR_TARGET"; then
5213506e
RW
14919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
14920$as_echo "$LD_FOR_TARGET" >&6; }
ca9f4b81 14921else
5213506e
RW
14922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14923$as_echo "no" >&6; }
ca9f4b81
AO
14924fi
14925
5213506e 14926
e8b05380
PB
14927 fi
14928 if test -z "$ac_cv_prog_LD_FOR_TARGET" && test $build = $target ; then
14929 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 14930set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14932$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14933if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
5213506e 14934 $as_echo_n "(cached) " >&6
ca9f4b81 14935else
2693c0b0
PB
14936 if test -n "$LD_FOR_TARGET"; then
14937 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 14938else
1c710c3c
DJ
14939as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14940for as_dir in $PATH
14941do
14942 IFS=$as_save_IFS
14943 test -z "$as_dir" && as_dir=.
5213506e 14944 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14945 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14946 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
5213506e 14947 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14948 break 2
14949 fi
14950done
5213506e
RW
14951 done
14952IFS=$as_save_IFS
1c710c3c 14953
ca9f4b81
AO
14954fi
14955fi
1c710c3c 14956LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
2693c0b0 14957if test -n "$LD_FOR_TARGET"; then
5213506e
RW
14958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
14959$as_echo "$LD_FOR_TARGET" >&6; }
ca9f4b81 14960else
5213506e
RW
14961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14962$as_echo "no" >&6; }
ca9f4b81 14963fi
1c710c3c 14964
5213506e 14965
e8b05380
PB
14966 fi
14967 test -n "$ac_cv_prog_LD_FOR_TARGET" && break
14968 done
14969fi
1c710c3c 14970
2693c0b0
PB
14971if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
14972 set dummy ld
14973 if test $build = $target ; then
14974 LD_FOR_TARGET="$2"
ca9f4b81 14975 else
2693c0b0 14976 LD_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 14977 fi
1c00b503
PB
14978else
14979 LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
ca9f4b81
AO
14980fi
14981
d1f8db0c
PB
14982else
14983 LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
e8b05380
PB
14984fi
14985
14986
14987
14988
14989if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
14990 if test -n "$with_build_time_tools"; then
5213506e
RW
14991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lipo in $with_build_time_tools" >&5
14992$as_echo_n "checking for lipo in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14993 if test -x $with_build_time_tools/lipo; then
14994 LIPO_FOR_TARGET=`cd $with_build_time_tools && pwd`/lipo
14995 ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
5213506e
RW
14996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_LIPO_FOR_TARGET" >&5
14997$as_echo "$ac_cv_path_LIPO_FOR_TARGET" >&6; }
d1f8db0c 14998 else
5213506e
RW
14999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15000$as_echo "no" >&6; }
d1f8db0c 15001 fi
e8b05380
PB
15002 elif test $build != $host && test $have_gcc_for_target = yes; then
15003 LIPO_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=lipo`
1c00b503
PB
15004 test $LIPO_FOR_TARGET = lipo && LIPO_FOR_TARGET=
15005 test -n "$LIPO_FOR_TARGET" && ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
e8b05380
PB
15006 fi
15007fi
278a7a38
AO
15008if test -z "$ac_cv_path_LIPO_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
15009 # Extract the first word of "lipo", so it can be a program name with args.
15010set dummy lipo; ac_word=$2
5213506e
RW
15011{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15012$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15013if ${ac_cv_path_LIPO_FOR_TARGET+:} false; then :
5213506e 15014 $as_echo_n "(cached) " >&6
278a7a38
AO
15015else
15016 case $LIPO_FOR_TARGET in
15017 [\\/]* | ?:[\\/]*)
15018 ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a path.
15019 ;;
15020 *)
15021 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15022for as_dir in $gcc_cv_tool_dirs
15023do
15024 IFS=$as_save_IFS
15025 test -z "$as_dir" && as_dir=.
5213506e 15026 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15027 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15028 ac_cv_path_LIPO_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 15029 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15030 break 2
15031 fi
15032done
5213506e
RW
15033 done
15034IFS=$as_save_IFS
278a7a38
AO
15035
15036 ;;
15037esac
15038fi
15039LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
278a7a38 15040if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15042$as_echo "$LIPO_FOR_TARGET" >&6; }
278a7a38 15043else
5213506e
RW
15044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15045$as_echo "no" >&6; }
278a7a38
AO
15046fi
15047
5213506e 15048
278a7a38
AO
15049fi
15050if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
15051
15052
15053if test -n "$LIPO_FOR_TARGET"; then
15054 ac_cv_prog_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
15055elif test -n "$ac_cv_prog_LIPO_FOR_TARGET"; then
15056 LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
15057fi
15058
15059if test -n "$ac_cv_prog_LIPO_FOR_TARGET"; then
15060 for ncn_progname in lipo; do
15061 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15062set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15063{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15064$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15065if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
5213506e 15066 $as_echo_n "(cached) " >&6
e8b05380 15067else
278a7a38
AO
15068 if test -n "$LIPO_FOR_TARGET"; then
15069 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
15070else
15071as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15072for as_dir in $PATH
1c710c3c
DJ
15073do
15074 IFS=$as_save_IFS
15075 test -z "$as_dir" && as_dir=.
5213506e 15076 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15078 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
5213506e 15079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15080 break 2
15081 fi
15082done
5213506e
RW
15083 done
15084IFS=$as_save_IFS
1c710c3c 15085
e8b05380 15086fi
278a7a38
AO
15087fi
15088LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
e8b05380 15089if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15091$as_echo "$LIPO_FOR_TARGET" >&6; }
e8b05380 15092else
5213506e
RW
15093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15094$as_echo "no" >&6; }
e8b05380
PB
15095fi
15096
5213506e 15097
278a7a38 15098 done
e8b05380 15099fi
278a7a38
AO
15100
15101if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15102 for ncn_progname in lipo; do
5213506e
RW
15103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15104$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15105 if test -x $with_build_time_tools/${ncn_progname}; then
15106 ac_cv_prog_LIPO_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15108$as_echo "yes" >&6; }
e8b05380
PB
15109 break
15110 else
5213506e
RW
15111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15112$as_echo "no" >&6; }
e8b05380
PB
15113 fi
15114 done
15115fi
15116
15117if test -z "$ac_cv_prog_LIPO_FOR_TARGET"; then
15118 for ncn_progname in lipo; do
15119 if test -n "$ncn_target_tool_prefix"; then
15120 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 15121set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15122{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15123$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15124if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
5213506e 15125 $as_echo_n "(cached) " >&6
040b1c5a
GK
15126else
15127 if test -n "$LIPO_FOR_TARGET"; then
15128 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
15129else
1c710c3c
DJ
15130as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15131for as_dir in $PATH
15132do
15133 IFS=$as_save_IFS
15134 test -z "$as_dir" && as_dir=.
5213506e 15135 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15137 ac_cv_prog_LIPO_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15139 break 2
15140 fi
15141done
5213506e
RW
15142 done
15143IFS=$as_save_IFS
1c710c3c 15144
040b1c5a
GK
15145fi
15146fi
1c710c3c 15147LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
040b1c5a 15148if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15150$as_echo "$LIPO_FOR_TARGET" >&6; }
040b1c5a 15151else
5213506e
RW
15152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15153$as_echo "no" >&6; }
040b1c5a
GK
15154fi
15155
5213506e 15156
e8b05380
PB
15157 fi
15158 if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test $build = $target ; then
15159 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 15160set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15162$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15163if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
5213506e 15164 $as_echo_n "(cached) " >&6
040b1c5a
GK
15165else
15166 if test -n "$LIPO_FOR_TARGET"; then
72a7ab82
AP
15167 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
15168else
1c710c3c
DJ
15169as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15170for as_dir in $PATH
15171do
15172 IFS=$as_save_IFS
15173 test -z "$as_dir" && as_dir=.
5213506e 15174 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15175 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15176 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
5213506e 15177 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15178 break 2
15179 fi
15180done
5213506e
RW
15181 done
15182IFS=$as_save_IFS
1c710c3c 15183
040b1c5a
GK
15184fi
15185fi
1c710c3c 15186LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
040b1c5a 15187if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15189$as_echo "$LIPO_FOR_TARGET" >&6; }
040b1c5a 15190else
5213506e
RW
15191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15192$as_echo "no" >&6; }
040b1c5a 15193fi
1c710c3c 15194
5213506e 15195
e8b05380
PB
15196 fi
15197 test -n "$ac_cv_prog_LIPO_FOR_TARGET" && break
15198 done
15199fi
1c710c3c 15200
040b1c5a
GK
15201if test -z "$ac_cv_prog_LIPO_FOR_TARGET" ; then
15202 set dummy lipo
15203 if test $build = $target ; then
15204 LIPO_FOR_TARGET="$2"
15205 else
15206 LIPO_FOR_TARGET="${ncn_target_tool_prefix}$2"
15207 fi
1c00b503
PB
15208else
15209 LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
040b1c5a
GK
15210fi
15211
d1f8db0c
PB
15212else
15213 LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
e8b05380
PB
15214fi
15215
15216
15217
15218
15219if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
15220 if test -n "$with_build_time_tools"; then
5213506e
RW
15221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nm in $with_build_time_tools" >&5
15222$as_echo_n "checking for nm in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15223 if test -x $with_build_time_tools/nm; then
15224 NM_FOR_TARGET=`cd $with_build_time_tools && pwd`/nm
15225 ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
5213506e
RW
15226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_NM_FOR_TARGET" >&5
15227$as_echo "$ac_cv_path_NM_FOR_TARGET" >&6; }
d1f8db0c 15228 else
5213506e
RW
15229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15230$as_echo "no" >&6; }
d1f8db0c 15231 fi
e8b05380
PB
15232 elif test $build != $host && test $have_gcc_for_target = yes; then
15233 NM_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=nm`
1c00b503
PB
15234 test $NM_FOR_TARGET = nm && NM_FOR_TARGET=
15235 test -n "$NM_FOR_TARGET" && ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
e8b05380
PB
15236 fi
15237fi
3e19841a 15238if test -z "$ac_cv_path_NM_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
15239 # Extract the first word of "nm", so it can be a program name with args.
15240set dummy nm; ac_word=$2
5213506e
RW
15241{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15242$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15243if ${ac_cv_path_NM_FOR_TARGET+:} false; then :
5213506e 15244 $as_echo_n "(cached) " >&6
e8b05380 15245else
1c710c3c
DJ
15246 case $NM_FOR_TARGET in
15247 [\\/]* | ?:[\\/]*)
e8b05380
PB
15248 ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
15249 ;;
e8b05380 15250 *)
1c710c3c
DJ
15251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15252for as_dir in $gcc_cv_tool_dirs
15253do
15254 IFS=$as_save_IFS
15255 test -z "$as_dir" && as_dir=.
5213506e 15256 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15258 ac_cv_path_NM_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 15259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15260 break 2
15261 fi
15262done
5213506e
RW
15263 done
15264IFS=$as_save_IFS
1c710c3c 15265
e8b05380
PB
15266 ;;
15267esac
15268fi
1c710c3c 15269NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
e8b05380 15270if test -n "$NM_FOR_TARGET"; then
5213506e
RW
15271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
15272$as_echo "$NM_FOR_TARGET" >&6; }
e8b05380 15273else
5213506e
RW
15274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15275$as_echo "no" >&6; }
e8b05380
PB
15276fi
15277
5213506e 15278
e8b05380
PB
15279fi
15280if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
278a7a38
AO
15281
15282
15283if test -n "$NM_FOR_TARGET"; then
15284 ac_cv_prog_NM_FOR_TARGET=$NM_FOR_TARGET
15285elif test -n "$ac_cv_prog_NM_FOR_TARGET"; then
15286 NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
15287fi
15288
15289if test -n "$ac_cv_prog_NM_FOR_TARGET"; then
15290 for ncn_progname in nm; do
15291 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15292set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15293{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15294$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15295if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
5213506e 15296 $as_echo_n "(cached) " >&6
278a7a38
AO
15297else
15298 if test -n "$NM_FOR_TARGET"; then
15299 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
15300else
15301as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15302for as_dir in $PATH
15303do
15304 IFS=$as_save_IFS
15305 test -z "$as_dir" && as_dir=.
5213506e 15306 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15307 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15308 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
5213506e 15309 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15310 break 2
15311 fi
15312done
5213506e
RW
15313 done
15314IFS=$as_save_IFS
278a7a38
AO
15315
15316fi
15317fi
15318NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
15319if test -n "$NM_FOR_TARGET"; then
5213506e
RW
15320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
15321$as_echo "$NM_FOR_TARGET" >&6; }
278a7a38 15322else
5213506e
RW
15323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15324$as_echo "no" >&6; }
278a7a38
AO
15325fi
15326
5213506e 15327
278a7a38
AO
15328 done
15329fi
15330
15331if test -z "$ac_cv_prog_NM_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15332 for ncn_progname in nm; do
5213506e
RW
15333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15334$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15335 if test -x $with_build_time_tools/${ncn_progname}; then
15336 ac_cv_prog_NM_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15338$as_echo "yes" >&6; }
e8b05380
PB
15339 break
15340 else
5213506e
RW
15341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15342$as_echo "no" >&6; }
e8b05380
PB
15343 fi
15344 done
15345fi
15346
15347if test -z "$ac_cv_prog_NM_FOR_TARGET"; then
15348 for ncn_progname in nm; do
15349 if test -n "$ncn_target_tool_prefix"; then
15350 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 15351set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15353$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15354if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
5213506e 15355 $as_echo_n "(cached) " >&6
ca9f4b81 15356else
4de997d1
PB
15357 if test -n "$NM_FOR_TARGET"; then
15358 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 15359else
1c710c3c
DJ
15360as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15361for as_dir in $PATH
15362do
15363 IFS=$as_save_IFS
15364 test -z "$as_dir" && as_dir=.
5213506e 15365 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15366 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15367 ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15368 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15369 break 2
15370 fi
15371done
5213506e
RW
15372 done
15373IFS=$as_save_IFS
1c710c3c 15374
ca9f4b81
AO
15375fi
15376fi
1c710c3c 15377NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
4de997d1 15378if test -n "$NM_FOR_TARGET"; then
5213506e
RW
15379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
15380$as_echo "$NM_FOR_TARGET" >&6; }
ca9f4b81 15381else
5213506e
RW
15382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15383$as_echo "no" >&6; }
ca9f4b81
AO
15384fi
15385
5213506e 15386
e8b05380
PB
15387 fi
15388 if test -z "$ac_cv_prog_NM_FOR_TARGET" && test $build = $target ; then
15389 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 15390set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15391{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15392$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15393if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
5213506e 15394 $as_echo_n "(cached) " >&6
ca9f4b81 15395else
2693c0b0
PB
15396 if test -n "$NM_FOR_TARGET"; then
15397 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 15398else
1c710c3c
DJ
15399as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15400for as_dir in $PATH
15401do
15402 IFS=$as_save_IFS
15403 test -z "$as_dir" && as_dir=.
5213506e 15404 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15405 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15406 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
5213506e 15407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15408 break 2
15409 fi
15410done
5213506e
RW
15411 done
15412IFS=$as_save_IFS
1c710c3c 15413
ca9f4b81
AO
15414fi
15415fi
1c710c3c 15416NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
2693c0b0 15417if test -n "$NM_FOR_TARGET"; then
5213506e
RW
15418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
15419$as_echo "$NM_FOR_TARGET" >&6; }
ca9f4b81 15420else
5213506e
RW
15421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15422$as_echo "no" >&6; }
ca9f4b81 15423fi
1c710c3c 15424
5213506e 15425
e8b05380
PB
15426 fi
15427 test -n "$ac_cv_prog_NM_FOR_TARGET" && break
15428 done
15429fi
1c710c3c 15430
2693c0b0
PB
15431if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
15432 set dummy nm
15433 if test $build = $target ; then
15434 NM_FOR_TARGET="$2"
ca9f4b81 15435 else
2693c0b0 15436 NM_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 15437 fi
1c00b503
PB
15438else
15439 NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
ca9f4b81
AO
15440fi
15441
d1f8db0c
PB
15442else
15443 NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
e8b05380
PB
15444fi
15445
15446
15447
15448
9bccfdf5
AP
15449if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" ; then
15450 if test -n "$with_build_time_tools"; then
15451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objcopy in $with_build_time_tools" >&5
15452$as_echo_n "checking for objcopy in $with_build_time_tools... " >&6; }
15453 if test -x $with_build_time_tools/objcopy; then
15454 OBJCOPY_FOR_TARGET=`cd $with_build_time_tools && pwd`/objcopy
15455 ac_cv_path_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
15456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OBJCOPY_FOR_TARGET" >&5
15457$as_echo "$ac_cv_path_OBJCOPY_FOR_TARGET" >&6; }
15458 else
15459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15460$as_echo "no" >&6; }
15461 fi
15462 elif test $build != $host && test $have_gcc_for_target = yes; then
15463 OBJCOPY_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objcopy`
15464 test $OBJCOPY_FOR_TARGET = objcopy && OBJCOPY_FOR_TARGET=
15465 test -n "$OBJCOPY_FOR_TARGET" && ac_cv_path_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
15466 fi
15467fi
15468if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
15469 # Extract the first word of "objcopy", so it can be a program name with args.
15470set dummy objcopy; ac_word=$2
15471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15472$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15473if ${ac_cv_path_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
15474 $as_echo_n "(cached) " >&6
15475else
15476 case $OBJCOPY_FOR_TARGET in
15477 [\\/]* | ?:[\\/]*)
15478 ac_cv_path_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test with a path.
15479 ;;
15480 *)
15481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15482for as_dir in $gcc_cv_tool_dirs
15483do
15484 IFS=$as_save_IFS
15485 test -z "$as_dir" && as_dir=.
15486 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
15488 ac_cv_path_OBJCOPY_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
15489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15490 break 2
15491 fi
15492done
15493 done
15494IFS=$as_save_IFS
15495
15496 ;;
15497esac
15498fi
15499OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
15500if test -n "$OBJCOPY_FOR_TARGET"; then
15501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
15502$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
15503else
15504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15505$as_echo "no" >&6; }
15506fi
15507
15508
15509fi
15510if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" ; then
15511
15512
15513if test -n "$OBJCOPY_FOR_TARGET"; then
15514 ac_cv_prog_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
15515elif test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
15516 OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
15517fi
15518
15519if test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
15520 for ncn_progname in objcopy; do
15521 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15522set dummy ${ncn_progname}; ac_word=$2
15523{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15524$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15525if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
15526 $as_echo_n "(cached) " >&6
15527else
15528 if test -n "$OBJCOPY_FOR_TARGET"; then
15529 ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
15530else
15531as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15532for as_dir in $PATH
15533do
15534 IFS=$as_save_IFS
15535 test -z "$as_dir" && as_dir=.
15536 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15537 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
15538 ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_progname}"
15539 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15540 break 2
15541 fi
15542done
15543 done
15544IFS=$as_save_IFS
15545
15546fi
15547fi
15548OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
15549if test -n "$OBJCOPY_FOR_TARGET"; then
15550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
15551$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
15552else
15553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15554$as_echo "no" >&6; }
15555fi
15556
15557
15558 done
15559fi
15560
15561if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" && test -n "$with_build_time_tools"; then
15562 for ncn_progname in objcopy; do
15563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15564$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
15565 if test -x $with_build_time_tools/${ncn_progname}; then
15566 ac_cv_prog_OBJCOPY_FOR_TARGET=$with_build_time_tools/${ncn_progname}
15567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15568$as_echo "yes" >&6; }
15569 break
15570 else
15571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15572$as_echo "no" >&6; }
15573 fi
15574 done
15575fi
15576
15577if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
15578 for ncn_progname in objcopy; do
15579 if test -n "$ncn_target_tool_prefix"; then
15580 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
15581set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
15582{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15583$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15584if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
15585 $as_echo_n "(cached) " >&6
15586else
15587 if test -n "$OBJCOPY_FOR_TARGET"; then
15588 ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
15589else
15590as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15591for as_dir in $PATH
15592do
15593 IFS=$as_save_IFS
15594 test -z "$as_dir" && as_dir=.
15595 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15596 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
15597 ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
15598 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15599 break 2
15600 fi
15601done
15602 done
15603IFS=$as_save_IFS
15604
15605fi
15606fi
15607OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
15608if test -n "$OBJCOPY_FOR_TARGET"; then
15609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
15610$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
15611else
15612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15613$as_echo "no" >&6; }
15614fi
15615
15616
15617 fi
15618 if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" && test $build = $target ; then
15619 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15620set dummy ${ncn_progname}; ac_word=$2
15621{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15622$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15623if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
15624 $as_echo_n "(cached) " >&6
15625else
15626 if test -n "$OBJCOPY_FOR_TARGET"; then
15627 ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
15628else
15629as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15630for as_dir in $PATH
15631do
15632 IFS=$as_save_IFS
15633 test -z "$as_dir" && as_dir=.
15634 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15635 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
15636 ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_progname}"
15637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15638 break 2
15639 fi
15640done
15641 done
15642IFS=$as_save_IFS
15643
15644fi
15645fi
15646OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
15647if test -n "$OBJCOPY_FOR_TARGET"; then
15648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
15649$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
15650else
15651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15652$as_echo "no" >&6; }
15653fi
15654
15655
15656 fi
15657 test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET" && break
15658 done
15659fi
15660
15661if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" ; then
15662 set dummy objcopy
15663 if test $build = $target ; then
15664 OBJCOPY_FOR_TARGET="$2"
15665 else
15666 OBJCOPY_FOR_TARGET="${ncn_target_tool_prefix}$2"
15667 fi
15668else
15669 OBJCOPY_FOR_TARGET="$ac_cv_prog_OBJCOPY_FOR_TARGET"
15670fi
15671
15672else
15673 OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
15674fi
15675
15676
15677
15678
e8b05380
PB
15679if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
15680 if test -n "$with_build_time_tools"; then
5213506e
RW
15681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdump in $with_build_time_tools" >&5
15682$as_echo_n "checking for objdump in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15683 if test -x $with_build_time_tools/objdump; then
15684 OBJDUMP_FOR_TARGET=`cd $with_build_time_tools && pwd`/objdump
15685 ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
5213506e
RW
15686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OBJDUMP_FOR_TARGET" >&5
15687$as_echo "$ac_cv_path_OBJDUMP_FOR_TARGET" >&6; }
d1f8db0c 15688 else
5213506e
RW
15689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15690$as_echo "no" >&6; }
d1f8db0c 15691 fi
e8b05380
PB
15692 elif test $build != $host && test $have_gcc_for_target = yes; then
15693 OBJDUMP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objdump`
1c00b503
PB
15694 test $OBJDUMP_FOR_TARGET = objdump && OBJDUMP_FOR_TARGET=
15695 test -n "$OBJDUMP_FOR_TARGET" && ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
e8b05380
PB
15696 fi
15697fi
3e19841a 15698if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
15699 # Extract the first word of "objdump", so it can be a program name with args.
15700set dummy objdump; ac_word=$2
5213506e
RW
15701{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15702$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15703if ${ac_cv_path_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 15704 $as_echo_n "(cached) " >&6
e8b05380 15705else
1c710c3c
DJ
15706 case $OBJDUMP_FOR_TARGET in
15707 [\\/]* | ?:[\\/]*)
e8b05380
PB
15708 ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a path.
15709 ;;
e8b05380 15710 *)
1c710c3c
DJ
15711 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15712for as_dir in $gcc_cv_tool_dirs
15713do
15714 IFS=$as_save_IFS
15715 test -z "$as_dir" && as_dir=.
5213506e 15716 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15717 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15718 ac_cv_path_OBJDUMP_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 15719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15720 break 2
15721 fi
15722done
5213506e
RW
15723 done
15724IFS=$as_save_IFS
1c710c3c 15725
e8b05380
PB
15726 ;;
15727esac
15728fi
1c710c3c 15729OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
e8b05380 15730if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
15731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
15732$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
e8b05380 15733else
5213506e
RW
15734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15735$as_echo "no" >&6; }
e8b05380
PB
15736fi
15737
5213506e 15738
e8b05380
PB
15739fi
15740if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
278a7a38
AO
15741
15742
15743if test -n "$OBJDUMP_FOR_TARGET"; then
15744 ac_cv_prog_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
15745elif test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
15746 OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
15747fi
15748
15749if test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
15750 for ncn_progname in objdump; do
15751 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15752set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15753{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15754$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15755if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 15756 $as_echo_n "(cached) " >&6
278a7a38
AO
15757else
15758 if test -n "$OBJDUMP_FOR_TARGET"; then
15759 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
15760else
15761as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15762for as_dir in $PATH
15763do
15764 IFS=$as_save_IFS
15765 test -z "$as_dir" && as_dir=.
5213506e 15766 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15767 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15768 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
5213506e 15769 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15770 break 2
15771 fi
15772done
5213506e
RW
15773 done
15774IFS=$as_save_IFS
278a7a38
AO
15775
15776fi
15777fi
15778OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
15779if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
15780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
15781$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
278a7a38 15782else
5213506e
RW
15783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15784$as_echo "no" >&6; }
278a7a38
AO
15785fi
15786
5213506e 15787
278a7a38
AO
15788 done
15789fi
15790
15791if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15792 for ncn_progname in objdump; do
5213506e
RW
15793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15794$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15795 if test -x $with_build_time_tools/${ncn_progname}; then
15796 ac_cv_prog_OBJDUMP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15798$as_echo "yes" >&6; }
e8b05380
PB
15799 break
15800 else
5213506e
RW
15801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15802$as_echo "no" >&6; }
e8b05380
PB
15803 fi
15804 done
15805fi
15806
15807if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
15808 for ncn_progname in objdump; do
15809 if test -n "$ncn_target_tool_prefix"; then
15810 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 15811set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15812{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15813$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15814if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 15815 $as_echo_n "(cached) " >&6
d739199a
DJ
15816else
15817 if test -n "$OBJDUMP_FOR_TARGET"; then
15818 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
15819else
1c710c3c
DJ
15820as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15821for as_dir in $PATH
15822do
15823 IFS=$as_save_IFS
15824 test -z "$as_dir" && as_dir=.
5213506e 15825 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15826 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15827 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15828 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15829 break 2
15830 fi
15831done
5213506e
RW
15832 done
15833IFS=$as_save_IFS
1c710c3c 15834
d739199a
DJ
15835fi
15836fi
1c710c3c 15837OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
d739199a 15838if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
15839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
15840$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
d739199a 15841else
5213506e
RW
15842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15843$as_echo "no" >&6; }
d739199a
DJ
15844fi
15845
5213506e 15846
e8b05380
PB
15847 fi
15848 if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test $build = $target ; then
15849 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
d739199a 15850set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15851{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15852$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15853if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 15854 $as_echo_n "(cached) " >&6
d739199a
DJ
15855else
15856 if test -n "$OBJDUMP_FOR_TARGET"; then
15857 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
15858else
1c710c3c
DJ
15859as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15860for as_dir in $PATH
15861do
15862 IFS=$as_save_IFS
15863 test -z "$as_dir" && as_dir=.
5213506e 15864 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15865 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15866 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
5213506e 15867 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15868 break 2
15869 fi
15870done
5213506e
RW
15871 done
15872IFS=$as_save_IFS
1c710c3c 15873
d739199a
DJ
15874fi
15875fi
1c710c3c 15876OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
d739199a 15877if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
15878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
15879$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
d739199a 15880else
5213506e
RW
15881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15882$as_echo "no" >&6; }
d739199a 15883fi
1c710c3c 15884
5213506e 15885
e8b05380
PB
15886 fi
15887 test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET" && break
15888 done
15889fi
1c710c3c 15890
d739199a
DJ
15891if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" ; then
15892 set dummy objdump
15893 if test $build = $target ; then
15894 OBJDUMP_FOR_TARGET="$2"
15895 else
15896 OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}$2"
15897 fi
1c00b503
PB
15898else
15899 OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
d739199a
DJ
15900fi
15901
d1f8db0c
PB
15902else
15903 OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
e8b05380
PB
15904fi
15905
15906
15907
15908
e4a9a572
IS
15909if test -z "$ac_cv_path_OTOOL_FOR_TARGET" ; then
15910 if test -n "$with_build_time_tools"; then
15911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for otool in $with_build_time_tools" >&5
15912$as_echo_n "checking for otool in $with_build_time_tools... " >&6; }
15913 if test -x $with_build_time_tools/otool; then
15914 OTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/otool
15915 ac_cv_path_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
15916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OTOOL_FOR_TARGET" >&5
15917$as_echo "$ac_cv_path_OTOOL_FOR_TARGET" >&6; }
15918 else
15919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15920$as_echo "no" >&6; }
15921 fi
15922 elif test $build != $host && test $have_gcc_for_target = yes; then
15923 OTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=otool`
15924 test $OTOOL_FOR_TARGET = otool && OTOOL_FOR_TARGET=
15925 test -n "$OTOOL_FOR_TARGET" && ac_cv_path_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
15926 fi
15927fi
15928if test -z "$ac_cv_path_OTOOL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
15929 # Extract the first word of "otool", so it can be a program name with args.
15930set dummy otool; ac_word=$2
15931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15932$as_echo_n "checking for $ac_word... " >&6; }
15933if ${ac_cv_path_OTOOL_FOR_TARGET+:} false; then :
15934 $as_echo_n "(cached) " >&6
15935else
15936 case $OTOOL_FOR_TARGET in
15937 [\\/]* | ?:[\\/]*)
15938 ac_cv_path_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test with a path.
15939 ;;
15940 *)
15941 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15942for as_dir in $gcc_cv_tool_dirs
15943do
15944 IFS=$as_save_IFS
15945 test -z "$as_dir" && as_dir=.
15946 for ac_exec_ext in '' $ac_executable_extensions; do
15947 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15948 ac_cv_path_OTOOL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
15949 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15950 break 2
15951 fi
15952done
15953 done
15954IFS=$as_save_IFS
15955
15956 ;;
15957esac
15958fi
15959OTOOL_FOR_TARGET=$ac_cv_path_OTOOL_FOR_TARGET
15960if test -n "$OTOOL_FOR_TARGET"; then
15961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
15962$as_echo "$OTOOL_FOR_TARGET" >&6; }
15963else
15964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15965$as_echo "no" >&6; }
15966fi
15967
15968
15969fi
15970if test -z "$ac_cv_path_OTOOL_FOR_TARGET" ; then
15971
15972
15973if test -n "$OTOOL_FOR_TARGET"; then
15974 ac_cv_prog_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
15975elif test -n "$ac_cv_prog_OTOOL_FOR_TARGET"; then
15976 OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
15977fi
15978
15979if test -n "$ac_cv_prog_OTOOL_FOR_TARGET"; then
15980 for ncn_progname in otool; do
15981 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15982set dummy ${ncn_progname}; ac_word=$2
15983{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15984$as_echo_n "checking for $ac_word... " >&6; }
15985if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
15986 $as_echo_n "(cached) " >&6
15987else
15988 if test -n "$OTOOL_FOR_TARGET"; then
15989 ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
15990else
15991as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15992for as_dir in $PATH
15993do
15994 IFS=$as_save_IFS
15995 test -z "$as_dir" && as_dir=.
15996 for ac_exec_ext in '' $ac_executable_extensions; do
15997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15998 ac_cv_prog_OTOOL_FOR_TARGET="${ncn_progname}"
15999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16000 break 2
16001 fi
16002done
16003 done
16004IFS=$as_save_IFS
16005
16006fi
16007fi
16008OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16009if test -n "$OTOOL_FOR_TARGET"; then
16010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16011$as_echo "$OTOOL_FOR_TARGET" >&6; }
16012else
16013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16014$as_echo "no" >&6; }
16015fi
16016
16017
16018 done
16019fi
16020
16021if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" && test -n "$with_build_time_tools"; then
16022 for ncn_progname in otool; do
16023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16024$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
16025 if test -x $with_build_time_tools/${ncn_progname}; then
16026 ac_cv_prog_OTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
16027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16028$as_echo "yes" >&6; }
16029 break
16030 else
16031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16032$as_echo "no" >&6; }
16033 fi
16034 done
16035fi
16036
16037if test -z "$ac_cv_prog_OTOOL_FOR_TARGET"; then
16038 for ncn_progname in otool; do
16039 if test -n "$ncn_target_tool_prefix"; then
16040 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
16041set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
16042{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16043$as_echo_n "checking for $ac_word... " >&6; }
16044if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
16045 $as_echo_n "(cached) " >&6
16046else
16047 if test -n "$OTOOL_FOR_TARGET"; then
16048 ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
16049else
16050as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16051for as_dir in $PATH
16052do
16053 IFS=$as_save_IFS
16054 test -z "$as_dir" && as_dir=.
16055 for ac_exec_ext in '' $ac_executable_extensions; do
16056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16057 ac_cv_prog_OTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
16058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16059 break 2
16060 fi
16061done
16062 done
16063IFS=$as_save_IFS
16064
16065fi
16066fi
16067OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16068if test -n "$OTOOL_FOR_TARGET"; then
16069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16070$as_echo "$OTOOL_FOR_TARGET" >&6; }
16071else
16072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16073$as_echo "no" >&6; }
16074fi
16075
16076
16077 fi
16078 if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" && test $build = $target ; then
16079 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16080set dummy ${ncn_progname}; ac_word=$2
16081{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16082$as_echo_n "checking for $ac_word... " >&6; }
16083if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
16084 $as_echo_n "(cached) " >&6
16085else
16086 if test -n "$OTOOL_FOR_TARGET"; then
16087 ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
16088else
16089as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16090for as_dir in $PATH
16091do
16092 IFS=$as_save_IFS
16093 test -z "$as_dir" && as_dir=.
16094 for ac_exec_ext in '' $ac_executable_extensions; do
16095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16096 ac_cv_prog_OTOOL_FOR_TARGET="${ncn_progname}"
16097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16098 break 2
16099 fi
16100done
16101 done
16102IFS=$as_save_IFS
16103
16104fi
16105fi
16106OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16107if test -n "$OTOOL_FOR_TARGET"; then
16108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16109$as_echo "$OTOOL_FOR_TARGET" >&6; }
16110else
16111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16112$as_echo "no" >&6; }
16113fi
16114
16115
16116 fi
16117 test -n "$ac_cv_prog_OTOOL_FOR_TARGET" && break
16118 done
16119fi
16120
16121if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" ; then
16122 set dummy otool
16123 if test $build = $target ; then
16124 OTOOL_FOR_TARGET="$2"
16125 else
16126 OTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
16127 fi
16128else
16129 OTOOL_FOR_TARGET="$ac_cv_prog_OTOOL_FOR_TARGET"
16130fi
16131
16132else
16133 OTOOL_FOR_TARGET=$ac_cv_path_OTOOL_FOR_TARGET
16134fi
16135
16136
16137
16138
e8b05380
PB
16139if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
16140 if test -n "$with_build_time_tools"; then
5213506e
RW
16141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ranlib in $with_build_time_tools" >&5
16142$as_echo_n "checking for ranlib in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16143 if test -x $with_build_time_tools/ranlib; then
16144 RANLIB_FOR_TARGET=`cd $with_build_time_tools && pwd`/ranlib
16145 ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
5213506e
RW
16146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_RANLIB_FOR_TARGET" >&5
16147$as_echo "$ac_cv_path_RANLIB_FOR_TARGET" >&6; }
d1f8db0c 16148 else
5213506e
RW
16149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16150$as_echo "no" >&6; }
d1f8db0c 16151 fi
e8b05380
PB
16152 elif test $build != $host && test $have_gcc_for_target = yes; then
16153 RANLIB_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ranlib`
1c00b503
PB
16154 test $RANLIB_FOR_TARGET = ranlib && RANLIB_FOR_TARGET=
16155 test -n "$RANLIB_FOR_TARGET" && ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
e8b05380
PB
16156 fi
16157fi
3e19841a 16158if test -z "$ac_cv_path_RANLIB_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
16159 # Extract the first word of "ranlib", so it can be a program name with args.
16160set dummy ranlib; ac_word=$2
5213506e
RW
16161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16162$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16163if ${ac_cv_path_RANLIB_FOR_TARGET+:} false; then :
5213506e 16164 $as_echo_n "(cached) " >&6
e8b05380 16165else
1c710c3c
DJ
16166 case $RANLIB_FOR_TARGET in
16167 [\\/]* | ?:[\\/]*)
e8b05380
PB
16168 ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
16169 ;;
e8b05380 16170 *)
1c710c3c
DJ
16171 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16172for as_dir in $gcc_cv_tool_dirs
16173do
16174 IFS=$as_save_IFS
16175 test -z "$as_dir" && as_dir=.
5213506e 16176 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16177 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16178 ac_cv_path_RANLIB_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 16179 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16180 break 2
16181 fi
16182done
5213506e
RW
16183 done
16184IFS=$as_save_IFS
1c710c3c 16185
e8b05380
PB
16186 ;;
16187esac
16188fi
1c710c3c 16189RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
e8b05380 16190if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16192$as_echo "$RANLIB_FOR_TARGET" >&6; }
e8b05380 16193else
5213506e
RW
16194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16195$as_echo "no" >&6; }
e8b05380
PB
16196fi
16197
5213506e 16198
e8b05380
PB
16199fi
16200if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
278a7a38
AO
16201
16202
16203if test -n "$RANLIB_FOR_TARGET"; then
16204 ac_cv_prog_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
16205elif test -n "$ac_cv_prog_RANLIB_FOR_TARGET"; then
16206 RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
16207fi
16208
16209if test -n "$ac_cv_prog_RANLIB_FOR_TARGET"; then
16210 for ncn_progname in ranlib; do
16211 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16212set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16213{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16214$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16215if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
5213506e 16216 $as_echo_n "(cached) " >&6
278a7a38
AO
16217else
16218 if test -n "$RANLIB_FOR_TARGET"; then
16219 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
16220else
16221as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16222for as_dir in $PATH
16223do
16224 IFS=$as_save_IFS
16225 test -z "$as_dir" && as_dir=.
5213506e 16226 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16227 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 16228 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
5213506e 16229 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
16230 break 2
16231 fi
16232done
5213506e
RW
16233 done
16234IFS=$as_save_IFS
278a7a38
AO
16235
16236fi
16237fi
16238RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
16239if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16241$as_echo "$RANLIB_FOR_TARGET" >&6; }
278a7a38 16242else
5213506e
RW
16243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16244$as_echo "no" >&6; }
278a7a38
AO
16245fi
16246
5213506e 16247
278a7a38
AO
16248 done
16249fi
16250
16251if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 16252 for ncn_progname in ranlib; do
5213506e
RW
16253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16254$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16255 if test -x $with_build_time_tools/${ncn_progname}; then
16256 ac_cv_prog_RANLIB_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
16257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16258$as_echo "yes" >&6; }
e8b05380
PB
16259 break
16260 else
5213506e
RW
16261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16262$as_echo "no" >&6; }
e8b05380
PB
16263 fi
16264 done
16265fi
16266
16267if test -z "$ac_cv_prog_RANLIB_FOR_TARGET"; then
16268 for ncn_progname in ranlib; do
16269 if test -n "$ncn_target_tool_prefix"; then
16270 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
d739199a 16271set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
16272{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16273$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16274if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
5213506e 16275 $as_echo_n "(cached) " >&6
ca9f4b81 16276else
4de997d1
PB
16277 if test -n "$RANLIB_FOR_TARGET"; then
16278 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 16279else
1c710c3c
DJ
16280as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16281for as_dir in $PATH
16282do
16283 IFS=$as_save_IFS
16284 test -z "$as_dir" && as_dir=.
5213506e 16285 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16286 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16287 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 16288 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16289 break 2
16290 fi
16291done
5213506e
RW
16292 done
16293IFS=$as_save_IFS
1c710c3c 16294
ca9f4b81
AO
16295fi
16296fi
1c710c3c 16297RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
4de997d1 16298if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16300$as_echo "$RANLIB_FOR_TARGET" >&6; }
ca9f4b81 16301else
5213506e
RW
16302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16303$as_echo "no" >&6; }
ca9f4b81
AO
16304fi
16305
5213506e 16306
e8b05380
PB
16307 fi
16308 if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test $build = $target ; then
16309 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 16310set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16311{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16312$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16313if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
5213506e 16314 $as_echo_n "(cached) " >&6
ca9f4b81 16315else
2693c0b0
PB
16316 if test -n "$RANLIB_FOR_TARGET"; then
16317 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 16318else
1c710c3c
DJ
16319as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16320for as_dir in $PATH
16321do
16322 IFS=$as_save_IFS
16323 test -z "$as_dir" && as_dir=.
5213506e 16324 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16325 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16326 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
5213506e 16327 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16328 break 2
16329 fi
16330done
5213506e
RW
16331 done
16332IFS=$as_save_IFS
1c710c3c 16333
ca9f4b81
AO
16334fi
16335fi
1c710c3c 16336RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
2693c0b0 16337if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16339$as_echo "$RANLIB_FOR_TARGET" >&6; }
ca9f4b81 16340else
5213506e
RW
16341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16342$as_echo "no" >&6; }
ca9f4b81 16343fi
1c710c3c 16344
5213506e 16345
e8b05380
PB
16346 fi
16347 test -n "$ac_cv_prog_RANLIB_FOR_TARGET" && break
16348 done
16349fi
1c710c3c 16350
e8b05380
PB
16351if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
16352 set dummy ranlib
16353 if test $build = $target ; then
16354 RANLIB_FOR_TARGET="$2"
16355 else
16356 RANLIB_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 16357 fi
1c00b503
PB
16358else
16359 RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
e8b05380 16360fi
2693c0b0 16361
d1f8db0c
PB
16362else
16363 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
ca9f4b81
AO
16364fi
16365
e8b05380
PB
16366
16367
16368
e7a82751
RM
16369if test -z "$ac_cv_path_READELF_FOR_TARGET" ; then
16370 if test -n "$with_build_time_tools"; then
16371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readelf in $with_build_time_tools" >&5
16372$as_echo_n "checking for readelf in $with_build_time_tools... " >&6; }
16373 if test -x $with_build_time_tools/readelf; then
16374 READELF_FOR_TARGET=`cd $with_build_time_tools && pwd`/readelf
16375 ac_cv_path_READELF_FOR_TARGET=$READELF_FOR_TARGET
16376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_READELF_FOR_TARGET" >&5
16377$as_echo "$ac_cv_path_READELF_FOR_TARGET" >&6; }
16378 else
16379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16380$as_echo "no" >&6; }
16381 fi
16382 elif test $build != $host && test $have_gcc_for_target = yes; then
16383 READELF_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=readelf`
16384 test $READELF_FOR_TARGET = readelf && READELF_FOR_TARGET=
16385 test -n "$READELF_FOR_TARGET" && ac_cv_path_READELF_FOR_TARGET=$READELF_FOR_TARGET
16386 fi
16387fi
16388if test -z "$ac_cv_path_READELF_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
16389 # Extract the first word of "readelf", so it can be a program name with args.
16390set dummy readelf; ac_word=$2
16391{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16392$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16393if ${ac_cv_path_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
16394 $as_echo_n "(cached) " >&6
16395else
16396 case $READELF_FOR_TARGET in
16397 [\\/]* | ?:[\\/]*)
16398 ac_cv_path_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test with a path.
16399 ;;
16400 *)
16401 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16402for as_dir in $gcc_cv_tool_dirs
16403do
16404 IFS=$as_save_IFS
16405 test -z "$as_dir" && as_dir=.
16406 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16407 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
16408 ac_cv_path_READELF_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
16409 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16410 break 2
16411 fi
16412done
16413 done
16414IFS=$as_save_IFS
16415
16416 ;;
16417esac
16418fi
16419READELF_FOR_TARGET=$ac_cv_path_READELF_FOR_TARGET
16420if test -n "$READELF_FOR_TARGET"; then
16421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
16422$as_echo "$READELF_FOR_TARGET" >&6; }
16423else
16424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16425$as_echo "no" >&6; }
16426fi
16427
16428
16429fi
16430if test -z "$ac_cv_path_READELF_FOR_TARGET" ; then
16431
16432
16433if test -n "$READELF_FOR_TARGET"; then
16434 ac_cv_prog_READELF_FOR_TARGET=$READELF_FOR_TARGET
16435elif test -n "$ac_cv_prog_READELF_FOR_TARGET"; then
16436 READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
16437fi
16438
16439if test -n "$ac_cv_prog_READELF_FOR_TARGET"; then
16440 for ncn_progname in readelf; do
16441 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16442set dummy ${ncn_progname}; ac_word=$2
16443{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16444$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16445if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
16446 $as_echo_n "(cached) " >&6
16447else
16448 if test -n "$READELF_FOR_TARGET"; then
16449 ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
16450else
16451as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16452for as_dir in $PATH
16453do
16454 IFS=$as_save_IFS
16455 test -z "$as_dir" && as_dir=.
16456 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16457 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
16458 ac_cv_prog_READELF_FOR_TARGET="${ncn_progname}"
16459 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16460 break 2
16461 fi
16462done
16463 done
16464IFS=$as_save_IFS
16465
16466fi
16467fi
16468READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
16469if test -n "$READELF_FOR_TARGET"; then
16470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
16471$as_echo "$READELF_FOR_TARGET" >&6; }
16472else
16473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16474$as_echo "no" >&6; }
16475fi
16476
16477
16478 done
16479fi
16480
16481if test -z "$ac_cv_prog_READELF_FOR_TARGET" && test -n "$with_build_time_tools"; then
16482 for ncn_progname in readelf; do
16483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16484$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
16485 if test -x $with_build_time_tools/${ncn_progname}; then
16486 ac_cv_prog_READELF_FOR_TARGET=$with_build_time_tools/${ncn_progname}
16487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16488$as_echo "yes" >&6; }
16489 break
16490 else
16491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16492$as_echo "no" >&6; }
16493 fi
16494 done
16495fi
16496
16497if test -z "$ac_cv_prog_READELF_FOR_TARGET"; then
16498 for ncn_progname in readelf; do
16499 if test -n "$ncn_target_tool_prefix"; then
16500 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
16501set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
16502{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16503$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16504if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
16505 $as_echo_n "(cached) " >&6
16506else
16507 if test -n "$READELF_FOR_TARGET"; then
16508 ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
16509else
16510as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16511for as_dir in $PATH
16512do
16513 IFS=$as_save_IFS
16514 test -z "$as_dir" && as_dir=.
16515 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16516 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
16517 ac_cv_prog_READELF_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
16518 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16519 break 2
16520 fi
16521done
16522 done
16523IFS=$as_save_IFS
16524
16525fi
16526fi
16527READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
16528if test -n "$READELF_FOR_TARGET"; then
16529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
16530$as_echo "$READELF_FOR_TARGET" >&6; }
16531else
16532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16533$as_echo "no" >&6; }
16534fi
16535
16536
16537 fi
16538 if test -z "$ac_cv_prog_READELF_FOR_TARGET" && test $build = $target ; then
16539 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16540set dummy ${ncn_progname}; ac_word=$2
16541{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16542$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16543if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
16544 $as_echo_n "(cached) " >&6
16545else
16546 if test -n "$READELF_FOR_TARGET"; then
16547 ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
16548else
16549as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16550for as_dir in $PATH
16551do
16552 IFS=$as_save_IFS
16553 test -z "$as_dir" && as_dir=.
16554 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16555 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
16556 ac_cv_prog_READELF_FOR_TARGET="${ncn_progname}"
16557 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16558 break 2
16559 fi
16560done
16561 done
16562IFS=$as_save_IFS
16563
16564fi
16565fi
16566READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
16567if test -n "$READELF_FOR_TARGET"; then
16568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
16569$as_echo "$READELF_FOR_TARGET" >&6; }
16570else
16571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16572$as_echo "no" >&6; }
16573fi
16574
16575
16576 fi
16577 test -n "$ac_cv_prog_READELF_FOR_TARGET" && break
16578 done
16579fi
16580
16581if test -z "$ac_cv_prog_READELF_FOR_TARGET" ; then
16582 set dummy readelf
16583 if test $build = $target ; then
16584 READELF_FOR_TARGET="$2"
16585 else
16586 READELF_FOR_TARGET="${ncn_target_tool_prefix}$2"
16587 fi
16588else
16589 READELF_FOR_TARGET="$ac_cv_prog_READELF_FOR_TARGET"
16590fi
16591
16592else
16593 READELF_FOR_TARGET=$ac_cv_path_READELF_FOR_TARGET
16594fi
16595
16596
16597
16598
e8b05380
PB
16599if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
16600 if test -n "$with_build_time_tools"; then
5213506e
RW
16601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strip in $with_build_time_tools" >&5
16602$as_echo_n "checking for strip in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16603 if test -x $with_build_time_tools/strip; then
16604 STRIP_FOR_TARGET=`cd $with_build_time_tools && pwd`/strip
16605 ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
5213506e
RW
16606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_STRIP_FOR_TARGET" >&5
16607$as_echo "$ac_cv_path_STRIP_FOR_TARGET" >&6; }
d1f8db0c 16608 else
5213506e
RW
16609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16610$as_echo "no" >&6; }
d1f8db0c 16611 fi
e8b05380
PB
16612 elif test $build != $host && test $have_gcc_for_target = yes; then
16613 STRIP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=strip`
1c00b503
PB
16614 test $STRIP_FOR_TARGET = strip && STRIP_FOR_TARGET=
16615 test -n "$STRIP_FOR_TARGET" && ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
e8b05380
PB
16616 fi
16617fi
3e19841a 16618if test -z "$ac_cv_path_STRIP_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
16619 # Extract the first word of "strip", so it can be a program name with args.
16620set dummy strip; ac_word=$2
5213506e
RW
16621{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16622$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16623if ${ac_cv_path_STRIP_FOR_TARGET+:} false; then :
5213506e 16624 $as_echo_n "(cached) " >&6
e8b05380 16625else
1c710c3c
DJ
16626 case $STRIP_FOR_TARGET in
16627 [\\/]* | ?:[\\/]*)
e8b05380
PB
16628 ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a path.
16629 ;;
e8b05380 16630 *)
1c710c3c
DJ
16631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16632for as_dir in $gcc_cv_tool_dirs
16633do
16634 IFS=$as_save_IFS
16635 test -z "$as_dir" && as_dir=.
5213506e 16636 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16637 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16638 ac_cv_path_STRIP_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 16639 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16640 break 2
16641 fi
16642done
5213506e
RW
16643 done
16644IFS=$as_save_IFS
1c710c3c 16645
e8b05380
PB
16646 ;;
16647esac
16648fi
1c710c3c 16649STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
e8b05380 16650if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
16651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
16652$as_echo "$STRIP_FOR_TARGET" >&6; }
e8b05380 16653else
5213506e
RW
16654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16655$as_echo "no" >&6; }
e8b05380
PB
16656fi
16657
5213506e 16658
e8b05380
PB
16659fi
16660if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
278a7a38
AO
16661
16662
16663if test -n "$STRIP_FOR_TARGET"; then
16664 ac_cv_prog_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
16665elif test -n "$ac_cv_prog_STRIP_FOR_TARGET"; then
16666 STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
16667fi
16668
16669if test -n "$ac_cv_prog_STRIP_FOR_TARGET"; then
16670 for ncn_progname in strip; do
16671 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16672set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16673{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16674$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16675if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
5213506e 16676 $as_echo_n "(cached) " >&6
278a7a38
AO
16677else
16678 if test -n "$STRIP_FOR_TARGET"; then
16679 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
16680else
16681as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16682for as_dir in $PATH
16683do
16684 IFS=$as_save_IFS
16685 test -z "$as_dir" && as_dir=.
5213506e 16686 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16687 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 16688 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
5213506e 16689 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
16690 break 2
16691 fi
16692done
5213506e
RW
16693 done
16694IFS=$as_save_IFS
278a7a38
AO
16695
16696fi
16697fi
16698STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
16699if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
16700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
16701$as_echo "$STRIP_FOR_TARGET" >&6; }
278a7a38 16702else
5213506e
RW
16703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16704$as_echo "no" >&6; }
278a7a38
AO
16705fi
16706
5213506e 16707
278a7a38
AO
16708 done
16709fi
16710
16711if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 16712 for ncn_progname in strip; do
5213506e
RW
16713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16714$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16715 if test -x $with_build_time_tools/${ncn_progname}; then
16716 ac_cv_prog_STRIP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
16717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16718$as_echo "yes" >&6; }
e8b05380
PB
16719 break
16720 else
5213506e
RW
16721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16722$as_echo "no" >&6; }
e8b05380
PB
16723 fi
16724 done
16725fi
16726
16727if test -z "$ac_cv_prog_STRIP_FOR_TARGET"; then
16728 for ncn_progname in strip; do
16729 if test -n "$ncn_target_tool_prefix"; then
16730 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 16731set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
16732{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16733$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16734if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
5213506e 16735 $as_echo_n "(cached) " >&6
af71363e
AS
16736else
16737 if test -n "$STRIP_FOR_TARGET"; then
1c710c3c
DJ
16738 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
16739else
16740as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16741for as_dir in $PATH
16742do
16743 IFS=$as_save_IFS
16744 test -z "$as_dir" && as_dir=.
5213506e 16745 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16746 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16747 ac_cv_prog_STRIP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 16748 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16749 break 2
16750 fi
16751done
5213506e
RW
16752 done
16753IFS=$as_save_IFS
1c710c3c 16754
040b1c5a
GK
16755fi
16756fi
1c710c3c 16757STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
040b1c5a 16758if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
16759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
16760$as_echo "$STRIP_FOR_TARGET" >&6; }
040b1c5a 16761else
5213506e
RW
16762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16763$as_echo "no" >&6; }
040b1c5a
GK
16764fi
16765
5213506e 16766
e8b05380
PB
16767 fi
16768 if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test $build = $target ; then
16769 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 16770set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16771{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16772$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16773if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
5213506e 16774 $as_echo_n "(cached) " >&6
040b1c5a
GK
16775else
16776 if test -n "$STRIP_FOR_TARGET"; then
16777 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
16778else
1c710c3c
DJ
16779as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16780for as_dir in $PATH
16781do
16782 IFS=$as_save_IFS
16783 test -z "$as_dir" && as_dir=.
5213506e 16784 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16785 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16786 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
5213506e 16787 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16788 break 2
16789 fi
16790done
5213506e
RW
16791 done
16792IFS=$as_save_IFS
1c710c3c 16793
040b1c5a
GK
16794fi
16795fi
1c710c3c 16796STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
040b1c5a 16797if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
16798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
16799$as_echo "$STRIP_FOR_TARGET" >&6; }
040b1c5a 16800else
5213506e
RW
16801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16802$as_echo "no" >&6; }
040b1c5a 16803fi
1c710c3c 16804
5213506e 16805
e8b05380
PB
16806 fi
16807 test -n "$ac_cv_prog_STRIP_FOR_TARGET" && break
16808 done
16809fi
1c710c3c 16810
040b1c5a
GK
16811if test -z "$ac_cv_prog_STRIP_FOR_TARGET" ; then
16812 set dummy strip
16813 if test $build = $target ; then
16814 STRIP_FOR_TARGET="$2"
16815 else
16816 STRIP_FOR_TARGET="${ncn_target_tool_prefix}$2"
16817 fi
1c00b503
PB
16818else
16819 STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
040b1c5a
GK
16820fi
16821
d1f8db0c
PB
16822else
16823 STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
e8b05380
PB
16824fi
16825
16826
16827
16828
16829if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
16830 if test -n "$with_build_time_tools"; then
5213506e
RW
16831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windres in $with_build_time_tools" >&5
16832$as_echo_n "checking for windres in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16833 if test -x $with_build_time_tools/windres; then
16834 WINDRES_FOR_TARGET=`cd $with_build_time_tools && pwd`/windres
16835 ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
5213506e
RW
16836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_WINDRES_FOR_TARGET" >&5
16837$as_echo "$ac_cv_path_WINDRES_FOR_TARGET" >&6; }
d1f8db0c 16838 else
5213506e
RW
16839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16840$as_echo "no" >&6; }
d1f8db0c 16841 fi
e8b05380
PB
16842 elif test $build != $host && test $have_gcc_for_target = yes; then
16843 WINDRES_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windres`
1c00b503
PB
16844 test $WINDRES_FOR_TARGET = windres && WINDRES_FOR_TARGET=
16845 test -n "$WINDRES_FOR_TARGET" && ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
e8b05380
PB
16846 fi
16847fi
3e19841a 16848if test -z "$ac_cv_path_WINDRES_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
16849 # Extract the first word of "windres", so it can be a program name with args.
16850set dummy windres; ac_word=$2
5213506e
RW
16851{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16852$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16853if ${ac_cv_path_WINDRES_FOR_TARGET+:} false; then :
5213506e 16854 $as_echo_n "(cached) " >&6
e8b05380 16855else
1c710c3c
DJ
16856 case $WINDRES_FOR_TARGET in
16857 [\\/]* | ?:[\\/]*)
e8b05380
PB
16858 ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a path.
16859 ;;
e8b05380 16860 *)
1c710c3c
DJ
16861 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16862for as_dir in $gcc_cv_tool_dirs
16863do
16864 IFS=$as_save_IFS
16865 test -z "$as_dir" && as_dir=.
5213506e 16866 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16867 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16868 ac_cv_path_WINDRES_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 16869 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16870 break 2
16871 fi
16872done
5213506e
RW
16873 done
16874IFS=$as_save_IFS
1c710c3c 16875
e8b05380
PB
16876 ;;
16877esac
16878fi
1c710c3c 16879WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
e8b05380 16880if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
16881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
16882$as_echo "$WINDRES_FOR_TARGET" >&6; }
e8b05380 16883else
5213506e
RW
16884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16885$as_echo "no" >&6; }
e8b05380
PB
16886fi
16887
5213506e 16888
e8b05380
PB
16889fi
16890if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
278a7a38
AO
16891
16892
16893if test -n "$WINDRES_FOR_TARGET"; then
16894 ac_cv_prog_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
16895elif test -n "$ac_cv_prog_WINDRES_FOR_TARGET"; then
16896 WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
16897fi
16898
16899if test -n "$ac_cv_prog_WINDRES_FOR_TARGET"; then
16900 for ncn_progname in windres; do
16901 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16902set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16903{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16904$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16905if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
5213506e 16906 $as_echo_n "(cached) " >&6
278a7a38
AO
16907else
16908 if test -n "$WINDRES_FOR_TARGET"; then
16909 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
16910else
16911as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16912for as_dir in $PATH
16913do
16914 IFS=$as_save_IFS
16915 test -z "$as_dir" && as_dir=.
5213506e 16916 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 16918 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
5213506e 16919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
16920 break 2
16921 fi
16922done
5213506e
RW
16923 done
16924IFS=$as_save_IFS
278a7a38
AO
16925
16926fi
16927fi
16928WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
16929if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
16930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
16931$as_echo "$WINDRES_FOR_TARGET" >&6; }
278a7a38 16932else
5213506e
RW
16933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16934$as_echo "no" >&6; }
278a7a38
AO
16935fi
16936
5213506e 16937
278a7a38
AO
16938 done
16939fi
16940
16941if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 16942 for ncn_progname in windres; do
5213506e
RW
16943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16944$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16945 if test -x $with_build_time_tools/${ncn_progname}; then
16946 ac_cv_prog_WINDRES_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
16947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16948$as_echo "yes" >&6; }
e8b05380
PB
16949 break
16950 else
5213506e
RW
16951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16952$as_echo "no" >&6; }
e8b05380
PB
16953 fi
16954 done
16955fi
16956
16957if test -z "$ac_cv_prog_WINDRES_FOR_TARGET"; then
16958 for ncn_progname in windres; do
16959 if test -n "$ncn_target_tool_prefix"; then
16960 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 16961set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
16962{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16963$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16964if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
5213506e 16965 $as_echo_n "(cached) " >&6
ca9f4b81 16966else
4de997d1
PB
16967 if test -n "$WINDRES_FOR_TARGET"; then
16968 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 16969else
1c710c3c
DJ
16970as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16971for as_dir in $PATH
16972do
16973 IFS=$as_save_IFS
16974 test -z "$as_dir" && as_dir=.
5213506e 16975 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16976 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16977 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 16978 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16979 break 2
16980 fi
16981done
5213506e
RW
16982 done
16983IFS=$as_save_IFS
1c710c3c 16984
ca9f4b81
AO
16985fi
16986fi
1c710c3c 16987WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
4de997d1 16988if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
16989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
16990$as_echo "$WINDRES_FOR_TARGET" >&6; }
ca9f4b81 16991else
5213506e
RW
16992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16993$as_echo "no" >&6; }
ca9f4b81
AO
16994fi
16995
5213506e 16996
e8b05380
PB
16997 fi
16998 if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test $build = $target ; then
16999 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 17000set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17002$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17003if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
5213506e 17004 $as_echo_n "(cached) " >&6
ca9f4b81 17005else
2693c0b0
PB
17006 if test -n "$WINDRES_FOR_TARGET"; then
17007 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 17008else
1c710c3c
DJ
17009as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17010for as_dir in $PATH
17011do
17012 IFS=$as_save_IFS
17013 test -z "$as_dir" && as_dir=.
5213506e 17014 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17015 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17016 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
5213506e 17017 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17018 break 2
17019 fi
17020done
5213506e
RW
17021 done
17022IFS=$as_save_IFS
1c710c3c 17023
ca9f4b81
AO
17024fi
17025fi
1c710c3c 17026WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
2693c0b0 17027if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
17028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
17029$as_echo "$WINDRES_FOR_TARGET" >&6; }
ca9f4b81 17030else
5213506e
RW
17031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17032$as_echo "no" >&6; }
ca9f4b81 17033fi
1c710c3c 17034
5213506e 17035
e8b05380
PB
17036 fi
17037 test -n "$ac_cv_prog_WINDRES_FOR_TARGET" && break
17038 done
17039fi
1c710c3c 17040
2693c0b0
PB
17041if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
17042 set dummy windres
17043 if test $build = $target ; then
17044 WINDRES_FOR_TARGET="$2"
ca9f4b81 17045 else
2693c0b0 17046 WINDRES_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 17047 fi
1c00b503
PB
17048else
17049 WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
ca9f4b81
AO
17050fi
17051
d1f8db0c
PB
17052else
17053 WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
e8b05380
PB
17054fi
17055
4977bab6 17056
901119ae
KT
17057
17058
17059if test -z "$ac_cv_path_WINDMC_FOR_TARGET" ; then
17060 if test -n "$with_build_time_tools"; then
5213506e
RW
17061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windmc in $with_build_time_tools" >&5
17062$as_echo_n "checking for windmc in $with_build_time_tools... " >&6; }
901119ae
KT
17063 if test -x $with_build_time_tools/windmc; then
17064 WINDMC_FOR_TARGET=`cd $with_build_time_tools && pwd`/windmc
17065 ac_cv_path_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
5213506e
RW
17066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_WINDMC_FOR_TARGET" >&5
17067$as_echo "$ac_cv_path_WINDMC_FOR_TARGET" >&6; }
901119ae 17068 else
5213506e
RW
17069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17070$as_echo "no" >&6; }
901119ae
KT
17071 fi
17072 elif test $build != $host && test $have_gcc_for_target = yes; then
17073 WINDMC_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windmc`
1c00b503
PB
17074 test $WINDMC_FOR_TARGET = windmc && WINDMC_FOR_TARGET=
17075 test -n "$WINDMC_FOR_TARGET" && ac_cv_path_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
901119ae
KT
17076 fi
17077fi
17078if test -z "$ac_cv_path_WINDMC_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
17079 # Extract the first word of "windmc", so it can be a program name with args.
17080set dummy windmc; ac_word=$2
5213506e
RW
17081{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17082$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17083if ${ac_cv_path_WINDMC_FOR_TARGET+:} false; then :
5213506e 17084 $as_echo_n "(cached) " >&6
901119ae
KT
17085else
17086 case $WINDMC_FOR_TARGET in
17087 [\\/]* | ?:[\\/]*)
17088 ac_cv_path_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test with a path.
17089 ;;
17090 *)
17091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17092for as_dir in $gcc_cv_tool_dirs
17093do
17094 IFS=$as_save_IFS
17095 test -z "$as_dir" && as_dir=.
5213506e 17096 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17098 ac_cv_path_WINDMC_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 17099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17100 break 2
17101 fi
17102done
5213506e
RW
17103 done
17104IFS=$as_save_IFS
901119ae
KT
17105
17106 ;;
17107esac
17108fi
17109WINDMC_FOR_TARGET=$ac_cv_path_WINDMC_FOR_TARGET
901119ae 17110if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17112$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17113else
5213506e
RW
17114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17115$as_echo "no" >&6; }
901119ae
KT
17116fi
17117
5213506e 17118
901119ae
KT
17119fi
17120if test -z "$ac_cv_path_WINDMC_FOR_TARGET" ; then
17121
17122
17123if test -n "$WINDMC_FOR_TARGET"; then
17124 ac_cv_prog_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
17125elif test -n "$ac_cv_prog_WINDMC_FOR_TARGET"; then
17126 WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17127fi
17128
17129if test -n "$ac_cv_prog_WINDMC_FOR_TARGET"; then
17130 for ncn_progname in windmc; do
17131 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17132set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17133{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17134$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17135if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
5213506e 17136 $as_echo_n "(cached) " >&6
901119ae
KT
17137else
17138 if test -n "$WINDMC_FOR_TARGET"; then
17139 ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
17140else
17141as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17142for as_dir in $PATH
17143do
17144 IFS=$as_save_IFS
17145 test -z "$as_dir" && as_dir=.
5213506e 17146 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17148 ac_cv_prog_WINDMC_FOR_TARGET="${ncn_progname}"
5213506e 17149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17150 break 2
17151 fi
17152done
5213506e
RW
17153 done
17154IFS=$as_save_IFS
901119ae
KT
17155
17156fi
17157fi
17158WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17159if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17161$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17162else
5213506e
RW
17163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17164$as_echo "no" >&6; }
901119ae
KT
17165fi
17166
5213506e 17167
901119ae
KT
17168 done
17169fi
17170
17171if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" && test -n "$with_build_time_tools"; then
17172 for ncn_progname in windmc; do
5213506e
RW
17173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
17174$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
901119ae
KT
17175 if test -x $with_build_time_tools/${ncn_progname}; then
17176 ac_cv_prog_WINDMC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
17177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17178$as_echo "yes" >&6; }
901119ae
KT
17179 break
17180 else
5213506e
RW
17181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17182$as_echo "no" >&6; }
901119ae
KT
17183 fi
17184 done
17185fi
17186
17187if test -z "$ac_cv_prog_WINDMC_FOR_TARGET"; then
17188 for ncn_progname in windmc; do
17189 if test -n "$ncn_target_tool_prefix"; then
17190 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
17191set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
17192{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17193$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17194if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
5213506e 17195 $as_echo_n "(cached) " >&6
901119ae
KT
17196else
17197 if test -n "$WINDMC_FOR_TARGET"; then
17198 ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
17199else
17200as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17201for as_dir in $PATH
17202do
17203 IFS=$as_save_IFS
17204 test -z "$as_dir" && as_dir=.
5213506e 17205 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17206 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17207 ac_cv_prog_WINDMC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 17208 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17209 break 2
17210 fi
17211done
5213506e
RW
17212 done
17213IFS=$as_save_IFS
901119ae
KT
17214
17215fi
17216fi
17217WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17218if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17220$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17221else
5213506e
RW
17222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17223$as_echo "no" >&6; }
901119ae
KT
17224fi
17225
5213506e 17226
901119ae
KT
17227 fi
17228 if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" && test $build = $target ; then
17229 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17230set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17231{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17232$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17233if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
5213506e 17234 $as_echo_n "(cached) " >&6
901119ae
KT
17235else
17236 if test -n "$WINDMC_FOR_TARGET"; then
17237 ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
17238else
17239as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17240for as_dir in $PATH
17241do
17242 IFS=$as_save_IFS
17243 test -z "$as_dir" && as_dir=.
5213506e 17244 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17245 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17246 ac_cv_prog_WINDMC_FOR_TARGET="${ncn_progname}"
5213506e 17247 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17248 break 2
17249 fi
17250done
5213506e
RW
17251 done
17252IFS=$as_save_IFS
901119ae
KT
17253
17254fi
17255fi
17256WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17257if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17259$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17260else
5213506e
RW
17261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17262$as_echo "no" >&6; }
901119ae
KT
17263fi
17264
5213506e 17265
901119ae
KT
17266 fi
17267 test -n "$ac_cv_prog_WINDMC_FOR_TARGET" && break
17268 done
17269fi
17270
17271if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" ; then
17272 set dummy windmc
17273 if test $build = $target ; then
17274 WINDMC_FOR_TARGET="$2"
17275 else
17276 WINDMC_FOR_TARGET="${ncn_target_tool_prefix}$2"
17277 fi
1c00b503
PB
17278else
17279 WINDMC_FOR_TARGET="$ac_cv_prog_WINDMC_FOR_TARGET"
901119ae
KT
17280fi
17281
17282else
17283 WINDMC_FOR_TARGET=$ac_cv_path_WINDMC_FOR_TARGET
17284fi
17285
17286
2abefe3d
PB
17287RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET"
17288
5213506e
RW
17289{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ar" >&5
17290$as_echo_n "checking where to find the target ar... " >&6; }
2abefe3d 17291if test "x${build}" != "x${host}" ; then
e8b05380
PB
17292 if expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
17293 # We already found the complete path
172e41aa 17294 ac_dir=`dirname $AR_FOR_TARGET`
5213506e
RW
17295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17296$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17297 else
17298 # Canadian cross, just use what we found
5213506e
RW
17299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17300$as_echo "pre-installed" >&6; }
e8b05380 17301 fi
2abefe3d
PB
17302else
17303 ok=yes
17304 case " ${configdirs} " in
17305 *" binutils "*) ;;
17306 *) ok=no ;;
17307 esac
1c710c3c 17308
2abefe3d
PB
17309 if test $ok = yes; then
17310 # An in-tree tool is available and we can use it
17311 AR_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ar'
5213506e
RW
17312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17313$as_echo "just compiled" >&6; }
e8b05380
PB
17314 elif expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
17315 # We already found the complete path
172e41aa 17316 ac_dir=`dirname $AR_FOR_TARGET`
5213506e
RW
17317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17318$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17319 elif test "x$target" = "x$host"; then
17320 # We can use an host tool
17321 AR_FOR_TARGET='$(AR)'
5213506e
RW
17322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17323$as_echo "host tool" >&6; }
2abefe3d
PB
17324 else
17325 # We need a cross tool
5213506e
RW
17326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17327$as_echo "pre-installed" >&6; }
2abefe3d
PB
17328 fi
17329fi
0b0dc272 17330
5213506e
RW
17331{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target as" >&5
17332$as_echo_n "checking where to find the target as... " >&6; }
2abefe3d 17333if test "x${build}" != "x${host}" ; then
e8b05380
PB
17334 if expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
17335 # We already found the complete path
172e41aa 17336 ac_dir=`dirname $AS_FOR_TARGET`
5213506e
RW
17337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17338$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17339 else
17340 # Canadian cross, just use what we found
5213506e
RW
17341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17342$as_echo "pre-installed" >&6; }
e8b05380 17343 fi
2abefe3d
PB
17344else
17345 ok=yes
17346 case " ${configdirs} " in
17347 *" gas "*) ;;
17348 *) ok=no ;;
17349 esac
1c710c3c 17350
2abefe3d
PB
17351 if test $ok = yes; then
17352 # An in-tree tool is available and we can use it
17353 AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gas/as-new'
5213506e
RW
17354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17355$as_echo "just compiled" >&6; }
e8b05380
PB
17356 elif expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
17357 # We already found the complete path
172e41aa 17358 ac_dir=`dirname $AS_FOR_TARGET`
5213506e
RW
17359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17360$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17361 elif test "x$target" = "x$host"; then
17362 # We can use an host tool
17363 AS_FOR_TARGET='$(AS)'
5213506e
RW
17364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17365$as_echo "host tool" >&6; }
2abefe3d
PB
17366 else
17367 # We need a cross tool
5213506e
RW
17368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17369$as_echo "pre-installed" >&6; }
2abefe3d
PB
17370 fi
17371fi
0b0dc272 17372
5213506e
RW
17373{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target cc" >&5
17374$as_echo_n "checking where to find the target cc... " >&6; }
2abefe3d 17375if test "x${build}" != "x${host}" ; then
e8b05380
PB
17376 if expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
17377 # We already found the complete path
172e41aa 17378 ac_dir=`dirname $CC_FOR_TARGET`
5213506e
RW
17379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17380$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17381 else
17382 # Canadian cross, just use what we found
5213506e
RW
17383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17384$as_echo "pre-installed" >&6; }
e8b05380 17385 fi
2abefe3d
PB
17386else
17387 ok=yes
17388 case " ${configdirs} " in
17389 *" gcc "*) ;;
17390 *) ok=no ;;
17391 esac
1c710c3c 17392
2abefe3d
PB
17393 if test $ok = yes; then
17394 # An in-tree tool is available and we can use it
17395 CC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
5213506e
RW
17396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17397$as_echo "just compiled" >&6; }
e8b05380
PB
17398 elif expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
17399 # We already found the complete path
172e41aa 17400 ac_dir=`dirname $CC_FOR_TARGET`
5213506e
RW
17401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17402$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17403 elif test "x$target" = "x$host"; then
17404 # We can use an host tool
17405 CC_FOR_TARGET='$(CC)'
5213506e
RW
17406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17407$as_echo "host tool" >&6; }
2abefe3d
PB
17408 else
17409 # We need a cross tool
5213506e
RW
17410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17411$as_echo "pre-installed" >&6; }
2abefe3d
PB
17412 fi
17413fi
0b0dc272 17414
5213506e
RW
17415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target c++" >&5
17416$as_echo_n "checking where to find the target c++... " >&6; }
2abefe3d 17417if test "x${build}" != "x${host}" ; then
e8b05380
PB
17418 if expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
17419 # We already found the complete path
172e41aa 17420 ac_dir=`dirname $CXX_FOR_TARGET`
5213506e
RW
17421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17422$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17423 else
17424 # Canadian cross, just use what we found
5213506e
RW
17425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17426$as_echo "pre-installed" >&6; }
e8b05380 17427 fi
2abefe3d
PB
17428else
17429 ok=yes
17430 case " ${configdirs} " in
17431 *" gcc "*) ;;
17432 *) ok=no ;;
17433 esac
17434 case ,${enable_languages}, in
17435 *,c++,*) ;;
17436 *) ok=no ;;
17437 esac
17438 if test $ok = yes; then
17439 # An in-tree tool is available and we can use it
2077db1b 17440 CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
5213506e
RW
17441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17442$as_echo "just compiled" >&6; }
e8b05380
PB
17443 elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
17444 # We already found the complete path
172e41aa 17445 ac_dir=`dirname $CXX_FOR_TARGET`
5213506e
RW
17446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17447$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17448 elif test "x$target" = "x$host"; then
17449 # We can use an host tool
17450 CXX_FOR_TARGET='$(CXX)'
5213506e
RW
17451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17452$as_echo "host tool" >&6; }
2abefe3d
PB
17453 else
17454 # We need a cross tool
5213506e
RW
17455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17456$as_echo "pre-installed" >&6; }
2abefe3d
PB
17457 fi
17458fi
0b0dc272 17459
5213506e
RW
17460{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target c++ for libstdc++" >&5
17461$as_echo_n "checking where to find the target c++ for libstdc++... " >&6; }
2abefe3d 17462if test "x${build}" != "x${host}" ; then
e8b05380
PB
17463 if expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
17464 # We already found the complete path
172e41aa 17465 ac_dir=`dirname $RAW_CXX_FOR_TARGET`
5213506e
RW
17466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17467$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17468 else
17469 # Canadian cross, just use what we found
5213506e
RW
17470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17471$as_echo "pre-installed" >&6; }
e8b05380 17472 fi
2abefe3d
PB
17473else
17474 ok=yes
17475 case " ${configdirs} " in
17476 *" gcc "*) ;;
17477 *) ok=no ;;
17478 esac
17479 case ,${enable_languages}, in
17480 *,c++,*) ;;
17481 *) ok=no ;;
17482 esac
17483 if test $ok = yes; then
17484 # An in-tree tool is available and we can use it
2077db1b 17485 RAW_CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -shared-libgcc -B$$r/$(HOST_SUBDIR)/gcc -nostdinc++ -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
5213506e
RW
17486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17487$as_echo "just compiled" >&6; }
e8b05380
PB
17488 elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
17489 # We already found the complete path
172e41aa 17490 ac_dir=`dirname $RAW_CXX_FOR_TARGET`
5213506e
RW
17491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17492$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17493 elif test "x$target" = "x$host"; then
17494 # We can use an host tool
17495 RAW_CXX_FOR_TARGET='$(CXX)'
5213506e
RW
17496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17497$as_echo "host tool" >&6; }
2abefe3d
PB
17498 else
17499 # We need a cross tool
5213506e
RW
17500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17501$as_echo "pre-installed" >&6; }
2abefe3d
PB
17502 fi
17503fi
0b0dc272 17504
5213506e
RW
17505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dlltool" >&5
17506$as_echo_n "checking where to find the target dlltool... " >&6; }
2abefe3d 17507if test "x${build}" != "x${host}" ; then
e8b05380
PB
17508 if expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
17509 # We already found the complete path
172e41aa 17510 ac_dir=`dirname $DLLTOOL_FOR_TARGET`
5213506e
RW
17511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17512$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17513 else
17514 # Canadian cross, just use what we found
5213506e
RW
17515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17516$as_echo "pre-installed" >&6; }
e8b05380 17517 fi
2abefe3d
PB
17518else
17519 ok=yes
17520 case " ${configdirs} " in
17521 *" binutils "*) ;;
17522 *) ok=no ;;
17523 esac
1c710c3c 17524
2abefe3d
PB
17525 if test $ok = yes; then
17526 # An in-tree tool is available and we can use it
17527 DLLTOOL_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/dlltool'
5213506e
RW
17528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17529$as_echo "just compiled" >&6; }
e8b05380
PB
17530 elif expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
17531 # We already found the complete path
172e41aa 17532 ac_dir=`dirname $DLLTOOL_FOR_TARGET`
5213506e
RW
17533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17534$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17535 elif test "x$target" = "x$host"; then
17536 # We can use an host tool
17537 DLLTOOL_FOR_TARGET='$(DLLTOOL)'
5213506e
RW
17538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17539$as_echo "host tool" >&6; }
2abefe3d
PB
17540 else
17541 # We need a cross tool
5213506e
RW
17542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17543$as_echo "pre-installed" >&6; }
2abefe3d
PB
17544 fi
17545fi
0b0dc272 17546
3b5e8ee4
IS
17547{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dsymutil" >&5
17548$as_echo_n "checking where to find the target dsymutil... " >&6; }
17549if test "x${build}" != "x${host}" ; then
17550 if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
17551 # We already found the complete path
17552 ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
17553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17554$as_echo "pre-installed in $ac_dir" >&6; }
17555 else
17556 # Canadian cross, just use what we found
17557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17558$as_echo "pre-installed" >&6; }
17559 fi
17560else
17561 if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
17562 # We already found the complete path
17563 ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
17564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17565$as_echo "pre-installed in $ac_dir" >&6; }
17566 elif test "x$target" = "x$host"; then
17567 # We can use an host tool
17568 DSYMUTIL_FOR_TARGET='$(DSYMUTIL)'
17569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17570$as_echo "host tool" >&6; }
17571 else
17572 # We need a cross tool
17573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17574$as_echo "pre-installed" >&6; }
17575 fi
17576fi
17577
5213506e
RW
17578{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gcc" >&5
17579$as_echo_n "checking where to find the target gcc... " >&6; }
2abefe3d 17580if test "x${build}" != "x${host}" ; then
e8b05380
PB
17581 if expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
17582 # We already found the complete path
172e41aa 17583 ac_dir=`dirname $GCC_FOR_TARGET`
5213506e
RW
17584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17585$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17586 else
17587 # Canadian cross, just use what we found
5213506e
RW
17588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17589$as_echo "pre-installed" >&6; }
e8b05380 17590 fi
2abefe3d
PB
17591else
17592 ok=yes
17593 case " ${configdirs} " in
17594 *" gcc "*) ;;
17595 *) ok=no ;;
17596 esac
1c710c3c 17597
2abefe3d
PB
17598 if test $ok = yes; then
17599 # An in-tree tool is available and we can use it
17600 GCC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
5213506e
RW
17601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17602$as_echo "just compiled" >&6; }
e8b05380
PB
17603 elif expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
17604 # We already found the complete path
172e41aa 17605 ac_dir=`dirname $GCC_FOR_TARGET`
5213506e
RW
17606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17607$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17608 elif test "x$target" = "x$host"; then
17609 # We can use an host tool
17610 GCC_FOR_TARGET='$()'
5213506e
RW
17611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17612$as_echo "host tool" >&6; }
2abefe3d
PB
17613 else
17614 # We need a cross tool
5213506e
RW
17615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17616$as_echo "pre-installed" >&6; }
2abefe3d
PB
17617 fi
17618fi
0b0dc272 17619
5213506e
RW
17620{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gfortran" >&5
17621$as_echo_n "checking where to find the target gfortran... " >&6; }
2abefe3d 17622if test "x${build}" != "x${host}" ; then
e8b05380
PB
17623 if expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
17624 # We already found the complete path
172e41aa 17625 ac_dir=`dirname $GFORTRAN_FOR_TARGET`
5213506e
RW
17626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17627$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17628 else
17629 # Canadian cross, just use what we found
5213506e
RW
17630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17631$as_echo "pre-installed" >&6; }
e8b05380 17632 fi
2abefe3d
PB
17633else
17634 ok=yes
17635 case " ${configdirs} " in
17636 *" gcc "*) ;;
17637 *) ok=no ;;
17638 esac
17639 case ,${enable_languages}, in
17640 *,fortran,*) ;;
17641 *) ok=no ;;
17642 esac
17643 if test $ok = yes; then
17644 # An in-tree tool is available and we can use it
17645 GFORTRAN_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/'
5213506e
RW
17646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17647$as_echo "just compiled" >&6; }
e8b05380
PB
17648 elif expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
17649 # We already found the complete path
172e41aa 17650 ac_dir=`dirname $GFORTRAN_FOR_TARGET`
5213506e
RW
17651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17652$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17653 elif test "x$target" = "x$host"; then
17654 # We can use an host tool
17655 GFORTRAN_FOR_TARGET='$(GFORTRAN)'
5213506e
RW
17656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17657$as_echo "host tool" >&6; }
2abefe3d
PB
17658 else
17659 # We need a cross tool
5213506e
RW
17660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17661$as_echo "pre-installed" >&6; }
2abefe3d
PB
17662 fi
17663fi
0b0dc272 17664
632e2a07
ILT
17665{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gccgo" >&5
17666$as_echo_n "checking where to find the target gccgo... " >&6; }
17667if test "x${build}" != "x${host}" ; then
17668 if expr "x$GOC_FOR_TARGET" : "x/" > /dev/null; then
17669 # We already found the complete path
17670 ac_dir=`dirname $GOC_FOR_TARGET`
17671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17672$as_echo "pre-installed in $ac_dir" >&6; }
17673 else
17674 # Canadian cross, just use what we found
17675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17676$as_echo "pre-installed" >&6; }
17677 fi
17678else
17679 ok=yes
17680 case " ${configdirs} " in
17681 *" gcc "*) ;;
17682 *) ok=no ;;
17683 esac
17684 case ,${enable_languages}, in
17685 *,go,*) ;;
17686 *) ok=no ;;
17687 esac
17688 if test $ok = yes; then
17689 # An in-tree tool is available and we can use it
17690 GOC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gccgo -B$$r/$(HOST_SUBDIR)/gcc/'
17691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17692$as_echo "just compiled" >&6; }
17693 elif expr "x$GOC_FOR_TARGET" : "x/" > /dev/null; then
17694 # We already found the complete path
17695 ac_dir=`dirname $GOC_FOR_TARGET`
17696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17697$as_echo "pre-installed in $ac_dir" >&6; }
17698 elif test "x$target" = "x$host"; then
17699 # We can use an host tool
17700 GOC_FOR_TARGET='$(GOC)'
17701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17702$as_echo "host tool" >&6; }
17703 else
17704 # We need a cross tool
17705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17706$as_echo "pre-installed" >&6; }
17707 fi
17708fi
17709
b4c522fa
IB
17710{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gdc" >&5
17711$as_echo_n "checking where to find the target gdc... " >&6; }
17712if test "x${build}" != "x${host}" ; then
17713 if expr "x$GDC_FOR_TARGET" : "x/" > /dev/null; then
17714 # We already found the complete path
17715 ac_dir=`dirname $GDC_FOR_TARGET`
17716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17717$as_echo "pre-installed in $ac_dir" >&6; }
17718 else
17719 # Canadian cross, just use what we found
17720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17721$as_echo "pre-installed" >&6; }
17722 fi
17723else
17724 ok=yes
17725 case " ${configdirs} " in
17726 *" gcc "*) ;;
17727 *) ok=no ;;
17728 esac
17729 case ,${enable_languages}, in
17730 *,d,*) ;;
17731 *) ok=no ;;
17732 esac
17733 if test $ok = yes; then
17734 # An in-tree tool is available and we can use it
17735 GDC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gdc -B$$r/$(HOST_SUBDIR)/gcc/'
17736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17737$as_echo "just compiled" >&6; }
17738 elif expr "x$GDC_FOR_TARGET" : "x/" > /dev/null; then
17739 # We already found the complete path
17740 ac_dir=`dirname $GDC_FOR_TARGET`
17741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17742$as_echo "pre-installed in $ac_dir" >&6; }
17743 elif test "x$target" = "x$host"; then
17744 # We can use an host tool
17745 GDC_FOR_TARGET='$(GDC)'
17746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17747$as_echo "host tool" >&6; }
17748 else
17749 # We need a cross tool
17750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17751$as_echo "pre-installed" >&6; }
17752 fi
17753fi
17754
5213506e
RW
17755{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ld" >&5
17756$as_echo_n "checking where to find the target ld... " >&6; }
2abefe3d 17757if test "x${build}" != "x${host}" ; then
e8b05380
PB
17758 if expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
17759 # We already found the complete path
172e41aa 17760 ac_dir=`dirname $LD_FOR_TARGET`
5213506e
RW
17761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17762$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17763 else
17764 # Canadian cross, just use what we found
5213506e
RW
17765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17766$as_echo "pre-installed" >&6; }
e8b05380 17767 fi
2abefe3d
PB
17768else
17769 ok=yes
17770 case " ${configdirs} " in
17771 *" ld "*) ;;
17772 *) ok=no ;;
17773 esac
1c710c3c 17774
2abefe3d
PB
17775 if test $ok = yes; then
17776 # An in-tree tool is available and we can use it
17777 LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/ld/ld-new'
5213506e
RW
17778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17779$as_echo "just compiled" >&6; }
e8b05380
PB
17780 elif expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
17781 # We already found the complete path
172e41aa 17782 ac_dir=`dirname $LD_FOR_TARGET`
5213506e
RW
17783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17784$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17785 elif test "x$target" = "x$host"; then
17786 # We can use an host tool
17787 LD_FOR_TARGET='$(LD)'
5213506e
RW
17788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17789$as_echo "host tool" >&6; }
2abefe3d
PB
17790 else
17791 # We need a cross tool
5213506e
RW
17792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17793$as_echo "pre-installed" >&6; }
2abefe3d
PB
17794 fi
17795fi
0b0dc272 17796
5213506e
RW
17797{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target lipo" >&5
17798$as_echo_n "checking where to find the target lipo... " >&6; }
2abefe3d 17799if test "x${build}" != "x${host}" ; then
e8b05380
PB
17800 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
17801 # We already found the complete path
172e41aa 17802 ac_dir=`dirname $LIPO_FOR_TARGET`
5213506e
RW
17803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17804$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17805 else
17806 # Canadian cross, just use what we found
5213506e
RW
17807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17808$as_echo "pre-installed" >&6; }
e8b05380 17809 fi
2abefe3d 17810else
e8b05380
PB
17811 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
17812 # We already found the complete path
172e41aa 17813 ac_dir=`dirname $LIPO_FOR_TARGET`
5213506e
RW
17814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17815$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380 17816 elif test "x$target" = "x$host"; then
2abefe3d
PB
17817 # We can use an host tool
17818 LIPO_FOR_TARGET='$(LIPO)'
5213506e
RW
17819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17820$as_echo "host tool" >&6; }
2abefe3d
PB
17821 else
17822 # We need a cross tool
5213506e
RW
17823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17824$as_echo "pre-installed" >&6; }
2abefe3d
PB
17825 fi
17826fi
0b0dc272 17827
5213506e
RW
17828{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target nm" >&5
17829$as_echo_n "checking where to find the target nm... " >&6; }
2abefe3d 17830if test "x${build}" != "x${host}" ; then
e8b05380
PB
17831 if expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
17832 # We already found the complete path
172e41aa 17833 ac_dir=`dirname $NM_FOR_TARGET`
5213506e
RW
17834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17835$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17836 else
17837 # Canadian cross, just use what we found
5213506e
RW
17838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17839$as_echo "pre-installed" >&6; }
e8b05380 17840 fi
2abefe3d
PB
17841else
17842 ok=yes
17843 case " ${configdirs} " in
17844 *" binutils "*) ;;
17845 *) ok=no ;;
17846 esac
1c710c3c 17847
2abefe3d
PB
17848 if test $ok = yes; then
17849 # An in-tree tool is available and we can use it
17850 NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/nm-new'
5213506e
RW
17851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17852$as_echo "just compiled" >&6; }
e8b05380
PB
17853 elif expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
17854 # We already found the complete path
172e41aa 17855 ac_dir=`dirname $NM_FOR_TARGET`
5213506e
RW
17856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17857$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17858 elif test "x$target" = "x$host"; then
17859 # We can use an host tool
17860 NM_FOR_TARGET='$(NM)'
5213506e
RW
17861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17862$as_echo "host tool" >&6; }
2abefe3d
PB
17863 else
17864 # We need a cross tool
5213506e
RW
17865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17866$as_echo "pre-installed" >&6; }
2abefe3d
PB
17867 fi
17868fi
0b0dc272 17869
9bccfdf5
AP
17870{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target objcopy" >&5
17871$as_echo_n "checking where to find the target objcopy... " >&6; }
17872if test "x${build}" != "x${host}" ; then
17873 if expr "x$OBJCOPY_FOR_TARGET" : "x/" > /dev/null; then
17874 # We already found the complete path
17875 ac_dir=`dirname $OBJCOPY_FOR_TARGET`
17876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17877$as_echo "pre-installed in $ac_dir" >&6; }
17878 else
17879 # Canadian cross, just use what we found
17880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17881$as_echo "pre-installed" >&6; }
17882 fi
17883else
17884 ok=yes
17885 case " ${configdirs} " in
17886 *" binutils "*) ;;
17887 *) ok=no ;;
17888 esac
17889
17890 if test $ok = yes; then
17891 # An in-tree tool is available and we can use it
17892 OBJCOPY_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objcopy'
17893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17894$as_echo "just compiled" >&6; }
17895 elif expr "x$OBJCOPY_FOR_TARGET" : "x/" > /dev/null; then
17896 # We already found the complete path
17897 ac_dir=`dirname $OBJCOPY_FOR_TARGET`
17898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17899$as_echo "pre-installed in $ac_dir" >&6; }
17900 elif test "x$target" = "x$host"; then
17901 # We can use an host tool
ec8fd1c0 17902 OBJCOPY_FOR_TARGET='$(OBJCOPY)'
9bccfdf5
AP
17903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17904$as_echo "host tool" >&6; }
17905 else
17906 # We need a cross tool
17907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17908$as_echo "pre-installed" >&6; }
17909 fi
17910fi
17911
5213506e
RW
17912{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target objdump" >&5
17913$as_echo_n "checking where to find the target objdump... " >&6; }
2abefe3d 17914if test "x${build}" != "x${host}" ; then
e8b05380
PB
17915 if expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
17916 # We already found the complete path
172e41aa 17917 ac_dir=`dirname $OBJDUMP_FOR_TARGET`
5213506e
RW
17918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17919$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17920 else
17921 # Canadian cross, just use what we found
5213506e
RW
17922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17923$as_echo "pre-installed" >&6; }
e8b05380 17924 fi
2abefe3d
PB
17925else
17926 ok=yes
17927 case " ${configdirs} " in
17928 *" binutils "*) ;;
17929 *) ok=no ;;
17930 esac
1c710c3c 17931
2abefe3d
PB
17932 if test $ok = yes; then
17933 # An in-tree tool is available and we can use it
17934 OBJDUMP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objdump'
5213506e
RW
17935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17936$as_echo "just compiled" >&6; }
e8b05380
PB
17937 elif expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
17938 # We already found the complete path
172e41aa 17939 ac_dir=`dirname $OBJDUMP_FOR_TARGET`
5213506e
RW
17940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17941$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17942 elif test "x$target" = "x$host"; then
17943 # We can use an host tool
17944 OBJDUMP_FOR_TARGET='$(OBJDUMP)'
5213506e
RW
17945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17946$as_echo "host tool" >&6; }
2abefe3d
PB
17947 else
17948 # We need a cross tool
5213506e
RW
17949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17950$as_echo "pre-installed" >&6; }
2abefe3d
PB
17951 fi
17952fi
0b0dc272 17953
e4a9a572
IS
17954{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target otool" >&5
17955$as_echo_n "checking where to find the target otool... " >&6; }
17956if test "x${build}" != "x${host}" ; then
17957 if expr "x$OTOOL_FOR_TARGET" : "x/" > /dev/null; then
17958 # We already found the complete path
17959 ac_dir=`dirname $OTOOL_FOR_TARGET`
17960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17961$as_echo "pre-installed in $ac_dir" >&6; }
17962 else
17963 # Canadian cross, just use what we found
17964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17965$as_echo "pre-installed" >&6; }
17966 fi
17967else
17968 if expr "x$OTOOL_FOR_TARGET" : "x/" > /dev/null; then
17969 # We already found the complete path
17970 ac_dir=`dirname $OTOOL_FOR_TARGET`
17971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17972$as_echo "pre-installed in $ac_dir" >&6; }
17973 elif test "x$target" = "x$host"; then
17974 # We can use an host tool
17975 OTOOL_FOR_TARGET='$(OTOOL)'
17976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17977$as_echo "host tool" >&6; }
17978 else
17979 # We need a cross tool
17980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17981$as_echo "pre-installed" >&6; }
17982 fi
17983fi
17984
5213506e
RW
17985{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ranlib" >&5
17986$as_echo_n "checking where to find the target ranlib... " >&6; }
2abefe3d 17987if test "x${build}" != "x${host}" ; then
e8b05380
PB
17988 if expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
17989 # We already found the complete path
172e41aa 17990 ac_dir=`dirname $RANLIB_FOR_TARGET`
5213506e
RW
17991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17992$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17993 else
17994 # Canadian cross, just use what we found
5213506e
RW
17995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17996$as_echo "pre-installed" >&6; }
e8b05380 17997 fi
2abefe3d
PB
17998else
17999 ok=yes
18000 case " ${configdirs} " in
18001 *" binutils "*) ;;
18002 *) ok=no ;;
18003 esac
1c710c3c 18004
2abefe3d
PB
18005 if test $ok = yes; then
18006 # An in-tree tool is available and we can use it
18007 RANLIB_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ranlib'
5213506e
RW
18008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18009$as_echo "just compiled" >&6; }
e8b05380
PB
18010 elif expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
18011 # We already found the complete path
172e41aa 18012 ac_dir=`dirname $RANLIB_FOR_TARGET`
5213506e
RW
18013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18014$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18015 elif test "x$target" = "x$host"; then
18016 # We can use an host tool
18017 RANLIB_FOR_TARGET='$(RANLIB)'
5213506e
RW
18018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18019$as_echo "host tool" >&6; }
2abefe3d
PB
18020 else
18021 # We need a cross tool
5213506e
RW
18022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18023$as_echo "pre-installed" >&6; }
2abefe3d
PB
18024 fi
18025fi
0b0dc272 18026
e7a82751
RM
18027{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target readelf" >&5
18028$as_echo_n "checking where to find the target readelf... " >&6; }
18029if test "x${build}" != "x${host}" ; then
18030 if expr "x$READELF_FOR_TARGET" : "x/" > /dev/null; then
18031 # We already found the complete path
18032 ac_dir=`dirname $READELF_FOR_TARGET`
18033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18034$as_echo "pre-installed in $ac_dir" >&6; }
18035 else
18036 # Canadian cross, just use what we found
18037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18038$as_echo "pre-installed" >&6; }
18039 fi
18040else
18041 ok=yes
18042 case " ${configdirs} " in
18043 *" binutils "*) ;;
18044 *) ok=no ;;
18045 esac
18046
18047 if test $ok = yes; then
18048 # An in-tree tool is available and we can use it
18049 READELF_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/readelf'
18050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18051$as_echo "just compiled" >&6; }
18052 elif expr "x$READELF_FOR_TARGET" : "x/" > /dev/null; then
18053 # We already found the complete path
18054 ac_dir=`dirname $READELF_FOR_TARGET`
18055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18056$as_echo "pre-installed in $ac_dir" >&6; }
18057 elif test "x$target" = "x$host"; then
18058 # We can use an host tool
18059 READELF_FOR_TARGET='$(READELF)'
18060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18061$as_echo "host tool" >&6; }
18062 else
18063 # We need a cross tool
18064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18065$as_echo "pre-installed" >&6; }
18066 fi
18067fi
18068
5213506e
RW
18069{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target strip" >&5
18070$as_echo_n "checking where to find the target strip... " >&6; }
2abefe3d 18071if test "x${build}" != "x${host}" ; then
e8b05380
PB
18072 if expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
18073 # We already found the complete path
172e41aa 18074 ac_dir=`dirname $STRIP_FOR_TARGET`
5213506e
RW
18075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18076$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18077 else
18078 # Canadian cross, just use what we found
5213506e
RW
18079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18080$as_echo "pre-installed" >&6; }
e8b05380 18081 fi
2abefe3d
PB
18082else
18083 ok=yes
18084 case " ${configdirs} " in
18085 *" binutils "*) ;;
18086 *) ok=no ;;
18087 esac
1c710c3c 18088
2abefe3d
PB
18089 if test $ok = yes; then
18090 # An in-tree tool is available and we can use it
455c8f48 18091 STRIP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/strip-new'
5213506e
RW
18092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18093$as_echo "just compiled" >&6; }
e8b05380
PB
18094 elif expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
18095 # We already found the complete path
172e41aa 18096 ac_dir=`dirname $STRIP_FOR_TARGET`
5213506e
RW
18097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18098$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18099 elif test "x$target" = "x$host"; then
18100 # We can use an host tool
18101 STRIP_FOR_TARGET='$(STRIP)'
5213506e
RW
18102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18103$as_echo "host tool" >&6; }
2abefe3d
PB
18104 else
18105 # We need a cross tool
5213506e
RW
18106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18107$as_echo "pre-installed" >&6; }
2abefe3d
PB
18108 fi
18109fi
0b0dc272 18110
5213506e
RW
18111{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target windres" >&5
18112$as_echo_n "checking where to find the target windres... " >&6; }
2abefe3d 18113if test "x${build}" != "x${host}" ; then
e8b05380
PB
18114 if expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
18115 # We already found the complete path
172e41aa 18116 ac_dir=`dirname $WINDRES_FOR_TARGET`
5213506e
RW
18117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18118$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18119 else
18120 # Canadian cross, just use what we found
5213506e
RW
18121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18122$as_echo "pre-installed" >&6; }
e8b05380 18123 fi
2abefe3d
PB
18124else
18125 ok=yes
18126 case " ${configdirs} " in
18127 *" binutils "*) ;;
18128 *) ok=no ;;
18129 esac
1c710c3c 18130
2abefe3d
PB
18131 if test $ok = yes; then
18132 # An in-tree tool is available and we can use it
18133 WINDRES_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windres'
5213506e
RW
18134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18135$as_echo "just compiled" >&6; }
e8b05380
PB
18136 elif expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
18137 # We already found the complete path
172e41aa 18138 ac_dir=`dirname $WINDRES_FOR_TARGET`
5213506e
RW
18139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18140$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18141 elif test "x$target" = "x$host"; then
18142 # We can use an host tool
18143 WINDRES_FOR_TARGET='$(WINDRES)'
5213506e
RW
18144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18145$as_echo "host tool" >&6; }
2abefe3d
PB
18146 else
18147 # We need a cross tool
5213506e
RW
18148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18149$as_echo "pre-installed" >&6; }
2abefe3d 18150 fi
671aa708 18151fi
be912515 18152
5213506e
RW
18153{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target windmc" >&5
18154$as_echo_n "checking where to find the target windmc... " >&6; }
901119ae
KT
18155if test "x${build}" != "x${host}" ; then
18156 if expr "x$WINDMC_FOR_TARGET" : "x/" > /dev/null; then
18157 # We already found the complete path
18158 ac_dir=`dirname $WINDMC_FOR_TARGET`
5213506e
RW
18159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18160$as_echo "pre-installed in $ac_dir" >&6; }
901119ae
KT
18161 else
18162 # Canadian cross, just use what we found
5213506e
RW
18163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18164$as_echo "pre-installed" >&6; }
901119ae
KT
18165 fi
18166else
18167 ok=yes
18168 case " ${configdirs} " in
18169 *" binutils "*) ;;
18170 *) ok=no ;;
18171 esac
18172
18173 if test $ok = yes; then
18174 # An in-tree tool is available and we can use it
18175 WINDMC_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windmc'
5213506e
RW
18176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18177$as_echo "just compiled" >&6; }
901119ae
KT
18178 elif expr "x$WINDMC_FOR_TARGET" : "x/" > /dev/null; then
18179 # We already found the complete path
18180 ac_dir=`dirname $WINDMC_FOR_TARGET`
5213506e
RW
18181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18182$as_echo "pre-installed in $ac_dir" >&6; }
901119ae
KT
18183 elif test "x$target" = "x$host"; then
18184 # We can use an host tool
18185 WINDMC_FOR_TARGET='$(WINDMC)'
5213506e
RW
18186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18187$as_echo "host tool" >&6; }
901119ae
KT
18188 else
18189 # We need a cross tool
5213506e
RW
18190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18191$as_echo "pre-installed" >&6; }
901119ae
KT
18192 fi
18193fi
18194
be912515
NN
18195
18196
2abefe3d 18197
0b0dc272 18198
671aa708
NN
18199# Certain tools may need extra flags.
18200AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
18201RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
18202NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
18203
2abefe3d
PB
18204# When building target libraries, except in a Canadian cross, we use
18205# the same toolchain as the compiler we just built.
18206COMPILER_AS_FOR_TARGET='$(AS_FOR_TARGET)'
18207COMPILER_LD_FOR_TARGET='$(LD_FOR_TARGET)'
18208COMPILER_NM_FOR_TARGET='$(NM_FOR_TARGET)'
18209if test $host = $build; then
18210 case " $configdirs " in
18211 *" gcc "*)
18212 COMPILER_AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/as'
18213 COMPILER_LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/collect-ld'
18214 COMPILER_NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/nm'${extra_nmflags_for_target}
18215 ;;
18216 esac
18217fi
18218
18219
18220
18221
18222
5213506e
RW
18223{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
18224$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
18225# Check whether --enable-maintainer-mode was given.
18226if test "${enable_maintainer_mode+set}" = set; then :
18227 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
ee03dc5e
AO
18228else
18229 USE_MAINTAINER_MODE=no
5213506e
RW
18230fi
18231
18232{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
18233$as_echo "$USE_MAINTAINER_MODE" >&6; }
ee03dc5e
AO
18234
18235
18236if test "$USE_MAINTAINER_MODE" = yes; then
18237 MAINTAINER_MODE_TRUE=
18238 MAINTAINER_MODE_FALSE='#'
18239else
18240 MAINTAINER_MODE_TRUE='#'
18241 MAINTAINER_MODE_FALSE=
1c710c3c 18242fi
ee03dc5e
AO
18243MAINT=$MAINTAINER_MODE_TRUE
18244
2805b53a
NN
18245# ---------------------
18246# GCC bootstrap support
18247# ---------------------
18248
18249# Stage specific cflags for build.
18250stage1_cflags="-g"
18251case $build in
18252 vax-*-*)
18253 case ${GCC} in
18254 yes) stage1_cflags="-g -Wa,-J" ;;
18255 *) stage1_cflags="-g -J" ;;
18256 esac ;;
2805b53a
NN
18257esac
18258
0b50988a 18259
2805b53a 18260
8efea775 18261# Enable --enable-checking in stage1 of the compiler.
5213506e
RW
18262# Check whether --enable-stage1-checking was given.
18263if test "${enable_stage1_checking+set}" = set; then :
18264 enableval=$enable_stage1_checking; stage1_checking=--enable-checking=${enable_stage1_checking}
8efea775 18265else
e643dc23 18266 if test "x$enable_checking" = xno || test "x$enable_checking" = x; then
c10b5ea0
JJ
18267 # For --disable-checking or implicit --enable-checking=release, avoid
18268 # setting --enable-checking=gc in the default stage1 checking for LTO
18269 # bootstraps. See PR62077.
c10b5ea0
JJ
18270 case $BUILD_CONFIG in
18271 *lto*)
7db11a5a
JJ
18272 stage1_checking=--enable-checking=release,misc,gimple,rtlflag,tree,types;;
18273 *)
18274 stage1_checking=--enable-checking=yes,types;;
c10b5ea0 18275 esac
7db11a5a
JJ
18276 if test "x$enable_checking" = x && \
18277 test -d ${srcdir}/gcc && \
18278 test x"`cat ${srcdir}/gcc/DEV-PHASE`" = xexperimental; then
c100769b 18279 stage1_checking=--enable-checking=yes,types,extra
7db11a5a 18280 fi
8efea775 18281else
e643dc23 18282 stage1_checking=--enable-checking=$enable_checking,types
8efea775 18283fi
5213506e 18284fi
8efea775
PB
18285
18286
2aeb72e9 18287
5213506e
RW
18288# Enable -Werror in bootstrap stage2 and later.
18289# Check whether --enable-werror was given.
18290if test "${enable_werror+set}" = set; then :
18291 enableval=$enable_werror;
09a9c095
NN
18292case ${enable_werror} in
18293 yes) stage2_werror_flag="--enable-werror-always" ;;
18294 *) stage2_werror_flag="" ;;
2805b53a
NN
18295esac
18296
afd88efc
ML
18297else
18298
01c712cb
ML
18299if test -d ${srcdir}/gcc && test x"`cat $srcdir/gcc/DEV-PHASE`" = xexperimental; then
18300 case $BUILD_CONFIG in
18301 bootstrap-debug)
18302 stage2_werror_flag="--enable-werror-always" ;;
18303 "")
18304 stage2_werror_flag="--enable-werror-always" ;;
18305 esac
18306fi
18307
afd88efc
ML
18308fi
18309
18310
01c712cb 18311
2805b53a 18312
f2689b09
SE
18313# Specify what files to not compare during bootstrap.
18314
18315compare_exclusions="gcc/cc*-checksum\$(objext) | gcc/ada/*tools/*"
18316case "$target" in
18317 hppa*64*-*-hpux*) ;;
4f943869
MK
18318 hppa*-*-hpux*) compare_exclusions="$compare_exclusions | */libgcc/lib2funcs* | gcc/function-tests.o" ;;
18319 powerpc*-ibm-aix*) compare_exclusions="$compare_exclusions | *libgomp*\$(objext)" ;;
f2689b09
SE
18320esac
18321
18322
5213506e
RW
18323ac_config_files="$ac_config_files Makefile"
18324
1c710c3c 18325cat >confcache <<\_ACEOF
671aa708
NN
18326# This file is a shell script that caches the results of configure
18327# tests run on this system so they can be shared between configure
1c710c3c
DJ
18328# scripts and configure runs, see configure's option --config-cache.
18329# It is not useful on other systems. If it contains results you don't
18330# want to keep, you may remove or edit it.
671aa708 18331#
1c710c3c
DJ
18332# config.status only pays attention to the cache file if you give it
18333# the --recheck option to rerun configure.
671aa708 18334#
1c710c3c
DJ
18335# `ac_cv_env_foo' variables (set or unset) will be overridden when
18336# loading this file, other *unset* `ac_cv_foo' will be assigned the
18337# following values.
18338
18339_ACEOF
18340
671aa708
NN
18341# The following way of writing the cache mishandles newlines in values,
18342# but we know of no workaround that is simple, portable, and efficient.
5213506e 18343# So, we kill variables containing newlines.
671aa708
NN
18344# Ultrix sh set writes to stderr and can't be redirected directly,
18345# and sets the high bit in the cache file unless we assign to the vars.
5213506e
RW
18346(
18347 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
18348 eval ac_val=\$$ac_var
18349 case $ac_val in #(
18350 *${as_nl}*)
18351 case $ac_var in #(
18352 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
18353$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
18354 esac
18355 case $ac_var in #(
18356 _ | IFS | as_nl) ;; #(
18357 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
18358 *) { eval $ac_var=; unset $ac_var;} ;;
18359 esac ;;
18360 esac
18361 done
18362
1c710c3c 18363 (set) 2>&1 |
5213506e
RW
18364 case $as_nl`(ac_space=' '; set) 2>&1` in #(
18365 *${as_nl}ac_space=\ *)
18366 # `set' does not quote correctly, so add quotes: double-quote
18367 # substitution turns \\\\ into \\, and sed turns \\ into \.
1c710c3c
DJ
18368 sed -n \
18369 "s/'/'\\\\''/g;
18370 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
5213506e 18371 ;; #(
1c710c3c
DJ
18372 *)
18373 # `set' quotes correctly as required by POSIX, so do not add quotes.
5213506e 18374 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1c710c3c 18375 ;;
5213506e
RW
18376 esac |
18377 sort
18378) |
1c710c3c 18379 sed '
5213506e 18380 /^ac_cv_env_/b end
1c710c3c 18381 t clear
5213506e 18382 :clear
1c710c3c
DJ
18383 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18384 t end
5213506e
RW
18385 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18386 :end' >>confcache
18387if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
18388 if test -w "$cache_file"; then
22e05272 18389 if test "x$cache_file" != "x/dev/null"; then
5213506e
RW
18390 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
18391$as_echo "$as_me: updating cache $cache_file" >&6;}
22e05272
JM
18392 if test ! -f "$cache_file" || test -h "$cache_file"; then
18393 cat confcache >"$cache_file"
18394 else
18395 case $cache_file in #(
18396 */* | ?:*)
18397 mv -f confcache "$cache_file"$$ &&
18398 mv -f "$cache_file"$$ "$cache_file" ;; #(
18399 *)
18400 mv -f confcache "$cache_file" ;;
18401 esac
18402 fi
18403 fi
671aa708 18404 else
5213506e
RW
18405 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
18406$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
671aa708 18407 fi
4977bab6 18408fi
671aa708 18409rm -f confcache
79c06341 18410
671aa708
NN
18411test "x$prefix" = xNONE && prefix=$ac_default_prefix
18412# Let make expand exec_prefix.
18413test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4e77e8f1 18414
671aa708
NN
18415# Transform confdefs.h into DEFS.
18416# Protect against shell expansion while executing Makefile rules.
18417# Protect against Makefile macro expansion.
1c710c3c
DJ
18418#
18419# If the first sed substitution is executed (which looks for macros that
5213506e 18420# take arguments), then branch to the quote section. Otherwise,
1c710c3c 18421# look for a macro that doesn't take arguments.
5213506e
RW
18422ac_script='
18423:mline
18424/\\$/{
18425 N
18426 s,\\\n,,
18427 b mline
18428}
1c710c3c 18429t clear
5213506e
RW
18430:clear
18431s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g
1c710c3c 18432t quote
5213506e 18433s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g
1c710c3c 18434t quote
5213506e
RW
18435b any
18436:quote
18437s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g
18438s/\[/\\&/g
18439s/\]/\\&/g
18440s/\$/$$/g
18441H
18442:any
18443${
18444 g
18445 s/^\n//
18446 s/\n/ /g
18447 p
18448}
18449'
18450DEFS=`sed -n "$ac_script" confdefs.h`
1c710c3c
DJ
18451
18452
18453ac_libobjs=
18454ac_ltlibobjs=
22e05272 18455U=
1c710c3c
DJ
18456for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
18457 # 1. Remove the extension, and $U if already installed.
5213506e
RW
18458 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
18459 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
18460 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
18461 # will be set to the directory where LIBOBJS objects are built.
18462 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
18463 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
1c710c3c
DJ
18464done
18465LIBOBJS=$ac_libobjs
fb0103e5 18466
1c710c3c 18467LTLIBOBJS=$ac_ltlibobjs
0b0dc272 18468
af71363e 18469
1c710c3c 18470
22e05272 18471: "${CONFIG_STATUS=./config.status}"
5213506e 18472ac_write_fail=0
1c710c3c
DJ
18473ac_clean_files_save=$ac_clean_files
18474ac_clean_files="$ac_clean_files $CONFIG_STATUS"
5213506e
RW
18475{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
18476$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
18477as_write_fail=0
18478cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
1c710c3c
DJ
18479#! $SHELL
18480# Generated by $as_me.
671aa708 18481# Run this file to recreate the current configuration.
671aa708 18482# Compiler output produced by configure, useful for debugging
1c710c3c 18483# configure, is in config.log if it exists.
0b0dc272 18484
1c710c3c
DJ
18485debug=false
18486ac_cs_recheck=false
18487ac_cs_silent=false
1c710c3c 18488
5213506e
RW
18489SHELL=\${CONFIG_SHELL-$SHELL}
18490export SHELL
18491_ASEOF
18492cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
18493## -------------------- ##
18494## M4sh Initialization. ##
18495## -------------------- ##
18496
18497# Be more Bourne compatible
18498DUALCASE=1; export DUALCASE # for MKS sh
18499if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
1c710c3c
DJ
18500 emulate sh
18501 NULLCMD=:
5213506e 18502 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
1c710c3c
DJ
18503 # is contrary to our usage. Disable this feature.
18504 alias -g '${1+"$@"}'='"$@"'
5213506e
RW
18505 setopt NO_GLOB_SUBST
18506else
18507 case `(set -o) 2>/dev/null` in #(
18508 *posix*) :
18509 set -o posix ;; #(
18510 *) :
18511 ;;
18512esac
1c710c3c 18513fi
1c710c3c 18514
5213506e
RW
18515
18516as_nl='
18517'
18518export as_nl
18519# Printing a long string crashes Solaris 7 /usr/bin/printf.
18520as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
18521as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
18522as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
18523# Prefer a ksh shell builtin over an external printf program on Solaris,
18524# but without wasting forks for bash or zsh.
18525if test -z "$BASH_VERSION$ZSH_VERSION" \
18526 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
18527 as_echo='print -r --'
18528 as_echo_n='print -rn --'
18529elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
18530 as_echo='printf %s\n'
18531 as_echo_n='printf %s'
18532else
18533 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
18534 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
18535 as_echo_n='/usr/ucb/echo -n'
18536 else
18537 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
18538 as_echo_n_body='eval
18539 arg=$1;
18540 case $arg in #(
18541 *"$as_nl"*)
18542 expr "X$arg" : "X\\(.*\\)$as_nl";
18543 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
18544 esac;
18545 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
18546 '
18547 export as_echo_n_body
18548 as_echo_n='sh -c $as_echo_n_body as_echo'
18549 fi
18550 export as_echo_body
18551 as_echo='sh -c $as_echo_body as_echo'
1c710c3c
DJ
18552fi
18553
5213506e
RW
18554# The user is always right.
18555if test "${PATH_SEPARATOR+set}" != set; then
18556 PATH_SEPARATOR=:
18557 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
18558 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
18559 PATH_SEPARATOR=';'
18560 }
18561fi
18562
18563
18564# IFS
18565# We need space, tab and new line, in precisely that order. Quoting is
18566# there to prevent editors from complaining about space-tab.
18567# (If _AS_PATH_WALK were called with IFS unset, it would disable word
18568# splitting by setting IFS to empty value.)
18569IFS=" "" $as_nl"
18570
18571# Find who we are. Look in the path if we contain no directory separator.
22e05272 18572as_myself=
5213506e
RW
18573case $0 in #((
18574 *[\\/]* ) as_myself=$0 ;;
18575 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18576for as_dir in $PATH
18577do
18578 IFS=$as_save_IFS
18579 test -z "$as_dir" && as_dir=.
18580 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18581 done
18582IFS=$as_save_IFS
18583
18584 ;;
18585esac
18586# We did not find ourselves, most probably we were run as `sh COMMAND'
18587# in which case we are not to be found in the path.
18588if test "x$as_myself" = x; then
18589 as_myself=$0
18590fi
18591if test ! -f "$as_myself"; then
18592 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
18593 exit 1
18594fi
1c710c3c 18595
5213506e
RW
18596# Unset variables that we do not need and which cause bugs (e.g. in
18597# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
18598# suppresses any "Segmentation fault" message there. '((' could
18599# trigger a bug in pdksh 5.2.14.
18600for as_var in BASH_ENV ENV MAIL MAILPATH
18601do eval test x\${$as_var+set} = xset \
18602 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
18603done
1c710c3c
DJ
18604PS1='$ '
18605PS2='> '
18606PS4='+ '
18607
18608# NLS nuisances.
5213506e
RW
18609LC_ALL=C
18610export LC_ALL
18611LANGUAGE=C
18612export LANGUAGE
18613
18614# CDPATH.
18615(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
18616
18617
22e05272
JM
18618# as_fn_error STATUS ERROR [LINENO LOG_FD]
18619# ----------------------------------------
5213506e
RW
18620# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
18621# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
22e05272 18622# script with STATUS, using 1 if that was 0.
5213506e
RW
18623as_fn_error ()
18624{
22e05272
JM
18625 as_status=$1; test $as_status -eq 0 && as_status=1
18626 if test "$4"; then
18627 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
18628 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
1c710c3c 18629 fi
22e05272 18630 $as_echo "$as_me: error: $2" >&2
5213506e
RW
18631 as_fn_exit $as_status
18632} # as_fn_error
18633
18634
18635# as_fn_set_status STATUS
18636# -----------------------
18637# Set $? to STATUS, without forking.
18638as_fn_set_status ()
18639{
18640 return $1
18641} # as_fn_set_status
18642
18643# as_fn_exit STATUS
18644# -----------------
18645# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
18646as_fn_exit ()
18647{
18648 set +e
18649 as_fn_set_status $1
18650 exit $1
18651} # as_fn_exit
18652
18653# as_fn_unset VAR
18654# ---------------
18655# Portably unset VAR.
18656as_fn_unset ()
18657{
18658 { eval $1=; unset $1;}
18659}
18660as_unset=as_fn_unset
18661# as_fn_append VAR VALUE
18662# ----------------------
18663# Append the text in VALUE to the end of the definition contained in VAR. Take
18664# advantage of any shell optimizations that allow amortized linear growth over
18665# repeated appends, instead of the typical quadratic growth present in naive
18666# implementations.
18667if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
18668 eval 'as_fn_append ()
18669 {
18670 eval $1+=\$2
18671 }'
18672else
18673 as_fn_append ()
18674 {
18675 eval $1=\$$1\$2
18676 }
18677fi # as_fn_append
18678
18679# as_fn_arith ARG...
18680# ------------------
18681# Perform arithmetic evaluation on the ARGs, and store the result in the
18682# global $as_val. Take advantage of shells that can avoid forks. The arguments
18683# must be portable across $(()) and expr.
18684if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
18685 eval 'as_fn_arith ()
18686 {
18687 as_val=$(( $* ))
18688 }'
18689else
18690 as_fn_arith ()
18691 {
18692 as_val=`expr "$@" || test $? -eq 1`
18693 }
18694fi # as_fn_arith
18695
1c710c3c 18696
5213506e
RW
18697if expr a : '\(a\)' >/dev/null 2>&1 &&
18698 test "X`expr 00001 : '.*\(...\)'`" = X001; then
1c710c3c
DJ
18699 as_expr=expr
18700else
18701 as_expr=false
18702fi
18703
5213506e 18704if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
1c710c3c
DJ
18705 as_basename=basename
18706else
18707 as_basename=false
18708fi
18709
5213506e
RW
18710if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
18711 as_dirname=dirname
18712else
18713 as_dirname=false
18714fi
1c710c3c 18715
5213506e 18716as_me=`$as_basename -- "$0" ||
1c710c3c
DJ
18717$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18718 X"$0" : 'X\(//\)$' \| \
5213506e
RW
18719 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
18720$as_echo X/"$0" |
18721 sed '/^.*\/\([^/][^/]*\)\/*$/{
18722 s//\1/
18723 q
18724 }
18725 /^X\/\(\/\/\)$/{
18726 s//\1/
18727 q
18728 }
18729 /^X\/\(\/\).*/{
18730 s//\1/
18731 q
18732 }
18733 s/.*/./; q'`
2aeb72e9 18734
2aeb72e9
DD
18735# Avoid depending upon Character Ranges.
18736as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18737as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18738as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18739as_cr_digits='0123456789'
18740as_cr_alnum=$as_cr_Letters$as_cr_digits
18741
5213506e
RW
18742ECHO_C= ECHO_N= ECHO_T=
18743case `echo -n x` in #(((((
18744-n*)
18745 case `echo 'xy\c'` in
18746 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
18747 xy) ECHO_C='\c';;
18748 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
18749 ECHO_T=' ';;
18750 esac;;
18751*)
18752 ECHO_N='-n';;
1c710c3c
DJ
18753esac
18754
5213506e
RW
18755rm -f conf$$ conf$$.exe conf$$.file
18756if test -d conf$$.dir; then
18757 rm -f conf$$.dir/conf$$.file
1c710c3c 18758else
5213506e
RW
18759 rm -f conf$$.dir
18760 mkdir conf$$.dir 2>/dev/null
1c710c3c 18761fi
5213506e
RW
18762if (echo >conf$$.file) 2>/dev/null; then
18763 if ln -s conf$$.file conf$$ 2>/dev/null; then
2aeb72e9 18764 as_ln_s='ln -s'
5213506e
RW
18765 # ... but there are two gotchas:
18766 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
18767 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
22e05272 18768 # In both cases, we have to default to `cp -pR'.
5213506e 18769 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
22e05272 18770 as_ln_s='cp -pR'
5213506e
RW
18771 elif ln conf$$.file conf$$ 2>/dev/null; then
18772 as_ln_s=ln
18773 else
22e05272 18774 as_ln_s='cp -pR'
2aeb72e9 18775 fi
1c710c3c 18776else
22e05272 18777 as_ln_s='cp -pR'
1c710c3c 18778fi
5213506e
RW
18779rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
18780rmdir conf$$.dir 2>/dev/null
18781
18782
18783# as_fn_mkdir_p
18784# -------------
18785# Create "$as_dir" as a directory, including parents if necessary.
18786as_fn_mkdir_p ()
18787{
18788
18789 case $as_dir in #(
18790 -*) as_dir=./$as_dir;;
18791 esac
18792 test -d "$as_dir" || eval $as_mkdir_p || {
18793 as_dirs=
18794 while :; do
18795 case $as_dir in #(
18796 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
18797 *) as_qdir=$as_dir;;
18798 esac
18799 as_dirs="'$as_qdir' $as_dirs"
18800 as_dir=`$as_dirname -- "$as_dir" ||
18801$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18802 X"$as_dir" : 'X\(//\)[^/]' \| \
18803 X"$as_dir" : 'X\(//\)$' \| \
18804 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
18805$as_echo X"$as_dir" |
18806 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18807 s//\1/
18808 q
18809 }
18810 /^X\(\/\/\)[^/].*/{
18811 s//\1/
18812 q
18813 }
18814 /^X\(\/\/\)$/{
18815 s//\1/
18816 q
18817 }
18818 /^X\(\/\).*/{
18819 s//\1/
18820 q
18821 }
18822 s/.*/./; q'`
18823 test -d "$as_dir" && break
18824 done
18825 test -z "$as_dirs" || eval "mkdir $as_dirs"
22e05272 18826 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
5213506e 18827
1c710c3c 18828
5213506e 18829} # as_fn_mkdir_p
1c710c3c 18830if mkdir -p . 2>/dev/null; then
5213506e 18831 as_mkdir_p='mkdir -p "$as_dir"'
1c710c3c
DJ
18832else
18833 test -d ./-p && rmdir ./-p
18834 as_mkdir_p=false
18835fi
18836
22e05272
JM
18837
18838# as_fn_executable_p FILE
18839# -----------------------
18840# Test if FILE is an executable regular file.
18841as_fn_executable_p ()
18842{
18843 test -f "$1" && test -x "$1"
18844} # as_fn_executable_p
18845as_test_x='test -x'
18846as_executable_p=as_fn_executable_p
1c710c3c
DJ
18847
18848# Sed expression to map a string onto a valid CPP name.
18849as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
18850
18851# Sed expression to map a string onto a valid variable name.
18852as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
18853
18854
1c710c3c 18855exec 6>&1
5213506e
RW
18856## ----------------------------------- ##
18857## Main body of $CONFIG_STATUS script. ##
18858## ----------------------------------- ##
18859_ASEOF
18860test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
18861
18862cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18863# Save the log message, to keep $0 and so on meaningful, and to
1c710c3c 18864# report actual input values of CONFIG_FILES etc. instead of their
5213506e
RW
18865# values after options handling.
18866ac_log="
1c710c3c 18867This file was extended by $as_me, which was
22e05272 18868generated by GNU Autoconf 2.69. Invocation command line was
1c710c3c
DJ
18869
18870 CONFIG_FILES = $CONFIG_FILES
18871 CONFIG_HEADERS = $CONFIG_HEADERS
18872 CONFIG_LINKS = $CONFIG_LINKS
18873 CONFIG_COMMANDS = $CONFIG_COMMANDS
18874 $ $0 $@
18875
5213506e
RW
18876on `(hostname || uname -n) 2>/dev/null | sed 1q`
18877"
18878
1c710c3c
DJ
18879_ACEOF
18880
5213506e
RW
18881case $ac_config_files in *"
18882"*) set x $ac_config_files; shift; ac_config_files=$*;;
18883esac
1c710c3c 18884
2aeb72e9 18885
2aeb72e9 18886
5213506e
RW
18887cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18888# Files that config.status was made for.
18889config_files="$ac_config_files"
1c710c3c 18890
5213506e 18891_ACEOF
2aeb72e9 18892
5213506e 18893cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1c710c3c 18894ac_cs_usage="\
5213506e
RW
18895\`$as_me' instantiates files and other configuration actions
18896from templates according to the current configuration. Unless the files
18897and actions are specified as TAGs, all are instantiated by default.
1c710c3c 18898
5213506e 18899Usage: $0 [OPTION]... [TAG]...
1c710c3c
DJ
18900
18901 -h, --help print this help, then exit
5213506e 18902 -V, --version print version number and configuration settings, then exit
22e05272 18903 --config print configuration, then exit
5213506e
RW
18904 -q, --quiet, --silent
18905 do not print progress messages
1c710c3c
DJ
18906 -d, --debug don't remove temporary files
18907 --recheck update $as_me by reconfiguring in the same conditions
5213506e
RW
18908 --file=FILE[:TEMPLATE]
18909 instantiate the configuration file FILE
1c710c3c
DJ
18910
18911Configuration files:
18912$config_files
18913
5213506e 18914Report bugs to the package provider."
2aeb72e9 18915
5213506e
RW
18916_ACEOF
18917cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22e05272 18918ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1c710c3c
DJ
18919ac_cs_version="\\
18920config.status
22e05272
JM
18921configured by $0, generated by GNU Autoconf 2.69,
18922 with options \\"\$ac_cs_config\\"
1c710c3c 18923
22e05272 18924Copyright (C) 2012 Free Software Foundation, Inc.
1c710c3c
DJ
18925This config.status script is free software; the Free Software Foundation
18926gives unlimited permission to copy, distribute and modify it."
5213506e
RW
18927
18928ac_pwd='$ac_pwd'
18929srcdir='$srcdir'
18930INSTALL='$INSTALL'
87264276 18931AWK='$AWK'
5213506e 18932test -n "\$AWK" || AWK=awk
1c710c3c
DJ
18933_ACEOF
18934
5213506e
RW
18935cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18936# The default lists apply if the user does not specify any file.
1c710c3c
DJ
18937ac_need_defaults=:
18938while test $# != 0
a4b9e93e 18939do
1c710c3c 18940 case $1 in
22e05272 18941 --*=?*)
5213506e
RW
18942 ac_option=`expr "X$1" : 'X\([^=]*\)='`
18943 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
1c710c3c
DJ
18944 ac_shift=:
18945 ;;
22e05272
JM
18946 --*=)
18947 ac_option=`expr "X$1" : 'X\([^=]*\)='`
18948 ac_optarg=
18949 ac_shift=:
18950 ;;
5213506e 18951 *)
1c710c3c
DJ
18952 ac_option=$1
18953 ac_optarg=$2
18954 ac_shift=shift
18955 ;;
1c710c3c
DJ
18956 esac
18957
18958 case $ac_option in
18959 # Handling of the options.
671aa708 18960 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1c710c3c 18961 ac_cs_recheck=: ;;
5213506e
RW
18962 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
18963 $as_echo "$ac_cs_version"; exit ;;
22e05272
JM
18964 --config | --confi | --conf | --con | --co | --c )
18965 $as_echo "$ac_cs_config"; exit ;;
5213506e 18966 --debug | --debu | --deb | --de | --d | -d )
1c710c3c
DJ
18967 debug=: ;;
18968 --file | --fil | --fi | --f )
18969 $ac_shift
5213506e
RW
18970 case $ac_optarg in
18971 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22e05272 18972 '') as_fn_error $? "missing file argument" ;;
5213506e
RW
18973 esac
18974 as_fn_append CONFIG_FILES " '$ac_optarg'"
2aeb72e9 18975 ac_need_defaults=false;;
5213506e
RW
18976 --he | --h | --help | --hel | -h )
18977 $as_echo "$ac_cs_usage"; exit ;;
1c710c3c
DJ
18978 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18979 | -silent | --silent | --silen | --sile | --sil | --si | --s)
18980 ac_cs_silent=: ;;
18981
18982 # This is an error.
22e05272 18983 -*) as_fn_error $? "unrecognized option: \`$1'
5213506e 18984Try \`$0 --help' for more information." ;;
1c710c3c 18985
5213506e
RW
18986 *) as_fn_append ac_config_targets " $1"
18987 ac_need_defaults=false ;;
1c710c3c 18988
0b0dc272 18989 esac
1c710c3c 18990 shift
0b0dc272
AM
18991done
18992
1c710c3c 18993ac_configure_extra_args=
0b0dc272 18994
1c710c3c
DJ
18995if $ac_cs_silent; then
18996 exec 6>/dev/null
18997 ac_configure_extra_args="$ac_configure_extra_args --silent"
18998fi
0b0dc272 18999
1c710c3c 19000_ACEOF
5213506e 19001cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1c710c3c 19002if \$ac_cs_recheck; then
22e05272 19003 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
5213506e
RW
19004 shift
19005 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
19006 CONFIG_SHELL='$SHELL'
19007 export CONFIG_SHELL
19008 exec "\$@"
1c710c3c
DJ
19009fi
19010
19011_ACEOF
5213506e
RW
19012cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19013exec 5>>config.log
19014{
19015 echo
19016 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19017## Running $as_me. ##
19018_ASBOX
19019 $as_echo "$ac_log"
19020} >&5
1c710c3c 19021
5213506e
RW
19022_ACEOF
19023cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
3e54529c
RW
19024#
19025# INIT-COMMANDS
19026#
19027extrasub_build="$extrasub_build"
19028 extrasub_host="$extrasub_host"
19029 extrasub_target="$extrasub_target"
19030
5213506e 19031_ACEOF
1c710c3c 19032
5213506e 19033cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11a67599 19034
5213506e 19035# Handling of arguments.
1c710c3c
DJ
19036for ac_config_target in $ac_config_targets
19037do
5213506e
RW
19038 case $ac_config_target in
19039 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
19040
22e05272 19041 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
1c710c3c
DJ
19042 esac
19043done
19044
5213506e 19045
1c710c3c
DJ
19046# If the user did not use the arguments to specify the items to instantiate,
19047# then the envvar interface is used. Set only those that are not.
19048# We use the long form for the default assignment because of an extremely
19049# bizarre bug on SunOS 4.1.3.
19050if $ac_need_defaults; then
19051 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19052fi
19053
19054# Have a temporary directory for convenience. Make it in the build tree
5213506e 19055# simply because there is no reason against having it here, and in addition,
1c710c3c 19056# creating and moving files from /tmp can sometimes cause problems.
5213506e
RW
19057# Hook for its removal unless debugging.
19058# Note that there is a small window in which the directory will not be cleaned:
19059# after its creation but before its name has been assigned to `$tmp'.
1c710c3c
DJ
19060$debug ||
19061{
22e05272 19062 tmp= ac_tmp=
5213506e 19063 trap 'exit_status=$?
22e05272
JM
19064 : "${ac_tmp:=$tmp}"
19065 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
5213506e
RW
19066' 0
19067 trap 'as_fn_exit 1' 1 2 13 15
1c710c3c 19068}
1c710c3c
DJ
19069# Create a (secure) tmp directory for tmp files.
19070
19071{
5213506e 19072 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
22e05272 19073 test -d "$tmp"
1c710c3c
DJ
19074} ||
19075{
5213506e
RW
19076 tmp=./conf$$-$RANDOM
19077 (umask 077 && mkdir "$tmp")
22e05272
JM
19078} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
19079ac_tmp=$tmp
5213506e
RW
19080
19081# Set up the scripts for CONFIG_FILES section.
19082# No need to generate them if there are no CONFIG_FILES.
19083# This happens for instance with `./config.status config.h'.
19084if test -n "$CONFIG_FILES"; then
19085
19086if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
19087 ac_cs_awk_getline=:
19088 ac_cs_awk_pipe_init=
19089 ac_cs_awk_read_file='
19090 while ((getline aline < (F[key])) > 0)
19091 print(aline)
19092 close(F[key])'
19093 ac_cs_awk_pipe_fini=
19094else
19095 ac_cs_awk_getline=false
19096 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
19097 ac_cs_awk_read_file='
19098 print "|#_!!_#|"
19099 print "cat " F[key] " &&"
19100 '$ac_cs_awk_pipe_init
19101 # The final `:' finishes the AND list.
19102 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
19103fi
19104ac_cr=`echo X | tr X '\015'`
19105# On cygwin, bash can eat \r inside `` if the user requested igncr.
19106# But we know of no other shell where ac_cr would be empty at this
19107# point, so we can use a bashism as a fallback.
19108if test "x$ac_cr" = x; then
19109 eval ac_cr=\$\'\\r\'
19110fi
19111ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
19112if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
22e05272 19113 ac_cs_awk_cr='\\r'
5213506e
RW
19114else
19115 ac_cs_awk_cr=$ac_cr
19116fi
19117
22e05272 19118echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
5213506e
RW
19119_ACEOF
19120
19121# Create commands to substitute file output variables.
1c710c3c 19122{
5213506e 19123 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
22e05272 19124 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
5213506e
RW
19125 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
19126 echo "_ACAWK" &&
19127 echo "_ACEOF"
19128} >conf$$files.sh &&
19129. ./conf$$files.sh ||
22e05272 19130 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
5213506e 19131rm -f conf$$files.sh
1c710c3c 19132
5213506e
RW
19133{
19134 echo "cat >conf$$subs.awk <<_ACEOF" &&
19135 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
19136 echo "_ACEOF"
19137} >conf$$subs.sh ||
22e05272
JM
19138 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19139ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
5213506e
RW
19140ac_delim='%!_!# '
19141for ac_last_try in false false false false false :; do
19142 . ./conf$$subs.sh ||
22e05272 19143 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
5213506e
RW
19144
19145 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
19146 if test $ac_delim_n = $ac_delim_num; then
19147 break
19148 elif $ac_last_try; then
22e05272 19149 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
5213506e
RW
19150 else
19151 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19152 fi
19153done
19154rm -f conf$$subs.sh
19155
19156cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22e05272 19157cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
2aeb72e9 19158_ACEOF
5213506e
RW
19159sed -n '
19160h
19161s/^/S["/; s/!.*/"]=/
19162p
19163g
19164s/^[^!]*!//
19165:repl
19166t repl
19167s/'"$ac_delim"'$//
19168t delim
19169:nl
19170h
22e05272 19171s/\(.\{148\}\)..*/\1/
5213506e
RW
19172t more1
19173s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
19174p
19175n
19176b repl
19177:more1
19178s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19179p
19180g
19181s/.\{148\}//
19182t nl
19183:delim
19184h
22e05272 19185s/\(.\{148\}\)..*/\1/
5213506e
RW
19186t more2
19187s/["\\]/\\&/g; s/^/"/; s/$/"/
19188p
19189b
19190:more2
19191s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19192p
19193g
19194s/.\{148\}//
19195t delim
19196' <conf$$subs.awk | sed '
19197/^[^""]/{
19198 N
19199 s/\n//
19200}
19201' >>$CONFIG_STATUS || ac_write_fail=1
19202rm -f conf$$subs.awk
19203cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19204_ACAWK
22e05272 19205cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
5213506e
RW
19206 for (key in S) S_is_set[key] = 1
19207 FS = "\a"
19208 \$ac_cs_awk_pipe_init
19209}
19210{
19211 line = $ 0
19212 nfields = split(line, field, "@")
19213 substed = 0
19214 len = length(field[1])
19215 for (i = 2; i < nfields; i++) {
19216 key = field[i]
19217 keylen = length(key)
19218 if (S_is_set[key]) {
19219 value = S[key]
19220 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
19221 len += length(value) + length(field[++i])
19222 substed = 1
19223 } else
19224 len += 1 + keylen
19225 }
19226 if (nfields == 3 && !substed) {
19227 key = field[2]
19228 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
19229 \$ac_cs_awk_read_file
19230 next
19231 }
19232 }
19233 print line
19234}
19235\$ac_cs_awk_pipe_fini
19236_ACAWK
19237_ACEOF
19238cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19239if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
19240 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
19241else
19242 cat
22e05272
JM
19243fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
19244 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
5213506e
RW
19245_ACEOF
19246
22e05272
JM
19247# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
19248# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
5213506e
RW
19249# trailing colons and then remove the whole line if VPATH becomes empty
19250# (actually we leave an empty line to preserve line numbers).
19251if test "x$srcdir" = x.; then
22e05272
JM
19252 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
19253h
19254s///
19255s/^/:/
19256s/[ ]*$/:/
19257s/:\$(srcdir):/:/g
19258s/:\${srcdir}:/:/g
19259s/:@srcdir@:/:/g
19260s/^:*//
5213506e 19261s/:*$//
22e05272
JM
19262x
19263s/\(=[ ]*\).*/\1/
19264G
19265s/\n//
5213506e
RW
19266s/^[^=]*=[ ]*$//
19267}'
19268fi
2aeb72e9 19269
5213506e
RW
19270cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19271fi # test -n "$CONFIG_FILES"
2aeb72e9 19272
1c710c3c 19273
5213506e
RW
19274eval set X " :F $CONFIG_FILES "
19275shift
19276for ac_tag
19277do
19278 case $ac_tag in
19279 :[FHLC]) ac_mode=$ac_tag; continue;;
19280 esac
19281 case $ac_mode$ac_tag in
19282 :[FHL]*:*);;
22e05272 19283 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
5213506e
RW
19284 :[FH]-) ac_tag=-:-;;
19285 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
19286 esac
19287 ac_save_IFS=$IFS
19288 IFS=:
19289 set x $ac_tag
19290 IFS=$ac_save_IFS
19291 shift
19292 ac_file=$1
19293 shift
79c06341 19294
5213506e
RW
19295 case $ac_mode in
19296 :L) ac_source=$1;;
19297 :[FH])
19298 ac_file_inputs=
19299 for ac_f
19300 do
19301 case $ac_f in
22e05272 19302 -) ac_f="$ac_tmp/stdin";;
5213506e
RW
19303 *) # Look for the file first in the build tree, then in the source tree
19304 # (if the path is not absolute). The absolute path cannot be DOS-style,
19305 # because $ac_f cannot contain `:'.
19306 test -f "$ac_f" ||
19307 case $ac_f in
19308 [\\/$]*) false;;
19309 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
19310 esac ||
22e05272 19311 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
5213506e
RW
19312 esac
19313 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
19314 as_fn_append ac_file_inputs " '$ac_f'"
19315 done
1c710c3c 19316
5213506e
RW
19317 # Let's still pretend it is `configure' which instantiates (i.e., don't
19318 # use $as_me), people would be surprised to read:
19319 # /* config.h. Generated by config.status. */
19320 configure_input='Generated from '`
19321 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
19322 `' by configure.'
19323 if test x"$ac_file" != x-; then
19324 configure_input="$ac_file. $configure_input"
19325 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
19326$as_echo "$as_me: creating $ac_file" >&6;}
2aeb72e9 19327 fi
5213506e
RW
19328 # Neutralize special characters interpreted by sed in replacement strings.
19329 case $configure_input in #(
19330 *\&* | *\|* | *\\* )
19331 ac_sed_conf_input=`$as_echo "$configure_input" |
19332 sed 's/[\\\\&|]/\\\\&/g'`;; #(
19333 *) ac_sed_conf_input=$configure_input;;
19334 esac
11a67599 19335
5213506e 19336 case $ac_tag in
22e05272
JM
19337 *:-:* | *:-) cat >"$ac_tmp/stdin" \
19338 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
5213506e
RW
19339 esac
19340 ;;
11a67599
ZW
19341 esac
19342
5213506e 19343 ac_dir=`$as_dirname -- "$ac_file" ||
1c710c3c
DJ
19344$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19345 X"$ac_file" : 'X\(//\)[^/]' \| \
19346 X"$ac_file" : 'X\(//\)$' \| \
5213506e
RW
19347 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
19348$as_echo X"$ac_file" |
19349 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19350 s//\1/
19351 q
19352 }
19353 /^X\(\/\/\)[^/].*/{
19354 s//\1/
19355 q
19356 }
19357 /^X\(\/\/\)$/{
19358 s//\1/
19359 q
19360 }
19361 /^X\(\/\).*/{
19362 s//\1/
19363 q
19364 }
19365 s/.*/./; q'`
19366 as_dir="$ac_dir"; as_fn_mkdir_p
1c710c3c 19367 ac_builddir=.
0b0dc272 19368
5213506e
RW
19369case "$ac_dir" in
19370.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
19371*)
19372 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
19373 # A ".." for each directory in $ac_dir_suffix.
19374 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
19375 case $ac_top_builddir_sub in
19376 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
19377 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
19378 esac ;;
19379esac
19380ac_abs_top_builddir=$ac_pwd
19381ac_abs_builddir=$ac_pwd$ac_dir_suffix
19382# for backward compatibility:
19383ac_top_builddir=$ac_top_build_prefix
1c710c3c
DJ
19384
19385case $srcdir in
5213506e 19386 .) # We are building in place.
1c710c3c 19387 ac_srcdir=.
5213506e
RW
19388 ac_top_srcdir=$ac_top_builddir_sub
19389 ac_abs_top_srcdir=$ac_pwd ;;
19390 [\\/]* | ?:[\\/]* ) # Absolute name.
1c710c3c 19391 ac_srcdir=$srcdir$ac_dir_suffix;
5213506e
RW
19392 ac_top_srcdir=$srcdir
19393 ac_abs_top_srcdir=$srcdir ;;
19394 *) # Relative name.
19395 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
19396 ac_top_srcdir=$ac_top_build_prefix$srcdir
19397 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1c710c3c 19398esac
5213506e 19399ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
a4b9e93e 19400
0b0dc272 19401
5213506e
RW
19402 case $ac_mode in
19403 :F)
19404 #
19405 # CONFIG_FILE
19406 #
1c710c3c
DJ
19407
19408 case $INSTALL in
19409 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
5213506e 19410 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
671aa708 19411 esac
5213506e 19412_ACEOF
11a67599 19413
5213506e
RW
19414cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19415# If the template does not know about datarootdir, expand it.
19416# FIXME: This hack should be removed a few years after 2.60.
19417ac_datarootdir_hack=; ac_datarootdir_seen=
19418ac_sed_dataroot='
19419/datarootdir/ {
19420 p
19421 q
19422}
19423/@datadir@/p
19424/@docdir@/p
19425/@infodir@/p
19426/@localedir@/p
19427/@mandir@/p'
19428case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
19429*datarootdir*) ac_datarootdir_seen=yes;;
19430*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
19431 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
19432$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
11a67599 19433_ACEOF
5213506e
RW
19434cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19435 ac_datarootdir_hack='
19436 s&@datadir@&$datadir&g
19437 s&@docdir@&$docdir&g
19438 s&@infodir@&$infodir&g
19439 s&@localedir@&$localedir&g
19440 s&@mandir@&$mandir&g
19441 s&\\\${datarootdir}&$datarootdir&g' ;;
19442esac
19443_ACEOF
19444
19445# Neutralize VPATH when `$srcdir' = `.'.
19446# Shell code in configure.ac might set extrasub.
19447# FIXME: do we really want to maintain this feature?
19448cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19449ac_sed_extra="$ac_vpsub
1c710c3c
DJ
19450$extrasub
19451_ACEOF
5213506e 19452cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1c710c3c
DJ
19453:t
19454/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
5213506e
RW
19455s|@configure_input@|$ac_sed_conf_input|;t t
19456s&@top_builddir@&$ac_top_builddir_sub&;t t
19457s&@top_build_prefix@&$ac_top_build_prefix&;t t
19458s&@srcdir@&$ac_srcdir&;t t
19459s&@abs_srcdir@&$ac_abs_srcdir&;t t
19460s&@top_srcdir@&$ac_top_srcdir&;t t
19461s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
19462s&@builddir@&$ac_builddir&;t t
19463s&@abs_builddir@&$ac_abs_builddir&;t t
19464s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
19465s&@INSTALL@&$ac_INSTALL&;t t
19466$ac_datarootdir_hack
19467"
19468eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
19469if $ac_cs_awk_getline; then
22e05272 19470 $AWK -f "$ac_tmp/subs.awk"
5213506e 19471else
22e05272
JM
19472 $AWK -f "$ac_tmp/subs.awk" | $SHELL
19473fi \
19474 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
5213506e
RW
19475
19476test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
22e05272
JM
19477 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
19478 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
19479 "$ac_tmp/out"`; test -z "$ac_out"; } &&
5213506e 19480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22e05272 19481which seems to be undefined. Please make sure it is defined" >&5
5213506e 19482$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22e05272 19483which seems to be undefined. Please make sure it is defined" >&2;}
5213506e 19484
22e05272 19485 rm -f "$ac_tmp/stdin"
5213506e 19486 case $ac_file in
22e05272
JM
19487 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
19488 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
5213506e 19489 esac \
22e05272 19490 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
5213506e 19491 ;;
11a67599 19492
11a67599 19493
79c06341 19494
5213506e
RW
19495 esac
19496
3e54529c
RW
19497
19498 case $ac_file$ac_mode in
19499 "Makefile":F) sed "$extrasub_build" Makefile |
19500 sed "$extrasub_host" |
19501 sed "$extrasub_target" > mf$$
19502 mv -f mf$$ Makefile ;;
19503
19504 esac
5213506e
RW
19505done # for ac_tag
19506
19507
19508as_fn_exit 0
1c710c3c 19509_ACEOF
1c710c3c
DJ
19510ac_clean_files=$ac_clean_files_save
19511
5213506e 19512test $ac_write_fail = 0 ||
22e05272 19513 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
5213506e 19514
1c710c3c
DJ
19515
19516# configure is writing to config.log, and then calls config.status.
19517# config.status does its own redirection, appending to config.log.
19518# Unfortunately, on DOS this fails, as config.log is still kept open
19519# by configure, so config.status won't be able to write to it; its
19520# output is simply discarded. So we exec the FD to /dev/null,
19521# effectively closing config.log, so it can be properly (re)opened and
19522# appended to by config.status. When coming back to configure, we
19523# need to make the FD available again.
19524if test "$no_create" != yes; then
19525 ac_cs_success=:
19526 ac_config_status_args=
19527 test "$silent" = yes &&
19528 ac_config_status_args="$ac_config_status_args --quiet"
19529 exec 5>/dev/null
19530 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
19531 exec 5>>config.log
19532 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19533 # would make configure fail if this is the last instruction.
22e05272 19534 $ac_cs_success || as_fn_exit 1
5213506e
RW
19535fi
19536if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
19537 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
19538$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
1c710c3c 19539fi
79c06341 19540