]> git.ipfire.org Git - thirdparty/gcc.git/blame - configure
tree-optimization/114787 - more careful loop update with CFG cleanup
[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
1eee94d3 616GM2_FOR_TARGET
b4c522fa 617GDC_FOR_TARGET
632e2a07 618GOC_FOR_TARGET
5213506e 619GFORTRAN_FOR_TARGET
5213506e
RW
620GCC_FOR_TARGET
621CXX_FOR_TARGET
622CC_FOR_TARGET
126f707e
L
623RANLIB_PLUGIN_OPTION
624AR_PLUGIN_OPTION
1ddd41fd 625PKG_CONFIG_PATH
5fee5ec3 626GDCFLAGS
e7a82751 627READELF
e4a9a572 628OTOOL
5213506e
RW
629OBJDUMP
630OBJCOPY
631WINDMC
632WINDRES
633STRIP
634RANLIB
635NM
636LIPO
637LD
3b5e8ee4 638DSYMUTIL
5213506e
RW
639DLLTOOL
640AS
641AR
642RUNTEST
643EXPECT
644MAKEINFO
645FLEX
646LEX
647M4
648BISON
649YACC
5213506e
RW
650WINDRES_FOR_BUILD
651WINDMC_FOR_BUILD
652RANLIB_FOR_BUILD
653NM_FOR_BUILD
654LD_FOR_BUILD
655LDFLAGS_FOR_BUILD
b4c522fa 656GDC_FOR_BUILD
632e2a07 657GOC_FOR_BUILD
5213506e 658GFORTRAN_FOR_BUILD
3b5e8ee4 659DSYMUTIL_FOR_BUILD
5213506e
RW
660DLLTOOL_FOR_BUILD
661CXX_FOR_BUILD
662CXXFLAGS_FOR_BUILD
84401ce5
RP
663CPPFLAGS_FOR_BUILD
664CPP_FOR_BUILD
5213506e
RW
665CFLAGS_FOR_BUILD
666CC_FOR_BUILD
667AS_FOR_BUILD
668AR_FOR_BUILD
aae29963 669target_configdirs
5213506e 670configdirs
5213506e 671build_configdirs
5213506e
RW
672INSTALL_GDB_TK
673GDB_TK
674CONFIGURE_GDB_TK
675build_tooldir
676tooldir
677GCC_SHLIB_SUBDIR
678RPATH_ENVVAR
ffedf511
RW
679target_configargs
680host_configargs
681build_configargs
e12c4094 682BUILD_CONFIG
6f57bdf6 683LDFLAGS_FOR_TARGET
5213506e
RW
684CXXFLAGS_FOR_TARGET
685CFLAGS_FOR_TARGET
686DEBUG_PREFIX_CFLAGS_FOR_TARGET
687SYSROOT_CFLAGS_FOR_TARGET
3c36aa6b 688get_gcc_base_ver
1c01ebf6 689extra_host_zlib_configure_flags
d7f09764 690extra_host_libiberty_configure_flags
fca38047 691stage1_languages
05048fc2 692host_libs_picflag
b6cb10af 693PICFLAG
cdfee50a 694host_shared
c1fecabe 695gcc_host_pie
b6cb10af 696host_pie
45b3824d
TS
697extra_linker_plugin_flags
698extra_linker_plugin_configure_flags
33ad93b9 699islinc
eae1a5d4 700isllibs
5213506e 701poststage1_ldflags
ed2eaa9f 702poststage1_libs
5213506e 703stage1_ldflags
0b21f5d3 704stage1_libs
0ff2d841 705extra_isl_gmp_configure_flags
5213506e
RW
706extra_mpc_mpfr_configure_flags
707extra_mpc_gmp_configure_flags
708extra_mpfr_configure_flags
709gmpinc
710gmplibs
4a5e71f2
L
711PGO_BUILD_LTO_CFLAGS
712PGO_BUILD_USE_CFLAGS
713PGO_BUILD_GEN_CFLAGS
7ffcf5d6 714HAVE_CXX11_FOR_BUILD
ffac9597 715HAVE_CXX11
5213506e 716do_compare
3e1e73fc 717CARGO
5fee5ec3 718GDC
5213506e
RW
719GNATMAKE
720GNATBIND
721ac_ct_CXX
722CXXFLAGS
723CXX
724OBJEXT
725EXEEXT
726ac_ct_CC
727CPPFLAGS
728LDFLAGS
729CFLAGS
730CC
731target_subdir
732host_subdir
733build_subdir
734build_libsubdir
87264276
PB
735AWK
736SED
5213506e
RW
737LN_S
738LN
739INSTALL_DATA
740INSTALL_SCRIPT
741INSTALL_PROGRAM
742target_os
743target_vendor
744target_cpu
745target
746host_os
747host_vendor
748host_cpu
749host
750target_noncanonical
751host_noncanonical
752build_noncanonical
753build_os
754build_vendor
755build_cpu
756build
757TOPLEVEL_CONFIGURE_ARGUMENTS
758target_alias
759host_alias
760build_alias
761LIBS
762ECHO_T
763ECHO_N
764ECHO_C
765DEFS
766mandir
767localedir
768libdir
769psdir
770pdfdir
771dvidir
772htmldir
773infodir
774docdir
775oldincludedir
776includedir
777localstatedir
778sharedstatedir
779sysconfdir
780datadir
781datarootdir
782libexecdir
783sbindir
784bindir
785program_transform_name
786prefix
787exec_prefix
788PACKAGE_URL
789PACKAGE_BUGREPORT
790PACKAGE_STRING
791PACKAGE_VERSION
792PACKAGE_TARNAME
793PACKAGE_NAME
794PATH_SEPARATOR
795SHELL'
796ac_subst_files='serialization_dependencies
797host_makefile_frag
798target_makefile_frag
799alphaieee_frag
800ospace_frag'
801ac_user_opts='
802enable_option_checking
803with_build_libsubdir
a05c2c75 804with_system_zlib
407a2c9a 805with_zstd
85c64bbe
BS
806enable_as_accelerator_for
807enable_offload_targets
fe5bfa67 808enable_offload_defaulted
5213506e 809enable_gold
21539e2e 810enable_ld
24552056 811enable_gprofng
78edb32f 812enable_compressed_debug_sections
c9884636 813enable_default_compressed_debug_sections_algorithm
a49d42e8 814enable_year2038
87e6d9dc
TB
815enable_libquadmath
816enable_libquadmath_support
5213506e 817enable_libada
1eee94d3 818enable_libgm2
5213506e 819enable_libssp
1873ec0c 820enable_libstdcxx
ff3ac0f4 821enable_bootstrap
4a5e71f2 822enable_pgo_build
5213506e
RW
823with_mpc
824with_mpc_include
825with_mpc_lib
5213506e
RW
826with_mpfr
827with_mpfr_include
828with_mpfr_lib
5213506e
RW
829with_gmp
830with_gmp_include
831with_gmp_lib
5213506e 832with_stage1_libs
aac9103b 833with_static_standard_libraries
0b21f5d3 834with_stage1_ldflags
5213506e 835with_boot_libs
ed2eaa9f 836with_boot_ldflags
33ad93b9
RG
837with_isl
838with_isl_include
839with_isl_lib
840enable_isl_version_check
d7f09764 841enable_lto
45b3824d
TS
842enable_linker_plugin_configure_flags
843enable_linker_plugin_flags
b6cb10af 844enable_host_pie
cdfee50a 845enable_host_shared
5213506e 846enable_stage1_languages
43c40f3e 847enable_objc_gc
114bf3f1
MK
848with_target_bdw_gc
849with_target_bdw_gc_include
850with_target_bdw_gc_lib
3c36aa6b 851with_gcc_major_version_only
5213506e
RW
852with_build_sysroot
853with_debug_prefix_map
5646b7b9 854with_build_config
beeda1d9 855enable_vtable_verify
5213506e
RW
856enable_serial_configure
857with_build_time_tools
858enable_maintainer_mode
859enable_stage1_checking
860enable_werror
5213506e
RW
861'
862 ac_precious_vars='build_alias
863host_alias
864target_alias
865CC
866CFLAGS
867LDFLAGS
868LIBS
869CPPFLAGS
870CXX
871CXXFLAGS
872CCC
ffedf511
RW
873build_configargs
874host_configargs
875target_configargs
5213506e
RW
876AR
877AS
878DLLTOOL
3b5e8ee4 879DSYMUTIL
5213506e
RW
880LD
881LIPO
882NM
883RANLIB
884STRIP
885WINDRES
886WINDMC
887OBJCOPY
888OBJDUMP
e4a9a572 889OTOOL
e7a82751 890READELF
5213506e
RW
891CC_FOR_TARGET
892CXX_FOR_TARGET
893GCC_FOR_TARGET
5213506e 894GFORTRAN_FOR_TARGET
632e2a07 895GOC_FOR_TARGET
b4c522fa 896GDC_FOR_TARGET
1eee94d3 897GM2_FOR_TARGET
5213506e
RW
898AR_FOR_TARGET
899AS_FOR_TARGET
900DLLTOOL_FOR_TARGET
3b5e8ee4 901DSYMUTIL_FOR_TARGET
5213506e
RW
902LD_FOR_TARGET
903LIPO_FOR_TARGET
904NM_FOR_TARGET
9bccfdf5 905OBJCOPY_FOR_TARGET
5213506e 906OBJDUMP_FOR_TARGET
e4a9a572 907OTOOL_FOR_TARGET
5213506e 908RANLIB_FOR_TARGET
e7a82751 909READELF_FOR_TARGET
5213506e
RW
910STRIP_FOR_TARGET
911WINDRES_FOR_TARGET
912WINDMC_FOR_TARGET'
913
671aa708
NN
914
915# Initialize some variables set by options.
1c710c3c
DJ
916ac_init_help=
917ac_init_version=false
5213506e
RW
918ac_unrecognized_opts=
919ac_unrecognized_sep=
671aa708
NN
920# The variables have the same names as the options, with
921# dashes changed to underlines.
1c710c3c 922cache_file=/dev/null
671aa708 923exec_prefix=NONE
671aa708 924no_create=
671aa708
NN
925no_recursion=
926prefix=NONE
927program_prefix=NONE
928program_suffix=NONE
929program_transform_name=s,x,x,
930silent=
931site=
932srcdir=
671aa708
NN
933verbose=
934x_includes=NONE
935x_libraries=NONE
1c710c3c
DJ
936
937# Installation directory options.
938# These are left unexpanded so users can "make install exec_prefix=/foo"
939# and all the variables that are supposed to be based on exec_prefix
940# by default will actually change.
941# Use braces instead of parens because sh, perl, etc. also accept them.
5213506e 942# (The list follows the same order as the GNU Coding Standards.)
671aa708
NN
943bindir='${exec_prefix}/bin'
944sbindir='${exec_prefix}/sbin'
945libexecdir='${exec_prefix}/libexec'
5213506e
RW
946datarootdir='${prefix}/share'
947datadir='${datarootdir}'
671aa708
NN
948sysconfdir='${prefix}/etc'
949sharedstatedir='${prefix}/com'
950localstatedir='${prefix}/var'
671aa708
NN
951includedir='${prefix}/include'
952oldincludedir='/usr/include'
5213506e
RW
953docdir='${datarootdir}/doc/${PACKAGE}'
954infodir='${datarootdir}/info'
955htmldir='${docdir}'
956dvidir='${docdir}'
957pdfdir='${docdir}'
958psdir='${docdir}'
959libdir='${exec_prefix}/lib'
960localedir='${datarootdir}/locale'
961mandir='${datarootdir}/man'
79c06341 962
671aa708 963ac_prev=
5213506e 964ac_dashdash=
671aa708
NN
965for ac_option
966do
671aa708
NN
967 # If the previous option needs an argument, assign it.
968 if test -n "$ac_prev"; then
5213506e 969 eval $ac_prev=\$ac_option
671aa708
NN
970 ac_prev=
971 continue
972 fi
79c06341 973
5213506e 974 case $ac_option in
22e05272
JM
975 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
976 *=) ac_optarg= ;;
977 *) ac_optarg=yes ;;
5213506e 978 esac
671aa708
NN
979
980 # Accept the important Cygnus configure options, so we can diagnose typos.
981
5213506e
RW
982 case $ac_dashdash$ac_option in
983 --)
984 ac_dashdash=yes ;;
671aa708
NN
985
986 -bindir | --bindir | --bindi | --bind | --bin | --bi)
987 ac_prev=bindir ;;
988 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1c710c3c 989 bindir=$ac_optarg ;;
671aa708
NN
990
991 -build | --build | --buil | --bui | --bu)
1c710c3c 992 ac_prev=build_alias ;;
671aa708 993 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1c710c3c 994 build_alias=$ac_optarg ;;
671aa708
NN
995
996 -cache-file | --cache-file | --cache-fil | --cache-fi \
997 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
998 ac_prev=cache_file ;;
999 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1000 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1c710c3c
DJ
1001 cache_file=$ac_optarg ;;
1002
1003 --config-cache | -C)
1004 cache_file=config.cache ;;
671aa708 1005
5213506e 1006 -datadir | --datadir | --datadi | --datad)
671aa708 1007 ac_prev=datadir ;;
5213506e 1008 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1c710c3c 1009 datadir=$ac_optarg ;;
671aa708 1010
5213506e
RW
1011 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1012 | --dataroo | --dataro | --datar)
1013 ac_prev=datarootdir ;;
1014 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1015 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1016 datarootdir=$ac_optarg ;;
1017
671aa708 1018 -disable-* | --disable-*)
5213506e 1019 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
671aa708 1020 # Reject names that are not valid shell variable names.
5213506e 1021 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1022 as_fn_error $? "invalid feature name: $ac_useropt"
5213506e
RW
1023 ac_useropt_orig=$ac_useropt
1024 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1025 case $ac_user_opts in
1026 *"
1027"enable_$ac_useropt"
1028"*) ;;
1029 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1030 ac_unrecognized_sep=', ';;
1031 esac
1032 eval enable_$ac_useropt=no ;;
1033
1034 -docdir | --docdir | --docdi | --doc | --do)
1035 ac_prev=docdir ;;
1036 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1037 docdir=$ac_optarg ;;
1038
1039 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1040 ac_prev=dvidir ;;
1041 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1042 dvidir=$ac_optarg ;;
671aa708
NN
1043
1044 -enable-* | --enable-*)
5213506e 1045 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
671aa708 1046 # Reject names that are not valid shell variable names.
5213506e 1047 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1048 as_fn_error $? "invalid feature name: $ac_useropt"
5213506e
RW
1049 ac_useropt_orig=$ac_useropt
1050 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1051 case $ac_user_opts in
1052 *"
1053"enable_$ac_useropt"
1054"*) ;;
1055 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1056 ac_unrecognized_sep=', ';;
2aeb72e9 1057 esac
5213506e 1058 eval enable_$ac_useropt=\$ac_optarg ;;
671aa708
NN
1059
1060 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1061 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1062 | --exec | --exe | --ex)
1063 ac_prev=exec_prefix ;;
1064 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1065 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1066 | --exec=* | --exe=* | --ex=*)
1c710c3c 1067 exec_prefix=$ac_optarg ;;
671aa708
NN
1068
1069 -gas | --gas | --ga | --g)
1070 # Obsolete; use --with-gas.
1071 with_gas=yes ;;
1072
1c710c3c
DJ
1073 -help | --help | --hel | --he | -h)
1074 ac_init_help=long ;;
1075 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1076 ac_init_help=recursive ;;
1077 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1078 ac_init_help=short ;;
671aa708
NN
1079
1080 -host | --host | --hos | --ho)
1c710c3c 1081 ac_prev=host_alias ;;
671aa708 1082 -host=* | --host=* | --hos=* | --ho=*)
1c710c3c 1083 host_alias=$ac_optarg ;;
671aa708 1084
5213506e
RW
1085 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1086 ac_prev=htmldir ;;
1087 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1088 | --ht=*)
1089 htmldir=$ac_optarg ;;
1090
671aa708
NN
1091 -includedir | --includedir | --includedi | --included | --include \
1092 | --includ | --inclu | --incl | --inc)
1093 ac_prev=includedir ;;
1094 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1095 | --includ=* | --inclu=* | --incl=* | --inc=*)
1c710c3c 1096 includedir=$ac_optarg ;;
671aa708
NN
1097
1098 -infodir | --infodir | --infodi | --infod | --info | --inf)
1099 ac_prev=infodir ;;
1100 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1c710c3c 1101 infodir=$ac_optarg ;;
671aa708
NN
1102
1103 -libdir | --libdir | --libdi | --libd)
1104 ac_prev=libdir ;;
1105 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1c710c3c 1106 libdir=$ac_optarg ;;
671aa708
NN
1107
1108 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1109 | --libexe | --libex | --libe)
1110 ac_prev=libexecdir ;;
1111 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1112 | --libexe=* | --libex=* | --libe=*)
1c710c3c 1113 libexecdir=$ac_optarg ;;
671aa708 1114
5213506e
RW
1115 -localedir | --localedir | --localedi | --localed | --locale)
1116 ac_prev=localedir ;;
1117 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1118 localedir=$ac_optarg ;;
1119
671aa708 1120 -localstatedir | --localstatedir | --localstatedi | --localstated \
5213506e 1121 | --localstate | --localstat | --localsta | --localst | --locals)
671aa708
NN
1122 ac_prev=localstatedir ;;
1123 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
5213506e 1124 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1c710c3c 1125 localstatedir=$ac_optarg ;;
671aa708
NN
1126
1127 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1128 ac_prev=mandir ;;
1129 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1c710c3c 1130 mandir=$ac_optarg ;;
671aa708
NN
1131
1132 -nfp | --nfp | --nf)
1133 # Obsolete; use --without-fp.
1134 with_fp=no ;;
1135
1136 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1c710c3c 1137 | --no-cr | --no-c | -n)
671aa708
NN
1138 no_create=yes ;;
1139
1140 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1141 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1142 no_recursion=yes ;;
1143
1144 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1145 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1146 | --oldin | --oldi | --old | --ol | --o)
1147 ac_prev=oldincludedir ;;
1148 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1149 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1150 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1c710c3c 1151 oldincludedir=$ac_optarg ;;
671aa708
NN
1152
1153 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1154 ac_prev=prefix ;;
1155 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1c710c3c 1156 prefix=$ac_optarg ;;
671aa708
NN
1157
1158 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1159 | --program-pre | --program-pr | --program-p)
1160 ac_prev=program_prefix ;;
1161 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1162 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1c710c3c 1163 program_prefix=$ac_optarg ;;
671aa708
NN
1164
1165 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1166 | --program-suf | --program-su | --program-s)
1167 ac_prev=program_suffix ;;
1168 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1169 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1c710c3c 1170 program_suffix=$ac_optarg ;;
671aa708
NN
1171
1172 -program-transform-name | --program-transform-name \
1173 | --program-transform-nam | --program-transform-na \
1174 | --program-transform-n | --program-transform- \
1175 | --program-transform | --program-transfor \
1176 | --program-transfo | --program-transf \
1177 | --program-trans | --program-tran \
1178 | --progr-tra | --program-tr | --program-t)
1179 ac_prev=program_transform_name ;;
1180 -program-transform-name=* | --program-transform-name=* \
1181 | --program-transform-nam=* | --program-transform-na=* \
1182 | --program-transform-n=* | --program-transform-=* \
1183 | --program-transform=* | --program-transfor=* \
1184 | --program-transfo=* | --program-transf=* \
1185 | --program-trans=* | --program-tran=* \
1186 | --progr-tra=* | --program-tr=* | --program-t=*)
1c710c3c 1187 program_transform_name=$ac_optarg ;;
671aa708 1188
5213506e
RW
1189 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1190 ac_prev=pdfdir ;;
1191 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1192 pdfdir=$ac_optarg ;;
1193
1194 -psdir | --psdir | --psdi | --psd | --ps)
1195 ac_prev=psdir ;;
1196 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1197 psdir=$ac_optarg ;;
1198
671aa708
NN
1199 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1200 | -silent | --silent | --silen | --sile | --sil)
1201 silent=yes ;;
1202
1203 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1204 ac_prev=sbindir ;;
1205 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1206 | --sbi=* | --sb=*)
1c710c3c 1207 sbindir=$ac_optarg ;;
671aa708
NN
1208
1209 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1210 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1211 | --sharedst | --shareds | --shared | --share | --shar \
1212 | --sha | --sh)
1213 ac_prev=sharedstatedir ;;
1214 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1215 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1216 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1217 | --sha=* | --sh=*)
1c710c3c 1218 sharedstatedir=$ac_optarg ;;
671aa708
NN
1219
1220 -site | --site | --sit)
1221 ac_prev=site ;;
1222 -site=* | --site=* | --sit=*)
1c710c3c 1223 site=$ac_optarg ;;
671aa708
NN
1224
1225 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1226 ac_prev=srcdir ;;
1227 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1c710c3c 1228 srcdir=$ac_optarg ;;
671aa708
NN
1229
1230 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1231 | --syscon | --sysco | --sysc | --sys | --sy)
1232 ac_prev=sysconfdir ;;
1233 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1234 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1c710c3c 1235 sysconfdir=$ac_optarg ;;
671aa708
NN
1236
1237 -target | --target | --targe | --targ | --tar | --ta | --t)
1c710c3c 1238 ac_prev=target_alias ;;
671aa708 1239 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1c710c3c 1240 target_alias=$ac_optarg ;;
671aa708
NN
1241
1242 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1243 verbose=yes ;;
1244
1c710c3c
DJ
1245 -version | --version | --versio | --versi | --vers | -V)
1246 ac_init_version=: ;;
671aa708
NN
1247
1248 -with-* | --with-*)
5213506e 1249 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
671aa708 1250 # Reject names that are not valid shell variable names.
5213506e 1251 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1252 as_fn_error $? "invalid package name: $ac_useropt"
5213506e
RW
1253 ac_useropt_orig=$ac_useropt
1254 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1255 case $ac_user_opts in
1256 *"
1257"with_$ac_useropt"
1258"*) ;;
1259 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1260 ac_unrecognized_sep=', ';;
2aeb72e9 1261 esac
5213506e 1262 eval with_$ac_useropt=\$ac_optarg ;;
671aa708
NN
1263
1264 -without-* | --without-*)
5213506e 1265 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
671aa708 1266 # Reject names that are not valid shell variable names.
5213506e 1267 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
22e05272 1268 as_fn_error $? "invalid package name: $ac_useropt"
5213506e
RW
1269 ac_useropt_orig=$ac_useropt
1270 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1271 case $ac_user_opts in
1272 *"
1273"with_$ac_useropt"
1274"*) ;;
1275 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1276 ac_unrecognized_sep=', ';;
1277 esac
1278 eval with_$ac_useropt=no ;;
671aa708
NN
1279
1280 --x)
1281 # Obsolete; use --with-x.
1282 with_x=yes ;;
1283
1284 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1285 | --x-incl | --x-inc | --x-in | --x-i)
1286 ac_prev=x_includes ;;
1287 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1288 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1c710c3c 1289 x_includes=$ac_optarg ;;
671aa708
NN
1290
1291 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1292 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1293 ac_prev=x_libraries ;;
1294 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1295 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1c710c3c 1296 x_libraries=$ac_optarg ;;
671aa708 1297
22e05272
JM
1298 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1299Try \`$0 --help' for more information"
671aa708
NN
1300 ;;
1301
1c710c3c
DJ
1302 *=*)
1303 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1304 # Reject names that are not valid shell variable names.
5213506e
RW
1305 case $ac_envvar in #(
1306 '' | [0-9]* | *[!_$as_cr_alnum]* )
22e05272 1307 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
5213506e
RW
1308 esac
1309 eval $ac_envvar=\$ac_optarg
1c710c3c
DJ
1310 export $ac_envvar ;;
1311
671aa708 1312 *)
1c710c3c 1313 # FIXME: should be removed in autoconf 3.0.
5213506e 1314 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1c710c3c 1315 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
5213506e 1316 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
22e05272 1317 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
671aa708
NN
1318 ;;
1319
1320 esac
1321done
1322
1323if test -n "$ac_prev"; then
1c710c3c 1324 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
22e05272 1325 as_fn_error $? "missing argument to $ac_option"
af71363e 1326fi
af71363e 1327
5213506e
RW
1328if test -n "$ac_unrecognized_opts"; then
1329 case $enable_option_checking in
1330 no) ;;
22e05272 1331 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
5213506e 1332 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2aeb72e9 1333 esac
5213506e 1334fi
2aeb72e9 1335
5213506e
RW
1336# Check all directory arguments for consistency.
1337for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1338 datadir sysconfdir sharedstatedir localstatedir includedir \
1339 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1340 libdir localedir mandir
2aeb72e9 1341do
5213506e
RW
1342 eval ac_val=\$$ac_var
1343 # Remove trailing slashes.
1344 case $ac_val in
1345 */ )
1346 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1347 eval $ac_var=\$ac_val;;
1348 esac
1349 # Be sure to have absolute directory names.
2aeb72e9 1350 case $ac_val in
5213506e
RW
1351 [\\/$]* | ?:[\\/]* ) continue;;
1352 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
671aa708 1353 esac
22e05272 1354 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
671aa708
NN
1355done
1356
1c710c3c
DJ
1357# There might be people who depend on the old broken behavior: `$host'
1358# used to hold the argument of --host etc.
1359# FIXME: To remove some day.
1360build=$build_alias
1361host=$host_alias
1362target=$target_alias
0b0dc272 1363
1c710c3c
DJ
1364# FIXME: To remove some day.
1365if test "x$host_alias" != x; then
1366 if test "x$build_alias" = x; then
1367 cross_compiling=maybe
1c710c3c
DJ
1368 elif test "x$build_alias" != "x$host_alias"; then
1369 cross_compiling=yes
1370 fi
1371fi
1372
1373ac_tool_prefix=
1374test -n "$host_alias" && ac_tool_prefix=$host_alias-
1375
1376test "$silent" = yes && exec 6>/dev/null
671aa708 1377
671aa708 1378
5213506e
RW
1379ac_pwd=`pwd` && test -n "$ac_pwd" &&
1380ac_ls_di=`ls -di .` &&
1381ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
22e05272 1382 as_fn_error $? "working directory cannot be determined"
5213506e 1383test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
22e05272 1384 as_fn_error $? "pwd does not report name of working directory"
5213506e
RW
1385
1386
671aa708
NN
1387# Find the source files, if location was not specified.
1388if test -z "$srcdir"; then
1389 ac_srcdir_defaulted=yes
5213506e
RW
1390 # Try the directory containing this script, then the parent directory.
1391 ac_confdir=`$as_dirname -- "$as_myself" ||
1392$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1393 X"$as_myself" : 'X\(//\)[^/]' \| \
1394 X"$as_myself" : 'X\(//\)$' \| \
1395 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1396$as_echo X"$as_myself" |
1397 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1398 s//\1/
1399 q
1400 }
1401 /^X\(\/\/\)[^/].*/{
1402 s//\1/
1403 q
1404 }
1405 /^X\(\/\/\)$/{
1406 s//\1/
1407 q
1408 }
1409 /^X\(\/\).*/{
1410 s//\1/
1411 q
1412 }
1413 s/.*/./; q'`
671aa708 1414 srcdir=$ac_confdir
5213506e 1415 if test ! -r "$srcdir/$ac_unique_file"; then
671aa708
NN
1416 srcdir=..
1417 fi
1418else
1419 ac_srcdir_defaulted=no
1420fi
5213506e
RW
1421if test ! -r "$srcdir/$ac_unique_file"; then
1422 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
22e05272 1423 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
5213506e
RW
1424fi
1425ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1426ac_abs_confdir=`(
22e05272 1427 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
5213506e
RW
1428 pwd)`
1429# When building in place, set srcdir=.
1430if test "$ac_abs_confdir" = "$ac_pwd"; then
1431 srcdir=.
1432fi
1433# Remove unnecessary trailing slashes from srcdir.
1434# Double slashes in file names in object file debugging info
1435# mess up M-x gdb in Emacs.
1436case $srcdir in
1437*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1438esac
87841584
AM
1439case $srcdir in
1440 *" "*)
22e05272 1441 as_fn_error $? "path to source, $srcdir, contains spaces"
87841584
AM
1442 ;;
1443esac
ac9e6043
RW
1444ac_subdirs_all=`cd $srcdir && echo */configure | sed 's,/configure,,g'`
1445
5213506e
RW
1446for ac_var in $ac_precious_vars; do
1447 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1448 eval ac_env_${ac_var}_value=\$${ac_var}
1449 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1450 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1451done
1c710c3c
DJ
1452
1453#
1454# Report the --help message.
1455#
1456if test "$ac_init_help" = "long"; then
1457 # Omit some internal or obsolete options to make the list less imposing.
1458 # This message is too long to be a string in the A/UX 3.1 sh.
1459 cat <<_ACEOF
1460\`configure' configures this package to adapt to many kinds of systems.
1461
1462Usage: $0 [OPTION]... [VAR=VALUE]...
1463
1464To assign environment variables (e.g., CC, CFLAGS...), specify them as
1465VAR=VALUE. See below for descriptions of some of the useful variables.
1466
1467Defaults for the options are specified in brackets.
1468
1469Configuration:
1470 -h, --help display this help and exit
1471 --help=short display options specific to this package
1472 --help=recursive display the short help of all the included packages
1473 -V, --version display version information and exit
22e05272 1474 -q, --quiet, --silent do not print \`checking ...' messages
1c710c3c
DJ
1475 --cache-file=FILE cache test results in FILE [disabled]
1476 -C, --config-cache alias for \`--cache-file=config.cache'
1477 -n, --no-create do not create output files
1478 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1479
1c710c3c
DJ
1480Installation directories:
1481 --prefix=PREFIX install architecture-independent files in PREFIX
5213506e 1482 [$ac_default_prefix]
1c710c3c 1483 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
5213506e 1484 [PREFIX]
1c710c3c
DJ
1485
1486By default, \`make install' will install all the files in
1487\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1488an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1489for instance \`--prefix=\$HOME'.
1490
1491For better control, use the options below.
1492
1493Fine tuning of the installation directories:
5213506e
RW
1494 --bindir=DIR user executables [EPREFIX/bin]
1495 --sbindir=DIR system admin executables [EPREFIX/sbin]
1496 --libexecdir=DIR program executables [EPREFIX/libexec]
1497 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1498 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1499 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1500 --libdir=DIR object code libraries [EPREFIX/lib]
1501 --includedir=DIR C header files [PREFIX/include]
1502 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1503 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1504 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1505 --infodir=DIR info documentation [DATAROOTDIR/info]
1506 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1507 --mandir=DIR man documentation [DATAROOTDIR/man]
1508 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1509 --htmldir=DIR html documentation [DOCDIR]
1510 --dvidir=DIR dvi documentation [DOCDIR]
1511 --pdfdir=DIR pdf documentation [DOCDIR]
1512 --psdir=DIR ps documentation [DOCDIR]
1c710c3c
DJ
1513_ACEOF
1514
1515 cat <<\_ACEOF
1516
1517Program names:
1518 --program-prefix=PREFIX prepend PREFIX to installed program names
1519 --program-suffix=SUFFIX append SUFFIX to installed program names
1520 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1521
1522System types:
1523 --build=BUILD configure for building on BUILD [guessed]
1524 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1525 --target=TARGET configure for building compilers for TARGET [HOST]
1526_ACEOF
1527fi
1528
1529if test -n "$ac_init_help"; then
1530
1531 cat <<\_ACEOF
1532
1533Optional Features:
5213506e 1534 --disable-option-checking ignore unrecognized --enable/--with options
1c710c3c
DJ
1535 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1536 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
85c64bbe
BS
1537 --enable-as-accelerator-for=ARG
1538 build as offload target compiler. Specify offload
1539 host triple by ARG
1540 --enable-offload-targets=LIST
1541 enable offloading to devices from comma-separated
1542 LIST of TARGET[=DIR]. Use optional path to find
1543 offload target compiler during the build
fe5bfa67
TB
1544 --enable-offload-defaulted
1545 If enabled, configured but not installed offload compilers and
1546 libgomp plugins are silently ignored. Useful for distribution
1547 compilers where those are in separate optional packages.
1548
21539e2e 1549 --enable-gold[=ARG] build gold [ARG={default,yes,no}]
33e39b66 1550 --enable-ld[=ARG] build ld [ARG={default,yes,no}]
24552056 1551 --enable-gprofng[=ARG] build gprofng [ARG={yes,no}]
324402a0 1552 --enable-compressed-debug-sections={all,gas,gold,ld,none}
78edb32f
L
1553 Enable compressed debug sections for gas, gold or ld
1554 by default
c9884636
ML
1555 --enable-default-compressed-debug-sections-algorithm={zlib,zstd}
1556 Default compression algorithm for
1557 --enable-compressed-debug-sections.
a49d42e8 1558 --enable-year2038 enable support for timestamps past the year 2038
87e6d9dc
TB
1559 --disable-libquadmath do not build libquadmath directory
1560 --disable-libquadmath-support
1561 disable libquadmath support for Fortran
30b74385 1562 --enable-libada build libada directory
1eee94d3 1563 --enable-libgm2 build libgm2 directory
30b74385 1564 --enable-libssp build libssp directory
1873ec0c 1565 --disable-libstdcxx do not build libstdc++-v3 directory
ff3ac0f4 1566 --enable-bootstrap enable bootstrapping [yes if native build]
4a5e71f2
L
1567 --enable-pgo-build[=lto]
1568 enable the PGO build
33ad93b9 1569 --disable-isl-version-check
560d18d3 1570 disable check for isl version
d7f09764 1571 --enable-lto enable link time optimization support
45b3824d
TS
1572 --enable-linker-plugin-configure-flags=FLAGS
1573 additional flags for configuring linker plugins
1574 [none]
1575 --enable-linker-plugin-flags=FLAGS
1576 additional flags for configuring and building linker
1577 plugins [none]
b6cb10af 1578 --enable-host-pie build position independent host executables
cdfee50a 1579 --enable-host-shared build host code as shared libraries
33e39b66
AS
1580 --enable-stage1-languages[=all]
1581 choose additional languages to build during stage1.
1582 Mostly useful for compiler development
43c40f3e
RO
1583 --enable-objc-gc enable use of Boehm's garbage collector with the GNU
1584 Objective-C runtime
318a4e6d 1585 --enable-vtable-verify Enable vtable verification feature
30b74385 1586 --enable-serial-[{host,target,build}-]configure
33e39b66
AS
1587 force sequential configuration of sub-packages for
1588 the host, target or build machine, or all
1589 sub-packages
1590 --enable-maintainer-mode
1591 enable make rules and dependencies not useful (and
1592 sometimes confusing) to the casual installer
1593 --enable-stage1-checking[=all]
1594 choose additional checking for stage1 of the
1595 compiler
1c710c3c
DJ
1596 --enable-werror enable -Werror in bootstrap stage2 and later
1597
1598Optional Packages:
1599 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1600 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1601 --with-build-libsubdir=DIR Directory where to find libraries for build system
a05c2c75 1602 --with-system-zlib use installed libz
407a2c9a
FS
1603 --with-zstd Support zstd compressed debug sections
1604 (default=auto)
33e39b66
AS
1605 --with-mpc=PATH specify prefix directory for installed MPC package.
1606 Equivalent to --with-mpc-include=PATH/include plus
1607 --with-mpc-lib=PATH/lib
1608 --with-mpc-include=PATH specify directory for installed MPC include files
1609 --with-mpc-lib=PATH specify directory for the installed MPC library
30b74385 1610 --with-mpfr=PATH specify prefix directory for installed MPFR package.
33e39b66
AS
1611 Equivalent to --with-mpfr-include=PATH/include plus
1612 --with-mpfr-lib=PATH/lib
1c710c3c 1613 --with-mpfr-include=PATH
30b74385
RW
1614 specify directory for installed MPFR include files
1615 --with-mpfr-lib=PATH specify directory for the installed MPFR library
33e39b66
AS
1616 --with-gmp=PATH specify prefix directory for the installed GMP
1617 package. Equivalent to
1618 --with-gmp-include=PATH/include plus
1619 --with-gmp-lib=PATH/lib
30b74385
RW
1620 --with-gmp-include=PATH specify directory for installed GMP include files
1621 --with-gmp-lib=PATH specify directory for the installed GMP library
0b21f5d3 1622 --with-stage1-libs=LIBS libraries for stage1
aac9103b
TT
1623 --with-static-standard-libraries
1624 use -static-libstdc++ and -static-libgcc
1625 (default=auto)
33e39b66
AS
1626 --with-stage1-ldflags=FLAGS
1627 linker flags for stage1
33e39b66
AS
1628 --with-boot-libs=LIBS libraries for stage2 and later
1629 --with-boot-ldflags=FLAGS
1630 linker flags for stage2 and later
e357a5e0 1631 --with-isl=PATH Specify prefix directory for the installed isl
33e39b66 1632 package. Equivalent to
33ad93b9
RG
1633 --with-isl-include=PATH/include plus
1634 --with-isl-lib=PATH/lib
560d18d3
AK
1635 --with-isl-include=PATH Specify directory for installed isl include files
1636 --with-isl-lib=PATH Specify the directory for the installed isl library
114bf3f1
MK
1637 --with-target-bdw-gc=PATHLIST
1638 specify prefix directory for installed bdw-gc
1639 package. Equivalent to
1640 --with-target-bdw-gc-include=PATH/include plus
1641 --with-target-bdw-gc-lib=PATH/lib
1642 --with-target-bdw-gc-include=PATHLIST
1643 specify directories for installed bdw-gc include
1644 files
1645 --with-target-bdw-gc-lib=PATHLIST
1646 specify directories for installed bdw-gc library
3c36aa6b
JJ
1647 --with-gcc-major-version-only
1648 use only GCC major number in filesystem paths
30b74385 1649 --with-build-sysroot=SYSROOT
1c710c3c 1650 use sysroot as the system root during the build
c8aea42c 1651 --with-debug-prefix-map='A=B C=D ...'
33e39b66
AS
1652 map A to B, C to D ... in debug information
1653 --with-build-config='NAME NAME2...'
1654 use config/NAME.mk build configuration
30b74385 1655 --with-build-time-tools=PATH
1c710c3c 1656 use given path to find target tools during the build
1c710c3c
DJ
1657
1658Some influential environment variables:
1659 CC C compiler command
1660 CFLAGS C compiler flags
1661 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1662 nonstandard directory <lib dir>
5213506e 1663 LIBS libraries to pass to the linker, e.g. -l<library>
22e05272 1664 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
5213506e 1665 you have headers in a nonstandard directory <include dir>
c3a86da9
DJ
1666 CXX C++ compiler command
1667 CXXFLAGS C++ compiler flags
ffedf511
RW
1668 build_configargs
1669 additional configure arguments for build directories
1670 host_configargs
1671 additional configure arguments for host directories
1672 target_configargs
1673 additional configure arguments for target directories
278a7a38
AO
1674 AR AR for the host
1675 AS AS for the host
1676 DLLTOOL DLLTOOL for the host
3b5e8ee4 1677 DSYMUTIL DSYMUTIL for the host
278a7a38
AO
1678 LD LD for the host
1679 LIPO LIPO for the host
1680 NM NM for the host
1681 RANLIB RANLIB for the host
1682 STRIP STRIP for the host
1683 WINDRES WINDRES for the host
901119ae 1684 WINDMC WINDMC for the host
278a7a38
AO
1685 OBJCOPY OBJCOPY for the host
1686 OBJDUMP OBJDUMP for the host
e4a9a572 1687 OTOOL OTOOL for the host
e7a82751 1688 READELF READELF for the host
278a7a38
AO
1689 CC_FOR_TARGET
1690 CC for the target
1691 CXX_FOR_TARGET
1692 CXX for the target
1693 GCC_FOR_TARGET
1694 GCC for the target
278a7a38
AO
1695 GFORTRAN_FOR_TARGET
1696 GFORTRAN for the target
632e2a07
ILT
1697 GOC_FOR_TARGET
1698 GOC for the target
b4c522fa
IB
1699 GDC_FOR_TARGET
1700 GDC for the target
1eee94d3
GM
1701 GM2_FOR_TARGET
1702 GM2 for the target
278a7a38
AO
1703 AR_FOR_TARGET
1704 AR for the target
1705 AS_FOR_TARGET
1706 AS for the target
1707 DLLTOOL_FOR_TARGET
1708 DLLTOOL for the target
3b5e8ee4
IS
1709 DSYMUTIL_FOR_TARGET
1710 DSYMUTIL for the target
278a7a38
AO
1711 LD_FOR_TARGET
1712 LD for the target
1713 LIPO_FOR_TARGET
1714 LIPO for the target
1715 NM_FOR_TARGET
1716 NM for the target
9bccfdf5
AP
1717 OBJCOPY_FOR_TARGET
1718 OBJCOPY for the target
278a7a38
AO
1719 OBJDUMP_FOR_TARGET
1720 OBJDUMP for the target
e4a9a572
IS
1721 OTOOL_FOR_TARGET
1722 OTOOL for the target
278a7a38
AO
1723 RANLIB_FOR_TARGET
1724 RANLIB for the target
e7a82751
RM
1725 READELF_FOR_TARGET
1726 READELF for the target
278a7a38
AO
1727 STRIP_FOR_TARGET
1728 STRIP for the target
1729 WINDRES_FOR_TARGET
1730 WINDRES for the target
901119ae
KT
1731 WINDMC_FOR_TARGET
1732 WINDMC for the target
1c710c3c
DJ
1733
1734Use these variables to override the choices made by `configure' or to help
1735it to find libraries and programs with nonstandard names/locations.
1736
5213506e 1737Report bugs to the package provider.
1c710c3c 1738_ACEOF
5213506e 1739ac_status=$?
1c710c3c
DJ
1740fi
1741
1742if test "$ac_init_help" = "recursive"; then
1743 # If there are subdirs, report their specific --help.
1c710c3c 1744 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
5213506e
RW
1745 test -d "$ac_dir" ||
1746 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1747 continue
1c710c3c
DJ
1748 ac_builddir=.
1749
5213506e
RW
1750case "$ac_dir" in
1751.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1752*)
1753 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1754 # A ".." for each directory in $ac_dir_suffix.
1755 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1756 case $ac_top_builddir_sub in
1757 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1758 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1759 esac ;;
1760esac
1761ac_abs_top_builddir=$ac_pwd
1762ac_abs_builddir=$ac_pwd$ac_dir_suffix
1763# for backward compatibility:
1764ac_top_builddir=$ac_top_build_prefix
1c710c3c
DJ
1765
1766case $srcdir in
5213506e 1767 .) # We are building in place.
1c710c3c 1768 ac_srcdir=.
5213506e
RW
1769 ac_top_srcdir=$ac_top_builddir_sub
1770 ac_abs_top_srcdir=$ac_pwd ;;
1771 [\\/]* | ?:[\\/]* ) # Absolute name.
1c710c3c 1772 ac_srcdir=$srcdir$ac_dir_suffix;
5213506e
RW
1773 ac_top_srcdir=$srcdir
1774 ac_abs_top_srcdir=$srcdir ;;
1775 *) # Relative name.
1776 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1777 ac_top_srcdir=$ac_top_build_prefix$srcdir
1778 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2aeb72e9 1779esac
5213506e
RW
1780ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1781
1782 cd "$ac_dir" || { ac_status=$?; continue; }
1783 # Check for guested configure.
1784 if test -f "$ac_srcdir/configure.gnu"; then
1785 echo &&
1786 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1787 elif test -f "$ac_srcdir/configure"; then
1788 echo &&
1789 $SHELL "$ac_srcdir/configure" --help=recursive
1c710c3c 1790 else
5213506e
RW
1791 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1792 fi || ac_status=$?
1793 cd "$ac_pwd" || { ac_status=$?; break; }
1c710c3c
DJ
1794 done
1795fi
1796
5213506e 1797test -n "$ac_init_help" && exit $ac_status
1c710c3c
DJ
1798if $ac_init_version; then
1799 cat <<\_ACEOF
5213506e 1800configure
22e05272 1801generated by GNU Autoconf 2.69
1c710c3c 1802
22e05272 1803Copyright (C) 2012 Free Software Foundation, Inc.
1c710c3c
DJ
1804This configure script is free software; the Free Software Foundation
1805gives unlimited permission to copy, distribute and modify it.
1806_ACEOF
5213506e 1807 exit
0b0dc272 1808fi
5213506e
RW
1809
1810## ------------------------ ##
1811## Autoconf initialization. ##
1812## ------------------------ ##
1813
1814# ac_fn_c_try_compile LINENO
1815# --------------------------
1816# Try to compile conftest.$ac_ext, and return whether this succeeded.
1817ac_fn_c_try_compile ()
1818{
1819 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1820 rm -f conftest.$ac_objext
1821 if { { ac_try="$ac_compile"
1822case "(($ac_try" in
1823 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1824 *) ac_try_echo=$ac_try;;
1825esac
1826eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1827$as_echo "$ac_try_echo"; } >&5
1828 (eval "$ac_compile") 2>conftest.err
1829 ac_status=$?
1830 if test -s conftest.err; then
1831 grep -v '^ *+' conftest.err >conftest.er1
1832 cat conftest.er1 >&5
1833 mv -f conftest.er1 conftest.err
1834 fi
1835 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1836 test $ac_status = 0; } && {
1837 test -z "$ac_c_werror_flag" ||
1838 test ! -s conftest.err
1839 } && test -s conftest.$ac_objext; then :
1840 ac_retval=0
1841else
1842 $as_echo "$as_me: failed program was:" >&5
1843sed 's/^/| /' conftest.$ac_ext >&5
1844
1845 ac_retval=1
1846fi
22e05272
JM
1847 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1848 as_fn_set_status $ac_retval
5213506e
RW
1849
1850} # ac_fn_c_try_compile
1851
1852# ac_fn_cxx_try_compile LINENO
1853# ----------------------------
1854# Try to compile conftest.$ac_ext, and return whether this succeeded.
1855ac_fn_cxx_try_compile ()
1856{
1857 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1858 rm -f conftest.$ac_objext
1859 if { { ac_try="$ac_compile"
1860case "(($ac_try" in
1861 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1862 *) ac_try_echo=$ac_try;;
1863esac
1864eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1865$as_echo "$ac_try_echo"; } >&5
1866 (eval "$ac_compile") 2>conftest.err
1867 ac_status=$?
1868 if test -s conftest.err; then
1869 grep -v '^ *+' conftest.err >conftest.er1
1870 cat conftest.er1 >&5
1871 mv -f conftest.er1 conftest.err
1872 fi
1873 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1874 test $ac_status = 0; } && {
1875 test -z "$ac_cxx_werror_flag" ||
1876 test ! -s conftest.err
1877 } && test -s conftest.$ac_objext; then :
1878 ac_retval=0
1879else
1880 $as_echo "$as_me: failed program was:" >&5
1881sed 's/^/| /' conftest.$ac_ext >&5
1882
1883 ac_retval=1
1884fi
22e05272
JM
1885 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1886 as_fn_set_status $ac_retval
5213506e
RW
1887
1888} # ac_fn_cxx_try_compile
1889
0b21f5d3
EB
1890# ac_fn_cxx_try_link LINENO
1891# -------------------------
1892# Try to link conftest.$ac_ext, and return whether this succeeded.
1893ac_fn_cxx_try_link ()
1894{
1895 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1896 rm -f conftest.$ac_objext conftest$ac_exeext
1897 if { { ac_try="$ac_link"
1898case "(($ac_try" in
1899 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1900 *) ac_try_echo=$ac_try;;
1901esac
1902eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1903$as_echo "$ac_try_echo"; } >&5
1904 (eval "$ac_link") 2>conftest.err
1905 ac_status=$?
1906 if test -s conftest.err; then
1907 grep -v '^ *+' conftest.err >conftest.er1
1908 cat conftest.er1 >&5
1909 mv -f conftest.er1 conftest.err
1910 fi
1911 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1912 test $ac_status = 0; } && {
1913 test -z "$ac_cxx_werror_flag" ||
1914 test ! -s conftest.err
1915 } && test -s conftest$ac_exeext && {
1916 test "$cross_compiling" = yes ||
22e05272 1917 test -x conftest$ac_exeext
0b21f5d3
EB
1918 }; then :
1919 ac_retval=0
1920else
1921 $as_echo "$as_me: failed program was:" >&5
1922sed 's/^/| /' conftest.$ac_ext >&5
1923
1924 ac_retval=1
1925fi
1926 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1927 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1928 # interfere with the next link command; also delete a directory that is
1929 # left behind by Apple's compiler. We do this before executing the actions.
1930 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
22e05272
JM
1931 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1932 as_fn_set_status $ac_retval
0b21f5d3
EB
1933
1934} # ac_fn_cxx_try_link
1935
5213506e
RW
1936# ac_fn_c_try_link LINENO
1937# -----------------------
1938# Try to link conftest.$ac_ext, and return whether this succeeded.
1939ac_fn_c_try_link ()
1940{
1941 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1942 rm -f conftest.$ac_objext conftest$ac_exeext
1943 if { { ac_try="$ac_link"
1944case "(($ac_try" in
1945 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1946 *) ac_try_echo=$ac_try;;
1947esac
1948eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1949$as_echo "$ac_try_echo"; } >&5
1950 (eval "$ac_link") 2>conftest.err
1951 ac_status=$?
1952 if test -s conftest.err; then
1953 grep -v '^ *+' conftest.err >conftest.er1
1954 cat conftest.er1 >&5
1955 mv -f conftest.er1 conftest.err
1956 fi
1957 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1958 test $ac_status = 0; } && {
1959 test -z "$ac_c_werror_flag" ||
1960 test ! -s conftest.err
1961 } && test -s conftest$ac_exeext && {
1962 test "$cross_compiling" = yes ||
22e05272 1963 test -x conftest$ac_exeext
5213506e
RW
1964 }; then :
1965 ac_retval=0
1966else
1967 $as_echo "$as_me: failed program was:" >&5
1968sed 's/^/| /' conftest.$ac_ext >&5
1969
1970 ac_retval=1
1971fi
1972 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1973 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1974 # interfere with the next link command; also delete a directory that is
1975 # left behind by Apple's compiler. We do this before executing the actions.
1976 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
22e05272
JM
1977 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1978 as_fn_set_status $ac_retval
5213506e
RW
1979
1980} # ac_fn_c_try_link
1981cat >config.log <<_ACEOF
1c710c3c
DJ
1982This file contains any messages produced by compilers while
1983running configure, to aid debugging if configure makes a mistake.
1984
1985It was created by $as_me, which was
22e05272 1986generated by GNU Autoconf 2.69. Invocation command line was
1c710c3c
DJ
1987
1988 $ $0 $@
1989
1990_ACEOF
5213506e 1991exec 5>>config.log
1c710c3c
DJ
1992{
1993cat <<_ASUNAME
1994## --------- ##
1995## Platform. ##
1996## --------- ##
1997
1998hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1999uname -m = `(uname -m) 2>/dev/null || echo unknown`
2000uname -r = `(uname -r) 2>/dev/null || echo unknown`
2001uname -s = `(uname -s) 2>/dev/null || echo unknown`
2002uname -v = `(uname -v) 2>/dev/null || echo unknown`
2003
2004/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2005/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2006
2007/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2008/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2009/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
5213506e 2010/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
1c710c3c
DJ
2011/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2012/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2013/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2014
2015_ASUNAME
2016
2017as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2018for as_dir in $PATH
2019do
2020 IFS=$as_save_IFS
2021 test -z "$as_dir" && as_dir=.
5213506e
RW
2022 $as_echo "PATH: $as_dir"
2023 done
2024IFS=$as_save_IFS
1c710c3c
DJ
2025
2026} >&5
2027
2028cat >&5 <<_ACEOF
2029
2030
2031## ----------- ##
2032## Core tests. ##
2033## ----------- ##
2034
2035_ACEOF
2036
2037
2038# Keep a trace of the command line.
2039# Strip out --no-create and --no-recursion so they do not pile up.
2040# Strip out --silent because we don't want to record it for future runs.
2041# Also quote any args containing shell meta-characters.
2042# Make two passes to allow for proper duplicate-argument suppression.
2043ac_configure_args=
2044ac_configure_args0=
2045ac_configure_args1=
1c710c3c
DJ
2046ac_must_keep_next=false
2047for ac_pass in 1 2
2048do
2049 for ac_arg
2050 do
2051 case $ac_arg in
2052 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2053 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2054 | -silent | --silent | --silen | --sile | --sil)
2055 continue ;;
5213506e
RW
2056 *\'*)
2057 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1c710c3c
DJ
2058 esac
2059 case $ac_pass in
5213506e 2060 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
1c710c3c 2061 2)
5213506e 2062 as_fn_append ac_configure_args1 " '$ac_arg'"
1c710c3c
DJ
2063 if test $ac_must_keep_next = true; then
2064 ac_must_keep_next=false # Got value, back to normal.
2065 else
2066 case $ac_arg in
2067 *=* | --config-cache | -C | -disable-* | --disable-* \
2068 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2069 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2070 | -with-* | --with-* | -without-* | --without-* | --x)
2071 case "$ac_configure_args0 " in
2072 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2073 esac
2074 ;;
2075 -* ) ac_must_keep_next=true ;;
2076 esac
2077 fi
5213506e 2078 as_fn_append ac_configure_args " '$ac_arg'"
1c710c3c
DJ
2079 ;;
2080 esac
2081 done
2082done
5213506e
RW
2083{ ac_configure_args0=; unset ac_configure_args0;}
2084{ ac_configure_args1=; unset ac_configure_args1;}
1c710c3c
DJ
2085
2086# When interrupted or exit'd, cleanup temporary files, and complete
2087# config.log. We remove comments because anyway the quotes in there
2088# would cause problems or look ugly.
5213506e
RW
2089# WARNING: Use '\'' to represent an apostrophe within the trap.
2090# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1c710c3c
DJ
2091trap 'exit_status=$?
2092 # Save into config.log some information that might help in debugging.
2093 {
2094 echo
2095
22e05272 2096 $as_echo "## ---------------- ##
1c710c3c 2097## Cache variables. ##
22e05272 2098## ---------------- ##"
1c710c3c
DJ
2099 echo
2100 # The following way of writing the cache mishandles newlines in values,
5213506e
RW
2101(
2102 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2103 eval ac_val=\$$ac_var
2104 case $ac_val in #(
2105 *${as_nl}*)
2106 case $ac_var in #(
2107 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2108$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2109 esac
2110 case $ac_var in #(
2111 _ | IFS | as_nl) ;; #(
2112 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2113 *) { eval $ac_var=; unset $ac_var;} ;;
2114 esac ;;
2115 esac
2116 done
1c710c3c 2117 (set) 2>&1 |
5213506e
RW
2118 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2119 *${as_nl}ac_space=\ *)
1c710c3c 2120 sed -n \
5213506e
RW
2121 "s/'\''/'\''\\\\'\'''\''/g;
2122 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2123 ;; #(
1c710c3c 2124 *)
5213506e 2125 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1c710c3c 2126 ;;
5213506e
RW
2127 esac |
2128 sort
2129)
1c710c3c
DJ
2130 echo
2131
22e05272 2132 $as_echo "## ----------------- ##
1c710c3c 2133## Output variables. ##
22e05272 2134## ----------------- ##"
1c710c3c
DJ
2135 echo
2136 for ac_var in $ac_subst_vars
2137 do
5213506e
RW
2138 eval ac_val=\$$ac_var
2139 case $ac_val in
2140 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2141 esac
2142 $as_echo "$ac_var='\''$ac_val'\''"
1c710c3c
DJ
2143 done | sort
2144 echo
2145
2146 if test -n "$ac_subst_files"; then
22e05272 2147 $as_echo "## ------------------- ##
5213506e 2148## File substitutions. ##
22e05272 2149## ------------------- ##"
1c710c3c
DJ
2150 echo
2151 for ac_var in $ac_subst_files
2152 do
5213506e
RW
2153 eval ac_val=\$$ac_var
2154 case $ac_val in
2155 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2156 esac
2157 $as_echo "$ac_var='\''$ac_val'\''"
1c710c3c
DJ
2158 done | sort
2159 echo
2160 fi
2161
2162 if test -s confdefs.h; then
22e05272 2163 $as_echo "## ----------- ##
1c710c3c 2164## confdefs.h. ##
22e05272 2165## ----------- ##"
1c710c3c 2166 echo
5213506e 2167 cat confdefs.h
1c710c3c
DJ
2168 echo
2169 fi
2170 test "$ac_signal" != 0 &&
5213506e
RW
2171 $as_echo "$as_me: caught signal $ac_signal"
2172 $as_echo "$as_me: exit $exit_status"
1c710c3c 2173 } >&5
5213506e
RW
2174 rm -f core *.core core.conftest.* &&
2175 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1c710c3c 2176 exit $exit_status
5213506e 2177' 0
1c710c3c 2178for ac_signal in 1 2 13 15; do
5213506e 2179 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
1c710c3c
DJ
2180done
2181ac_signal=0
2182
2183# confdefs.h avoids OS command line length limits that DEFS can exceed.
5213506e
RW
2184rm -f -r conftest* confdefs.h
2185
2186$as_echo "/* confdefs.h */" > confdefs.h
1c710c3c
DJ
2187
2188# Predefined preprocessor variables.
2189
2190cat >>confdefs.h <<_ACEOF
2191#define PACKAGE_NAME "$PACKAGE_NAME"
2192_ACEOF
2193
1c710c3c
DJ
2194cat >>confdefs.h <<_ACEOF
2195#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2196_ACEOF
2197
1c710c3c
DJ
2198cat >>confdefs.h <<_ACEOF
2199#define PACKAGE_VERSION "$PACKAGE_VERSION"
2200_ACEOF
0b0dc272 2201
1c710c3c
DJ
2202cat >>confdefs.h <<_ACEOF
2203#define PACKAGE_STRING "$PACKAGE_STRING"
2204_ACEOF
2205
1c710c3c
DJ
2206cat >>confdefs.h <<_ACEOF
2207#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2208_ACEOF
2209
5213506e
RW
2210cat >>confdefs.h <<_ACEOF
2211#define PACKAGE_URL "$PACKAGE_URL"
2212_ACEOF
2213
1c710c3c
DJ
2214
2215# Let the site file select an alternate cache file if it wants to.
5213506e
RW
2216# Prefer an explicitly selected file to automatically selected ones.
2217ac_site_file1=NONE
2218ac_site_file2=NONE
2219if test -n "$CONFIG_SITE"; then
22e05272
JM
2220 # We do not want a PATH search for config.site.
2221 case $CONFIG_SITE in #((
2222 -*) ac_site_file1=./$CONFIG_SITE;;
2223 */*) ac_site_file1=$CONFIG_SITE;;
2224 *) ac_site_file1=./$CONFIG_SITE;;
2225 esac
5213506e
RW
2226elif test "x$prefix" != xNONE; then
2227 ac_site_file1=$prefix/share/config.site
2228 ac_site_file2=$prefix/etc/config.site
2229else
2230 ac_site_file1=$ac_default_prefix/share/config.site
2231 ac_site_file2=$ac_default_prefix/etc/config.site
671aa708 2232fi
5213506e
RW
2233for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2234do
2235 test "x$ac_site_file" = xNONE && continue
22e05272 2236 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
5213506e
RW
2237 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2238$as_echo "$as_me: loading site script $ac_site_file" >&6;}
1c710c3c 2239 sed 's/^/| /' "$ac_site_file" >&5
22e05272
JM
2240 . "$ac_site_file" \
2241 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2242$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2243as_fn_error $? "failed to load site script $ac_site_file
2244See \`config.log' for more details" "$LINENO" 5; }
671aa708
NN
2245 fi
2246done
2247
2248if test -r "$cache_file"; then
22e05272
JM
2249 # Some versions of bash will fail to source /dev/null (special files
2250 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2251 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
5213506e
RW
2252 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2253$as_echo "$as_me: loading cache $cache_file" >&6;}
1c710c3c 2254 case $cache_file in
5213506e
RW
2255 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2256 *) . "./$cache_file";;
1c710c3c
DJ
2257 esac
2258 fi
671aa708 2259else
5213506e
RW
2260 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2261$as_echo "$as_me: creating cache $cache_file" >&6;}
1c710c3c
DJ
2262 >$cache_file
2263fi
2264
2265# Check that the precious variables saved in the cache have kept the same
2266# value.
2267ac_cache_corrupted=false
5213506e 2268for ac_var in $ac_precious_vars; do
1c710c3c
DJ
2269 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2270 eval ac_new_set=\$ac_env_${ac_var}_set
5213506e
RW
2271 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2272 eval ac_new_val=\$ac_env_${ac_var}_value
1c710c3c
DJ
2273 case $ac_old_set,$ac_new_set in
2274 set,)
5213506e
RW
2275 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2276$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1c710c3c
DJ
2277 ac_cache_corrupted=: ;;
2278 ,set)
5213506e
RW
2279 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2280$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1c710c3c
DJ
2281 ac_cache_corrupted=: ;;
2282 ,);;
2283 *)
2284 if test "x$ac_old_val" != "x$ac_new_val"; then
5213506e
RW
2285 # differences in whitespace do not lead to failure.
2286 ac_old_val_w=`echo x $ac_old_val`
2287 ac_new_val_w=`echo x $ac_new_val`
2288 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2289 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2290$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2291 ac_cache_corrupted=:
2292 else
2293 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2294$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2295 eval $ac_var=\$ac_old_val
2296 fi
2297 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2298$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2299 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2300$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
1c710c3c
DJ
2301 fi;;
2302 esac
2303 # Pass precious variables to config.status.
2304 if test "$ac_new_set" = set; then
2305 case $ac_new_val in
5213506e 2306 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1c710c3c
DJ
2307 *) ac_arg=$ac_var=$ac_new_val ;;
2308 esac
2309 case " $ac_configure_args " in
2310 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
5213506e 2311 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
1c710c3c
DJ
2312 esac
2313 fi
2314done
2315if $ac_cache_corrupted; then
5213506e
RW
2316 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2317$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2318 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2319$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
22e05272 2320 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
671aa708 2321fi
5213506e
RW
2322## -------------------- ##
2323## Main body of script. ##
2324## -------------------- ##
671aa708 2325
2aeb72e9
DD
2326ac_ext=c
2327ac_cpp='$CPP $CPPFLAGS'
2328ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2329ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2330ac_compiler_gnu=$ac_cv_c_compiler_gnu
2331
1c710c3c
DJ
2332
2333
2334
1c710c3c
DJ
2335
2336
0115d4a3 2337
1c710c3c 2338
ad33ff57
RW
2339progname=$0
2340# if PWD already has a value, it is probably wrong.
2341if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
2342
2343# Export original configure arguments for use by sub-configures.
2344# Quote arguments with shell meta charatcers.
2345TOPLEVEL_CONFIGURE_ARGUMENTS=
2346set -- "$progname" "$@"
2347for ac_arg
2348do
2349 case "$ac_arg" in
2350 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\']*)
2351 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
2352 # if the argument is of the form -foo=baz, quote the baz part only
2353 ac_arg=`echo "'$ac_arg'" | sed "s/^'\([-a-zA-Z0-9]*=\)/\\1'/"` ;;
2354 *) ;;
2355 esac
2356 # Add the quoted argument to the list.
2357 TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS $ac_arg"
2358done
2359if test "$silent" = yes; then
2360 TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS --silent"
2361fi
2362# Remove the initial space we just introduced and, as these will be
2363# expanded by make, quote '$'.
2364TOPLEVEL_CONFIGURE_ARGUMENTS=`echo "x$TOPLEVEL_CONFIGURE_ARGUMENTS" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
2365
1c710c3c
DJ
2366
2367# Find the build, host, and target systems.
671aa708 2368ac_aux_dir=
5213506e 2369for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
22e05272
JM
2370 if test -f "$ac_dir/install-sh"; then
2371 ac_aux_dir=$ac_dir
2372 ac_install_sh="$ac_aux_dir/install-sh -c"
2373 break
2374 elif test -f "$ac_dir/install.sh"; then
2375 ac_aux_dir=$ac_dir
2376 ac_install_sh="$ac_aux_dir/install.sh -c"
2377 break
2378 elif test -f "$ac_dir/shtool"; then
2379 ac_aux_dir=$ac_dir
2380 ac_install_sh="$ac_aux_dir/shtool install -c"
2381 break
2382 fi
671aa708
NN
2383done
2384if test -z "$ac_aux_dir"; then
22e05272 2385 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
671aa708 2386fi
5213506e
RW
2387
2388# These three variables are undocumented and unsupported,
2389# and are intended to be withdrawn in a future Autoconf release.
2390# They can cause serious problems if a builder's source tree is in a directory
2391# whose full name contains unusual characters.
2392ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2393ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2394ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2395
671aa708 2396
1c710c3c 2397# Make sure we can run config.sub.
5213506e 2398$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
22e05272 2399 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5213506e
RW
2400
2401{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2402$as_echo_n "checking build system type... " >&6; }
22e05272 2403if ${ac_cv_build+:} false; then :
5213506e
RW
2404 $as_echo_n "(cached) " >&6
2405else
2406 ac_build_alias=$build_alias
2407test "x$ac_build_alias" = x &&
2408 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2409test "x$ac_build_alias" = x &&
22e05272 2410 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
5213506e 2411ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
22e05272 2412 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5213506e
RW
2413
2414fi
2415{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2416$as_echo "$ac_cv_build" >&6; }
2417case $ac_cv_build in
2418*-*-*) ;;
22e05272 2419*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
5213506e 2420esac
1c710c3c 2421build=$ac_cv_build
5213506e
RW
2422ac_save_IFS=$IFS; IFS='-'
2423set x $ac_cv_build
2424shift
2425build_cpu=$1
2426build_vendor=$2
2427shift; shift
2428# Remember, the first character of IFS is used to create $*,
2429# except with old shells:
2430build_os=$*
2431IFS=$ac_save_IFS
2432case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
671aa708 2433
671aa708 2434
1c710c3c
DJ
2435 case ${build_alias} in
2436 "") build_noncanonical=${build} ;;
2437 *) build_noncanonical=${build_alias} ;;
af71363e
AS
2438esac
2439
2440
af71363e 2441
1c710c3c
DJ
2442 case ${host_alias} in
2443 "") host_noncanonical=${build_noncanonical} ;;
2444 *) host_noncanonical=${host_alias} ;;
af71363e
AS
2445esac
2446
af71363e 2447
1c710c3c
DJ
2448
2449 case ${target_alias} in
2450 "") target_noncanonical=${host_noncanonical} ;;
2451 *) target_noncanonical=${target_alias} ;;
af71363e
AS
2452esac
2453
af71363e 2454
1c710c3c
DJ
2455
2456
2457test "$host_noncanonical" = "$target_noncanonical" &&
671aa708
NN
2458 test "$program_prefix$program_suffix$program_transform_name" = \
2459 NONENONEs,x,x, &&
1c710c3c 2460 program_transform_name=s,y,y,
af71363e 2461
5213506e
RW
2462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2463$as_echo_n "checking host system type... " >&6; }
22e05272 2464if ${ac_cv_host+:} false; then :
5213506e 2465 $as_echo_n "(cached) " >&6
af71363e 2466else
5213506e
RW
2467 if test "x$host_alias" = x; then
2468 ac_cv_host=$ac_cv_build
2469else
2470 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
22e05272 2471 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5213506e 2472fi
1c710c3c 2473
af71363e 2474fi
5213506e
RW
2475{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2476$as_echo "$ac_cv_host" >&6; }
2477case $ac_cv_host in
2478*-*-*) ;;
22e05272 2479*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
5213506e 2480esac
1c710c3c 2481host=$ac_cv_host
5213506e
RW
2482ac_save_IFS=$IFS; IFS='-'
2483set x $ac_cv_host
2484shift
2485host_cpu=$1
2486host_vendor=$2
2487shift; shift
2488# Remember, the first character of IFS is used to create $*,
2489# except with old shells:
2490host_os=$*
2491IFS=$ac_save_IFS
2492case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2aeb72e9
DD
2493
2494
5213506e
RW
2495{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
2496$as_echo_n "checking target system type... " >&6; }
22e05272 2497if ${ac_cv_target+:} false; then :
5213506e 2498 $as_echo_n "(cached) " >&6
1c710c3c 2499else
5213506e
RW
2500 if test "x$target_alias" = x; then
2501 ac_cv_target=$ac_cv_host
2502else
2503 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
22e05272 2504 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
5213506e 2505fi
1c710c3c
DJ
2506
2507fi
5213506e
RW
2508{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
2509$as_echo "$ac_cv_target" >&6; }
2510case $ac_cv_target in
2511*-*-*) ;;
22e05272 2512*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
5213506e 2513esac
1c710c3c 2514target=$ac_cv_target
5213506e
RW
2515ac_save_IFS=$IFS; IFS='-'
2516set x $ac_cv_target
2517shift
2518target_cpu=$1
2519target_vendor=$2
2520shift; shift
2521# Remember, the first character of IFS is used to create $*,
2522# except with old shells:
2523target_os=$*
2524IFS=$ac_save_IFS
2525case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
1c710c3c
DJ
2526
2527
2528# The aliases save the names the user supplied, while $host etc.
2529# will get canonicalized.
2530test -n "$target_alias" &&
2531 test "$program_prefix$program_suffix$program_transform_name" = \
2532 NONENONEs,x,x, &&
2533 program_prefix=${target_alias}-
5213506e 2534
671aa708 2535test "$program_prefix" != NONE &&
5213506e 2536 program_transform_name="s&^&$program_prefix&;$program_transform_name"
671aa708
NN
2537# Use a double $ so make ignores it.
2538test "$program_suffix" != NONE &&
5213506e
RW
2539 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2540# Double any \ or $.
1c710c3c 2541# By default was `s,x,x', remove it if useless.
5213506e
RW
2542ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2543program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
af71363e 2544
671aa708
NN
2545
2546
775956d0
NN
2547# Get 'install' or 'install-sh' and its variants.
2548# Find a good install program. We prefer a C program (faster),
2549# so one script is as good as another. But avoid the broken or
2550# incompatible versions:
2551# SysV /etc/install, /usr/sbin/install
2552# SunOS /usr/etc/install
2553# IRIX /sbin/install
2554# AIX /bin/install
1c710c3c 2555# AmigaOS /C/install, which installs bootblocks on floppy discs
775956d0
NN
2556# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2557# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2558# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1c710c3c 2559# OS/2's system install, which has a completely different semantic
775956d0 2560# ./install, which can be erroneously created by make from ./install.sh.
38d24731 2561# Reject install programs that cannot install multiple files.
5213506e
RW
2562{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
2563$as_echo_n "checking for a BSD-compatible install... " >&6; }
775956d0 2564if test -z "$INSTALL"; then
22e05272 2565if ${ac_cv_path_install+:} false; then :
5213506e 2566 $as_echo_n "(cached) " >&6
1c710c3c
DJ
2567else
2568 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2569for as_dir in $PATH
2570do
2571 IFS=$as_save_IFS
2572 test -z "$as_dir" && as_dir=.
5213506e
RW
2573 # Account for people who put trailing slashes in PATH elements.
2574case $as_dir/ in #((
2575 ./ | .// | /[cC]/* | \
1c710c3c 2576 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5213506e 2577 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
1c710c3c
DJ
2578 /usr/ucb/* ) ;;
2579 *)
2580 # OSF1 and SCO ODT 3.0 have their own names for install.
2581 # Don't use installbsd from OSF since it installs stuff as root
2582 # by default.
2583 for ac_prog in ginstall scoinst install; do
2584 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 2585 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
775956d0 2586 if test $ac_prog = install &&
1c710c3c 2587 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
775956d0
NN
2588 # AIX install. It has an incompatible calling convention.
2589 :
1c710c3c
DJ
2590 elif test $ac_prog = install &&
2591 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2592 # program-specific install script used by HP pwplus--don't use.
2593 :
775956d0 2594 else
38d24731
RW
2595 rm -rf conftest.one conftest.two conftest.dir
2596 echo one > conftest.one
2597 echo two > conftest.two
2598 mkdir conftest.dir
2599 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
2600 test -s conftest.one && test -s conftest.two &&
2601 test -s conftest.dir/conftest.one &&
2602 test -s conftest.dir/conftest.two
2603 then
2604 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2605 break 3
2606 fi
775956d0
NN
2607 fi
2608 fi
2609 done
1c710c3c
DJ
2610 done
2611 ;;
2612esac
5213506e
RW
2613
2614 done
2615IFS=$as_save_IFS
1c710c3c 2616
38d24731 2617rm -rf conftest.one conftest.two conftest.dir
775956d0
NN
2618
2619fi
2620 if test "${ac_cv_path_install+set}" = set; then
1c710c3c 2621 INSTALL=$ac_cv_path_install
775956d0 2622 else
38d24731
RW
2623 # As a last resort, use the slow shell script. Don't cache a
2624 # value for INSTALL within a source directory, because that will
775956d0 2625 # break other packages using the cache if that directory is
38d24731 2626 # removed, or if the value is a relative name.
1c710c3c 2627 INSTALL=$ac_install_sh
775956d0
NN
2628 fi
2629fi
5213506e
RW
2630{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
2631$as_echo "$INSTALL" >&6; }
775956d0
NN
2632
2633# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2634# It thinks the first close brace ends the variable substitution.
2635test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2636
1c710c3c 2637test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
775956d0
NN
2638
2639test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2640
5213506e
RW
2641{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln works" >&5
2642$as_echo_n "checking whether ln works... " >&6; }
22e05272 2643if ${acx_cv_prog_LN+:} false; then :
5213506e 2644 $as_echo_n "(cached) " >&6
ad6717df
PB
2645else
2646 rm -f conftestdata_t
2647echo >conftestdata_f
2648if ln conftestdata_f conftestdata_t 2>/dev/null
2649then
2650 acx_cv_prog_LN=ln
2651else
2652 acx_cv_prog_LN=no
2653fi
2654rm -f conftestdata_f conftestdata_t
2655
2656fi
2657if test $acx_cv_prog_LN = no; then
2658 LN="cp"
5213506e
RW
2659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN" >&5
2660$as_echo "no, using $LN" >&6; }
ad6717df
PB
2661else
2662 LN="$acx_cv_prog_LN"
5213506e
RW
2663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2664$as_echo "yes" >&6; }
ad6717df
PB
2665fi
2666
5213506e
RW
2667{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
2668$as_echo_n "checking whether ln -s works... " >&6; }
1c710c3c
DJ
2669LN_S=$as_ln_s
2670if test "$LN_S" = "ln -s"; then
5213506e
RW
2671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2672$as_echo "yes" >&6; }
fb0103e5 2673else
5213506e
RW
2674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
2675$as_echo "no, using $LN_S" >&6; }
148907ea
PB
2676fi
2677
87264276
PB
2678{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
2679$as_echo_n "checking for a sed that does not truncate output... " >&6; }
22e05272 2680if ${ac_cv_path_SED+:} false; then :
87264276
PB
2681 $as_echo_n "(cached) " >&6
2682else
2683 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
2684 for ac_i in 1 2 3 4 5 6 7; do
2685 ac_script="$ac_script$as_nl$ac_script"
2686 done
2687 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
2688 { ac_script=; unset ac_script;}
2689 if test -z "$SED"; then
2690 ac_path_SED_found=false
2691 # Loop through the user's path and test for each of PROGNAME-LIST
2692 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2693for as_dir in $PATH
2694do
2695 IFS=$as_save_IFS
2696 test -z "$as_dir" && as_dir=.
2697 for ac_prog in sed gsed; do
2698 for ac_exec_ext in '' $ac_executable_extensions; do
2699 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
22e05272 2700 as_fn_executable_p "$ac_path_SED" || continue
87264276
PB
2701# Check for GNU ac_path_SED and select it if it is found.
2702 # Check for GNU $ac_path_SED
2703case `"$ac_path_SED" --version 2>&1` in
2704*GNU*)
2705 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
2706*)
2707 ac_count=0
2708 $as_echo_n 0123456789 >"conftest.in"
2709 while :
2710 do
2711 cat "conftest.in" "conftest.in" >"conftest.tmp"
2712 mv "conftest.tmp" "conftest.in"
2713 cp "conftest.in" "conftest.nl"
2714 $as_echo '' >> "conftest.nl"
2715 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
2716 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
2717 as_fn_arith $ac_count + 1 && ac_count=$as_val
2718 if test $ac_count -gt ${ac_path_SED_max-0}; then
2719 # Best one so far, save it but keep looking for a better one
2720 ac_cv_path_SED="$ac_path_SED"
2721 ac_path_SED_max=$ac_count
2722 fi
2723 # 10*(2^10) chars as input seems more than enough
2724 test $ac_count -gt 10 && break
2725 done
2726 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
2727esac
2728
2729 $ac_path_SED_found && break 3
2730 done
2731 done
2732 done
2733IFS=$as_save_IFS
2734 if test -z "$ac_cv_path_SED"; then
22e05272 2735 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
87264276
PB
2736 fi
2737else
2738 ac_cv_path_SED=$SED
2739fi
2740
2741fi
2742{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
2743$as_echo "$ac_cv_path_SED" >&6; }
2744 SED="$ac_cv_path_SED"
2745 rm -f conftest.sed
2746
2747for ac_prog in gawk mawk nawk awk
2748do
2749 # Extract the first word of "$ac_prog", so it can be a program name with args.
2750set dummy $ac_prog; ac_word=$2
2751{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2752$as_echo_n "checking for $ac_word... " >&6; }
22e05272 2753if ${ac_cv_prog_AWK+:} false; then :
87264276
PB
2754 $as_echo_n "(cached) " >&6
2755else
2756 if test -n "$AWK"; then
2757 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2758else
2759as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2760for as_dir in $PATH
2761do
2762 IFS=$as_save_IFS
2763 test -z "$as_dir" && as_dir=.
2764 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 2765 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
87264276
PB
2766 ac_cv_prog_AWK="$ac_prog"
2767 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2768 break 2
2769 fi
2770done
2771 done
2772IFS=$as_save_IFS
2773
2774fi
2775fi
2776AWK=$ac_cv_prog_AWK
2777if test -n "$AWK"; then
2778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
2779$as_echo "$AWK" >&6; }
2780else
2781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2782$as_echo "no" >&6; }
2783fi
2784
2785
2786 test -n "$AWK" && break
2787done
2788
775956d0 2789
ee6a22df
L
2790srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
2791
2792# We pass INSTALL explicitly to sub-makes. Make sure that it is not
2793# a relative path.
2794if test "$INSTALL" = "${srcdir}/install-sh -c"; then
2795 INSTALL="${srcpwd}/install-sh -c"
2796fi
2797
671aa708
NN
2798# Set srcdir to "." if that's what it is.
2799# This is important for multilib support.
2800pwd=`${PWDCMD-pwd}`
671aa708
NN
2801if test "${pwd}" = "${srcpwd}" ; then
2802 srcdir=.
79c06341
JL
2803fi
2804
671aa708 2805topsrcdir=$srcpwd
5d4a5ee6 2806
671aa708 2807extra_host_args=
afabd8e6 2808
671aa708
NN
2809### To add a new directory to the tree, first choose whether it is a target
2810### or a host dependent tool. Then put it into the appropriate list
2811### (library or tools, host or target), doing a dependency sort.
79c06341 2812
1c710c3c 2813# Subdirs will be configured in the order listed in build_configdirs,
671aa708 2814# configdirs, or target_configdirs; see the serialization section below.
79c06341 2815
1c710c3c
DJ
2816# Dependency sorting is only needed when *configuration* must be done in
2817# a particular order. In all cases a dependency should be specified in
671aa708 2818# the Makefile, whether or not it's implicitly specified here.
79c06341 2819
671aa708
NN
2820# Double entries in build_configdirs, configdirs, or target_configdirs may
2821# cause circular dependencies and break everything horribly.
79c06341 2822
23f6b2f9
PB
2823# these library is used by various programs built for the build
2824# environment
2825#
929315a9 2826build_libs="build-libiberty build-libcpp"
23f6b2f9
PB
2827
2828# these tools are built for the build environment
85bfb75e 2829build_tools="build-texinfo build-flex build-bison build-m4 build-fixincludes"
23f6b2f9 2830
671aa708 2831# these libraries are used by various programs built for the host environment
eae1a5d4 2832#f
725fb359 2833host_libs="gettext libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libcody libdecnumber gmp mpfr mpc isl libiconv libctf libsframe libgrust "
671aa708 2834
671aa708
NN
2835# these tools are built for the host environment
2836# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
2837# know that we are building the simulator.
2838# binutils, gas and ld appear in that order because it makes sense to run
2839# "make check" in that particular order.
38e3d868 2840# If --enable-gold is used, "gold" may replace "ld".
1eee94d3 2841host_tools="texinfo flex bison binutils gas ld fixincludes gcc cgen sid sim gdb gdbserver gprof etc expect dejagnu m4 utils guile fastjar gnattools libcc1 gm2tools gotools c++tools"
671aa708 2842
671aa708
NN
2843# these libraries are built for the target environment, and are built after
2844# the host libraries and the host tools (which may be a cross compiler)
8499116a 2845# Note that libiberty is not a target library.
291f172e 2846target_libraries="target-libgcc \
eff02e4f 2847 target-libbacktrace \
671aa708
NN
2848 target-libgloss \
2849 target-newlib \
6d3b5aea 2850 target-libgomp \
48310492 2851 target-libatomic \
0a35513e 2852 target-libitm \
cb543528 2853 target-libstdc++-v3 \
f35db108 2854 target-libsanitizer \
2077db1b 2855 target-libvtv \
77008252 2856 target-libssp \
1ec601bf 2857 target-libquadmath \
6de9cd9a 2858 target-libgfortran \
012447ea 2859 target-libffi \
d9cdb878 2860 target-libobjc \
632e2a07 2861 target-libada \
1eee94d3 2862 target-libgm2 \
b4c522fa 2863 target-libgo \
725fb359 2864 target-libgrust \
bb50312e
IB
2865 target-libphobos \
2866 target-zlib"
671aa708 2867
4dbda6f0
NN
2868# these tools are built using the target libraries, and are intended to
2869# run only in the target environment
671aa708 2870#
4dbda6f0 2871# note: any program that *uses* libraries that are in the "target_libraries"
1bcce263 2872# list belongs in this list.
671aa708 2873#
85bfb75e 2874target_tools="target-rda"
79c06341 2875
671aa708 2876################################################################################
79c06341 2877
671aa708
NN
2878## All tools belong in one of the four categories, and are assigned above
2879## We assign ${configdirs} this way to remove all embedded newlines. This
2880## is important because configure will choke if they ever get through.
2881## ${configdirs} is directories we build using the host tools.
2882## ${target_configdirs} is directories we build using the target tools.
671aa708 2883configdirs=`echo ${host_libs} ${host_tools}`
4dbda6f0 2884target_configdirs=`echo ${target_libraries} ${target_tools}`
71b5d516 2885build_configdirs=`echo ${build_libs} ${build_tools}`
8b87bb96 2886
ac9e6043
RW
2887
2888
671aa708 2889################################################################################
79c06341 2890
671aa708 2891srcname="gnu development package"
79c06341 2892
671aa708
NN
2893# This gets set non-empty for some net releases of packages.
2894appdirs=""
79c06341 2895
671aa708
NN
2896# Define is_cross_compiler to save on calls to 'test'.
2897is_cross_compiler=
2898if test x"${host}" = x"${target}" ; then
2899 is_cross_compiler=no
79c06341 2900else
671aa708 2901 is_cross_compiler=yes
1c710c3c 2902fi
79c06341 2903
b4acb5ef 2904# Find the build and target subdir names.
8b87bb96 2905
2e9e6f68
DJ
2906# post-stage1 host modules use a different CC_FOR_BUILD so, in order to
2907# have matching libraries, they should use host libraries: Makefile.tpl
2908# arranges to pass --with-build-libsubdir=$(HOST_SUBDIR).
2909# However, they still use the build modules, because the corresponding
2910# host modules (e.g. bison) are only built for the host when bootstrap
2911# finishes. So:
2912# - build_subdir is where we find build modules, and never changes.
2913# - build_libsubdir is where we find build libraries, and can be overridden.
2914
2915# Prefix 'build-' so this never conflicts with target_subdir.
8b87bb96 2916build_subdir="build-${build_noncanonical}"
1c710c3c 2917
5213506e
RW
2918# Check whether --with-build-libsubdir was given.
2919if test "${with_build_libsubdir+set}" = set; then :
2920 withval=$with_build_libsubdir; build_libsubdir="$withval"
2e9e6f68
DJ
2921else
2922 build_libsubdir="$build_subdir"
5213506e
RW
2923fi
2924
215c351a
PB
2925# --srcdir=. covers the toplevel, while "test -d" covers the subdirectories
2926if ( test $srcdir = . && test -d gcc ) \
2927 || test -d $srcdir/../host-${host_noncanonical}; then
2928 host_subdir="host-${host_noncanonical}"
2929else
2930 host_subdir=.
2931fi
8b87bb96
NN
2932# No prefix.
2933target_subdir=${target_noncanonical}
1c710c3c 2934
0db770bd
RW
2935# Be sure to cover against remnants of an in-tree build.
2936if test $srcdir != . && test -d $srcdir/host-${host_noncanonical}; then
22e05272 2937 as_fn_error $? "building out of tree but $srcdir contains host-${host_noncanonical}.
0db770bd
RW
2938Use a pristine source tree when building in a separate tree" "$LINENO" 5
2939fi
79c06341 2940
671aa708
NN
2941# Skipdirs are removed silently.
2942skipdirs=
2943# Noconfigdirs are removed loudly.
2944noconfigdirs=""
79c06341 2945
671aa708
NN
2946use_gnu_ld=
2947# Make sure we don't let GNU ld be added if we didn't want it.
2948if test x$with_gnu_ld = xno ; then
2949 use_gnu_ld=no
5afab7ad 2950 noconfigdirs="$noconfigdirs ld gold"
79c06341
JL
2951fi
2952
671aa708
NN
2953use_gnu_as=
2954# Make sure we don't let GNU as be added if we didn't want it.
2955if test x$with_gnu_as = xno ; then
2956 use_gnu_as=no
2957 noconfigdirs="$noconfigdirs gas"
79c06341
JL
2958fi
2959
d7f09764 2960use_included_zlib=
a05c2c75
L
2961
2962# Check whether --with-system-zlib was given.
2963if test "${with_system_zlib+set}" = set; then :
2964 withval=$with_system_zlib;
2965fi
2966
d7f09764
DN
2967# Make sure we don't let ZLIB be added if we didn't want it.
2968if test x$with_system_zlib = xyes ; then
2969 use_included_zlib=no
2970 noconfigdirs="$noconfigdirs zlib"
2971fi
2972
36ba9851
ДП
2973# Don't compile the bundled readline/libreadline.a if --with-system-readline
2974# is provided.
2975if test x$with_system_readline = xyes ; then
2976 noconfigdirs="$noconfigdirs readline"
2977fi
2978
407a2c9a
FS
2979
2980# Check whether --with-zstd was given.
2981if test "${with_zstd+set}" = set; then :
2982 withval=$with_zstd;
2983fi
2984
2985
1c710c3c 2986# some tools are so dependent upon X11 that if we're not building with X,
671aa708 2987# it's not even worth trying to configure, much less build, that tool.
79c06341 2988
671aa708
NN
2989case ${with_x} in
2990 yes | "") ;; # the default value for this tree is that X11 is available
2991 no)
b4f96efe 2992 skipdirs="${skipdirs} tk itcl libgui"
671aa708 2993 # We won't be able to build gdbtk without X.
1c710c3c 2994 enable_gdbtk=no
671aa708
NN
2995 ;;
2996 *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
2997esac
79c06341 2998
1bcce263 2999# Some are only suitable for cross toolchains.
671aa708
NN
3000# Remove these if host=target.
3001cross_only="target-libgloss target-newlib target-opcodes"
3002
3003case $is_cross_compiler in
3004 no) skipdirs="${skipdirs} ${cross_only}" ;;
671aa708 3005esac
79c06341 3006
671aa708
NN
3007# If both --with-headers and --with-libs are specified, default to
3008# --without-newlib.
ee6a22df
L
3009if test x"${with_headers}" != x && test x"${with_headers}" != xno \
3010 && test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
671aa708
NN
3011 if test x"${with_newlib}" = x ; then
3012 with_newlib=no
3013 fi
79c06341
JL
3014fi
3015
671aa708
NN
3016# Recognize --with-newlib/--without-newlib.
3017case ${with_newlib} in
3018 no) skipdirs="${skipdirs} target-newlib" ;;
3019 yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
3020esac
79c06341 3021
85c64bbe
BS
3022# Check whether --enable-as-accelerator-for was given.
3023if test "${enable_as_accelerator_for+set}" = set; then :
4b4f2e35 3024 enableval=$enable_as_accelerator_for;
85c64bbe
BS
3025fi
3026
3027
3028# Check whether --enable-offload-targets was given.
3029if test "${enable_offload_targets+set}" = set; then :
3030 enableval=$enable_offload_targets;
3031 if test x"$enable_offload_targets" = x; then
22e05272 3032 as_fn_error $? "no offload targets specified" "$LINENO" 5
85c64bbe
BS
3033 fi
3034
3035else
3036 enable_offload_targets=
3037fi
3038
3039
fe5bfa67
TB
3040# Check whether --enable-offload-defaulted was given.
3041if test "${enable_offload_defaulted+set}" = set; then :
3042 enableval=$enable_offload_defaulted; enable_offload_defaulted=$enableval
3043else
3044 enable_offload_defaulted=
3045fi
3046
3047
21539e2e
MK
3048# Handle --enable-gold, --enable-ld.
3049# --disable-gold [--enable-ld]
3050# Build only ld. Default option.
9580395f
L
3051# --enable-gold [--enable-ld]
3052# Build both gold and ld. Install gold as "ld.gold", install ld
3053# as "ld.bfd" and "ld".
3054# --enable-gold=default [--enable-ld]
21539e2e
MK
3055# Build both gold and ld. Install gold as "ld.gold" and "ld",
3056# install ld as "ld.bfd".
3057# --enable-gold[=default] --disable-ld
3058# Build only gold, which is then installed as both "ld.gold" and "ld".
3059# --enable-gold --enable-ld=default
9580395f
L
3060# Build both gold (installed as "ld.gold") and ld (installed as "ld"
3061# and ld.bfd).
21539e2e
MK
3062# In other words, ld is default
3063# --enable-gold=default --enable-ld=default
3064# Error.
3065
3066default_ld=
5213506e
RW
3067# Check whether --enable-gold was given.
3068if test "${enable_gold+set}" = set; then :
3069 enableval=$enable_gold; ENABLE_GOLD=$enableval
5afab7ad
ILT
3070else
3071 ENABLE_GOLD=no
5213506e
RW
3072fi
3073
21539e2e
MK
3074case "${ENABLE_GOLD}" in
3075 yes|default)
38e3d868
RM
3076 # Check for ELF target.
3077 is_elf=no
3078 case "${target}" in
3079 *-*-elf* | *-*-sysv4* | *-*-unixware* | *-*-eabi* | hppa*64*-*-hpux* \
0e76460f 3080 | *-*-linux* | *-*-gnu* | frv-*-uclinux* | *-*-irix5* | *-*-irix6* \
8c6d158a 3081 | *-*-netbsd* | *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* \
ead5103c 3082 | *-*-solaris2* | *-*-nto* | *-*-nacl* | *-*-haiku*)
38e3d868
RM
3083 case "${target}" in
3084 *-*-linux*aout* | *-*-linux*oldld*)
3085 ;;
3086 *)
3087 is_elf=yes
3088 ;;
3089 esac
3090 esac
3091
3092 if test "$is_elf" = "yes"; then
3093 # Check for target supported by gold.
5afab7ad 3094 case "${target}" in
7705dfd1 3095 i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-* \
f09a9dd3 3096 | aarch64*-*-* | tilegx*-*-* | mips*-*-* | s390*-*-*)
21539e2e
MK
3097 configdirs="$configdirs gold"
3098 if test x${ENABLE_GOLD} = xdefault; then
3099 default_ld=gold
3100 fi
38e3d868 3101 ENABLE_GOLD=yes
5afab7ad
ILT
3102 ;;
3103 esac
38e3d868
RM
3104 fi
3105 ;;
3106 no)
3107 ;;
3108 *)
22e05272 3109 as_fn_error $? "invalid --enable-gold argument" "$LINENO" 5
38e3d868 3110 ;;
21539e2e
MK
3111esac
3112
3113# Check whether --enable-ld was given.
3114if test "${enable_ld+set}" = set; then :
3115 enableval=$enable_ld; ENABLE_LD=$enableval
3116else
3117 ENABLE_LD=yes
3118fi
3119
3120
3121case "${ENABLE_LD}" in
3122 default)
9580395f 3123 if test x${default_ld} != x; then
22e05272 3124 as_fn_error $? "either gold or ld can be the default ld" "$LINENO" 5
21539e2e
MK
3125 fi
3126 ;;
3127 yes)
3128 ;;
3129 no)
3130 if test x${ENABLE_GOLD} != xyes; then
3131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: neither ld nor gold are enabled" >&5
3132$as_echo "$as_me: WARNING: neither ld nor gold are enabled" >&2;}
3133 fi
3134 configdirs=`echo " ${configdirs} " | sed -e 's/ ld / /'`
3135 ;;
3136 *)
22e05272 3137 as_fn_error $? "invalid --enable-ld argument" "$LINENO" 5
21539e2e
MK
3138 ;;
3139esac
5afab7ad 3140
24552056
VM
3141# Check whether --enable-gprofng was given.
3142if test "${enable_gprofng+set}" = set; then :
3143 enableval=$enable_gprofng; enable_gprofng=$enableval
3144else
3145 enable_gprofng=yes
3146fi
3147
3148if test "$enable_gprofng" = "yes"; then
3149 case "${target}" in
3150 x86_64-*-linux* | i?86-*-linux* | aarch64-*-linux*)
3151 configdirs="$configdirs gprofng"
3152 ;;
3153 esac
3154fi
3155
3156
78edb32f
L
3157# PR gas/19109
3158# Decide the default method for compressing debug sections.
3159# Provide a configure time option to override our default.
3160# Check whether --enable-compressed_debug_sections was given.
3161if test "${enable_compressed_debug_sections+set}" = set; then :
3162 enableval=$enable_compressed_debug_sections;
3163 if test x"$enable_compressed_debug_sections" = xyes; then
22e05272 3164 as_fn_error $? "no program with compressed debug sections specified" "$LINENO" 5
78edb32f
L
3165 fi
3166
3167else
3168 enable_compressed_debug_sections=
3169fi
3170
3171
c9884636
ML
3172# Select default compression algorithm.
3173# Check whether --enable-default_compressed_debug_sections_algorithm was given.
3174if test "${enable_default_compressed_debug_sections_algorithm+set}" = set; then :
3175 enableval=$enable_default_compressed_debug_sections_algorithm;
3176else
3177 default_compressed_debug_sections_algorithm=
3178fi
3179
3180
671aa708 3181# Configure extra directories which are host specific
79c06341 3182
671aa708
NN
3183case "${host}" in
3184 *-cygwin*)
3185 configdirs="$configdirs libtermcap" ;;
3186esac
79c06341 3187
4fab7234
HPN
3188# A target can indicate whether a language isn't supported for some reason.
3189# Only spaces may be used in this macro; not newlines or tabs.
3190unsupported_languages=
3191
1c710c3c 3192# Remove more programs from consideration, based on the host or
671aa708
NN
3193# target this usually means that a port of the program doesn't
3194# exist yet.
ec8d6ddc 3195
671aa708 3196case "${host}" in
111eeb6e 3197 i[3456789]86-*-msdosdjgpp*)
c9bdb152 3198 noconfigdirs="$noconfigdirs tcl tk itcl"
671aa708 3199 ;;
671aa708 3200esac
ec8d6ddc 3201
a49d42e8
LM
3202# Default to --disable-year2038 until we can handle differences between
3203# projects that use gnulib (which understands year 2038) and projects that
3204# do not (like BFD).
3205# Check whether --enable-year2038 was given.
3206if test "${enable_year2038+set}" = set; then :
3207 enableval=$enable_year2038; ENABLE_YEAR2038=$enableval
3208else
3209 ENABLE_YEAR2038=no
3210fi
3211
3212enable_year2038=
3213if test "${ENABLE_YEAR2038}" = "no" ; then
3214 enable_year2038=no
3215fi
6de9cd9a 3216
87e6d9dc
TB
3217# Check whether --enable-libquadmath was given.
3218if test "${enable_libquadmath+set}" = set; then :
3219 enableval=$enable_libquadmath; ENABLE_LIBQUADMATH=$enableval
3220else
3221 ENABLE_LIBQUADMATH=yes
3222fi
3223
3224if test "${ENABLE_LIBQUADMATH}" = "no" ; then
3225 noconfigdirs="$noconfigdirs target-libquadmath"
3226fi
3227
3228
3229# Check whether --enable-libquadmath-support was given.
3230if test "${enable_libquadmath_support+set}" = set; then :
3231 enableval=$enable_libquadmath_support; ENABLE_LIBQUADMATH_SUPPORT=$enableval
3232else
3233 ENABLE_LIBQUADMATH_SUPPORT=yes
3234fi
3235
3236enable_libquadmath_support=
3237if test "${ENABLE_LIBQUADMATH_SUPPORT}" = "no" ; then
3238 enable_libquadmath_support=no
3239fi
3240
3241
5213506e
RW
3242# Check whether --enable-libada was given.
3243if test "${enable_libada+set}" = set; then :
3244 enableval=$enable_libada; ENABLE_LIBADA=$enableval
d9cdb878
AC
3245else
3246 ENABLE_LIBADA=yes
5213506e
RW
3247fi
3248
d9cdb878 3249if test "${ENABLE_LIBADA}" != "yes" ; then
5395b47b 3250 noconfigdirs="$noconfigdirs gnattools"
d9cdb878
AC
3251fi
3252
1eee94d3
GM
3253# Check whether --enable-libgm2 was given.
3254if test "${enable_libgm2+set}" = set; then :
3255 enableval=$enable_libgm2; ENABLE_LIBGM2=$enableval
3256else
3257 ENABLE_LIBGM2=no
3258fi
3259
3260if test "${ENABLE_LIBGM2}" != "yes" ; then
3261 noconfigdirs="$noconfigdirs gm2tools"
3262fi
3263
5213506e
RW
3264# Check whether --enable-libssp was given.
3265if test "${enable_libssp+set}" = set; then :
3266 enableval=$enable_libssp; ENABLE_LIBSSP=$enableval
ef0087a7
KH
3267else
3268 ENABLE_LIBSSP=yes
5213506e
RW
3269fi
3270
ef0087a7 3271
1873ec0c
L
3272# Check whether --enable-libstdcxx was given.
3273if test "${enable_libstdcxx+set}" = set; then :
3274 enableval=$enable_libstdcxx; ENABLE_LIBSTDCXX=$enableval
3275else
3276 ENABLE_LIBSTDCXX=default
3277fi
3278
3279if test "${ENABLE_LIBSTDCXX}" = "no" ; then
1007a55c 3280 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1873ec0c
L
3281fi
3282
44a7d18d 3283# Enable libgomp by default on hosted POSIX systems, and a few others.
27079765 3284if test x$enable_libgomp = x ; then
953ff289 3285 case "${target}" in
416ac4d4 3286 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
953ff289 3287 ;;
8c6d158a 3288 *-*-netbsd* | *-*-freebsd* | *-*-openbsd* | *-*-dragonfly*)
953ff289 3289 ;;
b24513a1 3290 *-*-solaris2* | *-*-hpux11*)
953ff289 3291 ;;
cac90078 3292 *-*-darwin* | *-*-aix*)
953ff289 3293 ;;
29b1533a 3294 nvptx*-*-* | amdgcn*-*-*)
44a7d18d 3295 ;;
953ff289
DN
3296 *)
3297 noconfigdirs="$noconfigdirs target-libgomp"
3298 ;;
3299 esac
27079765 3300fi
953ff289 3301
48310492
RH
3302# Disable libatomic on unsupported systems.
3303if test -d ${srcdir}/libatomic; then
3304 if test x$enable_libatomic = x; then
3305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libatomic support" >&5
3306$as_echo_n "checking for libatomic support... " >&6; }
3307 if (srcdir=${srcdir}/libatomic; \
3308 . ${srcdir}/configure.tgt; \
3309 test -n "$UNSUPPORTED")
3310 then
3311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3312$as_echo "no" >&6; }
3313 noconfigdirs="$noconfigdirs target-libatomic"
3314 else
3315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3316$as_echo "yes" >&6; }
3317 fi
3318 fi
3319fi
3320
e948157d
RH
3321# Disable libitm on unsupported systems.
3322if test -d ${srcdir}/libitm; then
3323 if test x$enable_libitm = x; then
3324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libitm support" >&5
01f3428c 3325$as_echo_n "checking for libitm support... " >&6; }
e948157d
RH
3326 if (srcdir=${srcdir}/libitm; \
3327 . ${srcdir}/configure.tgt; \
3328 test -n "$UNSUPPORTED")
3329 then
3330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
01f3428c 3331$as_echo "no" >&6; }
e948157d
RH
3332 noconfigdirs="$noconfigdirs target-libitm"
3333 else
3334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
01f3428c 3335$as_echo "yes" >&6; }
e948157d
RH
3336 fi
3337 fi
0a35513e
AH
3338fi
3339
93bf5390
RH
3340# Disable libsanitizer on unsupported systems.
3341if test -d ${srcdir}/libsanitizer; then
3342 if test x$enable_libsanitizer = x; then
3343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libsanitizer support" >&5
3344$as_echo_n "checking for libsanitizer support... " >&6; }
3345 if (srcdir=${srcdir}/libsanitizer; \
3346 . ${srcdir}/configure.tgt; \
3347 test -n "$UNSUPPORTED")
3348 then
3349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3350$as_echo "no" >&6; }
3351 noconfigdirs="$noconfigdirs target-libsanitizer"
3352 else
3353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3354$as_echo "yes" >&6; }
3355 fi
3356 fi
3357fi
3358
2077db1b
CT
3359# Disable libvtv on unsupported systems.
3360if test -d ${srcdir}/libvtv; then
3361 if test x$enable_libvtv = x; then
3362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libvtv support" >&5
3363$as_echo_n "checking for libvtv support... " >&6; }
3364 if (srcdir=${srcdir}/libvtv; \
3365 . ${srcdir}/configure.tgt; \
1e74b850 3366 test "$VTV_SUPPORTED" != "yes")
2077db1b
CT
3367 then
3368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3369$as_echo "no" >&6; }
3370 noconfigdirs="$noconfigdirs target-libvtv"
3371 else
3372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3373$as_echo "yes" >&6; }
3374 fi
3375 fi
3376fi
3377
d91491e5
SE
3378# Disable libquadmath for some systems.
3379case "${target}" in
e7fae550
DE
3380 avr-*-*)
3381 noconfigdirs="$noconfigdirs target-libquadmath"
3382 ;;
d91491e5
SE
3383 # libquadmath is unused on AIX and libquadmath build process use of
3384 # LD_LIBRARY_PATH can break AIX bootstrap.
3385 powerpc-*-aix* | rs6000-*-aix*)
3386 noconfigdirs="$noconfigdirs target-libquadmath"
3387 ;;
3388esac
3389
1e9e0e23
JM
3390# Disable libssp for some systems.
3391case "${target}" in
3392 avr-*-*)
b318fb4b 3393 # No hosted I/O support.
1e9e0e23
JM
3394 noconfigdirs="$noconfigdirs target-libssp"
3395 ;;
91dfef96
JM
3396 bpf-*-*)
3397 noconfigdirs="$noconfigdirs target-libssp"
3398 ;;
1e9e0e23
JM
3399 powerpc-*-aix* | rs6000-*-aix*)
3400 noconfigdirs="$noconfigdirs target-libssp"
85b8555e 3401 ;;
8d2af3a2
DD
3402 pru-*-*)
3403 # No hosted I/O support.
3404 noconfigdirs="$noconfigdirs target-libssp"
3405 ;;
85b8555e 3406 rl78-*-*)
7cb62ef1
EB
3407 # libssp uses a misaligned load to trigger a fault, but the RL78
3408 # doesn't fault for those - instead, it gives a build-time error
3409 # for explicit misaligned loads.
85b8555e 3410 noconfigdirs="$noconfigdirs target-libssp"
1e9e0e23 3411 ;;
0969ec7d
EB
3412 visium-*-*)
3413 # No hosted I/O support.
3414 noconfigdirs="$noconfigdirs target-libssp"
3415 ;;
1e9e0e23
JM
3416esac
3417
1e9e0e23 3418# Disable libstdc++-v3 for some systems.
67a1cb2a 3419# Allow user to override this if they pass --enable-libstdcxx
1873ec0c
L
3420if test "${ENABLE_LIBSTDCXX}" = "default" ; then
3421 case "${target}" in
3422 *-*-vxworks*)
3423 # VxWorks uses the Dinkumware C++ library.
3424 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3425 ;;
afa3d80e
TS
3426 amdgcn*-*-*)
3427 # Not ported/fails to build when using newlib.
3428 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3429 ;;
1873ec0c
L
3430 arm*-wince-pe*)
3431 # the C++ libraries don't build on top of CE's C libraries
3432 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3433 ;;
3434 avr-*-*)
3435 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3436 ;;
91dfef96
JM
3437 bpf-*-*)
3438 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3439 ;;
fef939d6
JB
3440 ft32-*-*)
3441 noconfigdirs="$noconfigdirs target-libstdc++-v3"
3442 ;;
1873ec0c
L
3443 esac
3444fi
1e9e0e23 3445
91dfef96
JM
3446# Disable C++ on systems where it is known to not work.
3447# For testing, you can override this with --enable-languages=c++.
3448case ,${enable_languages}, in
3449 *,c++,*)
3450 ;;
3451 *)
3452 case "${target}" in
3453 bpf-*-*)
3454 unsupported_languages="$unsupported_languages c++"
3455 ;;
3456 esac
3457 ;;
3458esac
3459
3460# Disable Objc on systems where it is known to not work.
3461# For testing, you can override this with --enable-languages=objc.
3462case ,${enable_languages}, in
3463 *,objc,*)
3464 ;;
3465 *)
3466 case "${target}" in
3467 bpf-*-*)
3468 unsupported_languages="$unsupported_languages objc"
3469 ;;
3470 esac
3471 ;;
3472esac
3473
260eedb9
IB
3474# Disable D on systems where it is known to not work.
3475# For testing, you can override this with --enable-languages=d.
3476case ,${enable_languages}, in
3477 *,d,*)
3478 ;;
3479 *)
3480 case "${target}" in
91dfef96 3481 bpf-*-*)
260eedb9
IB
3482 unsupported_languages="$unsupported_languages d"
3483 ;;
3484 esac
3485 ;;
3486esac
3487
3488# Disable libphobos on unsupported systems.
3489# For testing, you can override this with --enable-libphobos.
3490if test -d ${srcdir}/libphobos; then
3491 if test x$enable_libphobos = x; then
3492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libphobos support" >&5
3493$as_echo_n "checking for libphobos support... " >&6; }
3494 if (srcdir=${srcdir}/libphobos; \
3495 . ${srcdir}/configure.tgt; \
7d31d331 3496 test "$LIBPHOBOS_SUPPORTED" != "yes")
260eedb9
IB
3497 then
3498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3499$as_echo "no" >&6; }
3500 noconfigdirs="$noconfigdirs target-libphobos"
3501 else
3502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3503$as_echo "yes" >&6; }
3504 fi
3505 fi
3506fi
3507
1e9e0e23
JM
3508# Disable Fortran for some systems.
3509case "${target}" in
3510 mmix-*-*)
3511 # See <http://gcc.gnu.org/ml/gcc-patches/2004-11/msg00572.html>.
3512 unsupported_languages="$unsupported_languages fortran"
3513 ;;
91dfef96
JM
3514 bpf-*-*)
3515 unsupported_languages="$unsupported_languages fortran"
3516 ;;
1e9e0e23
JM
3517esac
3518
012447ea
JJ
3519# Disable libffi for some systems.
3520case "${target}" in
3521 powerpc-*-darwin*)
3522 ;;
3523 i[3456789]86-*-darwin*)
3524 ;;
3525 x86_64-*-darwin[912]*)
3526 ;;
3527 *-*-darwin*)
3528 noconfigdirs="$noconfigdirs target-libffi"
3529 ;;
3530 *-*-netware*)
3531 noconfigdirs="$noconfigdirs target-libffi"
3532 ;;
3533 *-*-phoenix*)
3534 noconfigdirs="$noconfigdirs target-libffi"
3535 ;;
3536 *-*-rtems*)
3537 noconfigdirs="$noconfigdirs target-libffi"
3538 ;;
3539 *-*-tpf*)
3540 noconfigdirs="$noconfigdirs target-libffi"
3541 ;;
3542 *-*-uclinux*)
3543 noconfigdirs="$noconfigdirs target-libffi"
3544 ;;
3545 *-*-vxworks*)
3546 noconfigdirs="$noconfigdirs target-libffi"
3547 ;;
b20e7532
AT
3548 aarch64*-*-freebsd*)
3549 noconfigdirs="$noconfigdirs target-libffi"
3550 ;;
012447ea
JJ
3551 alpha*-*-*vms*)
3552 noconfigdirs="$noconfigdirs target-libffi"
3553 ;;
3554 arm*-*-freebsd*)
3555 noconfigdirs="$noconfigdirs target-libffi"
3556 ;;
3557 arm-wince-pe)
3558 noconfigdirs="$noconfigdirs target-libffi"
3559 ;;
3560 arm*-*-symbianelf*)
3561 noconfigdirs="$noconfigdirs target-libffi"
3562 ;;
91dfef96
JM
3563 bpf-*-*)
3564 noconfigdirs="$noconfigdirs target-libffi"
3565 ;;
012447ea
JJ
3566 cris-*-* | crisv32-*-*)
3567 case "${target}" in
3568 *-*-linux*)
3569 ;;
3570 *) # See PR46792 regarding target-libffi.
3571 noconfigdirs="$noconfigdirs target-libffi";;
3572 esac
3573 ;;
3574 hppa*64*-*-hpux*)
3575 noconfigdirs="$noconfigdirs target-libffi"
3576 ;;
b48e9940
AA
3577 hppa*-hp-hpux11*)
3578 ;;
3579 hppa*-*-hpux*)
3580 noconfigdirs="$noconfigdirs target-libffi"
3581 ;;
012447ea
JJ
3582 ia64*-*-*vms*)
3583 noconfigdirs="$noconfigdirs target-libffi"
3584 ;;
3585 i[3456789]86-w64-mingw*)
3586 noconfigdirs="$noconfigdirs target-libffi"
3587 ;;
3588 i[3456789]86-*-mingw*)
3589 noconfigdirs="$noconfigdirs target-libffi"
3590 ;;
3591 x86_64-*-mingw*)
3592 noconfigdirs="$noconfigdirs target-libffi"
3593 ;;
3594 mmix-*-*)
3595 noconfigdirs="$noconfigdirs target-libffi"
3596 ;;
3597 powerpc-*-aix*)
012447ea
JJ
3598 ;;
3599 rs6000-*-aix*)
012447ea
JJ
3600 ;;
3601 ft32-*-*)
3602 noconfigdirs="$noconfigdirs target-libffi"
3603 ;;
3604 *-*-lynxos*)
3605 noconfigdirs="$noconfigdirs target-libffi"
3606 ;;
3607esac
3608
3609# Disable the go frontend on systems where it is known to not work. Please keep
3610# this in sync with contrib/config-list.mk.
3611case "${target}" in
91dfef96 3612*-*-darwin* | *-*-cygwin* | *-*-mingw* | bpf-* )
012447ea
JJ
3613 unsupported_languages="$unsupported_languages go"
3614 ;;
3615esac
3616
f9d09df0
TT
3617# Only allow gdbserver on some systems.
3618if test -d ${srcdir}/gdbserver; then
3619 if test x$enable_gdbserver = x; then
3620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdbserver support" >&5
3621$as_echo_n "checking for gdbserver support... " >&6; }
3622 if (srcdir=${srcdir}/gdbserver; \
3623 . ${srcdir}/configure.srv; \
3624 test -n "$UNSUPPORTED")
3625 then
3626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3627$as_echo "no" >&6; }
3628 noconfigdirs="$noconfigdirs gdbserver"
3629 else
3630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3631$as_echo "yes" >&6; }
3632 fi
3633 fi
3634fi
3635
cdbc9e92
ILT
3636# Disable libgo for some systems where it is known to not work.
3637# For testing, you can easily override this with --enable-libgo.
3638if test x$enable_libgo = x; then
3639 case "${target}" in
3640 *-*-darwin*)
3641 # PR 46986
3642 noconfigdirs="$noconfigdirs target-libgo"
3643 ;;
3644 *-*-cygwin* | *-*-mingw*)
3645 noconfigdirs="$noconfigdirs target-libgo"
3646 ;;
91dfef96
JM
3647 bpf-*-*)
3648 noconfigdirs="$noconfigdirs target-libgo"
3649 ;;
cdbc9e92
ILT
3650 esac
3651fi
3652
c03353e2
RIL
3653# Default libgloss CPU subdirectory.
3654libgloss_dir="$target_cpu"
6de9cd9a 3655
fbcf0dca
JM
3656case "${target}" in
3657 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
3658 libgloss_dir=wince
3659 ;;
4dddfc74
YZ
3660 aarch64*-*-* )
3661 libgloss_dir=aarch64
3662 ;;
fbcf0dca
JM
3663 arm*-*-*)
3664 libgloss_dir=arm
3665 ;;
3666 cris-*-* | crisv32-*-*)
3667 libgloss_dir=cris
3668 ;;
3669 hppa*-*-*)
3670 libgloss_dir=pa
3671 ;;
3672 i[3456789]86-*-*)
3673 libgloss_dir=i386
3674 ;;
c6c0594e 3675 loongarch*-*-*)
3676 libgloss_dir=loongarch
3677 ;;
fbcf0dca
JM
3678 m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
3679 libgloss_dir=m68hc11
3680 ;;
3681 m68*-*-* | fido-*-*)
3682 libgloss_dir=m68k
3683 ;;
3684 mips*-*-*)
3685 libgloss_dir=mips
3686 ;;
3687 powerpc*-*-*)
3688 libgloss_dir=rs6000
3689 ;;
8d2af3a2
DD
3690 pru-*-*)
3691 libgloss_dir=pru
3692 ;;
fbcf0dca
JM
3693 sparc*-*-*)
3694 libgloss_dir=sparc
3695 ;;
3696esac
3697
6a789d5e 3698# Disable newlib and libgloss for various target OSes.
671aa708 3699case "${target}" in
6a789d5e
JM
3700 alpha*-dec-osf*)
3701 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3702 ;;
3703 i[3456789]86-*-linux*)
3704 # This section makes it possible to build newlib natively on linux.
3705 # If we are using a cross compiler then don't configure newlib.
3706 if test x${is_cross_compiler} != xno ; then
3707 noconfigdirs="$noconfigdirs target-newlib"
3708 fi
3709 noconfigdirs="$noconfigdirs target-libgloss"
3710 # If we are not using a cross compiler, do configure newlib.
3711 # Note however, that newlib will only be configured in this situation
3712 # if the --with-newlib option has been given, because otherwise
3713 # 'target-newlib' will appear in skipdirs.
3714 ;;
3715 i[3456789]86-*-rdos*)
3716 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3717 ;;
3718 sh*-*-pe|mips*-*-pe|arm-wince-pe)
3719 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3720 ;;
3721 sparc-*-sunos4*)
3722 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3723 ;;
91dfef96
JM
3724 bpf-*-*)
3725 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3726 ;;
6a789d5e
JM
3727 *-*-aix*)
3728 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3729 ;;
3730 *-*-beos*)
3731 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3732 ;;
671aa708 3733 *-*-chorusos)
0036370f 3734 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
671aa708 3735 ;;
6a789d5e
JM
3736 *-*-dragonfly*)
3737 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3738 ;;
3739 *-*-freebsd*)
3740 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3741 ;;
3742 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
3743 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3744 ;;
3745 *-*-lynxos*)
3746 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3747 ;;
3748 *-*-mingw*)
3749 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3750 ;;
3751 *-*-netbsd*)
3752 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3753 ;;
3754 *-*-netware*)
3755 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3756 ;;
3757 *-*-tpf*)
3758 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3759 ;;
3760 *-*-uclinux*)
3761 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3762 ;;
3763 *-*-vxworks*)
3764 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3765 ;;
3766esac
3767
3768case "${target}" in
3769 *-*-chorusos)
3770 ;;
3be96231
TG
3771 aarch64-*-darwin*)
3772 noconfigdirs="$noconfigdirs ld gas gdb gprof"
3773 noconfigdirs="$noconfigdirs sim target-rda"
3774 ;;
7431c1a1
AS
3775 amdgcn*-*-*)
3776 ;;
3be96231
TG
3777 arm-*-darwin*)
3778 noconfigdirs="$noconfigdirs ld gas gdb gprof"
3779 noconfigdirs="$noconfigdirs sim target-rda"
3780 ;;
75eeae1a 3781 powerpc-*-darwin*)
e1514c3f 3782 noconfigdirs="$noconfigdirs ld gas gdb gprof"
9c8f9ec2 3783 noconfigdirs="$noconfigdirs sim target-rda"
940cde4d 3784 ;;
354ebf88
RW
3785 i[3456789]86-*-darwin*)
3786 noconfigdirs="$noconfigdirs ld gprof"
3787 noconfigdirs="$noconfigdirs sim target-rda"
3788 ;;
3789 x86_64-*-darwin[912]*)
0db3a858
TG
3790 noconfigdirs="$noconfigdirs ld gas gprof"
3791 noconfigdirs="$noconfigdirs sim target-rda"
3792 ;;
42c1cd8a
AT
3793 *-*-darwin*)
3794 noconfigdirs="$noconfigdirs ld gas gdb gprof"
3795 noconfigdirs="$noconfigdirs sim target-rda"
42c1cd8a 3796 ;;
8c6d158a 3797 *-*-dragonfly*)
8c6d158a 3798 ;;
c3f84f61 3799 *-*-freebsd*)
88252529 3800 if test "x$with_gmp" = x \
c0d0a722 3801 && ! test -d ${srcdir}/gmp \
6de9cd9a
DN
3802 && test -f /usr/local/include/gmp.h; then
3803 with_gmp=/usr/local
3804 fi
6de9cd9a 3805 ;;
ef4e7569
US
3806 *-*-kaos*)
3807 # Remove unsupported stuff on all kaOS configurations.
ef4e7569
US
3808 noconfigdirs="$noconfigdirs target-libgloss"
3809 ;;
671aa708 3810 *-*-netbsd*)
671aa708 3811 ;;
61fec9ff 3812 *-*-netware*)
671aa708 3813 ;;
fd6487af
JS
3814 *-*-phoenix*)
3815 noconfigdirs="$noconfigdirs target-libgloss"
3816 ;;
671aa708 3817 *-*-rtems*)
2909494b 3818 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3819 ;;
a8ba31f2
EC
3820 # The tpf target doesn't support gdb yet.
3821 *-*-tpf*)
6a789d5e 3822 noconfigdirs="$noconfigdirs gdb tcl tk libgui itcl"
a8ba31f2 3823 ;;
5785c0ed 3824 *-*-uclinux*)
6a789d5e 3825 noconfigdirs="$noconfigdirs target-rda"
5785c0ed 3826 ;;
671aa708 3827 *-*-vxworks*)
671aa708
NN
3828 ;;
3829 alpha*-dec-osf*)
3830 # ld works, but does not support shared libraries.
671aa708 3831 # gas doesn't generate exception information.
6a789d5e 3832 noconfigdirs="$noconfigdirs gas ld"
671aa708
NN
3833 ;;
3834 alpha*-*-*vms*)
2909494b 3835 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
671aa708 3836 ;;
671aa708
NN
3837 alpha*-*-*)
3838 # newlib is not 64 bit ready
2909494b 3839 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
671aa708 3840 ;;
91dfef96
JM
3841 bpf-*-*)
3842 noconfigdirs="$noconfigdirs target-libobjc target-libbacktrace"
3843 ;;
671aa708 3844 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
b4f96efe 3845 noconfigdirs="$noconfigdirs tcl tk itcl libgui sim"
671aa708 3846 ;;
2fd88f4f
AK
3847 arc*-*-*)
3848 noconfigdirs="$noconfigdirs sim"
3849 ;;
671aa708 3850 arm-*-pe*)
2909494b 3851 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3852 ;;
671aa708 3853 arm-*-riscix*)
0036370f 3854 noconfigdirs="$noconfigdirs ld target-libgloss"
671aa708 3855 ;;
b588ae30
GJL
3856 avr-*-*)
3857 if test x${with_avrlibc} != xno; then
3858 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
3859 fi
3860 ;;
671aa708 3861 c4x-*-* | tic4x-*-*)
0036370f 3862 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3863 ;;
0036370f
JM
3864 tic54x-*-*)
3865 noconfigdirs="$noconfigdirs target-libgloss gdb"
671aa708 3866 ;;
671aa708 3867 d10v-*-*)
0036370f 3868 noconfigdirs="$noconfigdirs target-libgloss"
671aa708
NN
3869 ;;
3870 d30v-*-*)
0036370f 3871 noconfigdirs="$noconfigdirs gdb"
671aa708
NN
3872 ;;
3873 fr30-*-elf*)
2909494b 3874 noconfigdirs="$noconfigdirs gdb"
671aa708 3875 ;;
a05c2c75
L
3876 ft32-*-*)
3877 noconfigdirs="$noconfigdirs target-rda gprof"
3878 ;;
55f2d967 3879 moxie-*-*)
a05c2c75 3880 noconfigdirs="$noconfigdirs"
55f2d967 3881 ;;
671aa708 3882 h8300*-*-*)
2909494b 3883 noconfigdirs="$noconfigdirs target-libgloss"
671aa708
NN
3884 ;;
3885 h8500-*-*)
0036370f 3886 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3887 ;;
b48e9940
AA
3888 hppa1.1-*-osf* | hppa1.1-*-bsd* )
3889 ;;
a05c2c75
L
3890 hppa*64*-*-hpux*)
3891 noconfigdirs="$noconfigdirs gdb"
3892 ;;
b48e9940
AA
3893 hppa*-*-hpux11*)
3894 noconfigdirs="$noconfigdirs gdb ld"
3895 ;;
4569f85e 3896 hppa*64*-*-linux*)
671aa708 3897 ;;
56f8587a 3898 hppa*-*-linux*)
3e732ba0 3899 ;;
671aa708 3900 hppa*-*-*elf* | \
671aa708
NN
3901 hppa*-*-lites* | \
3902 hppa*-*-openbsd* | \
3903 hppa*64*-*-*)
671aa708 3904 ;;
c03353e2 3905 hppa*-*-pro*)
c03353e2 3906 ;;
671aa708 3907 hppa*-*-*)
2909494b 3908 noconfigdirs="$noconfigdirs ld"
671aa708 3909 ;;
fb87ad5d 3910 i960-*-*)
0036370f 3911 noconfigdirs="$noconfigdirs gdb"
fb87ad5d 3912 ;;
671aa708
NN
3913 ia64*-*-elf*)
3914 # No gdb support yet.
1bcce263 3915 noconfigdirs="$noconfigdirs readline libgui itcl gdb"
671aa708
NN
3916 ;;
3917 ia64*-**-hpux*)
5a2931d1 3918 # No ld support yet.
a05c2c75 3919 noconfigdirs="$noconfigdirs gdb libgui itcl ld"
671aa708 3920 ;;
52535a64 3921 ia64*-*-*vms*)
091fe9ca
TG
3922 # No ld support yet.
3923 noconfigdirs="$noconfigdirs libgui itcl ld"
52535a64 3924 ;;
ef4c4300 3925 i[3456789]86-w64-mingw*)
ef4c4300
KT
3926 ;;
3927 i[3456789]86-*-mingw*)
b91f0a41 3928 target_configdirs="$target_configdirs target-winsup"
1c710c3c 3929 ;;
671aa708
NN
3930 *-*-cygwin*)
3931 target_configdirs="$target_configdirs target-libtermcap target-winsup"
1bcce263 3932 noconfigdirs="$noconfigdirs target-libgloss"
801e2270 3933 # always build newlib if winsup directory is present.
b91f0a41 3934 if test -d "$srcdir/winsup/cygwin"; then
801e2270 3935 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
ee6a22df 3936 elif test -d "$srcdir/newlib"; then
b91f0a41 3937 echo "Warning: winsup/cygwin is missing so newlib can't be built."
801e2270 3938 fi
1c710c3c 3939 ;;
f2a0e225 3940 i[3456789]86-*-pe)
ebb9f8b0 3941 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3942 ;;
f2a0e225 3943 i[3456789]86-*-sco3.2v5*)
671aa708
NN
3944 # The linker does not yet know about weak symbols in COFF,
3945 # and is not configured to handle mixed ELF and COFF.
0036370f 3946 noconfigdirs="$noconfigdirs ld target-libgloss"
671aa708 3947 ;;
f2a0e225 3948 i[3456789]86-*-sco*)
0036370f 3949 noconfigdirs="$noconfigdirs gprof target-libgloss"
671aa708 3950 ;;
fbdd5d87 3951 i[3456789]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*)
671aa708
NN
3952 noconfigdirs="$noconfigdirs target-libgloss"
3953 ;;
f2a0e225 3954 i[3456789]86-*-sysv4*)
0036370f 3955 noconfigdirs="$noconfigdirs target-libgloss"
671aa708 3956 ;;
f2a0e225 3957 i[3456789]86-*-beos*)
6a789d5e 3958 noconfigdirs="$noconfigdirs gdb"
3aa83176 3959 ;;
d1f8db0c 3960 i[3456789]86-*-rdos*)
6a789d5e 3961 noconfigdirs="$noconfigdirs gdb"
c03353e2 3962 ;;
671aa708 3963 mmix-*-*)
2909494b 3964 noconfigdirs="$noconfigdirs gdb"
671aa708 3965 ;;
ab34901f 3966 mt-*-*)
79dd769c
AH
3967 noconfigdirs="$noconfigdirs sim"
3968 ;;
58b40a67
FT
3969 nfp-*-*)
3970 noconfigdirs="$noconfigdirs ld gas gdb gprof sim"
3971 noconfigdirs="$noconfigdirs $target_libraries"
3972 ;;
e6cbe965
SC
3973 pdp11-*-*)
3974 noconfigdirs="$noconfigdirs gdb gprof"
3975 ;;
671aa708
NN
3976 powerpc-*-aix*)
3977 # copied from rs6000-*-* entry
6a789d5e 3978 noconfigdirs="$noconfigdirs gprof"
671aa708 3979 ;;
4569f85e 3980 powerpc*-*-winnt* | powerpc*-*-pe*)
671aa708 3981 target_configdirs="$target_configdirs target-winsup"
0036370f 3982 noconfigdirs="$noconfigdirs gdb tcl tk target-libgloss itcl"
671aa708
NN
3983 # always build newlib.
3984 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
3985 ;;
3986 # This is temporary until we can link against shared libraries
3987 powerpcle-*-solaris*)
0036370f 3988 noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
671aa708
NN
3989 ;;
3990 powerpc-*-beos*)
6a789d5e 3991 noconfigdirs="$noconfigdirs gdb"
671aa708 3992 ;;
671aa708 3993 rs6000-*-lynxos*)
6a789d5e 3994 noconfigdirs="$noconfigdirs gprof"
671aa708
NN
3995 ;;
3996 rs6000-*-aix*)
6a789d5e 3997 noconfigdirs="$noconfigdirs gprof"
671aa708
NN
3998 ;;
3999 rs6000-*-*)
2909494b 4000 noconfigdirs="$noconfigdirs gprof"
671aa708
NN
4001 ;;
4002 m68k-apollo-*)
0036370f 4003 noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss"
671aa708 4004 ;;
ca9fe997 4005 microblaze*)
2909494b 4006 noconfigdirs="$noconfigdirs gprof"
ca9fe997 4007 ;;
d896cc4d 4008 mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
d9dced13
RS
4009 if test x$with_newlib = xyes; then
4010 noconfigdirs="$noconfigdirs gprof"
4011 fi
d9dced13 4012 ;;
671aa708 4013 mips*-*-irix5*)
0036370f 4014 noconfigdirs="$noconfigdirs gprof target-libgloss"
671aa708
NN
4015 ;;
4016 mips*-*-irix6*)
2909494b 4017 noconfigdirs="$noconfigdirs gprof target-libgloss"
671aa708 4018 ;;
671aa708 4019 mips*-*-bsd*)
bc98bcc4 4020 noconfigdirs="$noconfigdirs ld gas gprof target-libgloss"
671aa708 4021 ;;
671aa708 4022 mips*-*-linux*)
671aa708 4023 ;;
bc98bcc4
JBG
4024 mips*-*-ultrix* | mips*-*-osf* | mips*-*-ecoff* | mips*-*-pe* \
4025 | mips*-*-irix* | mips*-*-lnews* | mips*-*-riscos*)
4026 noconfigdirs="$noconfigdirs ld gas gprof"
4027 ;;
671aa708 4028 mips*-*-*)
2909494b 4029 noconfigdirs="$noconfigdirs gprof"
671aa708 4030 ;;
738f2522 4031 nvptx*-*-*)
738f2522
BS
4032 noconfigdirs="$noconfigdirs target-libssp target-libstdc++-v3 target-libobjc"
4033 ;;
bc6d9014 4034 sh-*-*)
ea2002ba
CB
4035 case "${target}" in
4036 sh*-*-elf)
2909494b 4037 ;;
ea2002ba 4038 *)
2909494b 4039 noconfigdirs="$noconfigdirs target-libgloss" ;;
ea2002ba 4040 esac
671aa708 4041 ;;
671aa708 4042 sparc-*-sunos4*)
6a789d5e 4043 if test x${is_cross_compiler} = xno ; then
671aa708
NN
4044 use_gnu_ld=no
4045 fi
4046 ;;
b42f0d7e 4047 tic6x-*-*)
0d557ff8 4048 noconfigdirs="$noconfigdirs sim"
b42f0d7e 4049 ;;
a885ec24
AA
4050 tilepro*-*-* | tilegx*-*-*)
4051 noconfigdirs="$noconfigdirs sim"
4052 ;;
671aa708 4053 v810-*-*)
0036370f 4054 noconfigdirs="$noconfigdirs bfd binutils gas gdb ld opcodes target-libgloss"
671aa708
NN
4055 ;;
4056 vax-*-*)
2909494b 4057 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
671aa708 4058 ;;
1fc1d82e
MR
4059 wasm32-*-*)
4060 noconfigdirs="$noconfigdirs ld"
4061 ;;
c6c0594e 4062 loongarch*-*-linux*)
4063 ;;
4064 loongarch*-*-*)
4065 noconfigdirs="$noconfigdirs gprof"
4066 ;;
671aa708 4067esac
79c06341 4068
671aa708
NN
4069# If we aren't building newlib, then don't build libgloss, since libgloss
4070# depends upon some newlib header files.
4071case "${noconfigdirs}" in
4072 *target-libgloss*) ;;
4073 *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
4074esac
4075
671aa708 4076# Work in distributions that contain no compiler tools, like Autoconf.
671aa708
NN
4077host_makefile_frag=/dev/null
4078if test -d ${srcdir}/config ; then
4079case "${host}" in
f2a0e225 4080 i[3456789]86-*-msdosdjgpp*)
671aa708
NN
4081 host_makefile_frag="config/mh-djgpp"
4082 ;;
4083 *-cygwin*)
2a79c47f 4084
5213506e
RW
4085{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if cat works as expected" >&5
4086$as_echo_n "checking to see if cat works as expected... " >&6; }
2a79c47f 4087echo a >cygwin-cat-check
e25a8c82 4088if test `cat cygwin-cat-check` = a ; then
2a79c47f 4089 rm cygwin-cat-check
5213506e
RW
4090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4091$as_echo "yes" >&6; }
2a79c47f
NC
4092else
4093 rm cygwin-cat-check
5213506e
RW
4094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4095$as_echo "no" >&6; }
22e05272 4096 as_fn_error $? "The cat command does not ignore carriage return characters.
2a79c47f
NC
4097 Please either mount the build directory in binary mode or run the following
4098 commands before running any configure script:
4099set -o igncr
4100export SHELLOPTS
5213506e 4101 " "$LINENO" 5
2a79c47f
NC
4102fi
4103
671aa708
NN
4104 host_makefile_frag="config/mh-cygwin"
4105 ;;
c53a18d3 4106 *-mingw*)
1f5a6b84 4107 host_makefile_frag="config/mh-mingw"
95af8923 4108 ;;
cabb9d59 4109 alpha*-linux*)
13be44ed
UB
4110 host_makefile_frag="config/mh-alpha-linux"
4111 ;;
111eeb6e 4112 hppa*-hp-hpux*)
efd41714
PB
4113 host_makefile_frag="config/mh-pa"
4114 ;;
4115 hppa*-*)
4116 host_makefile_frag="config/mh-pa"
4117 ;;
54258e22 4118 i?86-*-darwin[89]* | i?86-*-darwin1[0-7]* | powerpc*-*-darwin*)
d8ed14ce 4119 host_makefile_frag="config/mh-darwin"
be8fff81 4120 ;;
d19bca38
PB
4121 powerpc-*-aix*)
4122 host_makefile_frag="config/mh-ppc-aix"
4123 ;;
4124 rs6000-*-aix*)
4125 host_makefile_frag="config/mh-ppc-aix"
4126 ;;
671aa708
NN
4127esac
4128fi
4129
55ffb5ed 4130if test "${build}" != "${host}" ; then
0999159b
PB
4131 AR_FOR_BUILD=${AR_FOR_BUILD-ar}
4132 AS_FOR_BUILD=${AS_FOR_BUILD-as}
55ffb5ed 4133 CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
c841dc0a 4134 CPP_FOR_BUILD="${CPP_FOR_BUILD-\$(CC_FOR_BUILD) -E}"
0999159b 4135 CXX_FOR_BUILD=${CXX_FOR_BUILD-g++}
3b5e8ee4 4136 DSYMUTIL_FOR_BUILD=${DSYMUTIL_FOR_BUILD-dsymutil}
0999159b 4137 GFORTRAN_FOR_BUILD=${GFORTRAN_FOR_BUILD-gfortran}
632e2a07 4138 GOC_FOR_BUILD=${GOC_FOR_BUILD-gccgo}
b4c522fa 4139 GDC_FOR_BUILD=${GDC_FOR_BUILD-gdc}
0999159b
PB
4140 DLLTOOL_FOR_BUILD=${DLLTOOL_FOR_BUILD-dlltool}
4141 LD_FOR_BUILD=${LD_FOR_BUILD-ld}
4142 NM_FOR_BUILD=${NM_FOR_BUILD-nm}
4143 RANLIB_FOR_BUILD=${RANLIB_FOR_BUILD-ranlib}
4144 WINDRES_FOR_BUILD=${WINDRES_FOR_BUILD-windres}
4145 WINDMC_FOR_BUILD=${WINDMC_FOR_BUILD-windmc}
4146else
4147 AR_FOR_BUILD="\$(AR)"
4148 AS_FOR_BUILD="\$(AS)"
fb0103e5 4149 CC_FOR_BUILD="\$(CC)"
0999159b 4150 CXX_FOR_BUILD="\$(CXX)"
3b5e8ee4 4151 DSYMUTIL_FOR_BUILD="\$(DSYMUTIL)"
0999159b 4152 GFORTRAN_FOR_BUILD="\$(GFORTRAN)"
632e2a07 4153 GOC_FOR_BUILD="\$(GOC)"
b4c522fa 4154 GDC_FOR_BUILD="\$(GDC)"
0999159b
PB
4155 DLLTOOL_FOR_BUILD="\$(DLLTOOL)"
4156 LD_FOR_BUILD="\$(LD)"
4157 NM_FOR_BUILD="\$(NM)"
4158 RANLIB_FOR_BUILD="\$(RANLIB)"
4159 WINDRES_FOR_BUILD="\$(WINDRES)"
4160 WINDMC_FOR_BUILD="\$(WINDMC)"
c3a86da9
DJ
4161fi
4162
4163ac_ext=c
1c710c3c
DJ
4164ac_cpp='$CPP $CPPFLAGS'
4165ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4166ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4167ac_compiler_gnu=$ac_cv_c_compiler_gnu
4168if test -n "$ac_tool_prefix"; then
4169 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4170set dummy ${ac_tool_prefix}gcc; ac_word=$2
5213506e
RW
4171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4172$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4173if ${ac_cv_prog_CC+:} false; then :
5213506e 4174 $as_echo_n "(cached) " >&6
1c710c3c
DJ
4175else
4176 if test -n "$CC"; then
4177 ac_cv_prog_CC="$CC" # Let the user override the test.
4178else
4179as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4180for as_dir in $PATH
4181do
4182 IFS=$as_save_IFS
4183 test -z "$as_dir" && as_dir=.
5213506e 4184 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4185 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4186 ac_cv_prog_CC="${ac_tool_prefix}gcc"
5213506e 4187 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4188 break 2
4189 fi
4190done
5213506e
RW
4191 done
4192IFS=$as_save_IFS
1c710c3c
DJ
4193
4194fi
4195fi
4196CC=$ac_cv_prog_CC
4197if test -n "$CC"; then
5213506e
RW
4198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4199$as_echo "$CC" >&6; }
1c710c3c 4200else
5213506e
RW
4201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4202$as_echo "no" >&6; }
1c710c3c
DJ
4203fi
4204
5213506e 4205
1c710c3c
DJ
4206fi
4207if test -z "$ac_cv_prog_CC"; then
4208 ac_ct_CC=$CC
fb0103e5
RG
4209 # Extract the first word of "gcc", so it can be a program name with args.
4210set dummy gcc; ac_word=$2
5213506e
RW
4211{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4212$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4213if ${ac_cv_prog_ac_ct_CC+:} false; then :
5213506e 4214 $as_echo_n "(cached) " >&6
1c710c3c
DJ
4215else
4216 if test -n "$ac_ct_CC"; then
4217 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4218else
4219as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4220for as_dir in $PATH
4221do
4222 IFS=$as_save_IFS
4223 test -z "$as_dir" && as_dir=.
5213506e 4224 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4225 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4226 ac_cv_prog_ac_ct_CC="gcc"
5213506e 4227 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4228 break 2
4229 fi
4230done
5213506e
RW
4231 done
4232IFS=$as_save_IFS
1c710c3c
DJ
4233
4234fi
4235fi
4236ac_ct_CC=$ac_cv_prog_ac_ct_CC
4237if test -n "$ac_ct_CC"; then
5213506e
RW
4238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4239$as_echo "$ac_ct_CC" >&6; }
1c710c3c 4240else
5213506e
RW
4241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4242$as_echo "no" >&6; }
1c710c3c
DJ
4243fi
4244
5213506e
RW
4245 if test "x$ac_ct_CC" = x; then
4246 CC=""
4247 else
4248 case $cross_compiling:$ac_tool_warned in
4249yes:)
4250{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4251$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4252ac_tool_warned=yes ;;
4253esac
4254 CC=$ac_ct_CC
4255 fi
1c710c3c
DJ
4256else
4257 CC="$ac_cv_prog_CC"
4258fi
4259
4260if test -z "$CC"; then
5213506e
RW
4261 if test -n "$ac_tool_prefix"; then
4262 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1c710c3c 4263set dummy ${ac_tool_prefix}cc; ac_word=$2
5213506e
RW
4264{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4265$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4266if ${ac_cv_prog_CC+:} false; then :
5213506e 4267 $as_echo_n "(cached) " >&6
55ffb5ed
NN
4268else
4269 if test -n "$CC"; then
4270 ac_cv_prog_CC="$CC" # Let the user override the test.
4271else
1c710c3c
DJ
4272as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4273for as_dir in $PATH
4274do
4275 IFS=$as_save_IFS
4276 test -z "$as_dir" && as_dir=.
5213506e 4277 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4278 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4279 ac_cv_prog_CC="${ac_tool_prefix}cc"
5213506e 4280 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4281 break 2
4282 fi
4283done
5213506e
RW
4284 done
4285IFS=$as_save_IFS
1c710c3c 4286
0b0dc272 4287fi
0b0dc272 4288fi
1c710c3c 4289CC=$ac_cv_prog_CC
af71363e 4290if test -n "$CC"; then
5213506e
RW
4291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4292$as_echo "$CC" >&6; }
2aeb72e9 4293else
5213506e
RW
4294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4295$as_echo "no" >&6; }
2aeb72e9
DD
4296fi
4297
2aeb72e9 4298
5213506e 4299 fi
1c710c3c 4300fi
55ffb5ed
NN
4301if test -z "$CC"; then
4302 # Extract the first word of "cc", so it can be a program name with args.
4303set dummy cc; ac_word=$2
5213506e
RW
4304{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4305$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4306if ${ac_cv_prog_CC+:} false; then :
5213506e 4307 $as_echo_n "(cached) " >&6
55ffb5ed
NN
4308else
4309 if test -n "$CC"; then
4310 ac_cv_prog_CC="$CC" # Let the user override the test.
4311else
0b0dc272 4312 ac_prog_rejected=no
1c710c3c
DJ
4313as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4314for as_dir in $PATH
4315do
4316 IFS=$as_save_IFS
4317 test -z "$as_dir" && as_dir=.
5213506e 4318 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4319 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c
DJ
4320 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4321 ac_prog_rejected=yes
4322 continue
4323 fi
4324 ac_cv_prog_CC="cc"
5213506e 4325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4326 break 2
4327 fi
4328done
5213506e
RW
4329 done
4330IFS=$as_save_IFS
1c710c3c 4331
55ffb5ed
NN
4332if test $ac_prog_rejected = yes; then
4333 # We found a bogon in the path, so make sure we never use it.
4334 set dummy $ac_cv_prog_CC
4335 shift
1c710c3c 4336 if test $# != 0; then
55ffb5ed
NN
4337 # We chose a different compiler from the bogus one.
4338 # However, it has the same basename, so the bogon will be chosen
4339 # first if we set CC to just the basename; use the full file name.
4340 shift
1c710c3c 4341 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
55ffb5ed
NN
4342 fi
4343fi
4344fi
4345fi
1c710c3c 4346CC=$ac_cv_prog_CC
55ffb5ed 4347if test -n "$CC"; then
5213506e
RW
4348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4349$as_echo "$CC" >&6; }
55ffb5ed 4350else
5213506e
RW
4351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4352$as_echo "no" >&6; }
55ffb5ed
NN
4353fi
4354
5213506e 4355
1c710c3c
DJ
4356fi
4357if test -z "$CC"; then
4358 if test -n "$ac_tool_prefix"; then
5213506e 4359 for ac_prog in cl.exe
1c710c3c
DJ
4360 do
4361 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4362set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5213506e
RW
4363{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4364$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4365if ${ac_cv_prog_CC+:} false; then :
5213506e 4366 $as_echo_n "(cached) " >&6
55ffb5ed
NN
4367else
4368 if test -n "$CC"; then
4369 ac_cv_prog_CC="$CC" # Let the user override the test.
4370else
1c710c3c
DJ
4371as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4372for as_dir in $PATH
4373do
4374 IFS=$as_save_IFS
4375 test -z "$as_dir" && as_dir=.
5213506e 4376 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4377 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4378 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5213506e 4379 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4380 break 2
4381 fi
4382done
5213506e
RW
4383 done
4384IFS=$as_save_IFS
1c710c3c 4385
55ffb5ed
NN
4386fi
4387fi
1c710c3c 4388CC=$ac_cv_prog_CC
55ffb5ed 4389if test -n "$CC"; then
5213506e
RW
4390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4391$as_echo "$CC" >&6; }
a4b9e93e 4392else
5213506e
RW
4393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4394$as_echo "no" >&6; }
fb0103e5 4395fi
af71363e 4396
5213506e 4397
1c710c3c
DJ
4398 test -n "$CC" && break
4399 done
af71363e 4400fi
1c710c3c
DJ
4401if test -z "$CC"; then
4402 ac_ct_CC=$CC
5213506e 4403 for ac_prog in cl.exe
1c710c3c
DJ
4404do
4405 # Extract the first word of "$ac_prog", so it can be a program name with args.
4406set dummy $ac_prog; ac_word=$2
5213506e
RW
4407{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4408$as_echo_n "checking for $ac_word... " >&6; }
22e05272 4409if ${ac_cv_prog_ac_ct_CC+:} false; then :
5213506e 4410 $as_echo_n "(cached) " >&6
0b0dc272 4411else
1c710c3c
DJ
4412 if test -n "$ac_ct_CC"; then
4413 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
0b0dc272 4414else
1c710c3c
DJ
4415as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4416for as_dir in $PATH
4417do
4418 IFS=$as_save_IFS
4419 test -z "$as_dir" && as_dir=.
5213506e 4420 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 4421 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 4422 ac_cv_prog_ac_ct_CC="$ac_prog"
5213506e 4423 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
4424 break 2
4425 fi
4426done
5213506e
RW
4427 done
4428IFS=$as_save_IFS
1c710c3c 4429
af71363e
AS
4430fi
4431fi
1c710c3c
DJ
4432ac_ct_CC=$ac_cv_prog_ac_ct_CC
4433if test -n "$ac_ct_CC"; then
5213506e
RW
4434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4435$as_echo "$ac_ct_CC" >&6; }
fb0103e5 4436else
5213506e
RW
4437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4438$as_echo "no" >&6; }
af71363e 4439fi
0b0dc272 4440
5213506e 4441
1c710c3c
DJ
4442 test -n "$ac_ct_CC" && break
4443done
4444
5213506e
RW
4445 if test "x$ac_ct_CC" = x; then
4446 CC=""
4447 else
4448 case $cross_compiling:$ac_tool_warned in
4449yes:)
4450{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4451$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4452ac_tool_warned=yes ;;
4453esac
4454 CC=$ac_ct_CC
4455 fi
1c710c3c
DJ
4456fi
4457
4458fi
4459
4460
5213506e
RW
4461test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4462$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4463as_fn_error $? "no acceptable C compiler found in \$PATH
4464See \`config.log' for more details" "$LINENO" 5; }
1c710c3c
DJ
4465
4466# Provide some information about the compiler.
5213506e
RW
4467$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4468set X $ac_compile
4469ac_compiler=$2
4470for ac_option in --version -v -V -qversion; do
4471 { { ac_try="$ac_compiler $ac_option >&5"
4472case "(($ac_try" in
4473 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4474 *) ac_try_echo=$ac_try;;
4475esac
4476eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4477$as_echo "$ac_try_echo"; } >&5
4478 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
1c710c3c 4479 ac_status=$?
5213506e
RW
4480 if test -s conftest.err; then
4481 sed '10a\
4482... rest of stderr output deleted ...
4483 10q' conftest.err >conftest.er1
4484 cat conftest.er1 >&5
5213506e 4485 fi
22e05272 4486 rm -f conftest.er1 conftest.err
5213506e
RW
4487 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4488 test $ac_status = 0; }
4489done
1c710c3c 4490
5213506e 4491cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4492/* end confdefs.h. */
4493
4494int
4495main ()
4496{
4497
4498 ;
4499 return 0;
4500}
4501_ACEOF
4502ac_clean_files_save=$ac_clean_files
22e05272 4503ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
1c710c3c
DJ
4504# Try to create an executable without -o first, disregard a.out.
4505# It will help us diagnose broken compilers, and finding out an intuition
4506# of exeext.
22e05272
JM
4507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4508$as_echo_n "checking whether the C compiler works... " >&6; }
5213506e
RW
4509ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4510
4511# The possible output files:
4512ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4513
4514ac_rmfiles=
4515for ac_file in $ac_files
4516do
4517 case $ac_file in
4518 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4519 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4520 esac
4521done
4522rm -f $ac_rmfiles
4523
4524if { { ac_try="$ac_link_default"
4525case "(($ac_try" in
4526 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4527 *) ac_try_echo=$ac_try;;
4528esac
4529eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4530$as_echo "$ac_try_echo"; } >&5
4531 (eval "$ac_link_default") 2>&5
1c710c3c 4532 ac_status=$?
5213506e
RW
4533 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4534 test $ac_status = 0; }; then :
4535 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4536# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4537# in a Makefile. We should not override ac_cv_exeext if it was cached,
4538# so that the user can short-circuit this test for compilers unknown to
4539# Autoconf.
4540for ac_file in $ac_files ''
1c710c3c
DJ
4541do
4542 test -f "$ac_file" || continue
4543 case $ac_file in
5213506e 4544 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
1c710c3c
DJ
4545 ;;
4546 [ab].out )
4547 # We found the default executable, but exeext='' is most
4548 # certainly right.
4549 break;;
4550 *.* )
5213506e
RW
4551 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4552 then :; else
4553 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4554 fi
4555 # We set ac_cv_exeext here because the later test for it is not
4556 # safe: cross compilers may not add the suffix if given an `-o'
4557 # argument, so we may need to know it at that point already.
4558 # Even if this section looks crufty: it has the advantage of
4559 # actually working.
1c710c3c
DJ
4560 break;;
4561 * )
4562 break;;
4563 esac
4564done
5213506e
RW
4565test "$ac_cv_exeext" = no && ac_cv_exeext=
4566
1c710c3c 4567else
5213506e
RW
4568 ac_file=''
4569fi
5213506e 4570if test -z "$ac_file"; then :
22e05272
JM
4571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4572$as_echo "no" >&6; }
4573$as_echo "$as_me: failed program was:" >&5
1c710c3c
DJ
4574sed 's/^/| /' conftest.$ac_ext >&5
4575
5213506e
RW
4576{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4577$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4578as_fn_error 77 "C compiler cannot create executables
4579See \`config.log' for more details" "$LINENO" 5; }
4580else
4581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4582$as_echo "yes" >&6; }
1c710c3c 4583fi
22e05272
JM
4584{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4585$as_echo_n "checking for C compiler default output file name... " >&6; }
4586{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4587$as_echo "$ac_file" >&6; }
1c710c3c 4588ac_exeext=$ac_cv_exeext
1c710c3c 4589
22e05272 4590rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
1c710c3c 4591ac_clean_files=$ac_clean_files_save
5213506e
RW
4592{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4593$as_echo_n "checking for suffix of executables... " >&6; }
4594if { { ac_try="$ac_link"
4595case "(($ac_try" in
4596 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4597 *) ac_try_echo=$ac_try;;
4598esac
4599eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4600$as_echo "$ac_try_echo"; } >&5
4601 (eval "$ac_link") 2>&5
1c710c3c 4602 ac_status=$?
5213506e
RW
4603 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4604 test $ac_status = 0; }; then :
1c710c3c
DJ
4605 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4606# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4607# work properly (i.e., refer to `conftest.exe'), while it won't with
4608# `rm'.
4609for ac_file in conftest.exe conftest conftest.*; do
4610 test -f "$ac_file" || continue
4611 case $ac_file in
5213506e 4612 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
1c710c3c 4613 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1c710c3c
DJ
4614 break;;
4615 * ) break;;
4616 esac
4617done
af71363e 4618else
5213506e
RW
4619 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4620$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4621as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4622See \`config.log' for more details" "$LINENO" 5; }
1c710c3c 4623fi
22e05272 4624rm -f conftest conftest$ac_cv_exeext
5213506e
RW
4625{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4626$as_echo "$ac_cv_exeext" >&6; }
1c710c3c
DJ
4627
4628rm -f conftest.$ac_ext
4629EXEEXT=$ac_cv_exeext
4630ac_exeext=$EXEEXT
22e05272
JM
4631cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4632/* end confdefs.h. */
4633#include <stdio.h>
4634int
4635main ()
4636{
4637FILE *f = fopen ("conftest.out", "w");
4638 return ferror (f) || fclose (f) != 0;
4639
4640 ;
4641 return 0;
4642}
4643_ACEOF
4644ac_clean_files="$ac_clean_files conftest.out"
4645# Check that the compiler produces executables we can run. If not, either
4646# the compiler is broken, or we cross compile.
4647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4648$as_echo_n "checking whether we are cross compiling... " >&6; }
4649if test "$cross_compiling" != yes; then
4650 { { ac_try="$ac_link"
4651case "(($ac_try" in
4652 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4653 *) ac_try_echo=$ac_try;;
4654esac
4655eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4656$as_echo "$ac_try_echo"; } >&5
4657 (eval "$ac_link") 2>&5
4658 ac_status=$?
4659 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4660 test $ac_status = 0; }
4661 if { ac_try='./conftest$ac_cv_exeext'
4662 { { case "(($ac_try" in
4663 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4664 *) ac_try_echo=$ac_try;;
4665esac
4666eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4667$as_echo "$ac_try_echo"; } >&5
4668 (eval "$ac_try") 2>&5
4669 ac_status=$?
4670 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4671 test $ac_status = 0; }; }; then
4672 cross_compiling=no
4673 else
4674 if test "$cross_compiling" = maybe; then
4675 cross_compiling=yes
4676 else
4677 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4678$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4679as_fn_error $? "cannot run C compiled programs.
4680If you meant to cross compile, use \`--host'.
4681See \`config.log' for more details" "$LINENO" 5; }
4682 fi
4683 fi
4684fi
4685{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4686$as_echo "$cross_compiling" >&6; }
4687
4688rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4689ac_clean_files=$ac_clean_files_save
5213506e
RW
4690{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4691$as_echo_n "checking for suffix of object files... " >&6; }
22e05272 4692if ${ac_cv_objext+:} false; then :
5213506e 4693 $as_echo_n "(cached) " >&6
1c710c3c 4694else
5213506e 4695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4696/* end confdefs.h. */
4697
4698int
4699main ()
4700{
4701
4702 ;
4703 return 0;
4704}
4705_ACEOF
4706rm -f conftest.o conftest.obj
5213506e
RW
4707if { { ac_try="$ac_compile"
4708case "(($ac_try" in
4709 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4710 *) ac_try_echo=$ac_try;;
4711esac
4712eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4713$as_echo "$ac_try_echo"; } >&5
4714 (eval "$ac_compile") 2>&5
1c710c3c 4715 ac_status=$?
5213506e
RW
4716 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4717 test $ac_status = 0; }; then :
4718 for ac_file in conftest.o conftest.obj conftest.*; do
4719 test -f "$ac_file" || continue;
1c710c3c 4720 case $ac_file in
5213506e 4721 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
1c710c3c
DJ
4722 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4723 break;;
4724 esac
4725done
4726else
5213506e 4727 $as_echo "$as_me: failed program was:" >&5
1c710c3c
DJ
4728sed 's/^/| /' conftest.$ac_ext >&5
4729
5213506e
RW
4730{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4731$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22e05272
JM
4732as_fn_error $? "cannot compute suffix of object files: cannot compile
4733See \`config.log' for more details" "$LINENO" 5; }
1c710c3c 4734fi
1c710c3c
DJ
4735rm -f conftest.$ac_cv_objext conftest.$ac_ext
4736fi
5213506e
RW
4737{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4738$as_echo "$ac_cv_objext" >&6; }
1c710c3c
DJ
4739OBJEXT=$ac_cv_objext
4740ac_objext=$OBJEXT
5213506e
RW
4741{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4742$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
22e05272 4743if ${ac_cv_c_compiler_gnu+:} false; then :
5213506e 4744 $as_echo_n "(cached) " >&6
1c710c3c 4745else
5213506e 4746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4747/* end confdefs.h. */
4748
4749int
4750main ()
4751{
4752#ifndef __GNUC__
4753 choke me
4754#endif
4755
4756 ;
4757 return 0;
4758}
4759_ACEOF
5213506e 4760if ac_fn_c_try_compile "$LINENO"; then :
1c710c3c
DJ
4761 ac_compiler_gnu=yes
4762else
5213506e 4763 ac_compiler_gnu=no
1c710c3c 4764fi
5213506e 4765rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1c710c3c
DJ
4766ac_cv_c_compiler_gnu=$ac_compiler_gnu
4767
4768fi
5213506e
RW
4769{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4770$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4771if test $ac_compiler_gnu = yes; then
4772 GCC=yes
4773else
4774 GCC=
4775fi
1c710c3c
DJ
4776ac_test_CFLAGS=${CFLAGS+set}
4777ac_save_CFLAGS=$CFLAGS
5213506e
RW
4778{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4779$as_echo_n "checking whether $CC accepts -g... " >&6; }
22e05272 4780if ${ac_cv_prog_cc_g+:} false; then :
5213506e
RW
4781 $as_echo_n "(cached) " >&6
4782else
4783 ac_save_c_werror_flag=$ac_c_werror_flag
4784 ac_c_werror_flag=yes
4785 ac_cv_prog_cc_g=no
4786 CFLAGS="-g"
4787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4788/* end confdefs.h. */
4789
4790int
4791main ()
4792{
4793
4794 ;
4795 return 0;
4796}
4797_ACEOF
5213506e 4798if ac_fn_c_try_compile "$LINENO"; then :
55ffb5ed
NN
4799 ac_cv_prog_cc_g=yes
4800else
5213506e
RW
4801 CFLAGS=""
4802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4803/* end confdefs.h. */
4804
4805int
4806main ()
4807{
4808
4809 ;
4810 return 0;
4811}
4812_ACEOF
4813if ac_fn_c_try_compile "$LINENO"; then :
4814
4815else
4816 ac_c_werror_flag=$ac_save_c_werror_flag
4817 CFLAGS="-g"
4818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4819/* end confdefs.h. */
af71363e 4820
5213506e
RW
4821int
4822main ()
4823{
4824
4825 ;
4826 return 0;
4827}
4828_ACEOF
4829if ac_fn_c_try_compile "$LINENO"; then :
4830 ac_cv_prog_cc_g=yes
4831fi
4832rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
0b0dc272 4833fi
5213506e 4834rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1c710c3c 4835fi
5213506e
RW
4836rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4837 ac_c_werror_flag=$ac_save_c_werror_flag
4838fi
4839{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4840$as_echo "$ac_cv_prog_cc_g" >&6; }
55ffb5ed 4841if test "$ac_test_CFLAGS" = set; then
1c710c3c 4842 CFLAGS=$ac_save_CFLAGS
55ffb5ed
NN
4843elif test $ac_cv_prog_cc_g = yes; then
4844 if test "$GCC" = yes; then
4845 CFLAGS="-g -O2"
4846 else
4847 CFLAGS="-g"
4848 fi
4849else
4850 if test "$GCC" = yes; then
4851 CFLAGS="-O2"
4852 else
4853 CFLAGS=
4854 fi
4855fi
5213506e
RW
4856{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4857$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
22e05272 4858if ${ac_cv_prog_cc_c89+:} false; then :
5213506e 4859 $as_echo_n "(cached) " >&6
1c710c3c 4860else
5213506e 4861 ac_cv_prog_cc_c89=no
1c710c3c 4862ac_save_CC=$CC
5213506e 4863cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c
DJ
4864/* end confdefs.h. */
4865#include <stdarg.h>
4866#include <stdio.h>
22e05272 4867struct stat;
1c710c3c
DJ
4868/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4869struct buf { int x; };
4870FILE * (*rcsopen) (struct buf *, struct stat *, int);
4871static char *e (p, i)
4872 char **p;
4873 int i;
4874{
4875 return p[i];
4876}
4877static char *f (char * (*g) (char **, int), char **p, ...)
4878{
4879 char *s;
4880 va_list v;
4881 va_start (v,p);
4882 s = g (p, va_arg (v,int));
4883 va_end (v);
4884 return s;
4885}
4886
4887/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4888 function prototypes and stuff, but not '\xHH' hex character constants.
4889 These don't provoke an error unfortunately, instead are silently treated
5213506e 4890 as 'x'. The following induces an error, until -std is added to get
1c710c3c
DJ
4891 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4892 array size at least. It's necessary to write '\x00'==0 to get something
5213506e 4893 that's true only with -std. */
1c710c3c
DJ
4894int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4895
5213506e
RW
4896/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4897 inside strings and character constants. */
4898#define FOO(x) 'x'
4899int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4900
1c710c3c
DJ
4901int test (int i, double x);
4902struct s1 {int (*f) (int a);};
4903struct s2 {int (*f) (double a);};
4904int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4905int argc;
4906char **argv;
4907int
4908main ()
4909{
4910return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4911 ;
4912 return 0;
4913}
4914_ACEOF
5213506e
RW
4915for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4916 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
1c710c3c
DJ
4917do
4918 CC="$ac_save_CC $ac_arg"
5213506e
RW
4919 if ac_fn_c_try_compile "$LINENO"; then :
4920 ac_cv_prog_cc_c89=$ac_arg
1c710c3c 4921fi
5213506e
RW
4922rm -f core conftest.err conftest.$ac_objext
4923 test "x$ac_cv_prog_cc_c89" != "xno" && break
1c710c3c 4924done
5213506e 4925rm -f conftest.$ac_ext
1c710c3c
DJ
4926CC=$ac_save_CC
4927
4928fi
5213506e
RW
4929# AC_CACHE_VAL
4930case "x$ac_cv_prog_cc_c89" in
4931 x)
4932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4933$as_echo "none needed" >&6; } ;;
4934 xno)
4935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4936$as_echo "unsupported" >&6; } ;;
1c710c3c 4937 *)
5213506e
RW
4938 CC="$CC $ac_cv_prog_cc_c89"
4939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4940$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
1c710c3c 4941esac
5213506e 4942if test "x$ac_cv_prog_cc_c89" != xno; then :
1c710c3c 4943
2aeb72e9
DD
4944fi
4945
2aeb72e9
DD
4946ac_ext=c
4947ac_cpp='$CPP $CPPFLAGS'
4948ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4949ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4950ac_compiler_gnu=$ac_cv_c_compiler_gnu
4951
91743432
NC
4952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
4953$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
4954if ${ac_cv_prog_cc_c99+:} false; then :
4955 $as_echo_n "(cached) " >&6
4956else
4957 ac_cv_prog_cc_c99=no
4958ac_save_CC=$CC
4959cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4960/* end confdefs.h. */
4961#include <stdarg.h>
4962#include <stdbool.h>
4963#include <stdlib.h>
4964#include <wchar.h>
4965#include <stdio.h>
4966
4967// Check varargs macros. These examples are taken from C99 6.10.3.5.
4968#define debug(...) fprintf (stderr, __VA_ARGS__)
4969#define showlist(...) puts (#__VA_ARGS__)
4970#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4971static void
4972test_varargs_macros (void)
4973{
4974 int x = 1234;
4975 int y = 5678;
4976 debug ("Flag");
4977 debug ("X = %d\n", x);
4978 showlist (The first, second, and third items.);
4979 report (x>y, "x is %d but y is %d", x, y);
4980}
4981
4982// Check long long types.
4983#define BIG64 18446744073709551615ull
4984#define BIG32 4294967295ul
4985#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4986#if !BIG_OK
4987 your preprocessor is broken;
4988#endif
4989#if BIG_OK
4990#else
4991 your preprocessor is broken;
4992#endif
4993static long long int bignum = -9223372036854775807LL;
4994static unsigned long long int ubignum = BIG64;
4995
4996struct incomplete_array
4997{
4998 int datasize;
4999 double data[];
5000};
5001
5002struct named_init {
5003 int number;
5004 const wchar_t *name;
5005 double average;
5006};
5007
5008typedef const char *ccp;
5009
5010static inline int
5011test_restrict (ccp restrict text)
5012{
5013 // See if C++-style comments work.
5014 // Iterate through items via the restricted pointer.
5015 // Also check for declarations in for loops.
5016 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
5017 continue;
5018 return 0;
5019}
5020
5021// Check varargs and va_copy.
5022static void
5023test_varargs (const char *format, ...)
5024{
5025 va_list args;
5026 va_start (args, format);
5027 va_list args_copy;
5028 va_copy (args_copy, args);
5029
5030 const char *str;
5031 int number;
5032 float fnumber;
5033
5034 while (*format)
5035 {
5036 switch (*format++)
5037 {
5038 case 's': // string
5039 str = va_arg (args_copy, const char *);
5040 break;
5041 case 'd': // int
5042 number = va_arg (args_copy, int);
5043 break;
5044 case 'f': // float
5045 fnumber = va_arg (args_copy, double);
5046 break;
5047 default:
5048 break;
5049 }
5050 }
5051 va_end (args_copy);
5052 va_end (args);
5053}
5054
5055int
5056main ()
5057{
5058
5059 // Check bool.
5060 _Bool success = false;
5061
5062 // Check restrict.
5063 if (test_restrict ("String literal") == 0)
5064 success = true;
5065 char *restrict newvar = "Another string";
5066
5067 // Check varargs.
5068 test_varargs ("s, d' f .", "string", 65, 34.234);
5069 test_varargs_macros ();
5070
5071 // Check flexible array members.
5072 struct incomplete_array *ia =
5073 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5074 ia->datasize = 10;
5075 for (int i = 0; i < ia->datasize; ++i)
5076 ia->data[i] = i * 1.234;
5077
5078 // Check named initializers.
5079 struct named_init ni = {
5080 .number = 34,
5081 .name = L"Test wide string",
5082 .average = 543.34343,
5083 };
5084
5085 ni.number = 58;
5086
5087 int dynamic_array[ni.number];
5088 dynamic_array[ni.number - 1] = 543;
5089
5090 // work around unused variable warnings
5091 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5092 || dynamic_array[ni.number - 1] != 543);
5093
5094 ;
5095 return 0;
5096}
5097_ACEOF
5098for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
5099do
5100 CC="$ac_save_CC $ac_arg"
5101 if ac_fn_c_try_compile "$LINENO"; then :
5102 ac_cv_prog_cc_c99=$ac_arg
5103fi
5104rm -f core conftest.err conftest.$ac_objext
5105 test "x$ac_cv_prog_cc_c99" != "xno" && break
5106done
5107rm -f conftest.$ac_ext
5108CC=$ac_save_CC
5109
5110fi
5111# AC_CACHE_VAL
5112case "x$ac_cv_prog_cc_c99" in
5113 x)
5114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5115$as_echo "none needed" >&6; } ;;
5116 xno)
5117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5118$as_echo "unsupported" >&6; } ;;
5119 *)
5120 CC="$CC $ac_cv_prog_cc_c99"
5121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5122$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
5123esac
5124if test "x$ac_cv_prog_cc_c99" != xno; then :
5125
5126fi
5127
5128
5213506e 5129ac_ext=cpp
2aeb72e9
DD
5130ac_cpp='$CXXCPP $CPPFLAGS'
5131ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5132ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5133ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5213506e
RW
5134if test -z "$CXX"; then
5135 if test -n "$CCC"; then
5136 CXX=$CCC
5137 else
5138 if test -n "$ac_tool_prefix"; then
5139 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
2aeb72e9
DD
5140 do
5141 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5142set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5213506e
RW
5143{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5144$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5145if ${ac_cv_prog_CXX+:} false; then :
5213506e 5146 $as_echo_n "(cached) " >&6
2aeb72e9
DD
5147else
5148 if test -n "$CXX"; then
5149 ac_cv_prog_CXX="$CXX" # Let the user override the test.
5150else
5151as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5152for as_dir in $PATH
5153do
5154 IFS=$as_save_IFS
5155 test -z "$as_dir" && as_dir=.
5213506e 5156 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5157 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2aeb72e9 5158 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
5213506e 5159 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2aeb72e9
DD
5160 break 2
5161 fi
5162done
5213506e
RW
5163 done
5164IFS=$as_save_IFS
55ffb5ed 5165
c3a86da9
DJ
5166fi
5167fi
5168CXX=$ac_cv_prog_CXX
5169if test -n "$CXX"; then
5213506e
RW
5170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5171$as_echo "$CXX" >&6; }
c3a86da9 5172else
5213506e
RW
5173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5174$as_echo "no" >&6; }
c3a86da9
DJ
5175fi
5176
5213506e 5177
c3a86da9
DJ
5178 test -n "$CXX" && break
5179 done
5180fi
5181if test -z "$CXX"; then
5182 ac_ct_CXX=$CXX
5213506e 5183 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
c3a86da9
DJ
5184do
5185 # Extract the first word of "$ac_prog", so it can be a program name with args.
5186set dummy $ac_prog; ac_word=$2
5213506e
RW
5187{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5188$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5189if ${ac_cv_prog_ac_ct_CXX+:} false; then :
5213506e 5190 $as_echo_n "(cached) " >&6
c3a86da9
DJ
5191else
5192 if test -n "$ac_ct_CXX"; then
5193 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
5194else
5195as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5196for as_dir in $PATH
5197do
5198 IFS=$as_save_IFS
5199 test -z "$as_dir" && as_dir=.
5213506e 5200 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
c3a86da9 5202 ac_cv_prog_ac_ct_CXX="$ac_prog"
5213506e 5203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
c3a86da9
DJ
5204 break 2
5205 fi
5206done
5213506e
RW
5207 done
5208IFS=$as_save_IFS
c3a86da9
DJ
5209
5210fi
5211fi
5212ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
5213if test -n "$ac_ct_CXX"; then
5213506e
RW
5214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
5215$as_echo "$ac_ct_CXX" >&6; }
c3a86da9 5216else
5213506e
RW
5217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5218$as_echo "no" >&6; }
c3a86da9
DJ
5219fi
5220
5213506e 5221
c3a86da9
DJ
5222 test -n "$ac_ct_CXX" && break
5223done
c3a86da9 5224
5213506e
RW
5225 if test "x$ac_ct_CXX" = x; then
5226 CXX="g++"
5227 else
5228 case $cross_compiling:$ac_tool_warned in
5229yes:)
5230{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5231$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5232ac_tool_warned=yes ;;
5233esac
5234 CXX=$ac_ct_CXX
5235 fi
c3a86da9
DJ
5236fi
5237
5213506e
RW
5238 fi
5239fi
c3a86da9 5240# Provide some information about the compiler.
5213506e
RW
5241$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
5242set X $ac_compile
5243ac_compiler=$2
5244for ac_option in --version -v -V -qversion; do
5245 { { ac_try="$ac_compiler $ac_option >&5"
5246case "(($ac_try" in
5247 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5248 *) ac_try_echo=$ac_try;;
5249esac
5250eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5251$as_echo "$ac_try_echo"; } >&5
5252 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
c3a86da9 5253 ac_status=$?
5213506e
RW
5254 if test -s conftest.err; then
5255 sed '10a\
5256... rest of stderr output deleted ...
5257 10q' conftest.err >conftest.er1
5258 cat conftest.er1 >&5
5213506e 5259 fi
22e05272 5260 rm -f conftest.er1 conftest.err
5213506e
RW
5261 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5262 test $ac_status = 0; }
5263done
c3a86da9 5264
5213506e
RW
5265{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
5266$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
22e05272 5267if ${ac_cv_cxx_compiler_gnu+:} false; then :
5213506e 5268 $as_echo_n "(cached) " >&6
c3a86da9 5269else
5213506e 5270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9
DJ
5271/* end confdefs.h. */
5272
5273int
5274main ()
5275{
5276#ifndef __GNUC__
5277 choke me
5278#endif
5279
5280 ;
5281 return 0;
5282}
5283_ACEOF
5213506e 5284if ac_fn_cxx_try_compile "$LINENO"; then :
c3a86da9
DJ
5285 ac_compiler_gnu=yes
5286else
5213506e 5287 ac_compiler_gnu=no
c3a86da9 5288fi
5213506e 5289rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
c3a86da9
DJ
5290ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
5291
5292fi
5213506e
RW
5293{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
5294$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
5295if test $ac_compiler_gnu = yes; then
5296 GXX=yes
5297else
5298 GXX=
5299fi
c3a86da9
DJ
5300ac_test_CXXFLAGS=${CXXFLAGS+set}
5301ac_save_CXXFLAGS=$CXXFLAGS
5213506e
RW
5302{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
5303$as_echo_n "checking whether $CXX accepts -g... " >&6; }
22e05272 5304if ${ac_cv_prog_cxx_g+:} false; then :
5213506e
RW
5305 $as_echo_n "(cached) " >&6
5306else
5307 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5308 ac_cxx_werror_flag=yes
5309 ac_cv_prog_cxx_g=no
5310 CXXFLAGS="-g"
5311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9
DJ
5312/* end confdefs.h. */
5313
5314int
5315main ()
5316{
5317
5318 ;
5319 return 0;
5320}
5321_ACEOF
5213506e 5322if ac_fn_cxx_try_compile "$LINENO"; then :
c3a86da9
DJ
5323 ac_cv_prog_cxx_g=yes
5324else
5213506e
RW
5325 CXXFLAGS=""
5326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9 5327/* end confdefs.h. */
5213506e 5328
c3a86da9
DJ
5329int
5330main ()
5331{
5213506e 5332
c3a86da9
DJ
5333 ;
5334 return 0;
5335}
5336_ACEOF
5213506e 5337if ac_fn_cxx_try_compile "$LINENO"; then :
23f6b2f9 5338
5213506e
RW
5339else
5340 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5341 CXXFLAGS="-g"
5342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
c3a86da9 5343/* end confdefs.h. */
5213506e 5344
c3a86da9
DJ
5345int
5346main ()
5347{
5213506e 5348
c3a86da9
DJ
5349 ;
5350 return 0;
5351}
5352_ACEOF
5213506e
RW
5353if ac_fn_cxx_try_compile "$LINENO"; then :
5354 ac_cv_prog_cxx_g=yes
11a67599 5355fi
5213506e
RW
5356rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5357fi
5358rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5359fi
5360rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5361 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5362fi
5363{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
5364$as_echo "$ac_cv_prog_cxx_g" >&6; }
5365if test "$ac_test_CXXFLAGS" = set; then
5366 CXXFLAGS=$ac_save_CXXFLAGS
5367elif test $ac_cv_prog_cxx_g = yes; then
5368 if test "$GXX" = yes; then
5369 CXXFLAGS="-g -O2"
5370 else
5371 CXXFLAGS="-g"
5372 fi
5373else
5374 if test "$GXX" = yes; then
5375 CXXFLAGS="-O2"
5376 else
5377 CXXFLAGS=
5378 fi
c3a86da9 5379fi
c3a86da9
DJ
5380ac_ext=c
5381ac_cpp='$CPP $CPPFLAGS'
5382ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5383ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5384ac_compiler_gnu=$ac_cv_c_compiler_gnu
5385
5386
5387# We must set the default linker to the linker used by gcc for the correct
5388# operation of libtool. If LD is not defined and we are using gcc, try to
5389# set the LD default to the ld used by gcc.
5390if test -z "$LD"; then
5391 if test "$GCC" = yes; then
5392 case $build in
5393 *-*-mingw*)
5394 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
5395 *)
5396 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
5397 esac
5398 case $gcc_prog_ld in
5399 # Accept absolute paths.
5400 [\\/]* | [A-Za-z]:[\\/]*)
5401 LD="$gcc_prog_ld" ;;
5402 esac
5403 fi
23f6b2f9
PB
5404fi
5405
0b21f5d3
EB
5406# Check whether -static-libstdc++ -static-libgcc is supported.
5407have_static_libs=no
5408if test "$GCC" = yes; then
5409 saved_LDFLAGS="$LDFLAGS"
5410
5411 LDFLAGS="$LDFLAGS -static-libstdc++ -static-libgcc"
5412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether g++ accepts -static-libstdc++ -static-libgcc" >&5
5413$as_echo_n "checking whether g++ accepts -static-libstdc++ -static-libgcc... " >&6; }
5414 ac_ext=cpp
5415ac_cpp='$CXXCPP $CPPFLAGS'
5416ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5417ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5418ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5419
5420
5421cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5422/* end confdefs.h. */
0d6414b2
EB
5423
5424#if (__GNUC__ < 4) || (__GNUC__ == 4 && __GNUC_MINOR__ < 5)
5425#error -static-libstdc++ not implemented
5426#endif
0b21f5d3
EB
5427int main() {}
5428_ACEOF
5429if ac_fn_cxx_try_link "$LINENO"; then :
5430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5431$as_echo "yes" >&6; }; have_static_libs=yes
5432else
5433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5434$as_echo "no" >&6; }
5435fi
5436rm -f core conftest.err conftest.$ac_objext \
5437 conftest$ac_exeext conftest.$ac_ext
5438 ac_ext=c
5439ac_cpp='$CPP $CPPFLAGS'
5440ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5441ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5442ac_compiler_gnu=$ac_cv_c_compiler_gnu
5443
5444
5445 LDFLAGS="$saved_LDFLAGS"
5446fi
5447
23f6b2f9
PB
5448
5449
55ffb5ed 5450
1c710c3c
DJ
5451if test -n "$ac_tool_prefix"; then
5452 # Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args.
55ffb5ed 5453set dummy ${ac_tool_prefix}gnatbind; ac_word=$2
5213506e
RW
5454{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5455$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5456if ${ac_cv_prog_GNATBIND+:} false; then :
5213506e 5457 $as_echo_n "(cached) " >&6
55ffb5ed
NN
5458else
5459 if test -n "$GNATBIND"; then
5460 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
5461else
1c710c3c
DJ
5462as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5463for as_dir in $PATH
5464do
5465 IFS=$as_save_IFS
5466 test -z "$as_dir" && as_dir=.
5213506e 5467 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5468 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5469 ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind"
5213506e 5470 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5471 break 2
5472 fi
5473done
5213506e
RW
5474 done
5475IFS=$as_save_IFS
1c710c3c 5476
55ffb5ed
NN
5477fi
5478fi
1c710c3c 5479GNATBIND=$ac_cv_prog_GNATBIND
55ffb5ed 5480if test -n "$GNATBIND"; then
5213506e
RW
5481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATBIND" >&5
5482$as_echo "$GNATBIND" >&6; }
55ffb5ed 5483else
5213506e
RW
5484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5485$as_echo "no" >&6; }
55ffb5ed
NN
5486fi
5487
5213506e 5488
1c710c3c 5489fi
55ffb5ed 5490if test -z "$ac_cv_prog_GNATBIND"; then
1c710c3c 5491 ac_ct_GNATBIND=$GNATBIND
55ffb5ed
NN
5492 # Extract the first word of "gnatbind", so it can be a program name with args.
5493set dummy gnatbind; ac_word=$2
5213506e
RW
5494{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5495$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5496if ${ac_cv_prog_ac_ct_GNATBIND+:} false; then :
5213506e 5497 $as_echo_n "(cached) " >&6
55ffb5ed 5498else
1c710c3c
DJ
5499 if test -n "$ac_ct_GNATBIND"; then
5500 ac_cv_prog_ac_ct_GNATBIND="$ac_ct_GNATBIND" # Let the user override the test.
55ffb5ed 5501else
1c710c3c
DJ
5502as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5503for as_dir in $PATH
5504do
5505 IFS=$as_save_IFS
5506 test -z "$as_dir" && as_dir=.
5213506e 5507 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5508 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5509 ac_cv_prog_ac_ct_GNATBIND="gnatbind"
5213506e 5510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5511 break 2
5512 fi
5513done
5213506e
RW
5514 done
5515IFS=$as_save_IFS
1c710c3c 5516
55ffb5ed
NN
5517fi
5518fi
1c710c3c
DJ
5519ac_ct_GNATBIND=$ac_cv_prog_ac_ct_GNATBIND
5520if test -n "$ac_ct_GNATBIND"; then
5213506e
RW
5521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATBIND" >&5
5522$as_echo "$ac_ct_GNATBIND" >&6; }
55ffb5ed 5523else
5213506e
RW
5524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5525$as_echo "no" >&6; }
55ffb5ed
NN
5526fi
5527
5213506e
RW
5528 if test "x$ac_ct_GNATBIND" = x; then
5529 GNATBIND="no"
5530 else
5531 case $cross_compiling:$ac_tool_warned in
5532yes:)
5533{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5534$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5535ac_tool_warned=yes ;;
5536esac
5537 GNATBIND=$ac_ct_GNATBIND
5538 fi
55ffb5ed 5539else
1c710c3c 5540 GNATBIND="$ac_cv_prog_GNATBIND"
55ffb5ed
NN
5541fi
5542
1c710c3c
DJ
5543if test -n "$ac_tool_prefix"; then
5544 # Extract the first word of "${ac_tool_prefix}gnatmake", so it can be a program name with args.
5305be7e 5545set dummy ${ac_tool_prefix}gnatmake; ac_word=$2
5213506e
RW
5546{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5547$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5548if ${ac_cv_prog_GNATMAKE+:} false; then :
5213506e 5549 $as_echo_n "(cached) " >&6
5305be7e
RG
5550else
5551 if test -n "$GNATMAKE"; then
5552 ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test.
5553else
1c710c3c
DJ
5554as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5555for as_dir in $PATH
5556do
5557 IFS=$as_save_IFS
5558 test -z "$as_dir" && as_dir=.
5213506e 5559 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5560 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5561 ac_cv_prog_GNATMAKE="${ac_tool_prefix}gnatmake"
5213506e 5562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5563 break 2
5564 fi
5565done
5213506e
RW
5566 done
5567IFS=$as_save_IFS
1c710c3c 5568
5305be7e
RG
5569fi
5570fi
1c710c3c 5571GNATMAKE=$ac_cv_prog_GNATMAKE
5305be7e 5572if test -n "$GNATMAKE"; then
5213506e
RW
5573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATMAKE" >&5
5574$as_echo "$GNATMAKE" >&6; }
5305be7e 5575else
5213506e
RW
5576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5577$as_echo "no" >&6; }
5305be7e
RG
5578fi
5579
5213506e 5580
1c710c3c 5581fi
5305be7e 5582if test -z "$ac_cv_prog_GNATMAKE"; then
1c710c3c 5583 ac_ct_GNATMAKE=$GNATMAKE
5305be7e
RG
5584 # Extract the first word of "gnatmake", so it can be a program name with args.
5585set dummy gnatmake; ac_word=$2
5213506e
RW
5586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5587$as_echo_n "checking for $ac_word... " >&6; }
22e05272 5588if ${ac_cv_prog_ac_ct_GNATMAKE+:} false; then :
5213506e 5589 $as_echo_n "(cached) " >&6
5305be7e 5590else
1c710c3c
DJ
5591 if test -n "$ac_ct_GNATMAKE"; then
5592 ac_cv_prog_ac_ct_GNATMAKE="$ac_ct_GNATMAKE" # Let the user override the test.
5305be7e 5593else
1c710c3c
DJ
5594as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5595for as_dir in $PATH
5596do
5597 IFS=$as_save_IFS
5598 test -z "$as_dir" && as_dir=.
5213506e 5599 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 5600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 5601 ac_cv_prog_ac_ct_GNATMAKE="gnatmake"
5213506e 5602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
5603 break 2
5604 fi
5605done
5213506e
RW
5606 done
5607IFS=$as_save_IFS
1c710c3c 5608
5305be7e
RG
5609fi
5610fi
1c710c3c
DJ
5611ac_ct_GNATMAKE=$ac_cv_prog_ac_ct_GNATMAKE
5612if test -n "$ac_ct_GNATMAKE"; then
5213506e
RW
5613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATMAKE" >&5
5614$as_echo "$ac_ct_GNATMAKE" >&6; }
5305be7e 5615else
5213506e
RW
5616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5617$as_echo "no" >&6; }
5305be7e
RG
5618fi
5619
5213506e
RW
5620 if test "x$ac_ct_GNATMAKE" = x; then
5621 GNATMAKE="no"
5622 else
5623 case $cross_compiling:$ac_tool_warned in
5624yes:)
5625{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5626$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5627ac_tool_warned=yes ;;
5628esac
5629 GNATMAKE=$ac_ct_GNATMAKE
5630 fi
5305be7e 5631else
1c710c3c 5632 GNATMAKE="$ac_cv_prog_GNATMAKE"
5305be7e
RG
5633fi
5634
71f068a9
RS
5635{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler driver understands Ada and is recent enough" >&5
5636$as_echo_n "checking whether compiler driver understands Ada and is recent enough... " >&6; }
22e05272 5637if ${acx_cv_cc_gcc_supports_ada+:} false; then :
5213506e 5638 $as_echo_n "(cached) " >&6
55ffb5ed
NN
5639else
5640 cat >conftest.adb <<EOF
71f068a9
RS
5641pragma Warnings (Off);
5642with System.CRTL;
5643pragma Warnings (On);
5644use type System.CRTL.int64;
55ffb5ed
NN
5645procedure conftest is begin null; end conftest;
5646EOF
5647acx_cv_cc_gcc_supports_ada=no
5648# There is a bug in old released versions of GCC which causes the
5649# driver to exit successfully when the appropriate language module
5650# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
5651# Therefore we must check for the error message as well as an
5652# unsuccessful exit.
1db673ca
RO
5653# Other compilers, like HP Tru64 UNIX cc, exit successfully when
5654# given a .adb file, but produce no object file. So we must check
5655# if an object file was really produced to guard against this.
55ffb5ed 5656errors=`(${CC} -c conftest.adb) 2>&1 || echo failure`
1db673ca 5657if test x"$errors" = x && test -f conftest.$ac_objext; then
55ffb5ed 5658 acx_cv_cc_gcc_supports_ada=yes
55ffb5ed
NN
5659fi
5660rm -f conftest.*
5661fi
5213506e
RW
5662{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_cc_gcc_supports_ada" >&5
5663$as_echo "$acx_cv_cc_gcc_supports_ada" >&6; }
55ffb5ed 5664
7cb62ef1 5665if test "x$GNATBIND" != xno && test "x$GNATMAKE" != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
55ffb5ed
NN
5666 have_gnat=yes
5667else
5668 have_gnat=no
5669fi
5670
5fee5ec3
IB
5671
5672
5673if test -n "$ac_tool_prefix"; then
5674 # Extract the first word of "${ac_tool_prefix}gdc", so it can be a program name with args.
5675set dummy ${ac_tool_prefix}gdc; ac_word=$2
5676{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5677$as_echo_n "checking for $ac_word... " >&6; }
5678if ${ac_cv_prog_GDC+:} false; then :
5679 $as_echo_n "(cached) " >&6
5680else
5681 if test -n "$GDC"; then
5682 ac_cv_prog_GDC="$GDC" # Let the user override the test.
5683else
5684as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5685for as_dir in $PATH
5686do
5687 IFS=$as_save_IFS
5688 test -z "$as_dir" && as_dir=.
5689 for ac_exec_ext in '' $ac_executable_extensions; do
5690 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5691 ac_cv_prog_GDC="${ac_tool_prefix}gdc"
5692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5693 break 2
5694 fi
5695done
5696 done
5697IFS=$as_save_IFS
5698
5699fi
5700fi
5701GDC=$ac_cv_prog_GDC
5702if test -n "$GDC"; then
5703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC" >&5
5704$as_echo "$GDC" >&6; }
5705else
5706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5707$as_echo "no" >&6; }
5708fi
5709
5710
5711fi
5712if test -z "$ac_cv_prog_GDC"; then
5713 ac_ct_GDC=$GDC
5714 # Extract the first word of "gdc", so it can be a program name with args.
5715set dummy gdc; ac_word=$2
5716{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5717$as_echo_n "checking for $ac_word... " >&6; }
5718if ${ac_cv_prog_ac_ct_GDC+:} false; then :
5719 $as_echo_n "(cached) " >&6
5720else
5721 if test -n "$ac_ct_GDC"; then
5722 ac_cv_prog_ac_ct_GDC="$ac_ct_GDC" # Let the user override the test.
5723else
5724as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5725for as_dir in $PATH
5726do
5727 IFS=$as_save_IFS
5728 test -z "$as_dir" && as_dir=.
5729 for ac_exec_ext in '' $ac_executable_extensions; do
5730 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5731 ac_cv_prog_ac_ct_GDC="gdc"
5732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5733 break 2
5734 fi
5735done
5736 done
5737IFS=$as_save_IFS
5738
5739fi
5740fi
5741ac_ct_GDC=$ac_cv_prog_ac_ct_GDC
5742if test -n "$ac_ct_GDC"; then
5743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GDC" >&5
5744$as_echo "$ac_ct_GDC" >&6; }
5745else
5746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5747$as_echo "no" >&6; }
5748fi
5749
5750 if test "x$ac_ct_GDC" = x; then
5751 GDC="no"
5752 else
5753 case $cross_compiling:$ac_tool_warned in
5754yes:)
5755{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5756$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5757ac_tool_warned=yes ;;
5758esac
5759 GDC=$ac_ct_GDC
5760 fi
5761else
5762 GDC="$ac_cv_prog_GDC"
5763fi
5764
7c6ae994
IB
5765{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the D compiler works" >&5
5766$as_echo_n "checking whether the D compiler works... " >&6; }
5767if ${acx_cv_d_compiler_works+:} false; then :
5768 $as_echo_n "(cached) " >&6
5769else
5770 cat >conftest.d <<EOF
5771module conftest; int main() { return 0; }
5772EOF
5773acx_cv_d_compiler_works=no
5fee5ec3 5774if test "x$GDC" != xno; then
7c6ae994
IB
5775 errors=`(${GDC} -c conftest.d) 2>&1 || echo failure`
5776 if test x"$errors" = x && test -f conftest.$ac_objext; then
5777 acx_cv_d_compiler_works=yes
5778 fi
5779 rm -f conftest.*
5780fi
5781fi
5782{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_d_compiler_works" >&5
5783$as_echo "$acx_cv_d_compiler_works" >&6; }
5784if test "x$GDC" != xno && test x$acx_cv_d_compiler_works != xno; then
5fee5ec3
IB
5785 have_gdc=yes
5786else
5787 have_gdc=no
5788fi
5789
3ebc7898
TS
5790for ac_prog in cargo
5791do
5792 # Extract the first word of "$ac_prog", so it can be a program name with args.
5793set dummy $ac_prog; ac_word=$2
3e1e73fc
PEP
5794{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5795$as_echo_n "checking for $ac_word... " >&6; }
5796if ${ac_cv_prog_CARGO+:} false; then :
5797 $as_echo_n "(cached) " >&6
5798else
5799 if test -n "$CARGO"; then
5800 ac_cv_prog_CARGO="$CARGO" # Let the user override the test.
5801else
5802as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5803for as_dir in $PATH
5804do
5805 IFS=$as_save_IFS
5806 test -z "$as_dir" && as_dir=.
5807 for ac_exec_ext in '' $ac_executable_extensions; do
5808 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3ebc7898 5809 ac_cv_prog_CARGO="$ac_prog"
3e1e73fc
PEP
5810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5811 break 2
5812 fi
5813done
5814 done
5815IFS=$as_save_IFS
5816
5817fi
5818fi
5819CARGO=$ac_cv_prog_CARGO
5820if test -n "$CARGO"; then
5821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CARGO" >&5
5822$as_echo "$CARGO" >&6; }
5823else
5824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5825$as_echo "no" >&6; }
5826fi
5827
5828
3ebc7898 5829 test -n "$CARGO" && break
3e1e73fc 5830done
3ebc7898 5831test -n "$CARGO" || CARGO="no"
3e1e73fc
PEP
5832
5833if test "x$CARGO" != xno; then
5834 have_cargo=yes
5835else
5836 have_cargo=no
5837fi
5213506e
RW
5838{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to compare bootstrapped objects" >&5
5839$as_echo_n "checking how to compare bootstrapped objects... " >&6; }
22e05272 5840if ${gcc_cv_prog_cmp_skip+:} false; then :
5213506e 5841 $as_echo_n "(cached) " >&6
a76494aa
PB
5842else
5843 echo abfoo >t1
5844 echo cdfoo >t2
b55e6680 5845 gcc_cv_prog_cmp_skip='tail -c +17 $$f1 > tmp-foo1; tail -c +17 $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
6cf1ac42
PB
5846 if cmp t1 t2 2 2 > /dev/null 2>&1; then
5847 if cmp t1 t2 1 1 > /dev/null 2>&1; then
5848 :
5849 else
5850 gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
5851 fi
5852 fi
a76494aa
PB
5853 if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
5854 if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
6cf1ac42 5855 :
a76494aa
PB
5856 else
5857 gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
5858 fi
5859 fi
5860 rm t1 t2
5861
5862fi
5213506e
RW
5863{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_cmp_skip" >&5
5864$as_echo "$gcc_cv_prog_cmp_skip" >&6; }
a76494aa
PB
5865do_compare="$gcc_cv_prog_cmp_skip"
5866
5867
55ffb5ed 5868
ff3ac0f4
ILT
5869# Check whether --enable-bootstrap was given.
5870if test "${enable_bootstrap+set}" = set; then :
5871 enableval=$enable_bootstrap;
5872else
5873 enable_bootstrap=default
5874fi
5875
5876
5877# Issue errors and warnings for invalid/strange bootstrap combinations.
bf03b9ff
ILT
5878if test -r $srcdir/gcc/configure; then
5879 have_compiler=yes
5880else
5881 have_compiler=no
5882fi
ff3ac0f4
ILT
5883
5884case "$have_compiler:$host:$target:$enable_bootstrap" in
5885 *:*:*:no) ;;
5886
5887 # Default behavior. Enable bootstrap if we have a compiler
5888 # and we are in a native configuration.
5889 yes:$build:$build:default)
5890 enable_bootstrap=yes ;;
5891
5892 *:*:*:default)
5893 enable_bootstrap=no ;;
5894
5895 # We have a compiler and we are in a native configuration, bootstrap is ok
5896 yes:$build:$build:yes)
5897 ;;
5898
5899 # Other configurations, but we have a compiler. Assume the user knows
5900 # what he's doing.
5901 yes:*:*:yes)
5902 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: trying to bootstrap a cross compiler" >&5
5903$as_echo "$as_me: WARNING: trying to bootstrap a cross compiler" >&2;}
5904 ;;
5905
5906 # No compiler: if they passed --enable-bootstrap explicitly, fail
5907 no:*:*:yes)
22e05272 5908 as_fn_error $? "cannot bootstrap without a compiler" "$LINENO" 5 ;;
ff3ac0f4
ILT
5909
5910 # Fail if wrong command line
5911 *)
22e05272 5912 as_fn_error $? "invalid option for --enable-bootstrap" "$LINENO" 5
ff3ac0f4
ILT
5913 ;;
5914esac
5915
5329b59a 5916# When bootstrapping with GCC, build stage 1 in C++11 mode to ensure that a
ffac9597
JM
5917# C++11 compiler can still start the bootstrap. Otherwise, if building GCC,
5918# require C++11 (or higher).
46070488 5919if test "$enable_bootstrap:$GXX" = "yes:yes"; then
5329b59a 5920 CXX="$CXX -std=c++11"
ffac9597
JM
5921elif test "$have_compiler" = yes; then
5922 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
5923 ac_ext=cpp
5924ac_cpp='$CXXCPP $CPPFLAGS'
5925ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5926ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5927ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5928 ac_success=no
5929
5930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
5931$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
5932if ${ax_cv_cxx_compile_cxx11+:} false; then :
5933 $as_echo_n "(cached) " >&6
5934else
5935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5936/* end confdefs.h. */
5937
5938
5939// If the compiler admits that it is not ready for C++11, why torture it?
5940// Hopefully, this will speed up the test.
5941
5942#ifndef __cplusplus
5943
5944#error "This is not a C++ compiler"
5945
5946#elif __cplusplus < 201103L
5947
5948#error "This is not a C++11 compiler"
5949
5950#else
5951
5952namespace cxx11
5953{
5954
5955 namespace test_static_assert
5956 {
5957
5958 template <typename T>
5959 struct check
5960 {
5961 static_assert(sizeof(int) <= sizeof(T), "not big enough");
5962 };
5963
5964 }
5965
5966 namespace test_final_override
5967 {
5968
5969 struct Base
5970 {
5971 virtual ~Base() {}
5972 virtual void f() {}
5973 };
5974
5975 struct Derived : public Base
5976 {
5977 virtual ~Derived() override {}
5978 virtual void f() override {}
5979 };
5980
5981 }
5982
5983 namespace test_double_right_angle_brackets
5984 {
5985
5986 template < typename T >
5987 struct check {};
5988
5989 typedef check<void> single_type;
5990 typedef check<check<void>> double_type;
5991 typedef check<check<check<void>>> triple_type;
5992 typedef check<check<check<check<void>>>> quadruple_type;
5993
5994 }
5995
5996 namespace test_decltype
5997 {
5998
5999 int
6000 f()
6001 {
6002 int a = 1;
6003 decltype(a) b = 2;
6004 return a + b;
6005 }
6006
6007 }
6008
6009 namespace test_type_deduction
6010 {
6011
6012 template < typename T1, typename T2 >
6013 struct is_same
6014 {
6015 static const bool value = false;
6016 };
6017
6018 template < typename T >
6019 struct is_same<T, T>
6020 {
6021 static const bool value = true;
6022 };
6023
6024 template < typename T1, typename T2 >
6025 auto
6026 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6027 {
6028 return a1 + a2;
6029 }
6030
6031 int
6032 test(const int c, volatile int v)
6033 {
6034 static_assert(is_same<int, decltype(0)>::value == true, "");
6035 static_assert(is_same<int, decltype(c)>::value == false, "");
6036 static_assert(is_same<int, decltype(v)>::value == false, "");
6037 auto ac = c;
6038 auto av = v;
6039 auto sumi = ac + av + 'x';
6040 auto sumf = ac + av + 1.0;
6041 static_assert(is_same<int, decltype(ac)>::value == true, "");
6042 static_assert(is_same<int, decltype(av)>::value == true, "");
6043 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6044 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6045 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6046 return (sumf > 0.0) ? sumi : add(c, v);
6047 }
6048
6049 }
6050
6051 namespace test_noexcept
6052 {
6053
6054 int f() { return 0; }
6055 int g() noexcept { return 0; }
6056
6057 static_assert(noexcept(f()) == false, "");
6058 static_assert(noexcept(g()) == true, "");
6059
6060 }
6061
6062 namespace test_constexpr
6063 {
6064
6065 template < typename CharT >
6066 unsigned long constexpr
6067 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6068 {
6069 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6070 }
6071
6072 template < typename CharT >
6073 unsigned long constexpr
6074 strlen_c(const CharT *const s) noexcept
6075 {
6076 return strlen_c_r(s, 0UL);
6077 }
6078
6079 static_assert(strlen_c("") == 0UL, "");
6080 static_assert(strlen_c("1") == 1UL, "");
6081 static_assert(strlen_c("example") == 7UL, "");
6082 static_assert(strlen_c("another\0example") == 7UL, "");
6083
6084 }
6085
6086 namespace test_rvalue_references
6087 {
6088
6089 template < int N >
6090 struct answer
6091 {
6092 static constexpr int value = N;
6093 };
6094
6095 answer<1> f(int&) { return answer<1>(); }
6096 answer<2> f(const int&) { return answer<2>(); }
6097 answer<3> f(int&&) { return answer<3>(); }
6098
6099 void
6100 test()
6101 {
6102 int i = 0;
6103 const int c = 0;
6104 static_assert(decltype(f(i))::value == 1, "");
6105 static_assert(decltype(f(c))::value == 2, "");
6106 static_assert(decltype(f(0))::value == 3, "");
6107 }
6108
6109 }
6110
6111 namespace test_uniform_initialization
6112 {
6113
6114 struct test
6115 {
6116 static const int zero {};
6117 static const int one {1};
6118 };
6119
6120 static_assert(test::zero == 0, "");
6121 static_assert(test::one == 1, "");
6122
6123 }
6124
6125 namespace test_lambdas
6126 {
6127
6128 void
6129 test1()
6130 {
6131 auto lambda1 = [](){};
6132 auto lambda2 = lambda1;
6133 lambda1();
6134 lambda2();
6135 }
6136
6137 int
6138 test2()
6139 {
6140 auto a = [](int i, int j){ return i + j; }(1, 2);
6141 auto b = []() -> int { return '0'; }();
6142 auto c = [=](){ return a + b; }();
6143 auto d = [&](){ return c; }();
6144 auto e = [a, &b](int x) mutable {
6145 const auto identity = [](int y){ return y; };
6146 for (auto i = 0; i < a; ++i)
6147 a += b--;
6148 return x + identity(a + b);
6149 }(0);
6150 return a + b + c + d + e;
6151 }
6152
6153 int
6154 test3()
6155 {
6156 const auto nullary = [](){ return 0; };
6157 const auto unary = [](int x){ return x; };
6158 using nullary_t = decltype(nullary);
6159 using unary_t = decltype(unary);
6160 const auto higher1st = [](nullary_t f){ return f(); };
6161 const auto higher2nd = [unary](nullary_t f1){
6162 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6163 };
6164 return higher1st(nullary) + higher2nd(nullary)(unary);
6165 }
6166
6167 }
6168
6169 namespace test_variadic_templates
6170 {
6171
6172 template <int...>
6173 struct sum;
6174
6175 template <int N0, int... N1toN>
6176 struct sum<N0, N1toN...>
6177 {
6178 static constexpr auto value = N0 + sum<N1toN...>::value;
6179 };
6180
6181 template <>
6182 struct sum<>
6183 {
6184 static constexpr auto value = 0;
6185 };
6186
6187 static_assert(sum<>::value == 0, "");
6188 static_assert(sum<1>::value == 1, "");
6189 static_assert(sum<23>::value == 23, "");
6190 static_assert(sum<1, 2>::value == 3, "");
6191 static_assert(sum<5, 5, 11>::value == 21, "");
6192 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6193
6194 }
6195
6196 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6197 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6198 // because of this.
6199 namespace test_template_alias_sfinae
6200 {
6201
6202 struct foo {};
6203
6204 template<typename T>
6205 using member = typename T::member_type;
6206
6207 template<typename T>
6208 void func(...) {}
6209
6210 template<typename T>
6211 void func(member<T>*) {}
6212
6213 void test();
6214
6215 void test() { func<foo>(0); }
6216
6217 }
6218
6219} // namespace cxx11
6220
6221#endif // __cplusplus >= 201103L
6222
6223
6224
6225_ACEOF
6226if ac_fn_cxx_try_compile "$LINENO"; then :
6227 ax_cv_cxx_compile_cxx11=yes
6228else
6229 ax_cv_cxx_compile_cxx11=no
6230fi
6231rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6232fi
6233{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
6234$as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
6235 if test x$ax_cv_cxx_compile_cxx11 = xyes; then
6236 ac_success=yes
6237 fi
6238
6239 if test x$ac_success = xno; then
6240 for alternative in ${ax_cxx_compile_alternatives}; do
6241 switch="-std=gnu++${alternative}"
6242 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
6243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
6244$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
6245if eval \${$cachevar+:} false; then :
6246 $as_echo_n "(cached) " >&6
6247else
6248 ac_save_CXX="$CXX"
6249 CXX="$CXX $switch"
6250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6251/* end confdefs.h. */
6252
6253
6254// If the compiler admits that it is not ready for C++11, why torture it?
6255// Hopefully, this will speed up the test.
6256
6257#ifndef __cplusplus
6258
6259#error "This is not a C++ compiler"
6260
6261#elif __cplusplus < 201103L
6262
6263#error "This is not a C++11 compiler"
6264
6265#else
6266
6267namespace cxx11
6268{
6269
6270 namespace test_static_assert
6271 {
6272
6273 template <typename T>
6274 struct check
6275 {
6276 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6277 };
6278
6279 }
6280
6281 namespace test_final_override
6282 {
6283
6284 struct Base
6285 {
6286 virtual ~Base() {}
6287 virtual void f() {}
6288 };
6289
6290 struct Derived : public Base
6291 {
6292 virtual ~Derived() override {}
6293 virtual void f() override {}
6294 };
6295
6296 }
6297
6298 namespace test_double_right_angle_brackets
6299 {
6300
6301 template < typename T >
6302 struct check {};
6303
6304 typedef check<void> single_type;
6305 typedef check<check<void>> double_type;
6306 typedef check<check<check<void>>> triple_type;
6307 typedef check<check<check<check<void>>>> quadruple_type;
6308
6309 }
6310
6311 namespace test_decltype
6312 {
6313
6314 int
6315 f()
6316 {
6317 int a = 1;
6318 decltype(a) b = 2;
6319 return a + b;
6320 }
6321
6322 }
6323
6324 namespace test_type_deduction
6325 {
6326
6327 template < typename T1, typename T2 >
6328 struct is_same
6329 {
6330 static const bool value = false;
6331 };
6332
6333 template < typename T >
6334 struct is_same<T, T>
6335 {
6336 static const bool value = true;
6337 };
6338
6339 template < typename T1, typename T2 >
6340 auto
6341 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6342 {
6343 return a1 + a2;
6344 }
6345
6346 int
6347 test(const int c, volatile int v)
6348 {
6349 static_assert(is_same<int, decltype(0)>::value == true, "");
6350 static_assert(is_same<int, decltype(c)>::value == false, "");
6351 static_assert(is_same<int, decltype(v)>::value == false, "");
6352 auto ac = c;
6353 auto av = v;
6354 auto sumi = ac + av + 'x';
6355 auto sumf = ac + av + 1.0;
6356 static_assert(is_same<int, decltype(ac)>::value == true, "");
6357 static_assert(is_same<int, decltype(av)>::value == true, "");
6358 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6359 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6360 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6361 return (sumf > 0.0) ? sumi : add(c, v);
6362 }
6363
6364 }
6365
6366 namespace test_noexcept
6367 {
6368
6369 int f() { return 0; }
6370 int g() noexcept { return 0; }
6371
6372 static_assert(noexcept(f()) == false, "");
6373 static_assert(noexcept(g()) == true, "");
6374
6375 }
6376
6377 namespace test_constexpr
6378 {
6379
6380 template < typename CharT >
6381 unsigned long constexpr
6382 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6383 {
6384 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6385 }
6386
6387 template < typename CharT >
6388 unsigned long constexpr
6389 strlen_c(const CharT *const s) noexcept
6390 {
6391 return strlen_c_r(s, 0UL);
6392 }
6393
6394 static_assert(strlen_c("") == 0UL, "");
6395 static_assert(strlen_c("1") == 1UL, "");
6396 static_assert(strlen_c("example") == 7UL, "");
6397 static_assert(strlen_c("another\0example") == 7UL, "");
6398
6399 }
6400
6401 namespace test_rvalue_references
6402 {
6403
6404 template < int N >
6405 struct answer
6406 {
6407 static constexpr int value = N;
6408 };
6409
6410 answer<1> f(int&) { return answer<1>(); }
6411 answer<2> f(const int&) { return answer<2>(); }
6412 answer<3> f(int&&) { return answer<3>(); }
6413
6414 void
6415 test()
6416 {
6417 int i = 0;
6418 const int c = 0;
6419 static_assert(decltype(f(i))::value == 1, "");
6420 static_assert(decltype(f(c))::value == 2, "");
6421 static_assert(decltype(f(0))::value == 3, "");
6422 }
6423
6424 }
6425
6426 namespace test_uniform_initialization
6427 {
6428
6429 struct test
6430 {
6431 static const int zero {};
6432 static const int one {1};
6433 };
6434
6435 static_assert(test::zero == 0, "");
6436 static_assert(test::one == 1, "");
6437
6438 }
6439
6440 namespace test_lambdas
6441 {
6442
6443 void
6444 test1()
6445 {
6446 auto lambda1 = [](){};
6447 auto lambda2 = lambda1;
6448 lambda1();
6449 lambda2();
6450 }
6451
6452 int
6453 test2()
6454 {
6455 auto a = [](int i, int j){ return i + j; }(1, 2);
6456 auto b = []() -> int { return '0'; }();
6457 auto c = [=](){ return a + b; }();
6458 auto d = [&](){ return c; }();
6459 auto e = [a, &b](int x) mutable {
6460 const auto identity = [](int y){ return y; };
6461 for (auto i = 0; i < a; ++i)
6462 a += b--;
6463 return x + identity(a + b);
6464 }(0);
6465 return a + b + c + d + e;
6466 }
6467
6468 int
6469 test3()
6470 {
6471 const auto nullary = [](){ return 0; };
6472 const auto unary = [](int x){ return x; };
6473 using nullary_t = decltype(nullary);
6474 using unary_t = decltype(unary);
6475 const auto higher1st = [](nullary_t f){ return f(); };
6476 const auto higher2nd = [unary](nullary_t f1){
6477 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6478 };
6479 return higher1st(nullary) + higher2nd(nullary)(unary);
6480 }
6481
6482 }
6483
6484 namespace test_variadic_templates
6485 {
6486
6487 template <int...>
6488 struct sum;
6489
6490 template <int N0, int... N1toN>
6491 struct sum<N0, N1toN...>
6492 {
6493 static constexpr auto value = N0 + sum<N1toN...>::value;
6494 };
6495
6496 template <>
6497 struct sum<>
6498 {
6499 static constexpr auto value = 0;
6500 };
6501
6502 static_assert(sum<>::value == 0, "");
6503 static_assert(sum<1>::value == 1, "");
6504 static_assert(sum<23>::value == 23, "");
6505 static_assert(sum<1, 2>::value == 3, "");
6506 static_assert(sum<5, 5, 11>::value == 21, "");
6507 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6508
6509 }
6510
6511 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6512 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6513 // because of this.
6514 namespace test_template_alias_sfinae
6515 {
6516
6517 struct foo {};
6518
6519 template<typename T>
6520 using member = typename T::member_type;
6521
6522 template<typename T>
6523 void func(...) {}
6524
6525 template<typename T>
6526 void func(member<T>*) {}
6527
6528 void test();
6529
6530 void test() { func<foo>(0); }
6531
6532 }
6533
6534} // namespace cxx11
6535
6536#endif // __cplusplus >= 201103L
6537
6538
6539
6540_ACEOF
6541if ac_fn_cxx_try_compile "$LINENO"; then :
6542 eval $cachevar=yes
6543else
6544 eval $cachevar=no
6545fi
6546rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6547 CXX="$ac_save_CXX"
6548fi
6549eval ac_res=\$$cachevar
6550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6551$as_echo "$ac_res" >&6; }
6552 if eval test x\$$cachevar = xyes; then
6553 CXX="$CXX $switch"
6554 if test -n "$CXXCPP" ; then
6555 CXXCPP="$CXXCPP $switch"
6556 fi
6557 ac_success=yes
6558 break
6559 fi
6560 done
6561 fi
6562
6563 if test x$ac_success = xno; then
6564 for alternative in ${ax_cxx_compile_alternatives}; do
6565 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
6566 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
6567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
6568$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
6569if eval \${$cachevar+:} false; then :
6570 $as_echo_n "(cached) " >&6
6571else
6572 ac_save_CXX="$CXX"
6573 CXX="$CXX $switch"
6574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6575/* end confdefs.h. */
6576
6577
6578// If the compiler admits that it is not ready for C++11, why torture it?
6579// Hopefully, this will speed up the test.
6580
6581#ifndef __cplusplus
6582
6583#error "This is not a C++ compiler"
6584
6585#elif __cplusplus < 201103L
6586
6587#error "This is not a C++11 compiler"
6588
6589#else
6590
6591namespace cxx11
6592{
6593
6594 namespace test_static_assert
6595 {
6596
6597 template <typename T>
6598 struct check
6599 {
6600 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6601 };
6602
6603 }
6604
6605 namespace test_final_override
6606 {
6607
6608 struct Base
6609 {
6610 virtual ~Base() {}
6611 virtual void f() {}
6612 };
6613
6614 struct Derived : public Base
6615 {
6616 virtual ~Derived() override {}
6617 virtual void f() override {}
6618 };
6619
6620 }
6621
6622 namespace test_double_right_angle_brackets
6623 {
6624
6625 template < typename T >
6626 struct check {};
6627
6628 typedef check<void> single_type;
6629 typedef check<check<void>> double_type;
6630 typedef check<check<check<void>>> triple_type;
6631 typedef check<check<check<check<void>>>> quadruple_type;
6632
6633 }
6634
6635 namespace test_decltype
6636 {
6637
6638 int
6639 f()
6640 {
6641 int a = 1;
6642 decltype(a) b = 2;
6643 return a + b;
6644 }
6645
6646 }
6647
6648 namespace test_type_deduction
6649 {
6650
6651 template < typename T1, typename T2 >
6652 struct is_same
6653 {
6654 static const bool value = false;
6655 };
6656
6657 template < typename T >
6658 struct is_same<T, T>
6659 {
6660 static const bool value = true;
6661 };
6662
6663 template < typename T1, typename T2 >
6664 auto
6665 add(T1 a1, T2 a2) -> decltype(a1 + a2)
6666 {
6667 return a1 + a2;
6668 }
6669
6670 int
6671 test(const int c, volatile int v)
6672 {
6673 static_assert(is_same<int, decltype(0)>::value == true, "");
6674 static_assert(is_same<int, decltype(c)>::value == false, "");
6675 static_assert(is_same<int, decltype(v)>::value == false, "");
6676 auto ac = c;
6677 auto av = v;
6678 auto sumi = ac + av + 'x';
6679 auto sumf = ac + av + 1.0;
6680 static_assert(is_same<int, decltype(ac)>::value == true, "");
6681 static_assert(is_same<int, decltype(av)>::value == true, "");
6682 static_assert(is_same<int, decltype(sumi)>::value == true, "");
6683 static_assert(is_same<int, decltype(sumf)>::value == false, "");
6684 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
6685 return (sumf > 0.0) ? sumi : add(c, v);
6686 }
6687
6688 }
6689
6690 namespace test_noexcept
6691 {
6692
6693 int f() { return 0; }
6694 int g() noexcept { return 0; }
6695
6696 static_assert(noexcept(f()) == false, "");
6697 static_assert(noexcept(g()) == true, "");
6698
6699 }
6700
6701 namespace test_constexpr
6702 {
6703
6704 template < typename CharT >
6705 unsigned long constexpr
6706 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
6707 {
6708 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
6709 }
6710
6711 template < typename CharT >
6712 unsigned long constexpr
6713 strlen_c(const CharT *const s) noexcept
6714 {
6715 return strlen_c_r(s, 0UL);
6716 }
6717
6718 static_assert(strlen_c("") == 0UL, "");
6719 static_assert(strlen_c("1") == 1UL, "");
6720 static_assert(strlen_c("example") == 7UL, "");
6721 static_assert(strlen_c("another\0example") == 7UL, "");
6722
6723 }
6724
6725 namespace test_rvalue_references
6726 {
6727
6728 template < int N >
6729 struct answer
6730 {
6731 static constexpr int value = N;
6732 };
6733
6734 answer<1> f(int&) { return answer<1>(); }
6735 answer<2> f(const int&) { return answer<2>(); }
6736 answer<3> f(int&&) { return answer<3>(); }
6737
6738 void
6739 test()
6740 {
6741 int i = 0;
6742 const int c = 0;
6743 static_assert(decltype(f(i))::value == 1, "");
6744 static_assert(decltype(f(c))::value == 2, "");
6745 static_assert(decltype(f(0))::value == 3, "");
6746 }
6747
6748 }
6749
6750 namespace test_uniform_initialization
6751 {
6752
6753 struct test
6754 {
6755 static const int zero {};
6756 static const int one {1};
6757 };
6758
6759 static_assert(test::zero == 0, "");
6760 static_assert(test::one == 1, "");
6761
6762 }
6763
6764 namespace test_lambdas
6765 {
6766
6767 void
6768 test1()
6769 {
6770 auto lambda1 = [](){};
6771 auto lambda2 = lambda1;
6772 lambda1();
6773 lambda2();
6774 }
6775
6776 int
6777 test2()
6778 {
6779 auto a = [](int i, int j){ return i + j; }(1, 2);
6780 auto b = []() -> int { return '0'; }();
6781 auto c = [=](){ return a + b; }();
6782 auto d = [&](){ return c; }();
6783 auto e = [a, &b](int x) mutable {
6784 const auto identity = [](int y){ return y; };
6785 for (auto i = 0; i < a; ++i)
6786 a += b--;
6787 return x + identity(a + b);
6788 }(0);
6789 return a + b + c + d + e;
6790 }
6791
6792 int
6793 test3()
6794 {
6795 const auto nullary = [](){ return 0; };
6796 const auto unary = [](int x){ return x; };
6797 using nullary_t = decltype(nullary);
6798 using unary_t = decltype(unary);
6799 const auto higher1st = [](nullary_t f){ return f(); };
6800 const auto higher2nd = [unary](nullary_t f1){
6801 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
6802 };
6803 return higher1st(nullary) + higher2nd(nullary)(unary);
6804 }
6805
6806 }
6807
6808 namespace test_variadic_templates
6809 {
6810
6811 template <int...>
6812 struct sum;
6813
6814 template <int N0, int... N1toN>
6815 struct sum<N0, N1toN...>
6816 {
6817 static constexpr auto value = N0 + sum<N1toN...>::value;
6818 };
6819
6820 template <>
6821 struct sum<>
6822 {
6823 static constexpr auto value = 0;
6824 };
6825
6826 static_assert(sum<>::value == 0, "");
6827 static_assert(sum<1>::value == 1, "");
6828 static_assert(sum<23>::value == 23, "");
6829 static_assert(sum<1, 2>::value == 3, "");
6830 static_assert(sum<5, 5, 11>::value == 21, "");
6831 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
6832
6833 }
6834
6835 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
6836 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
6837 // because of this.
6838 namespace test_template_alias_sfinae
6839 {
6840
6841 struct foo {};
6842
6843 template<typename T>
6844 using member = typename T::member_type;
6845
6846 template<typename T>
6847 void func(...) {}
6848
6849 template<typename T>
6850 void func(member<T>*) {}
6851
6852 void test();
6853
6854 void test() { func<foo>(0); }
6855
6856 }
6857
6858} // namespace cxx11
6859
6860#endif // __cplusplus >= 201103L
6861
6862
6863
6864_ACEOF
6865if ac_fn_cxx_try_compile "$LINENO"; then :
6866 eval $cachevar=yes
6867else
6868 eval $cachevar=no
6869fi
6870rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6871 CXX="$ac_save_CXX"
6872fi
6873eval ac_res=\$$cachevar
6874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
6875$as_echo "$ac_res" >&6; }
6876 if eval test x\$$cachevar = xyes; then
6877 CXX="$CXX $switch"
6878 if test -n "$CXXCPP" ; then
6879 CXXCPP="$CXXCPP $switch"
6880 fi
6881 ac_success=yes
6882 break
6883 fi
6884 done
6885 if test x$ac_success = xyes; then
6886 break
6887 fi
6888 done
6889 fi
7ffcf5d6 6890
ffac9597
JM
6891 ac_ext=c
6892ac_cpp='$CPP $CPPFLAGS'
6893ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6894ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6895ac_compiler_gnu=$ac_cv_c_compiler_gnu
6896
6897 if test x$ax_cxx_compile_cxx11_required = xtrue; then
6898 if test x$ac_success = xno; then
6899 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
6900 fi
6901 fi
6902 if test x$ac_success = xno; then
6903 HAVE_CXX11=0
6904 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
6905$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
6906 else
6907 HAVE_CXX11=1
6908
6909$as_echo "#define HAVE_CXX11 1" >>confdefs.h
6910
6911 fi
6912
6913
7ffcf5d6
TB
6914
6915 if test "${build}" != "${host}"; then
6916 ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
6917 ac_ext=cpp
6918ac_cpp='$CXXCPP $CPPFLAGS'
6919ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6920ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6921ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6922 ac_success=no
6923 ax_cv_cxx_compile_cxx11_orig_cxx="$CXX"
6924 ax_cv_cxx_compile_cxx11_orig_cxxflags="$CXXFLAGS"
6925 ax_cv_cxx_compile_cxx11_orig_cppflags="$CPPFLAGS"
6926 CXX="$CXX_FOR_BUILD"
6927 CXXFLAGS="$CXXFLAGS_FOR_BUILD"
6928 CPPFLAGS="$CPPFLAGS_FOR_BUILD"
6929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
6930$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
6931if ${ax_cv_cxx_compile_cxx11_FOR_BUILD+:} false; then :
6932 $as_echo_n "(cached) " >&6
6933else
6934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6935/* end confdefs.h. */
6936
6937
6938// If the compiler admits that it is not ready for C++11, why torture it?
6939// Hopefully, this will speed up the test.
6940
6941#ifndef __cplusplus
6942
6943#error "This is not a C++ compiler"
6944
6945#elif __cplusplus < 201103L
6946
6947#error "This is not a C++11 compiler"
6948
6949#else
6950
6951namespace cxx11
6952{
6953
6954 namespace test_static_assert
6955 {
6956
6957 template <typename T>
6958 struct check
6959 {
6960 static_assert(sizeof(int) <= sizeof(T), "not big enough");
6961 };
6962
6963 }
6964
6965 namespace test_final_override
6966 {
6967
6968 struct Base
6969 {
6970 virtual ~Base() {}
6971 virtual void f() {}
6972 };
6973
6974 struct Derived : public Base
6975 {
6976 virtual ~Derived() override {}
6977 virtual void f() override {}
6978 };
6979
6980 }
6981
6982 namespace test_double_right_angle_brackets
6983 {
6984
6985 template < typename T >
6986 struct check {};
6987
6988 typedef check<void> single_type;
6989 typedef check<check<void>> double_type;
6990 typedef check<check<check<void>>> triple_type;
6991 typedef check<check<check<check<void>>>> quadruple_type;
6992
6993 }
6994
6995 namespace test_decltype
6996 {
6997
6998 int
6999 f()
7000 {
7001 int a = 1;
7002 decltype(a) b = 2;
7003 return a + b;
7004 }
7005
7006 }
7007
7008 namespace test_type_deduction
7009 {
7010
7011 template < typename T1, typename T2 >
7012 struct is_same
7013 {
7014 static const bool value = false;
7015 };
7016
7017 template < typename T >
7018 struct is_same<T, T>
7019 {
7020 static const bool value = true;
7021 };
7022
7023 template < typename T1, typename T2 >
7024 auto
7025 add(T1 a1, T2 a2) -> decltype(a1 + a2)
7026 {
7027 return a1 + a2;
7028 }
7029
7030 int
7031 test(const int c, volatile int v)
7032 {
7033 static_assert(is_same<int, decltype(0)>::value == true, "");
7034 static_assert(is_same<int, decltype(c)>::value == false, "");
7035 static_assert(is_same<int, decltype(v)>::value == false, "");
7036 auto ac = c;
7037 auto av = v;
7038 auto sumi = ac + av + 'x';
7039 auto sumf = ac + av + 1.0;
7040 static_assert(is_same<int, decltype(ac)>::value == true, "");
7041 static_assert(is_same<int, decltype(av)>::value == true, "");
7042 static_assert(is_same<int, decltype(sumi)>::value == true, "");
7043 static_assert(is_same<int, decltype(sumf)>::value == false, "");
7044 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
7045 return (sumf > 0.0) ? sumi : add(c, v);
7046 }
7047
7048 }
7049
7050 namespace test_noexcept
7051 {
7052
7053 int f() { return 0; }
7054 int g() noexcept { return 0; }
7055
7056 static_assert(noexcept(f()) == false, "");
7057 static_assert(noexcept(g()) == true, "");
7058
7059 }
7060
7061 namespace test_constexpr
7062 {
7063
7064 template < typename CharT >
7065 unsigned long constexpr
7066 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
7067 {
7068 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
7069 }
7070
7071 template < typename CharT >
7072 unsigned long constexpr
7073 strlen_c(const CharT *const s) noexcept
7074 {
7075 return strlen_c_r(s, 0UL);
7076 }
7077
7078 static_assert(strlen_c("") == 0UL, "");
7079 static_assert(strlen_c("1") == 1UL, "");
7080 static_assert(strlen_c("example") == 7UL, "");
7081 static_assert(strlen_c("another\0example") == 7UL, "");
7082
7083 }
7084
7085 namespace test_rvalue_references
7086 {
7087
7088 template < int N >
7089 struct answer
7090 {
7091 static constexpr int value = N;
7092 };
7093
7094 answer<1> f(int&) { return answer<1>(); }
7095 answer<2> f(const int&) { return answer<2>(); }
7096 answer<3> f(int&&) { return answer<3>(); }
7097
7098 void
7099 test()
7100 {
7101 int i = 0;
7102 const int c = 0;
7103 static_assert(decltype(f(i))::value == 1, "");
7104 static_assert(decltype(f(c))::value == 2, "");
7105 static_assert(decltype(f(0))::value == 3, "");
7106 }
7107
7108 }
7109
7110 namespace test_uniform_initialization
7111 {
7112
7113 struct test
7114 {
7115 static const int zero {};
7116 static const int one {1};
7117 };
7118
7119 static_assert(test::zero == 0, "");
7120 static_assert(test::one == 1, "");
7121
7122 }
7123
7124 namespace test_lambdas
7125 {
7126
7127 void
7128 test1()
7129 {
7130 auto lambda1 = [](){};
7131 auto lambda2 = lambda1;
7132 lambda1();
7133 lambda2();
7134 }
7135
7136 int
7137 test2()
7138 {
7139 auto a = [](int i, int j){ return i + j; }(1, 2);
7140 auto b = []() -> int { return '0'; }();
7141 auto c = [=](){ return a + b; }();
7142 auto d = [&](){ return c; }();
7143 auto e = [a, &b](int x) mutable {
7144 const auto identity = [](int y){ return y; };
7145 for (auto i = 0; i < a; ++i)
7146 a += b--;
7147 return x + identity(a + b);
7148 }(0);
7149 return a + b + c + d + e;
7150 }
7151
7152 int
7153 test3()
7154 {
7155 const auto nullary = [](){ return 0; };
7156 const auto unary = [](int x){ return x; };
7157 using nullary_t = decltype(nullary);
7158 using unary_t = decltype(unary);
7159 const auto higher1st = [](nullary_t f){ return f(); };
7160 const auto higher2nd = [unary](nullary_t f1){
7161 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
7162 };
7163 return higher1st(nullary) + higher2nd(nullary)(unary);
7164 }
7165
7166 }
7167
7168 namespace test_variadic_templates
7169 {
7170
7171 template <int...>
7172 struct sum;
7173
7174 template <int N0, int... N1toN>
7175 struct sum<N0, N1toN...>
7176 {
7177 static constexpr auto value = N0 + sum<N1toN...>::value;
7178 };
7179
7180 template <>
7181 struct sum<>
7182 {
7183 static constexpr auto value = 0;
7184 };
7185
7186 static_assert(sum<>::value == 0, "");
7187 static_assert(sum<1>::value == 1, "");
7188 static_assert(sum<23>::value == 23, "");
7189 static_assert(sum<1, 2>::value == 3, "");
7190 static_assert(sum<5, 5, 11>::value == 21, "");
7191 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
7192
7193 }
7194
7195 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
7196 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
7197 // because of this.
7198 namespace test_template_alias_sfinae
7199 {
7200
7201 struct foo {};
7202
7203 template<typename T>
7204 using member = typename T::member_type;
7205
7206 template<typename T>
7207 void func(...) {}
7208
7209 template<typename T>
7210 void func(member<T>*) {}
7211
7212 void test();
7213
7214 void test() { func<foo>(0); }
7215
7216 }
7217
7218} // namespace cxx11
7219
7220#endif // __cplusplus >= 201103L
7221
7222
7223
7224_ACEOF
7225if ac_fn_cxx_try_compile "$LINENO"; then :
7226 ax_cv_cxx_compile_cxx11_FOR_BUILD=yes
7227else
7228 ax_cv_cxx_compile_cxx11_FOR_BUILD=no
7229fi
7230rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7231fi
7232{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11_FOR_BUILD" >&5
7233$as_echo "$ax_cv_cxx_compile_cxx11_FOR_BUILD" >&6; }
7234 if test x$ax_cv_cxx_compile_cxx11_FOR_BUILD = xyes; then
7235 ac_success=yes
7236 fi
7237
7238 if test x$ac_success = xno; then
7239 for alternative in ${ax_cxx_compile_alternatives}; do
7240 switch="-std=gnu++${alternative}"
7241 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_FOR_BUILD_$switch" | $as_tr_sh`
7242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
7243$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
7244if eval \${$cachevar+:} false; then :
7245 $as_echo_n "(cached) " >&6
7246else
7247 ac_save_CXX="$CXX"
7248 CXX="$CXX $switch"
7249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7250/* end confdefs.h. */
7251
7252
7253// If the compiler admits that it is not ready for C++11, why torture it?
7254// Hopefully, this will speed up the test.
7255
7256#ifndef __cplusplus
7257
7258#error "This is not a C++ compiler"
7259
7260#elif __cplusplus < 201103L
7261
7262#error "This is not a C++11 compiler"
7263
7264#else
7265
7266namespace cxx11
7267{
7268
7269 namespace test_static_assert
7270 {
7271
7272 template <typename T>
7273 struct check
7274 {
7275 static_assert(sizeof(int) <= sizeof(T), "not big enough");
7276 };
7277
7278 }
7279
7280 namespace test_final_override
7281 {
7282
7283 struct Base
7284 {
7285 virtual ~Base() {}
7286 virtual void f() {}
7287 };
7288
7289 struct Derived : public Base
7290 {
7291 virtual ~Derived() override {}
7292 virtual void f() override {}
7293 };
7294
7295 }
7296
7297 namespace test_double_right_angle_brackets
7298 {
7299
7300 template < typename T >
7301 struct check {};
7302
7303 typedef check<void> single_type;
7304 typedef check<check<void>> double_type;
7305 typedef check<check<check<void>>> triple_type;
7306 typedef check<check<check<check<void>>>> quadruple_type;
7307
7308 }
7309
7310 namespace test_decltype
7311 {
7312
7313 int
7314 f()
7315 {
7316 int a = 1;
7317 decltype(a) b = 2;
7318 return a + b;
7319 }
7320
7321 }
7322
7323 namespace test_type_deduction
7324 {
7325
7326 template < typename T1, typename T2 >
7327 struct is_same
7328 {
7329 static const bool value = false;
7330 };
7331
7332 template < typename T >
7333 struct is_same<T, T>
7334 {
7335 static const bool value = true;
7336 };
7337
7338 template < typename T1, typename T2 >
7339 auto
7340 add(T1 a1, T2 a2) -> decltype(a1 + a2)
7341 {
7342 return a1 + a2;
7343 }
7344
7345 int
7346 test(const int c, volatile int v)
7347 {
7348 static_assert(is_same<int, decltype(0)>::value == true, "");
7349 static_assert(is_same<int, decltype(c)>::value == false, "");
7350 static_assert(is_same<int, decltype(v)>::value == false, "");
7351 auto ac = c;
7352 auto av = v;
7353 auto sumi = ac + av + 'x';
7354 auto sumf = ac + av + 1.0;
7355 static_assert(is_same<int, decltype(ac)>::value == true, "");
7356 static_assert(is_same<int, decltype(av)>::value == true, "");
7357 static_assert(is_same<int, decltype(sumi)>::value == true, "");
7358 static_assert(is_same<int, decltype(sumf)>::value == false, "");
7359 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
7360 return (sumf > 0.0) ? sumi : add(c, v);
7361 }
7362
7363 }
7364
7365 namespace test_noexcept
7366 {
7367
7368 int f() { return 0; }
7369 int g() noexcept { return 0; }
7370
7371 static_assert(noexcept(f()) == false, "");
7372 static_assert(noexcept(g()) == true, "");
7373
7374 }
7375
7376 namespace test_constexpr
7377 {
7378
7379 template < typename CharT >
7380 unsigned long constexpr
7381 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
7382 {
7383 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
7384 }
7385
7386 template < typename CharT >
7387 unsigned long constexpr
7388 strlen_c(const CharT *const s) noexcept
7389 {
7390 return strlen_c_r(s, 0UL);
7391 }
7392
7393 static_assert(strlen_c("") == 0UL, "");
7394 static_assert(strlen_c("1") == 1UL, "");
7395 static_assert(strlen_c("example") == 7UL, "");
7396 static_assert(strlen_c("another\0example") == 7UL, "");
7397
7398 }
7399
7400 namespace test_rvalue_references
7401 {
7402
7403 template < int N >
7404 struct answer
7405 {
7406 static constexpr int value = N;
7407 };
7408
7409 answer<1> f(int&) { return answer<1>(); }
7410 answer<2> f(const int&) { return answer<2>(); }
7411 answer<3> f(int&&) { return answer<3>(); }
7412
7413 void
7414 test()
7415 {
7416 int i = 0;
7417 const int c = 0;
7418 static_assert(decltype(f(i))::value == 1, "");
7419 static_assert(decltype(f(c))::value == 2, "");
7420 static_assert(decltype(f(0))::value == 3, "");
7421 }
7422
7423 }
7424
7425 namespace test_uniform_initialization
7426 {
7427
7428 struct test
7429 {
7430 static const int zero {};
7431 static const int one {1};
7432 };
7433
7434 static_assert(test::zero == 0, "");
7435 static_assert(test::one == 1, "");
7436
7437 }
7438
7439 namespace test_lambdas
7440 {
7441
7442 void
7443 test1()
7444 {
7445 auto lambda1 = [](){};
7446 auto lambda2 = lambda1;
7447 lambda1();
7448 lambda2();
7449 }
7450
7451 int
7452 test2()
7453 {
7454 auto a = [](int i, int j){ return i + j; }(1, 2);
7455 auto b = []() -> int { return '0'; }();
7456 auto c = [=](){ return a + b; }();
7457 auto d = [&](){ return c; }();
7458 auto e = [a, &b](int x) mutable {
7459 const auto identity = [](int y){ return y; };
7460 for (auto i = 0; i < a; ++i)
7461 a += b--;
7462 return x + identity(a + b);
7463 }(0);
7464 return a + b + c + d + e;
7465 }
7466
7467 int
7468 test3()
7469 {
7470 const auto nullary = [](){ return 0; };
7471 const auto unary = [](int x){ return x; };
7472 using nullary_t = decltype(nullary);
7473 using unary_t = decltype(unary);
7474 const auto higher1st = [](nullary_t f){ return f(); };
7475 const auto higher2nd = [unary](nullary_t f1){
7476 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
7477 };
7478 return higher1st(nullary) + higher2nd(nullary)(unary);
7479 }
7480
7481 }
7482
7483 namespace test_variadic_templates
7484 {
7485
7486 template <int...>
7487 struct sum;
7488
7489 template <int N0, int... N1toN>
7490 struct sum<N0, N1toN...>
7491 {
7492 static constexpr auto value = N0 + sum<N1toN...>::value;
7493 };
7494
7495 template <>
7496 struct sum<>
7497 {
7498 static constexpr auto value = 0;
7499 };
7500
7501 static_assert(sum<>::value == 0, "");
7502 static_assert(sum<1>::value == 1, "");
7503 static_assert(sum<23>::value == 23, "");
7504 static_assert(sum<1, 2>::value == 3, "");
7505 static_assert(sum<5, 5, 11>::value == 21, "");
7506 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
7507
7508 }
7509
7510 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
7511 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
7512 // because of this.
7513 namespace test_template_alias_sfinae
7514 {
7515
7516 struct foo {};
7517
7518 template<typename T>
7519 using member = typename T::member_type;
7520
7521 template<typename T>
7522 void func(...) {}
7523
7524 template<typename T>
7525 void func(member<T>*) {}
7526
7527 void test();
7528
7529 void test() { func<foo>(0); }
7530
7531 }
7532
7533} // namespace cxx11
7534
7535#endif // __cplusplus >= 201103L
7536
7537
7538
7539_ACEOF
7540if ac_fn_cxx_try_compile "$LINENO"; then :
7541 eval $cachevar=yes
7542else
7543 eval $cachevar=no
7544fi
7545rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7546 CXX="$ac_save_CXX"
7547fi
7548eval ac_res=\$$cachevar
7549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7550$as_echo "$ac_res" >&6; }
7551 if eval test x\$$cachevar = xyes; then
7552 CXX="$CXX $switch"
7553 if test -n "$CXXCPP" ; then
7554 CXXCPP="$CXXCPP $switch"
7555 fi
7556 ac_success=yes
7557 break
7558 fi
7559 done
7560 fi
7561
7562 if test x$ac_success = xno; then
7563 for alternative in ${ax_cxx_compile_alternatives}; do
7564 for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
7565 cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_FOR_BUILD_$switch" | $as_tr_sh`
7566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
7567$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
7568if eval \${$cachevar+:} false; then :
7569 $as_echo_n "(cached) " >&6
7570else
7571 ac_save_CXX="$CXX"
7572 CXX="$CXX $switch"
7573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7574/* end confdefs.h. */
7575
7576
7577// If the compiler admits that it is not ready for C++11, why torture it?
7578// Hopefully, this will speed up the test.
7579
7580#ifndef __cplusplus
7581
7582#error "This is not a C++ compiler"
7583
7584#elif __cplusplus < 201103L
7585
7586#error "This is not a C++11 compiler"
7587
7588#else
7589
7590namespace cxx11
7591{
7592
7593 namespace test_static_assert
7594 {
7595
7596 template <typename T>
7597 struct check
7598 {
7599 static_assert(sizeof(int) <= sizeof(T), "not big enough");
7600 };
7601
7602 }
7603
7604 namespace test_final_override
7605 {
7606
7607 struct Base
7608 {
7609 virtual ~Base() {}
7610 virtual void f() {}
7611 };
7612
7613 struct Derived : public Base
7614 {
7615 virtual ~Derived() override {}
7616 virtual void f() override {}
7617 };
7618
7619 }
7620
7621 namespace test_double_right_angle_brackets
7622 {
7623
7624 template < typename T >
7625 struct check {};
7626
7627 typedef check<void> single_type;
7628 typedef check<check<void>> double_type;
7629 typedef check<check<check<void>>> triple_type;
7630 typedef check<check<check<check<void>>>> quadruple_type;
7631
7632 }
7633
7634 namespace test_decltype
7635 {
7636
7637 int
7638 f()
7639 {
7640 int a = 1;
7641 decltype(a) b = 2;
7642 return a + b;
7643 }
7644
7645 }
7646
7647 namespace test_type_deduction
7648 {
7649
7650 template < typename T1, typename T2 >
7651 struct is_same
7652 {
7653 static const bool value = false;
7654 };
7655
7656 template < typename T >
7657 struct is_same<T, T>
7658 {
7659 static const bool value = true;
7660 };
7661
7662 template < typename T1, typename T2 >
7663 auto
7664 add(T1 a1, T2 a2) -> decltype(a1 + a2)
7665 {
7666 return a1 + a2;
7667 }
7668
7669 int
7670 test(const int c, volatile int v)
7671 {
7672 static_assert(is_same<int, decltype(0)>::value == true, "");
7673 static_assert(is_same<int, decltype(c)>::value == false, "");
7674 static_assert(is_same<int, decltype(v)>::value == false, "");
7675 auto ac = c;
7676 auto av = v;
7677 auto sumi = ac + av + 'x';
7678 auto sumf = ac + av + 1.0;
7679 static_assert(is_same<int, decltype(ac)>::value == true, "");
7680 static_assert(is_same<int, decltype(av)>::value == true, "");
7681 static_assert(is_same<int, decltype(sumi)>::value == true, "");
7682 static_assert(is_same<int, decltype(sumf)>::value == false, "");
7683 static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
7684 return (sumf > 0.0) ? sumi : add(c, v);
7685 }
7686
7687 }
7688
7689 namespace test_noexcept
7690 {
7691
7692 int f() { return 0; }
7693 int g() noexcept { return 0; }
7694
7695 static_assert(noexcept(f()) == false, "");
7696 static_assert(noexcept(g()) == true, "");
7697
7698 }
7699
7700 namespace test_constexpr
7701 {
7702
7703 template < typename CharT >
7704 unsigned long constexpr
7705 strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
7706 {
7707 return *s ? strlen_c_r(s + 1, acc + 1) : acc;
7708 }
7709
7710 template < typename CharT >
7711 unsigned long constexpr
7712 strlen_c(const CharT *const s) noexcept
7713 {
7714 return strlen_c_r(s, 0UL);
7715 }
7716
7717 static_assert(strlen_c("") == 0UL, "");
7718 static_assert(strlen_c("1") == 1UL, "");
7719 static_assert(strlen_c("example") == 7UL, "");
7720 static_assert(strlen_c("another\0example") == 7UL, "");
7721
7722 }
7723
7724 namespace test_rvalue_references
7725 {
7726
7727 template < int N >
7728 struct answer
7729 {
7730 static constexpr int value = N;
7731 };
7732
7733 answer<1> f(int&) { return answer<1>(); }
7734 answer<2> f(const int&) { return answer<2>(); }
7735 answer<3> f(int&&) { return answer<3>(); }
7736
7737 void
7738 test()
7739 {
7740 int i = 0;
7741 const int c = 0;
7742 static_assert(decltype(f(i))::value == 1, "");
7743 static_assert(decltype(f(c))::value == 2, "");
7744 static_assert(decltype(f(0))::value == 3, "");
7745 }
7746
7747 }
7748
7749 namespace test_uniform_initialization
7750 {
7751
7752 struct test
7753 {
7754 static const int zero {};
7755 static const int one {1};
7756 };
7757
7758 static_assert(test::zero == 0, "");
7759 static_assert(test::one == 1, "");
7760
7761 }
7762
7763 namespace test_lambdas
7764 {
7765
7766 void
7767 test1()
7768 {
7769 auto lambda1 = [](){};
7770 auto lambda2 = lambda1;
7771 lambda1();
7772 lambda2();
7773 }
7774
7775 int
7776 test2()
7777 {
7778 auto a = [](int i, int j){ return i + j; }(1, 2);
7779 auto b = []() -> int { return '0'; }();
7780 auto c = [=](){ return a + b; }();
7781 auto d = [&](){ return c; }();
7782 auto e = [a, &b](int x) mutable {
7783 const auto identity = [](int y){ return y; };
7784 for (auto i = 0; i < a; ++i)
7785 a += b--;
7786 return x + identity(a + b);
7787 }(0);
7788 return a + b + c + d + e;
7789 }
7790
7791 int
7792 test3()
7793 {
7794 const auto nullary = [](){ return 0; };
7795 const auto unary = [](int x){ return x; };
7796 using nullary_t = decltype(nullary);
7797 using unary_t = decltype(unary);
7798 const auto higher1st = [](nullary_t f){ return f(); };
7799 const auto higher2nd = [unary](nullary_t f1){
7800 return [unary, f1](unary_t f2){ return f2(unary(f1())); };
7801 };
7802 return higher1st(nullary) + higher2nd(nullary)(unary);
7803 }
7804
7805 }
7806
7807 namespace test_variadic_templates
7808 {
7809
7810 template <int...>
7811 struct sum;
7812
7813 template <int N0, int... N1toN>
7814 struct sum<N0, N1toN...>
7815 {
7816 static constexpr auto value = N0 + sum<N1toN...>::value;
7817 };
7818
7819 template <>
7820 struct sum<>
7821 {
7822 static constexpr auto value = 0;
7823 };
7824
7825 static_assert(sum<>::value == 0, "");
7826 static_assert(sum<1>::value == 1, "");
7827 static_assert(sum<23>::value == 23, "");
7828 static_assert(sum<1, 2>::value == 3, "");
7829 static_assert(sum<5, 5, 11>::value == 21, "");
7830 static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
7831
7832 }
7833
7834 // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
7835 // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
7836 // because of this.
7837 namespace test_template_alias_sfinae
7838 {
7839
7840 struct foo {};
7841
7842 template<typename T>
7843 using member = typename T::member_type;
7844
7845 template<typename T>
7846 void func(...) {}
7847
7848 template<typename T>
7849 void func(member<T>*) {}
7850
7851 void test();
7852
7853 void test() { func<foo>(0); }
7854
7855 }
7856
7857} // namespace cxx11
7858
7859#endif // __cplusplus >= 201103L
7860
7861
7862
7863_ACEOF
7864if ac_fn_cxx_try_compile "$LINENO"; then :
7865 eval $cachevar=yes
7866else
7867 eval $cachevar=no
7868fi
7869rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7870 CXX="$ac_save_CXX"
7871fi
7872eval ac_res=\$$cachevar
7873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7874$as_echo "$ac_res" >&6; }
7875 if eval test x\$$cachevar = xyes; then
7876 CXX="$CXX $switch"
7877 if test -n "$CXXCPP" ; then
7878 CXXCPP="$CXXCPP $switch"
7879 fi
7880 ac_success=yes
7881 break
7882 fi
7883 done
7884 if test x$ac_success = xyes; then
7885 break
7886 fi
7887 done
7888 fi
7889 CXX_FOR_BUILD="$CXX"
7890 CXXFLAGS_FOR_BUILD="$CXXFLAGS"
7891 CPPFLAGS_FOR_BUILD="$CPPFLAGS"
7892 CXX="$ax_cv_cxx_compile_cxx11_orig_cxx"
7893 CXXFLAGS="$ax_cv_cxx_compile_cxx11_orig_cxxflags"
7894 CPPFLAGS="$ax_cv_cxx_compile_cxx11_orig_cppflags"
7895 ac_ext=c
7896ac_cpp='$CPP $CPPFLAGS'
7897ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7898ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7899ac_compiler_gnu=$ac_cv_c_compiler_gnu
7900
7901 if test x$ax_cxx_compile_cxx11_required = xtrue; then
7902 if test x$ac_success = xno; then
7903 as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
7904 fi
7905 fi
7906 if test x$ac_success = xno; then
7907 HAVE_CXX11_FOR_BUILD=0
7908 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
7909$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
7910 else
7911 HAVE_CXX11_FOR_BUILD=1
7912
7913$as_echo "#define HAVE_CXX11_FOR_BUILD 1" >>confdefs.h
7914
7915 fi
7916
7917
7918 fi
46070488
JM
7919fi
7920
4a5e71f2
L
7921# Check whether --enable-pgo-build was given.
7922if test "${enable_pgo_build+set}" = set; then :
7923 enableval=$enable_pgo_build; enable_pgo_build=$enableval
7924else
7925 enable_pgo_build=no
7926fi
7927
7928
7929# Issue errors and warnings for invalid/strange PGO build combinations.
7930case "$have_compiler:$host:$target:$enable_pgo_build" in
7931 *:*:*:no) ;;
7932
7933 # Allow the PGO build only if we aren't building a compiler and
7934 # we are in a native configuration.
7935 no:$build:$build:yes | no:$build:$build:lto) ;;
7936
7937 # Disallow the PGO bootstrap if we are building a compiler.
7938 yes:*:*:yes | yes:*:*:lto)
7939 as_fn_error $? "cannot perform the PGO bootstrap when building a compiler" "$LINENO" 5 ;;
7940
7941 *)
7942 as_fn_error $? "invalid option for --enable-pgo-build" "$LINENO" 5
7943 ;;
7944esac
7945
7946if test "$enable_pgo_build" != "no"; then
7947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fprofile-generate" >&5
7948$as_echo_n "checking whether the compiler supports -fprofile-generate... " >&6; }
7949 old_CFLAGS="$CFLAGS"
7950 PGO_BUILD_GEN_CFLAGS="-fprofile-generate"
7951 CFLAGS="$CFLAGS $PGO_BUILD_CFLAGS"
7952
7953cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7954/* end confdefs.h. */
7955int foo;
7956_ACEOF
7957if ac_fn_c_try_compile "$LINENO"; then :
7958
7959else
7960 PGO_BUILD_GEN_CFLAGS=
7961fi
7962rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7963 CFLAGS="$old_CFLAGS"
7964 if test -n "$PGO_BUILD_GEN_CFLAGS"; then
7965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7966$as_echo "yes" >&6; }
7967 PGO_BUILD_USE_CFLAGS="-fprofile-use"
7968 else
7969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7970$as_echo "no" >&6; }
7971 as_fn_error $? "cannot perform the PGO build without -fprofile-generate" "$LINENO" 5
7972 fi
7973
7974 if test "$enable_pgo_build" = "lto"; then
7975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -flto=jobserver -ffat-lto-objects" >&5
7976$as_echo_n "checking whether the compiler supports -flto=jobserver -ffat-lto-objects... " >&6; }
7977 old_CFLAGS="$CFLAGS"
7978 PGO_BUILD_LTO_CFLAGS="-flto=jobserver -ffat-lto-objects"
7979 CFLAGS="$CFLAGS $PGO_BUILD_LTO_CFLAGS"
7980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7981/* end confdefs.h. */
7982int foo;
7983_ACEOF
7984if ac_fn_c_try_compile "$LINENO"; then :
7985
7986else
7987 PGO_BUILD_LTO_CFLAGS=
7988fi
7989rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7990 CFLAGS="$old_CFLAGS"
7991 if test -n "$PGO_BUILD_LTO_CFLAGS"; then
7992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7993$as_echo "yes" >&6; }
7994 else
7995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7996$as_echo "no" >&6; }
7997 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: LTO is disabled for the PGO build" >&5
7998$as_echo "$as_me: WARNING: LTO is disabled for the PGO build" >&2;}
7999 fi
8000 fi
8001fi
8002
8003
8004
8005
592c90ff
KG
8006# Used for setting $lt_cv_objdir
8007{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
8008$as_echo_n "checking for objdir... " >&6; }
22e05272 8009if ${lt_cv_objdir+:} false; then :
592c90ff
KG
8010 $as_echo_n "(cached) " >&6
8011else
8012 rm -f .libs 2>/dev/null
8013mkdir .libs 2>/dev/null
8014if test -d .libs; then
8015 lt_cv_objdir=.libs
8016else
8017 # MS-DOS does not allow filenames that begin with a dot.
8018 lt_cv_objdir=_libs
8019fi
8020rmdir .libs 2>/dev/null
8021fi
8022{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
8023$as_echo "$lt_cv_objdir" >&6; }
8024objdir=$lt_cv_objdir
8025
8026
8027
8028
8029
8030cat >>confdefs.h <<_ACEOF
8031#define LT_OBJDIR "$lt_cv_objdir/"
8032_ACEOF
8033
8034
8035
acd26225 8036# Check for GMP, MPFR and MPC
91e0d220
AP
8037require_gmp=no
8038require_mpc=no
8039if test -d ${srcdir}/gcc ; then
8040 require_gmp=yes
8041 require_mpc=yes
8042fi
8043if test -d ${srcdir}/gdb ; then
5977d14a
CC
8044 if test "x$enable_gdb" != xno; then
8045 require_gmp=yes
8046 fi
91e0d220
AP
8047fi
8048
8049gmplibs="-lmpfr -lgmp"
8050if test x"$require_mpc" = "xyes" ; then
8051 gmplibs="-lmpc $gmplibs"
8052fi
6de9cd9a 8053gmpinc=
e69bf64b 8054have_gmp=no
acd26225
KG
8055
8056# Specify a location for mpc
8057# check for this first so it ends up on the link line before mpfr.
8058
5213506e
RW
8059# Check whether --with-mpc was given.
8060if test "${with_mpc+set}" = set; then :
8061 withval=$with_mpc;
8062fi
acd26225 8063
acd26225 8064
9965e3cd 8065# Check whether --with-mpc-include was given.
5213506e
RW
8066if test "${with_mpc_include+set}" = set; then :
8067 withval=$with_mpc_include;
8068fi
acd26225 8069
acd26225 8070
9965e3cd 8071# Check whether --with-mpc-lib was given.
5213506e
RW
8072if test "${with_mpc_lib+set}" = set; then :
8073 withval=$with_mpc_lib;
8074fi
acd26225 8075
acd26225
KG
8076
8077if test "x$with_mpc" != x; then
3a5729ea
KG
8078 gmplibs="-L$with_mpc/lib $gmplibs"
8079 gmpinc="-I$with_mpc/include $gmpinc"
acd26225
KG
8080fi
8081if test "x$with_mpc_include" != x; then
3a5729ea 8082 gmpinc="-I$with_mpc_include $gmpinc"
acd26225
KG
8083fi
8084if test "x$with_mpc_lib" != x; then
3a5729ea 8085 gmplibs="-L$with_mpc_lib $gmplibs"
acd26225
KG
8086fi
8087if test "x$with_mpc$with_mpc_include$with_mpc_lib" = x && test -d ${srcdir}/mpc; then
592c90ff 8088 gmplibs='-L$$r/$(HOST_SUBDIR)/mpc/src/'"$lt_cv_objdir $gmplibs"
3a5729ea 8089 gmpinc='-I$$s/mpc/src '"$gmpinc"
acd26225
KG
8090 # Do not test the mpc version. Assume that it is sufficient, since
8091 # it is in the source tree, and the library has not been built yet
8092 # but it would be included on the link line in the version check below
8093 # hence making the test fail.
3a5729ea 8094 have_gmp=yes
acd26225 8095fi
e69bf64b 8096
bebf829d
PB
8097# Specify a location for mpfr
8098# check for this first so it ends up on the link line before gmp.
1c710c3c 8099
5213506e
RW
8100# Check whether --with-mpfr was given.
8101if test "${with_mpfr+set}" = set; then :
8102 withval=$with_mpfr;
8103fi
1c710c3c 8104
bebf829d 8105
9965e3cd 8106# Check whether --with-mpfr-include was given.
5213506e
RW
8107if test "${with_mpfr_include+set}" = set; then :
8108 withval=$with_mpfr_include;
8109fi
1c710c3c 8110
8a877c9c 8111
9965e3cd 8112# Check whether --with-mpfr-lib was given.
5213506e
RW
8113if test "${with_mpfr_lib+set}" = set; then :
8114 withval=$with_mpfr_lib;
8115fi
8a877c9c 8116
bebf829d
PB
8117
8118if test "x$with_mpfr" != x; then
8119 gmplibs="-L$with_mpfr/lib $gmplibs"
3a5729ea 8120 gmpinc="-I$with_mpfr/include $gmpinc"
bebf829d 8121fi
8a877c9c 8122if test "x$with_mpfr_include" != x; then
3a5729ea 8123 gmpinc="-I$with_mpfr_include $gmpinc"
8a877c9c
KG
8124fi
8125if test "x$with_mpfr_lib" != x; then
8126 gmplibs="-L$with_mpfr_lib $gmplibs"
8127fi
e69bf64b 8128if test "x$with_mpfr$with_mpfr_include$with_mpfr_lib" = x && test -d ${srcdir}/mpfr; then
8f3675f8
MR
8129 # MPFR v3.1.0 moved the sources into a src sub-directory.
8130 if ! test -d ${srcdir}/mpfr/src; then
22e05272 8131 as_fn_error $? "Building GCC with MPFR in the source tree is only handled for MPFR 3.1.0+." "$LINENO" 5
8f3675f8 8132 fi
00f35794
BE
8133 gmplibs='-L$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir $gmplibs"
8134 gmpinc='-I$$r/$(HOST_SUBDIR)/mpfr/src -I$$s/mpfr/src '"$gmpinc"
8135 extra_mpc_mpfr_configure_flags='--with-mpfr-include=$$s/mpfr/src --with-mpfr-lib=$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir"
e69bf64b
PB
8136 # Do not test the mpfr version. Assume that it is sufficient, since
8137 # it is in the source tree, and the library has not been built yet
8138 # but it would be included on the link line in the version check below
8139 # hence making the test fail.
8140 have_gmp=yes
8141fi
bebf829d 8142
6de9cd9a 8143# Specify a location for gmp
1c710c3c 8144
5213506e
RW
8145# Check whether --with-gmp was given.
8146if test "${with_gmp+set}" = set; then :
8147 withval=$with_gmp;
8148fi
1c710c3c 8149
6de9cd9a 8150
9965e3cd 8151# Check whether --with-gmp-include was given.
5213506e
RW
8152if test "${with_gmp_include+set}" = set; then :
8153 withval=$with_gmp_include;
8154fi
1c710c3c 8155
8a877c9c 8156
9965e3cd 8157# Check whether --with-gmp-lib was given.
5213506e
RW
8158if test "${with_gmp_lib+set}" = set; then :
8159 withval=$with_gmp_lib;
8160fi
8a877c9c
KG
8161
8162
6de9cd9a 8163
bebf829d
PB
8164if test "x$with_gmp" != x; then
8165 gmplibs="-L$with_gmp/lib $gmplibs"
8166 gmpinc="-I$with_gmp/include $gmpinc"
6de9cd9a 8167fi
8a877c9c
KG
8168if test "x$with_gmp_include" != x; then
8169 gmpinc="-I$with_gmp_include $gmpinc"
8170fi
8171if test "x$with_gmp_lib" != x; then
8172 gmplibs="-L$with_gmp_lib $gmplibs"
8173fi
e69bf64b 8174if test "x$with_gmp$with_gmp_include$with_gmp_lib" = x && test -d ${srcdir}/gmp; then
592c90ff 8175 gmplibs='-L$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir $gmplibs"
e69bf64b 8176 gmpinc='-I$$r/$(HOST_SUBDIR)/gmp -I$$s/gmp '"$gmpinc"
9183bdcf 8177 extra_mpfr_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
592c90ff 8178 extra_mpc_gmp_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
0ff2d841 8179 extra_isl_gmp_configure_flags='--with-gmp-builddir=$$r/$(HOST_SUBDIR)/gmp'
e69bf64b
PB
8180 # Do not test the gmp version. Assume that it is sufficient, since
8181 # it is in the source tree, and the library has not been built yet
8182 # but it would be included on the link line in the version check below
8183 # hence making the test fail.
8184 have_gmp=yes
8185fi
6de9cd9a 8186
91e0d220 8187if test "x$require_gmp" = xyes && test "x$have_gmp" = xno; then
e69bf64b
PB
8188 have_gmp=yes
8189 saved_CFLAGS="$CFLAGS"
8190 CFLAGS="$CFLAGS $gmpinc"
362c6d2f
KG
8191 # Check for the recommended and required versions of GMP.
8192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of gmp.h" >&5
8193$as_echo_n "checking for the correct version of gmp.h... " >&6; }
4a5e71f2 8194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
362c6d2f
KG
8195/* end confdefs.h. */
8196#include "gmp.h"
8197int
8198main ()
8199{
8200
8201 #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
8202 #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
385c0681 8203 #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,2,3)
362c6d2f
KG
8204 choke me
8205 #endif
8206
8207 ;
8208 return 0;
8209}
8210_ACEOF
8211if ac_fn_c_try_compile "$LINENO"; then :
e8fd69bb 8212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c 8213/* end confdefs.h. */
362c6d2f 8214#include <gmp.h>
1c710c3c
DJ
8215int
8216main ()
8217{
6de9cd9a 8218
362c6d2f
KG
8219 #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
8220 #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
8221 #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,3,2)
e69bf64b
PB
8222 choke me
8223 #endif
1c710c3c
DJ
8224
8225 ;
8226 return 0;
8227}
8228_ACEOF
5213506e
RW
8229if ac_fn_c_try_compile "$LINENO"; then :
8230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8231$as_echo "yes" >&6; }
362c6d2f
KG
8232else
8233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
8234$as_echo "buggy but acceptable" >&6; }
8235fi
8236rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1c710c3c 8237else
5213506e
RW
8238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8239$as_echo "no" >&6; }; have_gmp=no
1c710c3c 8240fi
5213506e 8241rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6de9cd9a 8242
acd26225 8243 # If we have GMP, check the MPFR version.
e69bf64b 8244 if test x"$have_gmp" = xyes; then
362c6d2f
KG
8245 # Check for the recommended and required versions of MPFR.
8246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of mpfr.h" >&5
8247$as_echo_n "checking for the correct version of mpfr.h... " >&6; }
5213506e 8248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c 8249/* end confdefs.h. */
70ec446f 8250#include <gmp.h>
e69bf64b 8251 #include <mpfr.h>
1c710c3c
DJ
8252int
8253main ()
8254{
e48d66a9 8255
8be34204 8256 #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,0)
e69bf64b
PB
8257 choke me
8258 #endif
1c710c3c
DJ
8259
8260 ;
8261 return 0;
8262}
8263_ACEOF
5213506e
RW
8264if ac_fn_c_try_compile "$LINENO"; then :
8265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1c710c3c 8266/* end confdefs.h. */
a3993f33 8267#include <gmp.h>
e69bf64b 8268 #include <mpfr.h>
1c710c3c
DJ
8269int
8270main ()
8271{
a3993f33 8272
8be34204 8273 #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,6)
e69bf64b
PB
8274 choke me
8275 #endif
acd26225
KG
8276
8277 ;
8278 return 0;
8279}
8280_ACEOF
5213506e
RW
8281if ac_fn_c_try_compile "$LINENO"; then :
8282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8283$as_echo "yes" >&6; }
acd26225 8284else
5213506e
RW
8285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
8286$as_echo "buggy but acceptable" >&6; }
acd26225 8287fi
5213506e 8288rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225 8289else
5213506e
RW
8290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8291$as_echo "no" >&6; }; have_gmp=no
acd26225 8292fi
5213506e 8293rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225
KG
8294 fi
8295
8296 # Check for the MPC header version.
91e0d220 8297 if test "x$require_mpc" = xyes && test x"$have_gmp" = xyes ; then
362c6d2f 8298 # Check for the recommended and required versions of MPC.
5213506e
RW
8299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of mpc.h" >&5
8300$as_echo_n "checking for the correct version of mpc.h... " >&6; }
8301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
acd26225
KG
8302/* end confdefs.h. */
8303#include <mpc.h>
8304int
8305main ()
8306{
8307
362c6d2f
KG
8308 #if MPC_VERSION < MPC_VERSION_NUM(0,8,0)
8309 choke me
8310 #endif
8311
8312 ;
8313 return 0;
8314}
8315_ACEOF
8316if ac_fn_c_try_compile "$LINENO"; then :
8317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8318/* end confdefs.h. */
8319#include <mpc.h>
8320int
8321main ()
8322{
8323
8324 #if MPC_VERSION < MPC_VERSION_NUM(0,8,1)
acd26225
KG
8325 choke me
8326 #endif
8327
8328 ;
8329 return 0;
8330}
8331_ACEOF
5213506e
RW
8332if ac_fn_c_try_compile "$LINENO"; then :
8333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3a5729ea 8334$as_echo "yes" >&6; }
362c6d2f
KG
8335else
8336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
8337$as_echo "buggy but acceptable" >&6; }
8338fi
8339rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225 8340else
5213506e 8341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3a5729ea 8342$as_echo "no" >&6; }; have_gmp=no
acd26225 8343fi
5213506e 8344rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
acd26225
KG
8345 fi
8346
8347 # Now check the MPFR library.
8348 if test x"$have_gmp" = xyes; then
8349 saved_LIBS="$LIBS"
8350 LIBS="$LIBS $gmplibs"
91e0d220
AP
8351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of the gmp/mpfr libraries" >&5
8352$as_echo_n "checking for the correct version of the gmp/mpfr libraries... " >&6; }
5213506e 8353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
acd26225 8354/* end confdefs.h. */
91e0d220 8355#include <mpfr.h>
acd26225
KG
8356int
8357main ()
8358{
8359
8360 mpfr_t n;
8361 mpfr_t x;
8362 int t;
8363 mpfr_init (n);
8364 mpfr_init (x);
90ca6847
TB
8365 mpfr_atan2 (n, n, x, MPFR_RNDN);
8366 mpfr_erfc (n, x, MPFR_RNDN);
8367 mpfr_subnormalize (x, t, MPFR_RNDN);
3a5729ea
KG
8368 mpfr_clear(n);
8369 mpfr_clear(x);
91e0d220
AP
8370
8371 ;
8372 return 0;
8373}
8374_ACEOF
8375if ac_fn_c_try_link "$LINENO"; then :
8376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8377$as_echo "yes" >&6; }
8378else
8379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8380$as_echo "no" >&6; }; have_gmp=no
8381fi
8382rm -f core conftest.err conftest.$ac_objext \
8383 conftest$ac_exeext conftest.$ac_ext
8384 LIBS="$saved_LIBS"
8385 fi
8386
8387 # Now check the MPC library
8388 if test "x$require_mpc" = xyes && test x"$have_gmp" = xyes; then
8389 saved_LIBS="$LIBS"
8390 LIBS="$LIBS $gmplibs"
8391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of the mpc libraries" >&5
8392$as_echo_n "checking for the correct version of the mpc libraries... " >&6; }
8393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8394/* end confdefs.h. */
8395#include <mpc.h>
8396int
8397main ()
8398{
8399
8400 mpc_t c;
3a5729ea
KG
8401 mpc_init2 (c, 53);
8402 mpc_set_ui_ui (c, 1, 1, MPC_RNDNN);
8403 mpc_cosh (c, c, MPC_RNDNN);
8404 mpc_pow (c, c, c, MPC_RNDNN);
8405 mpc_acosh (c, c, MPC_RNDNN);
8406 mpc_clear (c);
1c710c3c
DJ
8407
8408 ;
8409 return 0;
8410}
8411_ACEOF
5213506e
RW
8412if ac_fn_c_try_link "$LINENO"; then :
8413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8414$as_echo "yes" >&6; }
1c710c3c 8415else
5213506e
RW
8416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8417$as_echo "no" >&6; }; have_gmp=no
1c710c3c 8418fi
5213506e
RW
8419rm -f core conftest.err conftest.$ac_objext \
8420 conftest$ac_exeext conftest.$ac_ext
acd26225
KG
8421 LIBS="$saved_LIBS"
8422 fi
8423
e69bf64b 8424 CFLAGS="$saved_CFLAGS"
6de9cd9a 8425
362c6d2f
KG
8426# The library versions listed in the error message below should match
8427# the HARD-minimums enforced above.
e69bf64b 8428 if test x$have_gmp != xyes; then
91e0d220
AP
8429 if test -d ${srcdir}/gcc ; then
8430 as_fn_error $? "Building GCC requires GMP 4.2+, MPFR 3.1.0+ and MPC 0.8.0+.
3a5729ea
KG
8431Try the --with-gmp, --with-mpfr and/or --with-mpc options to specify
8432their locations. Source code for these libraries can be found at
8433their respective hosting sites as well as at
aeebd94c 8434https://gcc.gnu.org/pub/gcc/infrastructure/. See also
45ab87d4 8435http://gcc.gnu.org/install/prerequisites.html for additional info. If
3a5729ea
KG
8436you obtained GMP, MPFR and/or MPC from a vendor distribution package,
8437make sure that you have installed both the libraries and the header
8438files. They may be located in separate packages." "$LINENO" 5
91e0d220
AP
8439 else
8440 as_fn_error $? "Building GDB requires GMP 4.2+, and MPFR 3.1.0+.
8441Try the --with-gmp and/or --with-mpfr options to specify
8442their locations. If you obtained GMP and/or MPFR from a vendor
8443distribution package, make sure that you have installed both the libraries
8444and the header files. They may be located in separate packages." "$LINENO" 5
8445 fi
e69bf64b 8446 fi
70ec446f
KG
8447fi
8448
acd26225
KG
8449# Flags needed for both GMP, MPFR and/or MPC.
8450
8451
6de9cd9a
DN
8452
8453
8454
9e3eba15 8455
0ff2d841 8456
0b21f5d3 8457# Libraries to use for stage1 or when not bootstrapping.
00020c16 8458
0b21f5d3
EB
8459# Check whether --with-stage1-libs was given.
8460if test "${with_stage1_libs+set}" = set; then :
8461 withval=$with_stage1_libs; if test "$withval" = "no" -o "$withval" = "yes"; then
8462 stage1_libs=
00020c16 8463 else
0b21f5d3 8464 stage1_libs=$withval
00020c16
ILT
8465 fi
8466else
5dc85f7e 8467 stage1_libs=
5213506e
RW
8468fi
8469
00020c16
ILT
8470
8471
aac9103b
TT
8472# Whether or not to use -static-libstdc++ and -static-libgcc. The
8473# default is yes if gcc is being built; no otherwise. The reason for
8474# this default is that gdb is sometimes linked against GNU Source
8475# Highlight, which is a shared library that uses C++ exceptions. In
8476# this case, -static-libstdc++ will cause crashes.
8477
8478# Check whether --with-static-standard-libraries was given.
8479if test "${with_static_standard_libraries+set}" = set; then :
8480 withval=$with_static_standard_libraries;
8481else
8482 with_static_standard_libraries=auto
8483fi
8484
8485if test "$with_static_standard_libraries" = auto; then
8486 with_static_standard_libraries=$have_compiler
8487fi
8488
0b21f5d3 8489# Linker flags to use for stage1 or when not bootstrapping.
00020c16 8490
0b21f5d3
EB
8491# Check whether --with-stage1-ldflags was given.
8492if test "${with_stage1_ldflags+set}" = set; then :
8493 withval=$with_stage1_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
8494 stage1_ldflags=
00020c16 8495 else
0b21f5d3 8496 stage1_ldflags=$withval
00020c16
ILT
8497 fi
8498else
0b21f5d3
EB
8499 stage1_ldflags=
8500 # In stage 1, default to linking libstdc++ and libgcc statically with GCC
8501 # if supported. But if the user explicitly specified the libraries to use,
8502 # trust that they are doing what they want.
aac9103b
TT
8503 if test "$with_static_standard_libraries" = yes -a "$stage1_libs" = "" \
8504 -a "$have_static_libs" = yes; then
0b21f5d3
EB
8505 stage1_ldflags="-static-libstdc++ -static-libgcc"
8506 fi
5213506e
RW
8507fi
8508
00020c16
ILT
8509
8510
5dc85f7e 8511# Libraries to use for stage2 and later builds.
00020c16 8512
5213506e
RW
8513# Check whether --with-boot-libs was given.
8514if test "${with_boot_libs+set}" = set; then :
8515 withval=$with_boot_libs; if test "$withval" = "no" -o "$withval" = "yes"; then
e90e6bd7
ILT
8516 poststage1_libs=
8517 else
8518 poststage1_libs=$withval
8519 fi
8520else
5dc85f7e 8521 poststage1_libs=
5213506e
RW
8522fi
8523
00020c16
ILT
8524
8525
ed2eaa9f
ILT
8526# Linker flags to use for stage2 and later builds.
8527
8528# Check whether --with-boot-ldflags was given.
8529if test "${with_boot_ldflags+set}" = set; then :
8530 withval=$with_boot_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
8531 poststage1_ldflags=
8532 else
8533 poststage1_ldflags=$withval
8534 fi
8535else
8536 poststage1_ldflags=
bec93d73
ILT
8537 # In stages 2 and 3, default to linking libstdc++ and libgcc
8538 # statically. But if the user explicitly specified the libraries to
8539 # use, trust that they are doing what they want.
8540 if test "$poststage1_libs" = ""; then
ed2eaa9f
ILT
8541 poststage1_ldflags="-static-libstdc++ -static-libgcc"
8542 fi
8543fi
8544
6a6d3817
IS
8545case $target in
8546 *-darwin2* | *-darwin1[56789]*)
8547 # For these versions, we default to using embedded rpaths.
8548 if test "x$enable_darwin_at_rpath" != "xno"; then
8549 poststage1_ldflags="$poststage1_ldflags -nodefaultrpaths"
8550 fi
8551 ;;
8552 *-darwin*)
8553 # For these versions, we only use embedded rpaths on demand.
8554 if test "x$enable_darwin_at_rpath" = "xyes"; then
8555 poststage1_ldflags="$poststage1_ldflags -nodefaultrpaths"
8556 fi
8557 ;;
8558esac
ed2eaa9f
ILT
8559
8560
e357a5e0 8561# GCC GRAPHITE dependency isl.
4a9bb2aa 8562# Basic setup is inlined here, actual checks are in config/isl.m4
f8bf9252
SP
8563
8564
33ad93b9
RG
8565# Check whether --with-isl was given.
8566if test "${with_isl+set}" = set; then :
8567 withval=$with_isl;
5213506e 8568fi
f8bf9252 8569
f8bf9252 8570
eae1a5d4 8571# Treat --without-isl as a request to disable
625afa23 8572# GRAPHITE support and skip all following checks.
eae1a5d4 8573if test "x$with_isl" != "xno"; then
e357a5e0 8574 # Check for isl
625afa23
RG
8575
8576
33ad93b9
RG
8577# Check whether --with-isl-include was given.
8578if test "${with_isl_include+set}" = set; then :
8579 withval=$with_isl_include;
5213506e
RW
8580fi
8581
f8bf9252 8582
33ad93b9
RG
8583# Check whether --with-isl-lib was given.
8584if test "${with_isl_lib+set}" = set; then :
8585 withval=$with_isl_lib;
5213506e 8586fi
f8bf9252 8587
f8bf9252 8588
33ad93b9
RG
8589 # Check whether --enable-isl-version-check was given.
8590if test "${enable_isl_version_check+set}" = set; then :
8591 enableval=$enable_isl_version_check; ENABLE_ISL_CHECK=$enableval
8592else
8593 ENABLE_ISL_CHECK=yes
7d32a440
SP
8594fi
8595
8596
33ad93b9
RG
8597 # Initialize isllibs and islinc.
8598 case $with_isl in
8599 no)
8600 isllibs=
8601 islinc=
8602 ;;
8603 "" | yes)
8604 ;;
8605 *)
8606 isllibs="-L$with_isl/lib"
8607 islinc="-I$with_isl/include"
8608 ;;
8609 esac
8610 if test "x${with_isl_include}" != x ; then
8611 islinc="-I$with_isl_include"
8612 fi
8613 if test "x${with_isl_lib}" != x; then
8614 isllibs="-L$with_isl_lib"
8615 fi
8616 if test "x${islinc}" = x && test "x${isllibs}" = x \
8617 && test -d ${srcdir}/isl; then
8618 isllibs='-L$$r/$(HOST_SUBDIR)/isl/'"$lt_cv_objdir"' '
8619 islinc='-I$$r/$(HOST_SUBDIR)/isl/include -I$$s/isl/include'
8620 ENABLE_ISL_CHECK=no
560d18d3
AK
8621 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using in-tree isl, disabling version check" >&5
8622$as_echo "$as_me: WARNING: using in-tree isl, disabling version check" >&2;}
33ad93b9 8623 fi
7d32a440 8624
eae1a5d4
RG
8625 isllibs="${isllibs} -lisl"
8626
7d32a440 8627
7d32a440 8628
9847828b
RB
8629 if test "${ENABLE_ISL_CHECK}" = yes ; then
8630 _isl_saved_CFLAGS=$CFLAGS
8631 _isl_saved_LDFLAGS=$LDFLAGS
8632 _isl_saved_LIBS=$LIBS
8633
8634 CFLAGS="${_isl_saved_CFLAGS} ${islinc} ${gmpinc}"
70decafb
NS
8635 LDFLAGS="${_isl_saved_LDFLAGS} ${isllibs} ${gmplibs}"
8636 LIBS="${_isl_saved_LIBS} -lisl -lgmp"
9847828b 8637
f877b3ad
RB
8638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isl 0.15 or later" >&5
8639$as_echo_n "checking for isl 0.15 or later... " >&6; }
e0c0c325 8640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
622dbadf 8641/* end confdefs.h. */
f877b3ad 8642#include <isl/schedule.h>
622dbadf
BC
8643int
8644main ()
8645{
f877b3ad 8646isl_options_set_schedule_serialize_sccs (NULL, 0);
622dbadf
BC
8647 ;
8648 return 0;
8649}
8650_ACEOF
8651if ac_fn_c_try_link "$LINENO"; then :
9847828b 8652 gcc_cv_isl=yes
622dbadf
BC
8653else
8654 gcc_cv_isl=no
8655fi
8656rm -f core conftest.err conftest.$ac_objext \
8657 conftest$ac_exeext conftest.$ac_ext
9847828b
RB
8658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_isl" >&5
8659$as_echo "$gcc_cv_isl" >&6; }
8660
560d18d3 8661 if test "${gcc_cv_isl}" = no ; then
f877b3ad
RB
8662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: required isl version is 0.15 or later" >&5
8663$as_echo "required isl version is 0.15 or later" >&6; }
1e050c90
AK
8664 fi
8665
9847828b
RB
8666 CFLAGS=$_isl_saved_CFLAGS
8667 LDFLAGS=$_isl_saved_LDFLAGS
8668 LIBS=$_isl_saved_LIBS
8669 fi
8670
8671
f8bf9252 8672
f8bf9252 8673
33ad93b9
RG
8674
8675
33ad93b9
RG
8676 if test "x${with_isl}" = xno; then
8677 graphite_requested=no
8678 elif test "x${with_isl}" != x \
8679 || test "x${with_isl_include}" != x \
8680 || test "x${with_isl_lib}" != x ; then
8681 graphite_requested=yes
8682 else
8683 graphite_requested=no
7d32a440 8684 fi
d789184e 8685
d789184e
SP
8686
8687
33ad93b9
RG
8688 if test "${gcc_cv_isl}" = no ; then
8689 isllibs=
8690 islinc=
8691 fi
8692
8693 if test "${graphite_requested}" = yes \
8694 && test "x${isllibs}" = x \
8695 && test "x${islinc}" = x ; then
f8bf9252 8696
22e05272 8697 as_fn_error $? "Unable to find a usable isl. See config.log for details." "$LINENO" 5
33ad93b9 8698 fi
f8bf9252 8699
d32ef397 8700
d32ef397
AS
8701fi
8702
e357a5e0 8703# If the isl check failed, disable builds of in-tree variant of isl
625afa23 8704if test "x$with_isl" = xno ||
625afa23 8705 test "x$gcc_cv_isl" = xno; then
4a9bb2aa 8706 noconfigdirs="$noconfigdirs isl"
625afa23 8707 islinc=
32d024bf
RG
8708fi
8709
625afa23
RG
8710
8711
8712
d7f09764
DN
8713# Check for LTO support.
8714# Check whether --enable-lto was given.
8715if test "${enable_lto+set}" = set; then :
8716 enableval=$enable_lto; enable_lto=$enableval
8717else
8718 enable_lto=yes; default_enable_lto=yes
8719fi
8720
8721
7413962d 8722
9a02962b
DK
8723
8724
8725target_elf=no
8726case $target in
8727 *-darwin* | *-aix* | *-cygwin* | *-mingw* | *-aout* | *-*coff* | \
e44dbbe1 8728 *-msdosdjgpp* | *-vms* | *-wince* | *-*-pe* | \
8f56cb51 8729 alpha*-dec-osf* | *-interix* | hppa[12]*-*-hpux* | \
8ae12d71 8730 nvptx-*-none)
9a02962b
DK
8731 target_elf=no
8732 ;;
8733 *)
8734 target_elf=yes
8735 ;;
8736esac
8737
8738if test $target_elf = yes; then :
48215350
DK
8739 # ELF platforms build the lto-plugin always.
8740 build_lto_plugin=yes
9a02962b 8741
9a02962b
DK
8742else
8743 if test x"$default_enable_lto" = x"yes" ; then
bb79486c 8744 case $target in
deeba76a 8745 *-apple-darwin[912]* | *-cygwin* | *-mingw* | *djgpp*) ;;
48215350 8746 # On other non-ELF platforms, LTO has yet to be validated.
bb79486c
JH
8747 *) enable_lto=no ;;
8748 esac
9a02962b 8749 else
db50fe7d
IS
8750 # Apart from ELF platforms, only Windows and Darwin support LTO so far.
8751 # It would also be nice to check the binutils support, but we don't
9a02962b
DK
8752 # have gcc_GAS_CHECK_FEATURE available here. For now, we'll just
8753 # warn during gcc/ subconfigure; unless you're bootstrapping with
8754 # -flto it won't be needed until after installation anyway.
8755 case $target in
9e530bcd 8756 *-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
9a02962b 8757 *) if test x"$enable_lto" = x"yes"; then
22e05272 8758 as_fn_error $? "LTO support is not enabled for this target." "$LINENO" 5
9a02962b
DK
8759 fi
8760 ;;
8761 esac
8762 fi
1cd0b716 8763 # Among non-ELF, only Windows platforms support the lto-plugin so far.
48215350 8764 # Build it unless LTO was explicitly disabled.
1cd0b716 8765 case $target in
48215350 8766 *-cygwin* | *-mingw*) build_lto_plugin=$enable_lto ;;
1cd0b716
DK
8767 *) ;;
8768 esac
48215350 8769
9a02962b
DK
8770fi
8771
d7f09764 8772
45b3824d
TS
8773# Check whether --enable-linker-plugin-configure-flags was given.
8774if test "${enable_linker_plugin_configure_flags+set}" = set; then :
8775 enableval=$enable_linker_plugin_configure_flags; extra_linker_plugin_configure_flags=$enableval
8776else
8777 extra_linker_plugin_configure_flags=
8778fi
8779
8780
8781# Check whether --enable-linker-plugin-flags was given.
8782if test "${enable_linker_plugin_flags+set}" = set; then :
8783 enableval=$enable_linker_plugin_flags; extra_linker_plugin_flags=$enableval
8784else
8785 extra_linker_plugin_flags=
8786fi
8787
8788
8789
c1fecabe
IS
8790# Handle --enable-host-pie
8791# If host PIE executables are the default (or must be forced on) for some host,
8792# we must pass that configuration to the gcc directory.
8793gcc_host_pie=
b6cb10af
MP
8794# Check whether --enable-host-pie was given.
8795if test "${enable_host_pie+set}" = set; then :
8796 enableval=$enable_host_pie; host_pie=$enableval
8797 case $host in
c1fecabe 8798 *-*-darwin2*)
b6cb10af 8799 if test x$host_pie != xyes ; then
c1fecabe
IS
8800 # for Darwin20+ this is required.
8801 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PIE executables are required for the configured host, host-pie setting ignored." >&5
8802$as_echo "$as_me: WARNING: PIE executables are required for the configured host, host-pie setting ignored." >&2;}
b6cb10af 8803 host_pie=yes
c1fecabe 8804 gcc_host_pie=--enable-host-pie
b6cb10af
MP
8805 fi ;;
8806 *) ;;
8807 esac
8808else
8809 case $host in
c1fecabe
IS
8810 *-*-darwin2*)
8811 # Default to PIE (mandatory for aarch64).
8812 host_pie=yes
8813 gcc_host_pie=--enable-host-pie
8814 ;;
b6cb10af
MP
8815 *) host_pie=no ;;
8816 esac
8817fi
8818
8819
8820
8821
c1fecabe 8822
cdfee50a
NS
8823# Enable --enable-host-shared.
8824# Checked early to determine whether jit is an 'all' language
8825# Check whether --enable-host-shared was given.
8826if test "${enable_host_shared+set}" = set; then :
8827 enableval=$enable_host_shared; host_shared=$enableval
1edfc8f2 8828 case $host in
a1d2b162
IS
8829 x86_64-*-darwin* | aarch64-*-darwin*)
8830 if test x$host_shared != xyes ; then
8831 # PIC is the default, and actually cannot be switched off.
c1fecabe
IS
8832 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PIC code is required for the configured host; host-shared setting ignored." >&5
8833$as_echo "$as_me: WARNING: PIC code is required for the configured host; host-shared setting ignored." >&2;}
a1d2b162
IS
8834 host_shared=yes
8835 fi ;;
b6cb10af 8836 *-*-darwin*)
c1fecabe
IS
8837 if test x$host_pie = xyes -a x$host_shared != xyes ; then
8838 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PIC code is required for PIE host executables host-shared setting ignored." >&5
8839$as_echo "$as_me: WARNING: PIC code is required for PIE host executables host-shared setting ignored." >&2;}
b6cb10af
MP
8840 host_shared=yes
8841 fi ;;
a1d2b162
IS
8842 *) ;;
8843 esac
cdfee50a 8844else
1edfc8f2 8845 case $host in
c1fecabe 8846 # 64B x86_64 and Aarch64 Darwin default to PIC.
a1d2b162 8847 x86_64-*-darwin* | aarch64-*-darwin*) host_shared=yes ;;
c1fecabe
IS
8848 # 32B and powerpc64 Darwin must use PIC to link PIE exes.
8849 *-*-darwin*) host_shared=$host_pie ;;
b6cb10af 8850 *) host_shared=no;;
a1d2b162 8851 esac
cdfee50a
NS
8852fi
8853
8854
f8bf9252 8855
05048fc2 8856
b6cb10af 8857if test x$host_shared = xyes; then
c1fecabe
IS
8858 case $host in
8859 *-*-darwin*)
8860 # Since host shared is the default for 64b Darwin, and also enabled for
8861 # host_pie, ensure that we present the PIE flag when host_pie is active.
8862 if test x$host_pie = xyes; then
8863 PICFLAG=-fPIE
8864 fi
8865 ;;
8866 *)
8867 PICFLAG=-fPIC
8868 ;;
8869 esac
b6cb10af
MP
8870elif test x$host_pie = xyes; then
8871 PICFLAG=-fPIE
8872else
8873 PICFLAG=
8874fi
8875
8876
8877
05048fc2
IS
8878# If we are building PIC/PIE host executables, and we are building dependent
8879# libs (e.g. GMP) in-tree those libs need to be configured to generate PIC
8880# code.
8881host_libs_picflag=
b6cb10af 8882if test "$host_shared" = "yes" -o "$host_pie" = "yes"; then
05048fc2
IS
8883host_libs_picflag='--with-pic'
8884fi
8885
8886
0823efed 8887# By default, C and C++ are the only stage 1 languages.
e1888513 8888stage1_languages=,c,
2805b53a 8889
00020c16 8890# Target libraries that we bootstrap.
ad1e5170 8891bootstrap_target_libs=,target-libgcc,
00020c16 8892
55ffb5ed
NN
8893# Figure out what language subdirectories are present.
8894# Look if the user specified --enable-languages="..."; if not, use
8895# the environment variable $LANGUAGES if defined. $LANGUAGES might
8896# go away some day.
8897# NB: embedded tabs in this IF block -- do not untabify
8898if test -d ${srcdir}/gcc; then
8899 if test x"${enable_languages+set}" != xset; then
8900 if test x"${LANGUAGES+set}" = xset; then
8901 enable_languages="${LANGUAGES}"
6b1786aa 8902 echo configure.ac: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
55ffb5ed 8903 else
cdfee50a 8904 enable_languages=default
55ffb5ed
NN
8905 fi
8906 else
8907 if test x"${enable_languages}" = x ||
8908 test x"${enable_languages}" = xyes;
8909 then
6b1786aa 8910 echo configure.ac: --enable-languages needs at least one language argument 1>&2
55ffb5ed
NN
8911 exit 1
8912 fi
8913 fi
8914 enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
8915
7f26dfa3
FXC
8916 # 'f95' is the old name for the 'fortran' language. We issue a warning
8917 # and make the substitution.
8918 case ,${enable_languages}, in
8919 *,f95,*)
6b1786aa 8920 echo configure.ac: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
7f26dfa3
FXC
8921 enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
8922 ;;
8923 esac
8924
0823efed
DN
8925 # If bootstrapping, C++ must be enabled.
8926 case ",$enable_languages,:$enable_bootstrap" in
8927 *,c++,*:*) ;;
8928 *:yes)
ff3ac0f4
ILT
8929 if test -f ${srcdir}/gcc/cp/config-lang.in; then
8930 enable_languages="${enable_languages},c++"
8931 else
22e05272 8932 as_fn_error $? "bootstrapping requires c++ sources" "$LINENO" 5
ff3ac0f4
ILT
8933 fi
8934 ;;
8935 esac
8936
55ffb5ed
NN
8937 # First scan to see if an enabled language requires some other language.
8938 # We assume that a given config-lang.in will list all the language
8939 # front ends it requires, even if some are required indirectly.
8940 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
8941 case ${lang_frag} in
8942 ..) ;;
8943 # The odd quoting in the next line works around
8944 # an apparent bug in bash 1.12 on linux.
8945 ${srcdir}/gcc/[*]/config-lang.in) ;;
8946 *)
69ecd18f
ILT
8947 # From the config-lang.in, get $language, $lang_requires, and
8948 # $lang_requires_boot_languages.
55ffb5ed
NN
8949 language=
8950 lang_requires=
69ecd18f 8951 lang_requires_boot_languages=
d4360477
NS
8952 # set srcdir during sourcing lang_frag to the gcc dir.
8953 # Sadly overriding srcdir on the . line doesn't work in plain sh as it
8954 # polutes this shell
8955 saved_srcdir=${srcdir}
8956 srcdir=${srcdir}/gcc . ${lang_frag}
8957 srcdir=${saved_srcdir}
69ecd18f 8958 for other in ${lang_requires} ${lang_requires_boot_languages}; do
55ffb5ed
NN
8959 case ,${enable_languages}, in
8960 *,$other,*) ;;
cdfee50a 8961 *,default,*) ;;
55ffb5ed
NN
8962 *,all,*) ;;
8963 *,$language,*)
8964 echo " \`$other' language required by \`$language'; enabling" 1>&2
8965 enable_languages="${enable_languages},${other}"
8966 ;;
8967 esac
8968 done
69ecd18f
ILT
8969 for other in ${lang_requires_boot_languages} ; do
8970 if test "$other" != "c"; then
8971 case ,${enable_stage1_languages}, in
8972 *,$other,*) ;;
cdfee50a 8973 *,default,*) ;;
69ecd18f
ILT
8974 *,all,*) ;;
8975 *)
8976 case ,${enable_languages}, in
8977 *,$language,*)
8978 echo " '$other' language required by '$language' in stage 1; enabling" 1>&2
8979 enable_stage1_languages="$enable_stage1_languages,${other}"
8980 ;;
8981 esac
8982 ;;
8983 esac
8984 fi
8985 done
55ffb5ed
NN
8986 ;;
8987 esac
8988 done
8989
e1888513 8990 new_enable_languages=,c,
d7f09764
DN
8991
8992 # If LTO is enabled, add the LTO front end.
d7f09764 8993 if test "$enable_lto" = "yes" ; then
e4c5bd48
RW
8994 case ,${enable_languages}, in
8995 *,lto,*) ;;
8996 *) enable_languages="${enable_languages},lto" ;;
8997 esac
1cd0b716 8998 if test "${build_lto_plugin}" = "yes" ; then
d7f09764 8999 configdirs="$configdirs lto-plugin"
d7f09764
DN
9000 fi
9001 fi
9002
426c1eb0
TS
9003 # If we're building an offloading compiler, add the LTO front end.
9004 if test x"$enable_as_accelerator_for" != x ; then
9005 case ,${enable_languages}, in
9006 *,lto,*) ;;
9007 *) enable_languages="${enable_languages},lto" ;;
9008 esac
9009 fi
9010
cdfee50a 9011 missing_languages=`echo ",$enable_languages," | sed -e s/,default,/,/ -e s/,all,/,/ -e s/,c,/,/ `
e1888513 9012 potential_languages=,c,
55ffb5ed 9013
4da3b0f8
ILT
9014 enabled_target_libs=
9015 disabled_target_libs=
9016
55ffb5ed
NN
9017 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
9018 case ${lang_frag} in
9019 ..) ;;
9020 # The odd quoting in the next line works around
9021 # an apparent bug in bash 1.12 on linux.
9022 ${srcdir}/gcc/[*]/config-lang.in) ;;
9023 *)
1c710c3c 9024 # From the config-lang.in, get $language, $target_libs,
2805b53a 9025 # $lang_dirs, $boot_language, and $build_by_default
55ffb5ed
NN
9026 language=
9027 target_libs=
9028 lang_dirs=
1546bb64 9029 subdir_requires=
e1888513
PB
9030 boot_language=no
9031 build_by_default=yes
d4360477
NS
9032 # set srcdir during sourcing. See above about save & restore
9033 saved_srcdir=${srcdir}
9034 srcdir=${srcdir}/gcc . ${lang_frag}
9035 srcdir=${saved_srcdir}
e1888513
PB
9036 if test x${language} = x; then
9037 echo "${lang_frag} doesn't set \$language." 1>&2
9038 exit 1
9039 fi
9040
78767fd9 9041 if test "$language" = "c++"; then
0823efed 9042 boot_language=yes
00020c16
ILT
9043 fi
9044
178f875a 9045 add_this_lang=no
cdfee50a
NS
9046 # C is always enabled, so no need to add it again
9047 if test "$language" != "c"; then
9048 case ,${enable_languages}, in
9049 *,${language},*)
9050 # Language was explicitly selected; include it
d4a10d0a 9051 add_this_lang=yes
cdfee50a
NS
9052 ;;
9053 *,all,*)
9054 # All languages are enabled
9055 add_this_lang=all
9056 ;;
9057 *,default,*)
9058 # 'default' was selected, select it if it is a default language
178f875a 9059 add_this_lang=${build_by_default}
cdfee50a
NS
9060 ;;
9061 esac
9062 fi
6de9cd9a 9063
1546bb64 9064 # Disable languages that need other directories if these aren't available.
95695ad3 9065 for i in $subdir_requires; do
b6348cb3 9066 test -f "$srcdir/gcc/$i/config-lang.in" && continue
cdfee50a
NS
9067 case ${add_this_lang} in
9068 yes)
1546bb64 9069 # Specifically requested language; tell them.
22e05272 9070 as_fn_error $? "The gcc/$i directory contains parts of $language but is missing" "$LINENO" 5
1546bb64 9071 ;;
cdfee50a
NS
9072 all)
9073 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The gcc/$i directory contains parts of $language but is missing" >&5
9074$as_echo "$as_me: WARNING: The gcc/$i directory contains parts of $language but is missing" >&2;}
9075 add_this_lang=unsupported
9076 ;;
1546bb64
PB
9077 *)
9078 # Silently disable.
e1888513 9079 add_this_lang=unsupported
1546bb64
PB
9080 ;;
9081 esac
9082 done
9083
e1888513 9084 # Disable Ada if no preexisting GNAT is available.
cdfee50a
NS
9085 case ${add_this_lang}:${language}:${have_gnat} in
9086 yes:ada:no)
e1888513 9087 # Specifically requested language; tell them.
22e05272 9088 as_fn_error $? "GNAT is required to build $language" "$LINENO" 5
e1888513 9089 ;;
cdfee50a
NS
9090 all:ada:no)
9091 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNAT is required to build $language" >&5
9092$as_echo "$as_me: WARNING: GNAT is required to build $language" >&2;}
9093 add_this_lang=unsupported
9094 ;;
e1888513
PB
9095 *:ada:no)
9096 # Silently disable.
9097 add_this_lang=unsupported
9098 ;;
9099 esac
9100
5fee5ec3
IB
9101 # Disable D if no preexisting GDC is available.
9102 case ${add_this_lang}:${language}:${have_gdc} in
9103 yes:d:no)
9104 # Specifically requested language; tell them.
9105 as_fn_error $? "GDC is required to build $language" "$LINENO" 5
9106 ;;
9107 all:d:no)
9108 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GDC is required to build $language" >&5
9109$as_echo "$as_me: WARNING: GDC is required to build $language" >&2;}
9110 add_this_lang=unsupported
9111 ;;
9112 *:d:no)
9113 # Silently disable.
9114 add_this_lang=unsupported
9115 ;;
9116 esac
9117
cdfee50a 9118 # Disable jit if -enable-host-shared not specified
ffac9597
JM
9119 # but not if building for Mingw. All code in Windows
9120 # is position independent code (PIC).
c83027f3
NB
9121 case $target in
9122 *mingw*) ;;
9123 *)
9124 case ${add_this_lang}:${language}:${host_shared} in
9125 yes:jit:no)
9126 # PR jit/64780: explicitly specify --enable-host-shared
22e05272 9127 as_fn_error $? "
cdfee50a
NS
9128Enabling language \"jit\" requires --enable-host-shared.
9129
9130--enable-host-shared typically slows the rest of the compiler down by
9131a few %, so you must explicitly enable it.
9132
9133If you want to build both the jit and the regular compiler, it is often
9134best to do this via two separate configure/builds, in separate
9135directories, to avoid imposing the performance cost of
9136--enable-host-shared on the regular compiler." "$LINENO" 5
c83027f3
NB
9137 ;;
9138 all:jit:no)
9139 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-host-shared required to build $language" >&5
cdfee50a 9140$as_echo "$as_me: WARNING: --enable-host-shared required to build $language" >&2;}
c83027f3
NB
9141 add_this_lang=unsupported
9142 ;;
9143 *:jit:no)
9144 # Silently disable.
9145 add_this_lang=unsupported
9146 ;;
9147 esac
9148 ;;
9149 esac
cdfee50a 9150
dc17e754
TS
9151 # Pre-conditions to consider whether cargo being supported.
9152 if test x"$have_cargo" = xyes \
9153 && test x"$build" != x"$host"; then
9154 # Until <https://github.com/Rust-GCC/gccrs/issues/2898>
9155 # "'cargo' should build for the host system" is resolved:
9156 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: use of cargo not yet supported here in Canadian cross configurations" >&5
9157$as_echo "$as_me: WARNING: use of cargo not yet supported here in Canadian cross configurations" >&2;}
9158 have_cargo=no
9159 else
9160 # Assume that cargo-produced object files are compatible with what
9161 # we're going to build here.
9162 :
9163 fi
3e1e73fc
PEP
9164 # Disable Rust if cargo is unavailable.
9165 case ${add_this_lang}:${language}:${have_cargo} in
9166 yes:rust:no)
9167 # Specifically requested language; tell them.
9168 as_fn_error $? "cargo is required to build $language" "$LINENO" 5
9169 ;;
9170 all:rust:no)
9171 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cargo is required to build $language" >&5
9172$as_echo "$as_me: WARNING: cargo is required to build $language" >&2;}
9173 add_this_lang=unsupported
9174 ;;
9175 *:rust:no)
9176 # Silently disable.
9177 add_this_lang=unsupported
9178 ;;
9179 esac
9180
9181
cdfee50a
NS
9182 # Disable a language that is unsupported by the target.
9183 case "${add_this_lang}: $unsupported_languages " in
9184 no:*) ;;
9185 unsupported:*) ;;
9186 *:*" $language "*)
9187 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ${language} not supported for this target" >&5
9188$as_echo "$as_me: WARNING: ${language} not supported for this target" >&2;}
e1888513 9189 add_this_lang=unsupported
4fab7234
HPN
9190 ;;
9191 esac
9192
6de9cd9a 9193 case $add_this_lang in
e1888513 9194 unsupported)
55ffb5ed 9195 # Remove language-dependent dirs.
4da3b0f8
ILT
9196 disabled_target_libs="$disabled_target_libs $target_libs"
9197 noconfigdirs="$noconfigdirs $lang_dirs"
2805b53a 9198 ;;
e1888513
PB
9199 no)
9200 # Remove language-dependent dirs; still show language as supported.
4da3b0f8
ILT
9201 disabled_target_libs="$disabled_target_libs $target_libs"
9202 noconfigdirs="$noconfigdirs $lang_dirs"
e1888513
PB
9203 potential_languages="${potential_languages}${language},"
9204 ;;
cdfee50a 9205 all|yes)
e1888513
PB
9206 new_enable_languages="${new_enable_languages}${language},"
9207 potential_languages="${potential_languages}${language},"
2805b53a 9208 missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
4da3b0f8 9209 enabled_target_libs="$enabled_target_libs $target_libs"
ab9dcd0c
RW
9210 case "${boot_language}:,$enable_stage1_languages," in
9211 yes:* | *:*,$language,* | *:*,yes, | *:*,all,)
340de83f 9212 # Add to (comma-separated) list of stage 1 languages.
ab9dcd0c
RW
9213 case ",$stage1_languages," in
9214 *,$language,* | ,yes, | ,all,) ;;
9215 *) stage1_languages="${stage1_languages}${language}," ;;
9216 esac
00020c16 9217 # We need to bootstrap any supporting libraries.
5fee5ec3 9218 bootstrap_target_libs=`echo "${bootstrap_target_libs}${target_libs}," | sed "s/ /,/g"`
2805b53a
NN
9219 ;;
9220 esac
9221 ;;
55ffb5ed
NN
9222 esac
9223 ;;
9224 esac
9225 done
9226
4da3b0f8
ILT
9227 # Add target libraries which are only needed for disabled languages
9228 # to noconfigdirs.
9229 if test -n "$disabled_target_libs"; then
9230 for dir in $disabled_target_libs; do
9231 case " $enabled_target_libs " in
9232 *" ${dir} "*) ;;
9233 *) noconfigdirs="$noconfigdirs $dir" ;;
9234 esac
9235 done
9236 fi
9237
5213506e
RW
9238 # Check whether --enable-stage1-languages was given.
9239if test "${enable_stage1_languages+set}" = set; then :
9240 enableval=$enable_stage1_languages; case ,${enable_stage1_languages}, in
e1888513
PB
9241 ,no,|,,)
9242 # Set it to something that will have no effect in the loop below
9243 enable_stage1_languages=c ;;
9244 ,yes,)
9245 enable_stage1_languages=`echo $new_enable_languages | \
9246 sed -e "s/^,//" -e "s/,$//" ` ;;
9247 *,all,*)
9248 enable_stage1_languages=`echo ,$enable_stage1_languages, | \
9249 sed -e "s/,all,/$new_enable_languages/" -e "s/^,//" -e "s/,$//" ` ;;
9250 esac
9251
9252 # Add "good" languages from enable_stage1_languages to stage1_languages,
9253 # while "bad" languages go in missing_languages. Leave no duplicates.
9254 for i in `echo $enable_stage1_languages | sed 's/,/ /g' `; do
9255 case $potential_languages in
9256 *,$i,*)
9257 case $stage1_languages in
9258 *,$i,*) ;;
9259 *) stage1_languages="$stage1_languages$i," ;;
9260 esac ;;
9261 *)
9262 case $missing_languages in
9263 *,$i,*) ;;
9264 *) missing_languages="$missing_languages$i," ;;
9265 esac ;;
9266 esac
9267 done
5213506e
RW
9268fi
9269
e1888513
PB
9270
9271 # Remove leading/trailing commas that were added for simplicity
9272 potential_languages=`echo "$potential_languages" | sed -e "s/^,//" -e "s/,$//"`
79b4b7d2 9273 missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
e1888513
PB
9274 stage1_languages=`echo "$stage1_languages" | sed -e "s/^,//" -e "s/,$//"`
9275 new_enable_languages=`echo "$new_enable_languages" | sed -e "s/^,//" -e "s/,$//"`
9276
55ffb5ed 9277 if test "x$missing_languages" != x; then
22e05272 9278 as_fn_error $? "
0cf085e4 9279The following requested languages could not be built: ${missing_languages}
5213506e 9280Supported languages are: ${potential_languages}" "$LINENO" 5
55ffb5ed 9281 fi
55ffb5ed
NN
9282 if test "x$new_enable_languages" != "x$enable_languages"; then
9283 echo The following languages will be built: ${new_enable_languages}
e1888513 9284 enable_languages="$new_enable_languages"
55ffb5ed 9285 fi
e1888513 9286
1c710c3c 9287
b2eaac4a 9288 ac_configure_args=`echo " $ac_configure_args" | sed -e "s/ '--enable-languages=[^ ]*'//g" -e "s/$/ '--enable-languages="$enable_languages"'/" `
55ffb5ed
NN
9289fi
9290
27079765
AH
9291# Handle --disable-<component> generically.
9292for dir in $configdirs $build_configdirs $target_configdirs ; do
9293 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g -e s/-/_/g`
ac9e6043
RW
9294 varname=`echo $dirname | sed -e s/+/_/g`
9295 if eval test x\${enable_${varname}} "=" xno ; then
27079765
AH
9296 noconfigdirs="$noconfigdirs $dir"
9297 fi
9298done
9299
43c40f3e
RO
9300# Check for Boehm's garbage collector
9301# Check whether --enable-objc-gc was given.
9302if test "${enable_objc_gc+set}" = set; then :
114bf3f1
MK
9303 enableval=$enable_objc_gc;
9304fi
9305
9306
9307# Check whether --with-target-bdw-gc was given.
9308if test "${with_target_bdw_gc+set}" = set; then :
9309 withval=$with_target_bdw_gc;
9310fi
9311
9312
9313# Check whether --with-target-bdw-gc-include was given.
9314if test "${with_target_bdw_gc_include+set}" = set; then :
9315 withval=$with_target_bdw_gc_include;
9316fi
9317
9318
9319# Check whether --with-target-bdw-gc-lib was given.
9320if test "${with_target_bdw_gc_lib+set}" = set; then :
9321 withval=$with_target_bdw_gc_lib;
9322fi
9323
9324
9325case ,${enable_languages},:${enable_objc_gc} in *,objc,*:yes|*,objc,*:auto)
9326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bdw garbage collector" >&5
9327$as_echo_n "checking for bdw garbage collector... " >&6; }
9328 if test "x$with_target_bdw_gc$with_target_bdw_gc_include$with_target_bdw_gc_lib" = x; then
825fba52
MK
9329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: using bdw-gc in default locations" >&5
9330$as_echo "using bdw-gc in default locations" >&6; }
114bf3f1
MK
9331 else
9332 if test "x$with_target_bdw_gc_include" = x && test "x$with_target_bdw_gc_lib" != x; then
22e05272 9333 as_fn_error $? "found --with-target-bdw-gc-lib but --with-target-bdw-gc-include missing" "$LINENO" 5
114bf3f1 9334 elif test "x$with_target_bdw_gc_include" != x && test "x$with_target_bdw_gc_lib" = x; then
22e05272 9335 as_fn_error $? "found --with-target-bdw-gc-include but --with-target-bdw-gc-lib missing" "$LINENO" 5
114bf3f1
MK
9336 else
9337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: using paths configured with --with-target-bdw-gc options" >&5
9338$as_echo "using paths configured with --with-target-bdw-gc options" >&6; }
9339 fi
9340 fi
43c40f3e
RO
9341esac
9342
e4cba494 9343# Disable libitm, libsanitizer, libvtv if we're not building C++
99776ebd 9344case ,${enable_languages}, in
1007a55c 9345 *,c++,*)
5e9d6aa4 9346 # Disable libitm, libsanitizer if we're not building libstdc++
1007a55c
JW
9347 case "${noconfigdirs}" in
9348 *target-libstdc++-v3*)
5e9d6aa4 9349 noconfigdirs="$noconfigdirs target-libitm target-libsanitizer"
1007a55c
JW
9350 ;;
9351 *) ;;
9352 esac
9353 ;;
99776ebd 9354 *)
e4cba494 9355 noconfigdirs="$noconfigdirs target-libitm target-libsanitizer target-libvtv"
99776ebd
RH
9356 ;;
9357esac
9358
725fb359
PEP
9359case ,${enable_languages}, in
9360 *,rust,*)
9361 case " ${noconfigdirs} " in
9362 *\ target-libstdc++-v3\ *)
9363 # Disable target libgrust if we're not building target libstdc++.
9364 noconfigdirs="$noconfigdirs target-libgrust"
9365 ;;
9366 esac
9367 ;;
9368esac
9369
dc614a83
AB
9370# If gcc/ is not in the source tree then we'll not be building a
9371# target compiler, assume in that case we don't want to build any
9372# target libraries or tools.
9373#
9374# This was added primarily for the benefit for binutils-gdb who reuse
9375# this configure script, but don't always have target tools available.
9376if test ! -d ${srcdir}/gcc; then
9377 skipdirs="${skipdirs} ${target_configdirs}"
9378fi
9379
ee6a22df
L
9380# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
9381# $build_configdirs and $target_configdirs.
55ffb5ed
NN
9382# If we have the source for $noconfigdirs entries, add them to $notsupp.
9383
9384notsupp=""
9385for dir in . $skipdirs $noconfigdirs ; do
ee6a22df 9386 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
55ffb5ed
NN
9387 if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9388 configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
9389 if test -r $srcdir/$dirname/configure ; then
9390 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9391 true
9392 else
9393 notsupp="$notsupp $dir"
9394 fi
9395 fi
9396 fi
ee6a22df
L
9397 if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9398 build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
9399 if test -r $srcdir/$dirname/configure ; then
9400 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9401 true
9402 else
9403 notsupp="$notsupp $dir"
9404 fi
9405 fi
9406 fi
55ffb5ed
NN
9407 if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9408 target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
9409 if test -r $srcdir/$dirname/configure ; then
9410 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9411 true
9412 else
9413 notsupp="$notsupp $dir"
9414 fi
9415 fi
9416 fi
9417done
9418
55ffb5ed
NN
9419# Quietly strip out all directories which aren't configurable in this tree.
9420# This relies on all configurable subdirectories being autoconfiscated, which
9421# is now the case.
23f6b2f9
PB
9422build_configdirs_all="$build_configdirs"
9423build_configdirs=
9424for i in ${build_configdirs_all} ; do
1c710c3c 9425 j=`echo $i | sed -e s/build-//g`
23f6b2f9
PB
9426 if test -f ${srcdir}/$j/configure ; then
9427 build_configdirs="${build_configdirs} $i"
9428 fi
9429done
9430
55ffb5ed
NN
9431configdirs_all="$configdirs"
9432configdirs=
9433for i in ${configdirs_all} ; do
9434 if test -f ${srcdir}/$i/configure ; then
9435 configdirs="${configdirs} $i"
9436 fi
9437done
23f6b2f9 9438
55ffb5ed
NN
9439target_configdirs_all="$target_configdirs"
9440target_configdirs=
9441for i in ${target_configdirs_all} ; do
1c710c3c 9442 j=`echo $i | sed -e s/target-//g`
55ffb5ed
NN
9443 if test -f ${srcdir}/$j/configure ; then
9444 target_configdirs="${target_configdirs} $i"
9445 fi
9446done
9447
45b3824d
TS
9448# libiberty-linker-plugin is special: it doesn't have its own source directory,
9449# so we have to add it after the preceding checks.
9450if test x"$extra_linker_plugin_flags$extra_linker_plugin_configure_flags" != x
9451then
9452 case " $configdirs " in
9453 *" libiberty "*)
9454 # If we can build libiberty, we can also build libiberty-linker-plugin.
9455 configdirs="$configdirs libiberty-linker-plugin"
9456 extra_linker_plugin_configure_flags="$extra_linker_plugin_configure_flags \
9457 --with-libiberty=../libiberty-linker-plugin";;
9458 *)
22e05272 9459 as_fn_error $? "libiberty missing" "$LINENO" 5;;
45b3824d
TS
9460 esac
9461fi
9462
fca38047
TS
9463# Sometimes we have special requirements for the host libiberty.
9464extra_host_libiberty_configure_flags=
9465case " $configdirs " in
15368960 9466 *" lto-plugin "* | *" libcc1 "* | *" gdbserver "*)
fca38047
TS
9467 # When these are to be built as shared libraries, the same applies to
9468 # libiberty.
9469 extra_host_libiberty_configure_flags=--enable-shared
9470 ;;
04bb15e4
TV
9471esac
9472
9473
9474# Sometimes we have special requirements for the host zlib.
9475extra_host_zlib_configure_flags=
9476case " $configdirs " in
1c01ebf6
L
9477 *" bfd "*)
9478 # When bfd is to be built as a shared library, the same applies to
9479 # zlib.
9480 if test "$enable_shared" = "yes"; then
9481 extra_host_zlib_configure_flags=--enable-host-shared
9482 fi
9483 ;;
fca38047
TS
9484esac
9485
9486
55ffb5ed
NN
9487# Produce a warning message for the subdirs we can't configure.
9488# This isn't especially interesting in the Cygnus tree, but in the individual
9489# FSF releases, it's important to let people know when their machine isn't
9490# supported by the one or two programs in a package.
9491
9492if test -n "${notsupp}" && test -z "${norecursion}" ; then
9493 # If $appdirs is non-empty, at least one of those directories must still
9494 # be configured, or we error out. (E.g., if the gas release supports a
9495 # specified target in some subdirs but not the gas subdir, we shouldn't
9496 # pretend that all is well.)
9497 if test -n "$appdirs" ; then
9498 for dir in $appdirs ; do
9499 if test -r $dir/Makefile.in ; then
9500 if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
9501 appdirs=""
9502 break
9503 fi
23f6b2f9 9504 if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
55ffb5ed
NN
9505 appdirs=""
9506 break
9507 fi
9508 fi
9509 done
9510 if test -n "$appdirs" ; then
9511 echo "*** This configuration is not supported by this package." 1>&2
9512 exit 1
9513 fi
9514 fi
9515 # Okay, some application will build, or we don't care to check. Still
9516 # notify of subdirs not getting built.
9517 echo "*** This configuration is not supported in the following subdirectories:" 1>&2
9518 echo " ${notsupp}" 1>&2
9519 echo " (Any other directories should still work fine.)" 1>&2
9520fi
9521
9522case "$host" in
9523 *msdosdjgpp*)
9524 enable_gdbtk=no ;;
9525esac
9526
c3a86da9
DJ
9527# To find our prefix, in gcc_cv_tool_prefix.
9528
9529# The user is always right.
9530if test "${PATH_SEPARATOR+set}" != set; then
9531 echo "#! /bin/sh" >conf$$.sh
9532 echo "exit 0" >>conf$$.sh
9533 chmod +x conf$$.sh
9534 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
9535 PATH_SEPARATOR=';'
9536 else
9537 PATH_SEPARATOR=:
9538 fi
9539 rm -f conf$$.sh
9540fi
9541
9542
3c36aa6b
JJ
9543 get_gcc_base_ver="cat"
9544
9545# Check whether --with-gcc-major-version-only was given.
9546if test "${with_gcc_major_version_only+set}" = set; then :
9547 withval=$with_gcc_major_version_only; if test x$with_gcc_major_version_only = xyes ; then
31db0fe0 9548 get_gcc_base_ver="sed -e 's/^\([0-9]*\).*/\1/'"
3c36aa6b
JJ
9549 fi
9550
9551fi
9552
9553
9554
9555
9556
c3a86da9
DJ
9557
9558if test "x$exec_prefix" = xNONE; then
9559 if test "x$prefix" = xNONE; then
9560 gcc_cv_tool_prefix=$ac_default_prefix
9561 else
9562 gcc_cv_tool_prefix=$prefix
9563 fi
9564else
9565 gcc_cv_tool_prefix=$exec_prefix
9566fi
9567
9568# If there is no compiler in the tree, use the PATH only. In any
9569# case, if there is no compiler in the tree nobody should use
9570# AS_FOR_TARGET and LD_FOR_TARGET.
9571if test x$host = x$build && test -f $srcdir/gcc/BASE-VER; then
3c36aa6b
JJ
9572 if test x$with_gcc_major_version_only = xyes ; then
9573 gcc_version=`sed -e 's/^\([0-9]*\).*$/\1/' $srcdir/gcc/BASE-VER`
9574 else
9575 gcc_version=`cat $srcdir/gcc/BASE-VER`
9576 fi
c3a86da9
DJ
9577 gcc_cv_tool_dirs="$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
9578 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical$PATH_SEPARATOR"
9579 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
9580 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical$PATH_SEPARATOR"
9581 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
9582 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin$PATH_SEPARATOR"
9583else
9584 gcc_cv_tool_dirs=
9585fi
9586
9587if test x$build = x$target && test -n "$md_exec_prefix"; then
9588 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$md_exec_prefix$PATH_SEPARATOR"
9589fi
9590
9591
9592
55ffb5ed
NN
9593copy_dirs=
9594
1c710c3c 9595
5213506e
RW
9596# Check whether --with-build-sysroot was given.
9597if test "${with_build_sysroot+set}" = set; then :
9598 withval=$with_build_sysroot; if test x"$withval" != x ; then
526635cb
MM
9599 SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
9600 fi
9601else
9602 SYSROOT_CFLAGS_FOR_TARGET=
5213506e 9603fi
526635cb
MM
9604
9605
c8aea42c 9606
5213506e
RW
9607
9608# Check whether --with-debug-prefix-map was given.
9609if test "${with_debug_prefix_map+set}" = set; then :
9610 withval=$with_debug_prefix_map; if test x"$withval" != x; then
c8aea42c
PB
9611 DEBUG_PREFIX_CFLAGS_FOR_TARGET=
9612 for debug_map in $withval; do
9613 DEBUG_PREFIX_CFLAGS_FOR_TARGET="$DEBUG_PREFIX_CFLAGS_FOR_TARGET -fdebug-prefix-map=$debug_map"
9614 done
9615 fi
9616else
9617 DEBUG_PREFIX_CFLAGS_FOR_TARGET=
5213506e
RW
9618fi
9619
c8aea42c
PB
9620
9621
1c8bd6a3
PB
9622# During gcc bootstrap, if we use some random cc for stage1 then CFLAGS
9623# might be empty or "-g". We don't require a C++ compiler, so CXXFLAGS
9624# might also be empty (or "-g", if a non-GCC C++ compiler is in the path).
9625# We want to ensure that TARGET libraries (which we know are built with
9626# gcc) are built with "-O2 -g", so include those options when setting
9627# CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.
9628if test "x$CFLAGS_FOR_TARGET" = x; then
fc30054e
AH
9629 if test "x${is_cross_compiler}" = xyes; then
9630 CFLAGS_FOR_TARGET="-g -O2"
9631 else
9632 CFLAGS_FOR_TARGET=$CFLAGS
9633 case " $CFLAGS " in
9634 *" -O2 "*) ;;
9635 *) CFLAGS_FOR_TARGET="-O2 $CFLAGS_FOR_TARGET" ;;
9636 esac
9637 case " $CFLAGS " in
9638 *" -g "* | *" -g3 "*) ;;
9639 *) CFLAGS_FOR_TARGET="-g $CFLAGS_FOR_TARGET" ;;
9640 esac
9641 fi
1c8bd6a3
PB
9642fi
9643
9644
9645if test "x$CXXFLAGS_FOR_TARGET" = x; then
fc30054e
AH
9646 if test "x${is_cross_compiler}" = xyes; then
9647 CXXFLAGS_FOR_TARGET="-g -O2"
9648 else
9649 CXXFLAGS_FOR_TARGET=$CXXFLAGS
9650 case " $CXXFLAGS " in
9651 *" -O2 "*) ;;
9652 *) CXXFLAGS_FOR_TARGET="-O2 $CXXFLAGS_FOR_TARGET" ;;
9653 esac
9654 case " $CXXFLAGS " in
9655 *" -g "* | *" -g3 "*) ;;
9656 *) CXXFLAGS_FOR_TARGET="-g $CXXFLAGS_FOR_TARGET" ;;
9657 esac
9658 fi
1c8bd6a3
PB
9659fi
9660
9661
6f57bdf6
DK
9662
9663
55ffb5ed
NN
9664# Handle --with-headers=XXX. If the value is not "yes", the contents of
9665# the named directory are copied to $(tooldir)/sys-include.
9666if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
9667 if test x${is_cross_compiler} = xno ; then
9668 echo 1>&2 '***' --with-headers is only supported when cross compiling
9669 exit 1
9670 fi
9671 if test x"${with_headers}" != xyes ; then
c3a86da9 9672 x=${gcc_cv_tool_prefix}
1c710c3c 9673 copy_dirs="${copy_dirs} ${with_headers} $x/${target_noncanonical}/sys-include"
55ffb5ed
NN
9674 fi
9675fi
9676
9677# Handle --with-libs=XXX. If the value is not "yes", the contents of
9678# the name directories are copied to $(tooldir)/lib. Multiple directories
9679# are permitted.
9680if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
9681 if test x${is_cross_compiler} = xno ; then
9682 echo 1>&2 '***' --with-libs is only supported when cross compiling
9683 exit 1
9684 fi
9685 if test x"${with_libs}" != xyes ; then
9686 # Copy the libraries in reverse order, so that files in the first named
9687 # library override files in subsequent libraries.
c3a86da9 9688 x=${gcc_cv_tool_prefix}
55ffb5ed 9689 for l in ${with_libs}; do
1c710c3c 9690 copy_dirs="$l $x/${target_noncanonical}/lib ${copy_dirs}"
55ffb5ed
NN
9691 done
9692 fi
9693fi
9694
d7f09764 9695# Set with_gnu_as, with_gnu_ld, and with_system_zlib as appropriate.
e8b05380
PB
9696#
9697# This is done by determining whether or not the appropriate directory
9698# is available, and by checking whether or not specific configurations
9699# have requested that this magic not happen.
1c710c3c
DJ
9700#
9701# The command line options always override the explicit settings in
6b1786aa 9702# configure.ac, and the settings in configure.ac override this magic.
e8b05380 9703#
1c710c3c 9704# If the default for a toolchain is to use GNU as and ld, and you don't
e8b05380 9705# want to do that, then you should use the --without-gnu-as and
d7f09764
DN
9706# --without-gnu-ld options for the configure script. Similarly, if
9707# the default is to use the included zlib and you don't want to do that,
9708# you should use the --with-system-zlib option for the configure script.
e8b05380
PB
9709
9710if test x${use_gnu_as} = x &&
9711 echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
9712 with_gnu_as=yes
9713 extra_host_args="$extra_host_args --with-gnu-as"
9714fi
9715
9716if test x${use_gnu_ld} = x &&
5afab7ad 9717 echo " ${configdirs} " | egrep " (go)?ld " > /dev/null 2>&1 ; then
e8b05380
PB
9718 with_gnu_ld=yes
9719 extra_host_args="$extra_host_args --with-gnu-ld"
9720fi
9721
d7f09764
DN
9722if test x${use_included_zlib} = x &&
9723 echo " ${configdirs} " | grep " zlib " > /dev/null 2>&1 ; then
9724 :
9725else
9726 with_system_zlib=yes
9727 extra_host_args="$extra_host_args --with-system-zlib"
9728fi
9729
e8b05380
PB
9730# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
9731# can detect this case.
9732
9733if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
9734 with_newlib=yes
9735 extra_host_args="$extra_host_args --with-newlib"
9736fi
9737
55ffb5ed
NN
9738# Handle ${copy_dirs}
9739set fnord ${copy_dirs}
9740shift
9741while test $# != 0 ; do
9742 if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
9743 :
9744 else
9745 echo Copying $1 to $2
9746
9747 # Use the install script to create the directory and all required
9748 # parent directories.
9749 if test -d $2 ; then
9750 :
9751 else
9752 echo >config.temp
9753 ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
9754 fi
9755
9756 # Copy the directory, assuming we have tar.
9757 # FIXME: Should we use B in the second tar? Not all systems support it.
9758 (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
9759
9760 # It is the responsibility of the user to correctly adjust all
9761 # symlinks. If somebody can figure out how to handle them correctly
9762 # here, feel free to add the code.
9763
9764 echo $1 > $2/COPIED
9765 fi
9766 shift; shift
9767done
9768
e8b05380
PB
9769# Determine a target-dependent exec_prefix that the installed
9770# gcc will search in. Keep this list sorted by triplet, with
9771# the *-*-osname triplets last.
9772md_exec_prefix=
9773case "${target}" in
30b74385 9774 i[34567]86-pc-msdosdjgpp*)
e8b05380
PB
9775 md_exec_prefix=/dev/env/DJDIR/bin
9776 ;;
e8b05380 9777 *-*-hpux* | \
e8b05380 9778 *-*-nto-qnx* | \
6de66370 9779 *-*-solaris2*)
e8b05380
PB
9780 md_exec_prefix=/usr/ccs/bin
9781 ;;
9782esac
9783
671aa708
NN
9784extra_arflags_for_target=
9785extra_nmflags_for_target=
9786extra_ranlibflags_for_target=
9787target_makefile_frag=/dev/null
9788case "${target}" in
58e24147
AM
9789 spu-*-*)
9790 target_makefile_frag="config/mt-spu"
9791 ;;
227b18f5
YY
9792 loongarch*-*linux* | loongarch*-*gnu*)
9793 target_makefile_frag="config/mt-loongarch-gnu"
9794 ;;
9795 loongarch*-*elf*)
9796 target_makefile_frag="config/mt-loongarch-elf"
9797 ;;
d896cc4d 9798 mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
4bf6c438
RS
9799 target_makefile_frag="config/mt-sde"
9800 ;;
1ec3b87b
RS
9801 mipsisa*-*-elfoabi*)
9802 target_makefile_frag="config/mt-mips-elfoabi"
9803 ;;
08d0963a
RS
9804 mips*-*-*linux* | mips*-*-gnu*)
9805 target_makefile_frag="config/mt-mips-gnu"
9806 ;;
707f1839
SL
9807 nios2-*-elf*)
9808 target_makefile_frag="config/mt-nios2-elf"
9809 ;;
76052545
EB
9810 *-*-linux-android*)
9811 target_makefile_frag="config/mt-android"
9812 ;;
416ac4d4 9813 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
98a5bb3b 9814 target_makefile_frag="config/mt-gnu"
671aa708
NN
9815 ;;
9816 *-*-aix4.[3456789]* | *-*-aix[56789].*)
1c710c3c 9817 # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
671aa708
NN
9818 # commands to handle both 32-bit and 64-bit objects. These flags are
9819 # harmless if we're using GNU nm or ar.
9820 extra_arflags_for_target=" -X32_64"
9821 extra_nmflags_for_target=" -B -X32_64"
9822 ;;
671aa708
NN
9823esac
9824
9825alphaieee_frag=/dev/null
9826case $target in
9827 alpha*-*-*)
9828 # This just makes sure to use the -mieee option to build target libs.
9829 # This should probably be set individually by each library.
9830 alphaieee_frag="config/mt-alphaieee"
9831 ;;
9832esac
9833
9834# If --enable-target-optspace always use -Os instead of -O2 to build
9835# the target libraries, similarly if it is not specified, use -Os
9836# on selected platforms.
9837ospace_frag=/dev/null
9838case "${enable_target_optspace}:${target}" in
9839 yes:*)
9840 ospace_frag="config/mt-ospace"
9841 ;;
9842 :d30v-*)
9843 ospace_frag="config/mt-d30v"
9844 ;;
d9063947 9845 :m32r-* | :d10v-* | :fr30-* | :i?86*-*-elfiamcu)
671aa708
NN
9846 ospace_frag="config/mt-ospace"
9847 ;;
9848 no:* | :*)
9849 ;;
9850 *)
9851 echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
9852 ;;
9853esac
9854
671aa708
NN
9855# Some systems (e.g., one of the i386-aix systems the gas testers are
9856# using) don't handle "\$" correctly, so don't use it here.
1c710c3c 9857tooldir='${exec_prefix}'/${target_noncanonical}
671aa708
NN
9858build_tooldir=${tooldir}
9859
671aa708
NN
9860# Create a .gdbinit file which runs the one in srcdir
9861# and tells GDB to look there for source files.
9862
9863if test -r ${srcdir}/.gdbinit ; then
9864 case ${srcdir} in
9865 .) ;;
9866 *) cat > ./.gdbinit <<EOF
9867# ${NO_EDIT}
9868dir ${srcdir}
9869dir .
9870source ${srcdir}/.gdbinit
9871EOF
9872 ;;
9873 esac
9874fi
9875
671aa708
NN
9876# Make sure that the compiler is able to generate an executable. If it
9877# can't, we are probably in trouble. We don't care whether we can run the
9878# executable--we might be using a cross compiler--we only care whether it
9879# can be created. At this point the main configure script has set CC.
9880we_are_ok=no
9881echo "int main () { return 0; }" > conftest.c
9882${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
9883if test $? = 0 ; then
9884 if test -s conftest || test -s conftest.exe ; then
9885 we_are_ok=yes
9886 fi
1c710c3c 9887fi
671aa708
NN
9888case $we_are_ok in
9889 no)
9890 echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
9891 echo 1>&2 "*** You must set the environment variable CC to a working compiler."
9892 rm -f conftest*
9893 exit 1
9894 ;;
9895esac
9896rm -f conftest*
9897
d89f0ad6 9898# Decide which environment variable is used to find dynamic libraries.
671aa708
NN
9899case "${host}" in
9900 *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
111eeb6e 9901 *-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
d89f0ad6 9902 *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
671aa708
NN
9903 *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
9904esac
9905
d89f0ad6
AL
9906# On systems where the dynamic library environment variable is PATH,
9907# gcc/ will put dynamic libraries into a subdirectory to avoid adding
9908# built executables to PATH.
9909if test "$RPATH_ENVVAR" = PATH; then
9910 GCC_SHLIB_SUBDIR=/shlib
9911else
9912 GCC_SHLIB_SUBDIR=
9913fi
9914
beeda1d9
JJ
9915# Adjust the toplevel makefile according to whether bootstrap was selected.
9916case $enable_bootstrap in
9917 yes)
9918 bootstrap_suffix=bootstrap
9919 BUILD_CONFIG=bootstrap-debug
9920 ;;
9921 no)
9922 bootstrap_suffix=no-bootstrap
9923 BUILD_CONFIG=
9924 ;;
9925esac
9926
9927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default BUILD_CONFIG" >&5
9928$as_echo_n "checking for default BUILD_CONFIG... " >&6; }
9929
9930
9931# Check whether --with-build-config was given.
9932if test "${with_build_config+set}" = set; then :
9933 withval=$with_build_config; case $with_build_config in
9934 yes) with_build_config= ;;
9935 no) with_build_config= BUILD_CONFIG= ;;
9936 esac
9937fi
9938
9939
9940if test "x${with_build_config}" != x; then
9941 BUILD_CONFIG=$with_build_config
9942else
9943 case $BUILD_CONFIG in
9944 bootstrap-debug)
9945 if echo "int f (void) { return 0; }" > conftest.c &&
9946 ${CC} -c conftest.c &&
9947 mv conftest.o conftest.o.g0 &&
9948 ${CC} -c -g conftest.c &&
9949 mv conftest.o conftest.o.g &&
9950 ${srcdir}/contrib/compare-debug conftest.o.g0 conftest.o.g > /dev/null 2>&1; then
9951 :
9952 else
9953 BUILD_CONFIG=
9954 fi
9955 rm -f conftest.c conftest.o conftest.o.g0 conftest.o.g
9956 ;;
9957 esac
9958fi
9959{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CONFIG" >&5
9960$as_echo "$BUILD_CONFIG" >&6; }
9961
9962
9963# Use same top-level configure hooks in libgcc/libstdc++/libvtv.
9964{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-vtable-verify" >&5
9965$as_echo_n "checking for --enable-vtable-verify... " >&6; }
9966# Check whether --enable-vtable-verify was given.
9967if test "${enable_vtable_verify+set}" = set; then :
9968 enableval=$enable_vtable_verify; case "$enableval" in
9969 yes) enable_vtable_verify=yes ;;
9970 no) enable_vtable_verify=no ;;
9971 *) enable_vtable_verify=no;;
9972 esac
9973else
9974 enable_vtable_verify=no
9975fi
9976
9977{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_vtable_verify" >&5
9978$as_echo "$enable_vtable_verify" >&6; }
9979
671aa708
NN
9980# Record target_configdirs and the configure arguments for target and
9981# build configuration in Makefile.
9982target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
23f6b2f9 9983build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
9e1c8fc1 9984bootstrap_fixincludes=no
671aa708 9985
ad1e5170
JR
9986# If we are building libgomp, bootstrap it.
9987if echo " ${target_configdirs} " | grep " libgomp " > /dev/null 2>&1 ; then
9988 bootstrap_target_libs=${bootstrap_target_libs}target-libgomp,
9989fi
9990
beeda1d9
JJ
9991# If we are building libsanitizer and $BUILD_CONFIG contains bootstrap-asan
9992# or bootstrap-ubsan, bootstrap it.
9993if echo " ${target_configdirs} " | grep " libsanitizer " > /dev/null 2>&1; then
9994 case "$BUILD_CONFIG" in
170e618e 9995 *bootstrap-hwasan* | *bootstrap-asan* | *bootstrap-ubsan* )
beeda1d9 9996 bootstrap_target_libs=${bootstrap_target_libs}target-libsanitizer,
9e1c8fc1 9997 bootstrap_fixincludes=yes
beeda1d9
JJ
9998 ;;
9999 esac
ac8701fe
L
10000fi
10001
beeda1d9
JJ
10002# If we are building libvtv and --enable-vtable-verify, bootstrap it.
10003if echo " ${target_configdirs} " | grep " libvtv " > /dev/null 2>&1 &&
10004 test "$enable_vtable_verify" != no; then
2077db1b
CT
10005 bootstrap_target_libs=${bootstrap_target_libs}target-libvtv,
10006fi
10007
5fee5ec3
IB
10008# If we are building libatomic and the list of enabled languages includes the
10009# D frontend, bootstrap it.
10010if echo " ${target_configdirs} " | grep " libatomic " > /dev/null 2>&1; then
10011 case ,${enable_languages}, in
10012 *,d,*)
10013 bootstrap_target_libs=${bootstrap_target_libs}target-libatomic,
10014 ;;
10015 esac
10016fi
10017
671aa708
NN
10018# Determine whether gdb needs tk/tcl or not.
10019# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
10020# and in that case we want gdb to be built without tk. Ugh!
10021# In fact I believe gdb is the *only* package directly dependent on tk,
10022# so we should be able to put the 'maybe's in unconditionally and
10023# leave out the maybe dependencies when enable_gdbtk is false. I'm not
10024# 100% sure that that's safe though.
e914a571 10025
b4f96efe 10026gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
671aa708
NN
10027case "$enable_gdbtk" in
10028 no)
10029 GDB_TK="" ;;
e914a571
AC
10030 yes)
10031 GDB_TK="${gdb_tk}" ;;
671aa708 10032 *)
e914a571
AC
10033 # Only add the dependency on gdbtk when GDBtk is part of the gdb
10034 # distro. Eventually someone will fix this and move Insight, nee
10035 # gdbtk to a separate directory.
10036 if test -d ${srcdir}/gdb/gdbtk ; then
10037 GDB_TK="${gdb_tk}"
10038 else
10039 GDB_TK=""
10040 fi
10041 ;;
671aa708 10042esac
ef9db8d5
DJ
10043CONFIGURE_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-configure-/g`
10044INSTALL_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-install-/g`
671aa708 10045
f9d09df0
TT
10046# gdb and gdbserver depend on gnulib and gdbsupport, but as nothing
10047# else does, only include them if one of these is built. The Makefile
10048# provides the ordering, so it's enough here to add to the list.
10049case " ${configdirs} " in
10050 *\ gdb\ *)
10051 configdirs="${configdirs} gnulib gdbsupport"
10052 ;;
10053 *\ gdbserver\ *)
10054 configdirs="${configdirs} gnulib gdbsupport"
10055 ;;
f14c9bd4
MF
10056 *\ sim\ *)
10057 configdirs="${configdirs} gnulib"
10058 ;;
f9d09df0 10059esac
98e5be21 10060
60975492 10061# Strip out unwanted targets.
8b87bb96
NN
10062
10063# While at that, we remove Makefiles if we were started for recursive
10064# configuration, so that the top-level Makefile reconfigures them,
10065# like we used to do when configure itself was recursive.
8b87bb96 10066
3e54529c
RW
10067# Loop over modules. We used to use the "$extrasub" feature from Autoconf
10068# but now we're fixing up the Makefile ourselves with the additional
10069# commands passed to AC_CONFIG_FILES. Use separate variables
10070# extrasub-{build,host,target} not because there is any reason to split
10071# the substitutions up that way, but only to remain below the limit of
10072# 99 commands in a script, for HP-UX sed.
da34ca3f
AO
10073
10074# Do not nest @if/@endif or @unless/@endunless pairs, because
10075# configure will not warn you at all.
8b87bb96 10076
79cd2b23
RW
10077case "$enable_bootstrap:$ENABLE_GOLD: $configdirs :,$stage1_languages," in
10078 yes:yes:*\ gold\ *:*,c++,*) ;;
10079 yes:yes:*\ gold\ *:*)
22e05272 10080 as_fn_error $? "in a combined tree, bootstrapping with --enable-gold requires c++ in stage1_languages" "$LINENO" 5
79cd2b23
RW
10081 ;;
10082esac
10083
3e54529c 10084extrasub_build=
23f6b2f9 10085for module in ${build_configdirs} ; do
5607edfd
PB
10086 if test -z "${no_recursion}" \
10087 && test -f ${build_subdir}/${module}/Makefile; then
10088 echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
10089 rm -f ${build_subdir}/${module}/Makefile
10090 fi
3e54529c 10091 extrasub_build="$extrasub_build
5607edfd
PB
10092/^@if build-$module\$/d
10093/^@endif build-$module\$/d
da34ca3f 10094/^@unless build-$module\$/,/^@endunless build-$module\$/d
5607edfd 10095/^@if build-$module-$bootstrap_suffix\$/d
da34ca3f
AO
10096/^@endif build-$module-$bootstrap_suffix\$/d
10097/^@unless build-$module-$bootstrap_suffix\$/,/^@endunless build-$module-$bootstrap_suffix\$/d"
5607edfd 10098done
3e54529c 10099extrasub_host=
5607edfd 10100for module in ${configdirs} ; do
a6fbc1e2 10101 if test -z "${no_recursion}"; then
f063a9ed 10102 for file in stage*-${module}/Makefile prev-${module}/Makefile ${module}/Makefile; do
a6fbc1e2
AS
10103 if test -f ${file}; then
10104 echo 1>&2 "*** removing ${file} to force reconfigure"
10105 rm -f ${file}
10106 fi
10107 done
5607edfd 10108 fi
9e1c8fc1
JJ
10109 case ${module},${bootstrap_fixincludes} in
10110 fixincludes,no) host_bootstrap_suffix=no-bootstrap ;;
10111 *) host_bootstrap_suffix=$bootstrap_suffix ;;
10112 esac
3e54529c 10113 extrasub_host="$extrasub_host
5607edfd
PB
10114/^@if $module\$/d
10115/^@endif $module\$/d
da34ca3f 10116/^@unless $module\$/,/^@endunless $module\$/d
9e1c8fc1 10117/^@if $module-$host_bootstrap_suffix\$/d
da34ca3f
AO
10118/^@endif $module-$host_bootstrap_suffix\$/d
10119/^@unless $module-$host_bootstrap_suffix\$/,/^@endunless $module-$host_bootstrap_suffix\$/d"
5607edfd 10120done
3e54529c 10121extrasub_target=
5607edfd
PB
10122for module in ${target_configdirs} ; do
10123 if test -z "${no_recursion}" \
10124 && test -f ${target_subdir}/${module}/Makefile; then
10125 echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
10126 rm -f ${target_subdir}/${module}/Makefile
10127 fi
00020c16
ILT
10128
10129 # We only bootstrap target libraries listed in bootstrap_target_libs.
10130 case $bootstrap_target_libs in
10131 *,target-$module,*) target_bootstrap_suffix=$bootstrap_suffix ;;
10132 *) target_bootstrap_suffix=no-bootstrap ;;
10133 esac
10134
3e54529c 10135 extrasub_target="$extrasub_target
5607edfd
PB
10136/^@if target-$module\$/d
10137/^@endif target-$module\$/d
da34ca3f 10138/^@unless target-$module\$/,/^@endunless target-$module\$/d
00020c16 10139/^@if target-$module-$target_bootstrap_suffix\$/d
da34ca3f
AO
10140/^@endif target-$module-$target_bootstrap_suffix\$/d
10141/^@unless target-$module-$target_bootstrap_suffix\$/,/^@endunless target-$module-$target_bootstrap_suffix\$/d"
5607edfd
PB
10142done
10143
3e54529c
RW
10144# Do the final fixup along with target modules.
10145extrasub_target="$extrasub_target
da34ca3f
AO
10146/^@if /,/^@endif /d
10147/^@unless /d
10148/^@endunless /d"
671aa708 10149
4a5e71f2
L
10150if test "$enable_pgo_build" != "no"; then
10151 extrasub_build="$extrasub_build
10152/^@if pgo-build\$/d
10153/^@endif pgo-build\$/d"
10154fi
10155
671aa708
NN
10156# Create the serialization dependencies. This uses a temporary file.
10157
5213506e
RW
10158# Check whether --enable-serial-configure was given.
10159if test "${enable_serial_configure+set}" = set; then :
10160 enableval=$enable_serial_configure;
10161fi
ade82b16
AO
10162
10163
bf1d3e81
NN
10164case ${enable_serial_configure} in
10165 yes)
10166 enable_serial_build_configure=yes
10167 enable_serial_host_configure=yes
10168 enable_serial_target_configure=yes
10169 ;;
10170esac
10171
671aa708
NN
10172# These force 'configure's to be done one at a time, to avoid problems
10173# with contention over a shared config.cache.
10174rm -f serdep.tmp
7d115e01 10175if test "x${enable_serial_build_configure}" = xyes || test "x${enable_serial_host_configure}" = xyes || test "x${enable_serial_target_configure}" = xyes; then
ade82b16 10176echo '# serdep.tmp' > serdep.tmp
7d115e01 10177fi
671aa708 10178olditem=
bf1d3e81 10179test "x${enable_serial_build_configure}" = xyes &&
671aa708
NN
10180for item in ${build_configdirs} ; do
10181 case ${olditem} in
10182 "") ;;
ade82b16 10183 *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
671aa708
NN
10184 esac
10185 olditem=${item}
10186done
10187olditem=
bf1d3e81 10188test "x${enable_serial_host_configure}" = xyes &&
671aa708
NN
10189for item in ${configdirs} ; do
10190 case ${olditem} in
10191 "") ;;
ade82b16 10192 *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
671aa708
NN
10193 esac
10194 olditem=${item}
10195done
10196olditem=
bf1d3e81 10197test "x${enable_serial_target_configure}" = xyes &&
671aa708
NN
10198for item in ${target_configdirs} ; do
10199 case ${olditem} in
10200 "") ;;
ade82b16 10201 *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
671aa708
NN
10202 esac
10203 olditem=${item}
10204done
10205serialization_dependencies=serdep.tmp
10206
10207
ade82b16 10208# Base args. Strip norecursion, cache-file, srcdir, host, build,
1c710c3c 10209# target, nonopt, and variable assignments. These are the ones we
f1a036e4
NC
10210# might not want to pass down to subconfigures. The exception being
10211# --cache-file=/dev/null, which is used to turn off the use of cache
10212# files altogether, and which should be passed on to subconfigures.
10213# Also strip program-prefix, program-suffix, and program-transform-name,
10214# so that we can pass down a consistent program-transform-name.
db50aea6
AA
10215hbaseargs=
10216bbaseargs=
29a63921 10217tbaseargs=
1c710c3c
DJ
10218keep_next=no
10219skip_next=no
10220eval "set -- $ac_configure_args"
44bfc3ac
DJ
10221for ac_arg
10222do
1c710c3c
DJ
10223 if test X"$skip_next" = X"yes"; then
10224 skip_next=no
10225 continue
10226 fi
10227 if test X"$keep_next" = X"yes"; then
10228 case $ac_arg in
10229 *\'*)
10230 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
10231 esac
db50aea6
AA
10232 hbaseargs="$hbaseargs '$ac_arg'"
10233 bbaseargs="$bbaseargs '$ac_arg'"
29a63921 10234 tbaseargs="$tbaseargs '$ac_arg'"
1c710c3c
DJ
10235 keep_next=no
10236 continue
10237 fi
10238
10239 # Handle separated arguments. Based on the logic generated by
10240 # autoconf 2.59.
10241 case $ac_arg in
10242 *=* | --config-cache | -C | -disable-* | --disable-* \
10243 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
10244 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
10245 | -with-* | --with-* | -without-* | --without-* | --x)
10246 separate_arg=no
10247 ;;
10248 -*)
10249 separate_arg=yes
10250 ;;
10251 *)
10252 separate_arg=no
10253 ;;
10254 esac
10255
29a63921 10256 skip_targ=no
db50aea6 10257 skip_barg=no
29a63921
AO
10258 case $ac_arg in
10259
10260 --with-* | --without-*)
10261 libopt=`echo "$ac_arg" | sed -e 's,^--[^-_]*[-_],,' -e 's,=.*$,,'`
10262
10263 case $libopt in
10264 *[-_]include)
10265 lib=`echo "$libopt" | sed 's,[-_]include$,,'`
10266 ;;
10267 *[-_]lib)
10268 lib=`echo "$libopt" | sed 's,[-_]lib$,,'`
10269 ;;
db50aea6
AA
10270 *[-_]prefix)
10271 lib=`echo "$libopt" | sed 's,[-_]prefix$,,'`
10272 ;;
10273 *[-_]type)
10274 lib=`echo "$libopt" | sed 's,[-_]type$,,'`
10275 ;;
29a63921
AO
10276 *)
10277 lib=$libopt
10278 ;;
10279 esac
10280
10281
10282 case $lib in
4a9bb2aa 10283 mpc | mpfr | gmp | isl)
29a63921
AO
10284 # If we're processing --with-$lib, --with-$lib-include or
10285 # --with-$lib-lib, for one of the libs above, and target is
10286 # different from host, don't pass the current argument to any
10287 # target library's configure.
10288 if test x$is_cross_compiler = xyes; then
10289 skip_targ=yes
10290 fi
10291 ;;
db50aea6
AA
10292 libintl | libiconv)
10293 # We don't want libintl (and co.) in anything but the host arguments.
10294 skip_targ=yes
10295 skip_barg=yes
10296 ;;
29a63921
AO
10297 esac
10298 ;;
10299 esac
10300
1c710c3c 10301 case "$ac_arg" in
f1a036e4
NC
10302 --cache-file=/dev/null | \
10303 -cache-file=/dev/null )
10304 # Handled here to avoid the test to skip args below.
db50aea6
AA
10305 hbaseargs="$hbaseargs '$ac_arg'"
10306 bbaseargs="$bbaseargs '$ac_arg'"
29a63921 10307 tbaseargs="$tbaseargs '$ac_arg'"
f1a036e4
NC
10308 # Assert: $separate_arg should always be no.
10309 keep_next=$separate_arg
10310 ;;
1c710c3c
DJ
10311 --no*)
10312 continue
10313 ;;
10314 --c* | \
10315 --sr* | \
10316 --ho* | \
10317 --bu* | \
10318 --t* | \
10319 --program-* | \
10320 -cache_file* | \
10321 -srcdir* | \
10322 -host* | \
10323 -build* | \
10324 -target* | \
10325 -program-prefix* | \
10326 -program-suffix* | \
10327 -program-transform-name* )
10328 skip_next=$separate_arg
10329 continue
10330 ;;
10331 -*)
10332 # An option. Add it.
10333 case $ac_arg in
10334 *\'*)
10335 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
10336 esac
db50aea6
AA
10337 hbaseargs="$hbaseargs '$ac_arg'"
10338 if test X"$skip_barg" = Xno; then
10339 bbaseargs="$bbaseargs '$ac_arg'"
10340 fi
29a63921
AO
10341 if test X"$skip_targ" = Xno; then
10342 tbaseargs="$tbaseargs '$ac_arg'"
10343 fi
1c710c3c
DJ
10344 keep_next=$separate_arg
10345 ;;
10346 *)
10347 # Either a variable assignment, or a nonopt (triplet). Don't
10348 # pass it down; let the Makefile handle this.
10349 continue
10350 ;;
10351 esac
10352done
10353# Remove the initial space we just introduced and, as these will be
10354# expanded by make, quote '$'.
db50aea6
AA
10355hbaseargs=`echo "x$hbaseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
10356bbaseargs=`echo "x$bbaseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
671aa708 10357
43bb47c2
DJ
10358# Add in --program-transform-name, after --program-prefix and
10359# --program-suffix have been applied to it. Autoconf has already
10360# doubled dollar signs and backslashes in program_transform_name; we want
10361# the backslashes un-doubled, and then the entire thing wrapped in single
1c710c3c 10362# quotes, because this will be expanded first by make and then by the shell.
43bb47c2
DJ
10363# Also, because we want to override the logic in subdir configure scripts to
10364# choose program_transform_name, replace any s,x,x, with s,y,y,.
10365sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
10366${program_transform_name}
10367EOF_SED
10368gcc_transform_name=`cat conftestsed.out`
10369rm -f conftestsed.out
db50aea6
AA
10370hbaseargs="$hbaseargs --program-transform-name='${gcc_transform_name}'"
10371bbaseargs="$bbaseargs --program-transform-name='${gcc_transform_name}'"
29a63921 10372tbaseargs="$tbaseargs --program-transform-name='${gcc_transform_name}'"
d9acb717 10373if test "$silent" = yes; then
db50aea6
AA
10374 bbaseargs="$bbaseargs --silent"
10375 hbaseargs="$hbaseargs --silent"
29a63921 10376 tbaseargs="$tbaseargs --silent"
d9acb717 10377fi
a49d42e8 10378
db50aea6
AA
10379bbaseargs="$bbaseargs --disable-option-checking"
10380hbaseargs="$hbaseargs --disable-option-checking"
29a63921 10381tbaseargs="$tbaseargs --disable-option-checking"
43bb47c2 10382
a49d42e8
LM
10383if test "$enable_year2038" = no; then
10384 baseargs="$baseargs --disable-year2038"
10385 tbaseargs="$tbaseargs --disable-year2038"
10386fi
10387
ffedf511
RW
10388# Record and document user additions to sub configure arguments.
10389
10390
10391
10392
671aa708
NN
10393# For the build-side libraries, we just need to pretend we're native,
10394# and not use the same cache file. Multilibs are neither needed nor
3d96b0d0
HPN
10395# desired. We can't even use the same cache file for all build-side
10396# libraries, as they're compiled differently; some with C, some with
10397# C++ or with different feature-enabling options.
db50aea6 10398build_configargs="$build_configargs --cache-file=./config.cache ${bbaseargs}"
671aa708
NN
10399
10400# For host modules, accept cache file option, or specification as blank.
10401case "${cache_file}" in
10402"") # empty
10403 cache_file_option="" ;;
10404/* | [A-Za-z]:[\\/]* ) # absolute path
10405 cache_file_option="--cache-file=${cache_file}" ;;
10406*) # relative path
10407 cache_file_option="--cache-file=../${cache_file}" ;;
10408esac
10409
09438bde
NN
10410# Host dirs don't like to share a cache file either, horribly enough.
10411# This seems to be due to autoconf 2.5x stupidity.
db50aea6 10412host_configargs="$host_configargs --cache-file=./config.cache ${extra_host_args} ${hbaseargs}"
671aa708 10413
29a63921 10414target_configargs="$target_configargs ${tbaseargs}"
671aa708
NN
10415
10416# Passing a --with-cross-host argument lets the target libraries know
10417# whether they are being built with a cross-compiler or being built
10418# native. However, it would be better to use other mechanisms to make the
10419# sorts of decisions they want to make on this basis. Please consider
10420# this option to be deprecated. FIXME.
10421if test x${is_cross_compiler} = xyes ; then
1c710c3c 10422 target_configargs="--with-cross-host=${host_noncanonical} ${target_configargs}"
671aa708
NN
10423fi
10424
79e0604d
FXC
10425# Special user-friendly check for native x86_64-linux build, if
10426# multilib is not explicitly enabled.
10427case "$target:$have_compiler:$host:$target:$enable_multilib" in
10428 x86_64-*linux*:yes:$build:$build:)
e640447c 10429 # Make sure we have a development environment that handles 32-bit
79e0604d
FXC
10430 dev64=no
10431 echo "int main () { return 0; }" > conftest.c
10432 ${CC} -m32 -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
10433 if test $? = 0 ; then
10434 if test -s conftest || test -s conftest.exe ; then
10435 dev64=yes
10436 fi
10437 fi
10438 rm -f conftest*
10439 if test x${dev64} != xyes ; then
22e05272 10440 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
10441 fi
10442 ;;
10443esac
10444
dc683a3f
RW
10445# Default to --enable-multilib.
10446if test x${enable_multilib} = x ; then
671aa708 10447 target_configargs="--enable-multilib ${target_configargs}"
dc683a3f 10448fi
671aa708
NN
10449
10450# Pass --with-newlib if appropriate. Note that target_configdirs has
10451# changed from the earlier setting of with_newlib.
10452if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
10453 target_configargs="--with-newlib ${target_configargs}"
10454fi
10455
6b9eb62c
NN
10456# Different target subdirs use different values of certain variables
10457# (notably CXX). Worse, multilibs use *lots* of different values.
10458# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
10459# it doesn't automatically accept command-line overrides of them.
10460# This means it's not safe for target subdirs to share a cache file,
10461# which is disgusting, but there you have it. Hopefully this can be
10462# fixed in future. It's still worthwhile to use a cache file for each
10463# directory. I think.
10464
bebcd931
MS
10465# Pass the appropriate --build, --host, --target and --cache-file arguments.
10466# We need to pass --target, as newer autoconf's requires consistency
10467# for target_alias and gcc doesn't manage it consistently.
e69bf64b 10468target_configargs="--cache-file=./config.cache ${target_configargs}"
671aa708 10469
671aa708
NN
10470FLAGS_FOR_TARGET=
10471case " $target_configdirs " in
10472 *" newlib "*)
10473 case " $target_configargs " in
10474 *" --with-newlib "*)
10475 case "$target" in
5d571eaa 10476 *-cygwin*)
443e6238 10477 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -isystem $$s/winsup/cygwin/include'
5d571eaa 10478 ;;
671aa708
NN
10479 esac
10480
10481 # If we're not building GCC, don't discard standard headers.
10482 if test -d ${srcdir}/gcc; then
10483 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
10484
10485 if test "${build}" != "${host}"; then
10486 # On Canadian crosses, CC_FOR_TARGET will have already been set
10487 # by `configure', so we won't have an opportunity to add -Bgcc/
10488 # to it. This is right: we don't want to search that directory
10489 # for binaries, but we want the header files in there, so add
10490 # them explicitly.
0463992b 10491 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include -isystem $$r/$(HOST_SUBDIR)/gcc/include-fixed'
671aa708
NN
10492
10493 # Someone might think of using the pre-installed headers on
10494 # Canadian crosses, in case the installed compiler is not fully
10495 # compatible with the compiler being built. In this case, it
10496 # would be better to flag an error than risking having
10497 # incompatible object files being constructed. We can't
10498 # guarantee that an error will be flagged, but let's hope the
10499 # compiler will do it, when presented with incompatible header
10500 # files.
10501 fi
10502 fi
10503
10504 case "${target}-${is_cross_compiler}" in
f2a0e225 10505 i[3456789]86-*-linux*-no)
671aa708
NN
10506 # Here host == target, so we don't need to build gcc,
10507 # so we don't want to discard standard headers.
10508 FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
10509 ;;
10510 *)
10511 # If we're building newlib, use its generic headers last, but search
10512 # for any libc-related directories first (so make it the last -B
10513 # switch).
10514 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
10515
10516 # If we're building libgloss, find the startup file, simulator library
10517 # and linker script.
10518 case " $target_configdirs " in
10519 *" libgloss "*)
10520 # Look for startup file, simulator library and maybe linker script.
10521 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/libgloss/'"$libgloss_dir"
10522 # Look for libnosys.a in case the target needs it.
10523 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/libnosys'
10524 # Most targets have the linker script in the source directory.
10525 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$s/libgloss/'"$libgloss_dir"
10526 ;;
10527 esac
671aa708
NN
10528 ;;
10529 esac
10530 ;;
10531 esac
10532 ;;
10533esac
5d571eaa 10534
b91f0a41 10535case "$target" in
5d571eaa
OS
10536 x86_64-*mingw* | *-w64-mingw*)
10537 # MinGW-w64 does not use newlib, nor does it use winsup. It may,
10538 # however, use a symlink named 'mingw' in ${prefix} .
10539 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L${prefix}/${target}/lib -L${prefix}/mingw/lib -isystem ${prefix}/${target}/include -isystem ${prefix}/mingw/include'
10540 ;;
10541 *-mingw*)
10542 # MinGW can't be handled as Cygwin above since it does not use newlib.
10543 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'
10544 ;;
b91f0a41 10545esac
671aa708 10546
6691a79e
ME
10547# Allow the user to override the flags for
10548# our build compiler if desired.
f019adc1
MF
10549if test x"${build}" = x"${host}" ; then
10550 CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
84401ce5 10551 CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-${CPPFLAGS}}
f019adc1
MF
10552 CXXFLAGS_FOR_BUILD=${CXXFLAGS_FOR_BUILD-${CXXFLAGS}}
10553 LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-${LDFLAGS}}
10554fi
6691a79e 10555
671aa708
NN
10556# On Canadian crosses, we'll be searching the right directories for
10557# the previously-installed cross compiler, so don't bother to add
10558# flags for directories within the install tree of the compiler
10559# being built; programs in there won't even run.
10560if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
10561 # Search for pre-installed headers if nothing else fits.
9124bc53 10562 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
10563fi
10564
10565if test "x${use_gnu_ld}" = x &&
10566 echo " ${configdirs} " | grep " ld " > /dev/null ; then
10567 # Arrange for us to find uninstalled linker scripts.
215c351a 10568 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
671aa708
NN
10569fi
10570
e88a2c09
DD
10571# Search for other target-specific linker scripts and such.
10572case "${target}" in
3e19841a
PB
10573 mep*)
10574 FLAGS_FOR_TARGET="$FLAGS_FOR_TARGET -mlibrary"
10575 ;;
9b8ffbb8
OH
10576 # The VxWorks support for shared libraries is getting in
10577 # incrementally. Make sure it doesn't get activated implicitly:
10578 *vxworks*)
10579 if test "${enable_shared-unset}" = unset ; then
10580 enable_shared=no
10581 # So the build of libraries knows ...
10582 target_configargs="${target_configargs} --disable-shared"
10583 # So gcc knows ...
10584 host_configargs="${host_configargs} --disable-shared"
10585 fi
10586 ;;
e88a2c09
DD
10587esac
10588
671aa708 10589# Makefile fragments.
7b61653a
PE
10590for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
10591do
10592 eval fragval=\$$frag
10593 if test $fragval != /dev/null; then
10594 eval $frag=${srcdir}/$fragval
10595 fi
10596done
671aa708
NN
10597
10598
10599
10600
10601
10602# Miscellanea: directories, flags, etc.
10603
10604
10605
10606
10607
10608
10609
d89f0ad6 10610
23f6b2f9 10611# Build module lists & subconfigure args.
671aa708
NN
10612
10613
10614
2abefe3d
PB
10615# Host module lists & subconfigure args.
10616
10617
10618
aae29963 10619
2abefe3d
PB
10620# Target module lists & subconfigure args.
10621
10622
10623
10624# Build tools.
10625
10626
10627
0999159b
PB
10628
10629
10630
10631
10632
10633
10634
10635
10636
10637
10638
10639
10640
b4c522fa 10641
3b5e8ee4 10642
a1d2b162
IS
10643
10644
2abefe3d
PB
10645# Generate default definitions for YACC, M4, LEX and other programs that run
10646# on the build machine. These are used if the Makefile can't locate these
10647# programs in objdir.
10648MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
10649
10650for ac_prog in 'bison -y' byacc yacc
10651do
1c710c3c 10652 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10653set dummy $ac_prog; ac_word=$2
5213506e
RW
10654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10655$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10656if ${ac_cv_prog_YACC+:} false; then :
5213506e 10657 $as_echo_n "(cached) " >&6
2abefe3d
PB
10658else
10659 if test -n "$YACC"; then
10660 ac_cv_prog_YACC="$YACC" # Let the user override the test.
10661else
1c710c3c
DJ
10662as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10663for as_dir in $PATH
10664do
10665 IFS=$as_save_IFS
10666 test -z "$as_dir" && as_dir=.
5213506e 10667 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10668 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10669 ac_cv_prog_YACC="$ac_prog"
5213506e 10670 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10671 break 2
10672 fi
10673done
5213506e
RW
10674 done
10675IFS=$as_save_IFS
1c710c3c 10676
2abefe3d
PB
10677fi
10678fi
1c710c3c 10679YACC=$ac_cv_prog_YACC
2abefe3d 10680if test -n "$YACC"; then
5213506e
RW
10681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
10682$as_echo "$YACC" >&6; }
2abefe3d 10683else
5213506e
RW
10684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10685$as_echo "no" >&6; }
2abefe3d
PB
10686fi
10687
5213506e 10688
1c710c3c 10689 test -n "$YACC" && break
2abefe3d
PB
10690done
10691test -n "$YACC" || YACC="$MISSING bison -y"
10692
10693case " $build_configdirs " in
10694 *" bison "*) YACC='$$r/$(BUILD_SUBDIR)/bison/tests/bison -y' ;;
2abefe3d
PB
10695esac
10696
10697for ac_prog in bison
10698do
1c710c3c 10699 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10700set dummy $ac_prog; ac_word=$2
5213506e
RW
10701{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10702$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10703if ${ac_cv_prog_BISON+:} false; then :
5213506e 10704 $as_echo_n "(cached) " >&6
2abefe3d
PB
10705else
10706 if test -n "$BISON"; then
10707 ac_cv_prog_BISON="$BISON" # Let the user override the test.
10708else
1c710c3c
DJ
10709as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10710for as_dir in $PATH
10711do
10712 IFS=$as_save_IFS
10713 test -z "$as_dir" && as_dir=.
5213506e 10714 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10715 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10716 ac_cv_prog_BISON="$ac_prog"
5213506e 10717 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10718 break 2
10719 fi
10720done
5213506e
RW
10721 done
10722IFS=$as_save_IFS
1c710c3c 10723
2abefe3d
PB
10724fi
10725fi
1c710c3c 10726BISON=$ac_cv_prog_BISON
2abefe3d 10727if test -n "$BISON"; then
5213506e
RW
10728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
10729$as_echo "$BISON" >&6; }
2abefe3d 10730else
5213506e
RW
10731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10732$as_echo "no" >&6; }
2abefe3d
PB
10733fi
10734
5213506e 10735
1c710c3c 10736 test -n "$BISON" && break
2abefe3d
PB
10737done
10738test -n "$BISON" || BISON="$MISSING bison"
10739
10740case " $build_configdirs " in
10741 *" bison "*) BISON='$$r/$(BUILD_SUBDIR)/bison/tests/bison' ;;
10742esac
10743
10744for ac_prog in gm4 gnum4 m4
10745do
1c710c3c 10746 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10747set dummy $ac_prog; ac_word=$2
5213506e
RW
10748{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10749$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10750if ${ac_cv_prog_M4+:} false; then :
5213506e 10751 $as_echo_n "(cached) " >&6
2abefe3d
PB
10752else
10753 if test -n "$M4"; then
10754 ac_cv_prog_M4="$M4" # Let the user override the test.
10755else
1c710c3c
DJ
10756as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10757for as_dir in $PATH
10758do
10759 IFS=$as_save_IFS
10760 test -z "$as_dir" && as_dir=.
5213506e 10761 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10762 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10763 ac_cv_prog_M4="$ac_prog"
5213506e 10764 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10765 break 2
10766 fi
10767done
5213506e
RW
10768 done
10769IFS=$as_save_IFS
1c710c3c 10770
2abefe3d
PB
10771fi
10772fi
1c710c3c 10773M4=$ac_cv_prog_M4
2abefe3d 10774if test -n "$M4"; then
5213506e
RW
10775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M4" >&5
10776$as_echo "$M4" >&6; }
2abefe3d 10777else
5213506e
RW
10778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10779$as_echo "no" >&6; }
2abefe3d
PB
10780fi
10781
5213506e 10782
1c710c3c 10783 test -n "$M4" && break
2abefe3d
PB
10784done
10785test -n "$M4" || M4="$MISSING m4"
10786
10787case " $build_configdirs " in
10788 *" m4 "*) M4='$$r/$(BUILD_SUBDIR)/m4/m4' ;;
10789esac
10790
10791for ac_prog in flex lex
10792do
1c710c3c 10793 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10794set dummy $ac_prog; ac_word=$2
5213506e
RW
10795{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10796$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10797if ${ac_cv_prog_LEX+:} false; then :
5213506e 10798 $as_echo_n "(cached) " >&6
2abefe3d
PB
10799else
10800 if test -n "$LEX"; then
10801 ac_cv_prog_LEX="$LEX" # Let the user override the test.
10802else
1c710c3c
DJ
10803as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10804for as_dir in $PATH
10805do
10806 IFS=$as_save_IFS
10807 test -z "$as_dir" && as_dir=.
5213506e 10808 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10809 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10810 ac_cv_prog_LEX="$ac_prog"
5213506e 10811 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10812 break 2
10813 fi
10814done
5213506e
RW
10815 done
10816IFS=$as_save_IFS
1c710c3c 10817
2abefe3d
PB
10818fi
10819fi
1c710c3c 10820LEX=$ac_cv_prog_LEX
2abefe3d 10821if test -n "$LEX"; then
5213506e
RW
10822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
10823$as_echo "$LEX" >&6; }
2abefe3d 10824else
5213506e
RW
10825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10826$as_echo "no" >&6; }
2abefe3d
PB
10827fi
10828
5213506e 10829
1c710c3c 10830 test -n "$LEX" && break
2abefe3d
PB
10831done
10832test -n "$LEX" || LEX="$MISSING flex"
10833
10834case " $build_configdirs " in
10835 *" flex "*) LEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
10836 *" lex "*) LEX='$$r/$(BUILD_SUBDIR)/lex/lex' ;;
10837esac
10838
10839for ac_prog in flex
10840do
1c710c3c 10841 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10842set dummy $ac_prog; ac_word=$2
5213506e
RW
10843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10844$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10845if ${ac_cv_prog_FLEX+:} false; then :
5213506e 10846 $as_echo_n "(cached) " >&6
2abefe3d
PB
10847else
10848 if test -n "$FLEX"; then
10849 ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
10850else
1c710c3c
DJ
10851as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10852for as_dir in $PATH
10853do
10854 IFS=$as_save_IFS
10855 test -z "$as_dir" && as_dir=.
5213506e 10856 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10857 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10858 ac_cv_prog_FLEX="$ac_prog"
5213506e 10859 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10860 break 2
10861 fi
10862done
5213506e
RW
10863 done
10864IFS=$as_save_IFS
1c710c3c 10865
2abefe3d
PB
10866fi
10867fi
1c710c3c 10868FLEX=$ac_cv_prog_FLEX
2abefe3d 10869if test -n "$FLEX"; then
5213506e
RW
10870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLEX" >&5
10871$as_echo "$FLEX" >&6; }
2abefe3d 10872else
5213506e
RW
10873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10874$as_echo "no" >&6; }
2abefe3d
PB
10875fi
10876
5213506e 10877
1c710c3c 10878 test -n "$FLEX" && break
2abefe3d
PB
10879done
10880test -n "$FLEX" || FLEX="$MISSING flex"
10881
10882case " $build_configdirs " in
10883 *" flex "*) FLEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
10884esac
10885
10886for ac_prog in makeinfo
10887do
1c710c3c 10888 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10889set dummy $ac_prog; ac_word=$2
5213506e
RW
10890{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10891$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10892if ${ac_cv_prog_MAKEINFO+:} false; then :
5213506e 10893 $as_echo_n "(cached) " >&6
2abefe3d
PB
10894else
10895 if test -n "$MAKEINFO"; then
10896 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
10897else
1c710c3c
DJ
10898as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10899for as_dir in $PATH
10900do
10901 IFS=$as_save_IFS
10902 test -z "$as_dir" && as_dir=.
5213506e 10903 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10904 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10905 ac_cv_prog_MAKEINFO="$ac_prog"
5213506e 10906 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10907 break 2
10908 fi
10909done
5213506e
RW
10910 done
10911IFS=$as_save_IFS
1c710c3c 10912
2abefe3d
PB
10913fi
10914fi
1c710c3c 10915MAKEINFO=$ac_cv_prog_MAKEINFO
2abefe3d 10916if test -n "$MAKEINFO"; then
5213506e
RW
10917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
10918$as_echo "$MAKEINFO" >&6; }
2abefe3d 10919else
5213506e
RW
10920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10921$as_echo "no" >&6; }
2abefe3d
PB
10922fi
10923
5213506e 10924
1c710c3c 10925 test -n "$MAKEINFO" && break
2abefe3d
PB
10926done
10927test -n "$MAKEINFO" || MAKEINFO="$MISSING makeinfo"
10928
10929case " $build_configdirs " in
10930 *" texinfo "*) MAKEINFO='$$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo' ;;
10931 *)
10932
d18ff35a 10933 # For an installed makeinfo, we require it to be from texinfo 4.7 or
2abefe3d
PB
10934 # higher, else we use the "missing" dummy.
10935 if ${MAKEINFO} --version \
d18ff35a 10936 | egrep 'texinfo[^0-9]*(4\.([7-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
2abefe3d
PB
10937 :
10938 else
10939 MAKEINFO="$MISSING makeinfo"
10940 fi
10941 ;;
10942
10943esac
671aa708 10944
2abefe3d 10945# FIXME: expect and dejagnu may become build tools?
671aa708 10946
2abefe3d
PB
10947for ac_prog in expect
10948do
1c710c3c 10949 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10950set dummy $ac_prog; ac_word=$2
5213506e
RW
10951{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10952$as_echo_n "checking for $ac_word... " >&6; }
22e05272 10953if ${ac_cv_prog_EXPECT+:} false; then :
5213506e 10954 $as_echo_n "(cached) " >&6
2abefe3d
PB
10955else
10956 if test -n "$EXPECT"; then
10957 ac_cv_prog_EXPECT="$EXPECT" # Let the user override the test.
10958else
1c710c3c
DJ
10959as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10960for as_dir in $PATH
10961do
10962 IFS=$as_save_IFS
10963 test -z "$as_dir" && as_dir=.
5213506e 10964 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 10965 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 10966 ac_cv_prog_EXPECT="$ac_prog"
5213506e 10967 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
10968 break 2
10969 fi
10970done
5213506e
RW
10971 done
10972IFS=$as_save_IFS
1c710c3c 10973
2abefe3d
PB
10974fi
10975fi
1c710c3c 10976EXPECT=$ac_cv_prog_EXPECT
2abefe3d 10977if test -n "$EXPECT"; then
5213506e
RW
10978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPECT" >&5
10979$as_echo "$EXPECT" >&6; }
2abefe3d 10980else
5213506e
RW
10981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10982$as_echo "no" >&6; }
2abefe3d 10983fi
671aa708 10984
5213506e 10985
1c710c3c 10986 test -n "$EXPECT" && break
2abefe3d
PB
10987done
10988test -n "$EXPECT" || EXPECT="expect"
671aa708 10989
2abefe3d
PB
10990case " $configdirs " in
10991 *" expect "*)
10992 test $host = $build && EXPECT='$$r/$(HOST_SUBDIR)/expect/expect'
10993 ;;
10994esac
671aa708 10995
2abefe3d
PB
10996for ac_prog in runtest
10997do
1c710c3c 10998 # Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 10999set dummy $ac_prog; ac_word=$2
5213506e
RW
11000{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11001$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11002if ${ac_cv_prog_RUNTEST+:} false; then :
5213506e 11003 $as_echo_n "(cached) " >&6
2abefe3d
PB
11004else
11005 if test -n "$RUNTEST"; then
11006 ac_cv_prog_RUNTEST="$RUNTEST" # Let the user override the test.
fb0103e5 11007else
1c710c3c
DJ
11008as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11009for as_dir in $PATH
11010do
11011 IFS=$as_save_IFS
11012 test -z "$as_dir" && as_dir=.
5213506e 11013 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11014 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11015 ac_cv_prog_RUNTEST="$ac_prog"
5213506e 11016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11017 break 2
11018 fi
11019done
5213506e
RW
11020 done
11021IFS=$as_save_IFS
1c710c3c 11022
2abefe3d
PB
11023fi
11024fi
1c710c3c 11025RUNTEST=$ac_cv_prog_RUNTEST
2abefe3d 11026if test -n "$RUNTEST"; then
5213506e
RW
11027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUNTEST" >&5
11028$as_echo "$RUNTEST" >&6; }
2abefe3d 11029else
5213506e
RW
11030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11031$as_echo "no" >&6; }
2abefe3d 11032fi
671aa708 11033
5213506e 11034
1c710c3c 11035 test -n "$RUNTEST" && break
2abefe3d
PB
11036done
11037test -n "$RUNTEST" || RUNTEST="runtest"
671aa708 11038
2abefe3d
PB
11039case " $configdirs " in
11040 *" dejagnu "*)
c394e891 11041 test $host = $build && RUNTEST='$$s/$(HOST_SUBDIR)/dejagnu/runtest'
2abefe3d
PB
11042 ;;
11043esac
671aa708 11044
4e3dcf20 11045
671aa708 11046# Host tools.
ca9f4b81
AO
11047ncn_tool_prefix=
11048test -n "$host_alias" && ncn_tool_prefix=$host_alias-
11049ncn_target_tool_prefix=
11050test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
11051
278a7a38
AO
11052
11053
11054if test -n "$AR"; then
11055 ac_cv_prog_AR=$AR
11056elif test -n "$ac_cv_prog_AR"; then
11057 AR=$ac_cv_prog_AR
11058fi
11059
11060if test -n "$ac_cv_prog_AR"; then
11061 for ncn_progname in ar; do
11062 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11063set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11064{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11065$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11066if ${ac_cv_prog_AR+:} false; then :
5213506e 11067 $as_echo_n "(cached) " >&6
278a7a38
AO
11068else
11069 if test -n "$AR"; then
11070 ac_cv_prog_AR="$AR" # Let the user override the test.
11071else
11072as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11073for as_dir in $PATH
11074do
11075 IFS=$as_save_IFS
11076 test -z "$as_dir" && as_dir=.
5213506e 11077 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11079 ac_cv_prog_AR="${ncn_progname}"
5213506e 11080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11081 break 2
11082 fi
11083done
5213506e
RW
11084 done
11085IFS=$as_save_IFS
278a7a38
AO
11086
11087fi
11088fi
11089AR=$ac_cv_prog_AR
11090if test -n "$AR"; then
5213506e
RW
11091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
11092$as_echo "$AR" >&6; }
278a7a38 11093else
5213506e
RW
11094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11095$as_echo "no" >&6; }
278a7a38
AO
11096fi
11097
5213506e 11098
278a7a38
AO
11099 done
11100fi
11101
11102for ncn_progname in ar; do
2693c0b0
PB
11103 if test -n "$ncn_tool_prefix"; then
11104 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11105set dummy ${ncn_tool_prefix}${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_AR+:} false; then :
5213506e 11109 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11110else
11111 if test -n "$AR"; then
11112 ac_cv_prog_AR="$AR" # Let the user override the test.
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_AR="${ncn_tool_prefix}${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 11131AR=$ac_cv_prog_AR
ca9f4b81 11132if test -n "$AR"; then
5213506e
RW
11133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
11134$as_echo "$AR" >&6; }
ca9f4b81 11135else
5213506e
RW
11136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11137$as_echo "no" >&6; }
ca9f4b81
AO
11138fi
11139
5213506e 11140
2693c0b0
PB
11141 fi
11142 if test -z "$ac_cv_prog_AR" && test $build = $host ; then
11143 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11144set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11145{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11146$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11147if ${ac_cv_prog_AR+:} false; then :
5213506e 11148 $as_echo_n "(cached) " >&6
ca9f4b81 11149else
2693c0b0 11150 if test -n "$AR"; then
af71363e
AS
11151 ac_cv_prog_AR="$AR" # Let the user override the test.
11152else
1c710c3c
DJ
11153as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11154for as_dir in $PATH
11155do
11156 IFS=$as_save_IFS
11157 test -z "$as_dir" && as_dir=.
5213506e 11158 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11159 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11160 ac_cv_prog_AR="${ncn_progname}"
5213506e 11161 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11162 break 2
11163 fi
11164done
5213506e
RW
11165 done
11166IFS=$as_save_IFS
1c710c3c 11167
ca9f4b81
AO
11168fi
11169fi
1c710c3c 11170AR=$ac_cv_prog_AR
2693c0b0 11171if test -n "$AR"; then
5213506e
RW
11172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
11173$as_echo "$AR" >&6; }
ca9f4b81 11174else
5213506e
RW
11175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11176$as_echo "no" >&6; }
ca9f4b81 11177fi
1c710c3c 11178
5213506e 11179
2693c0b0
PB
11180 fi
11181 test -n "$ac_cv_prog_AR" && break
11182done
11183
11184if test -z "$ac_cv_prog_AR" ; then
11185 set dummy ar
11186 if test $build = $host ; then
11187 AR="$2"
ca9f4b81 11188 else
2693c0b0 11189 AR="${ncn_tool_prefix}$2"
ca9f4b81 11190 fi
ca9f4b81
AO
11191fi
11192
278a7a38
AO
11193
11194
11195if test -n "$AS"; then
11196 ac_cv_prog_AS=$AS
11197elif test -n "$ac_cv_prog_AS"; then
11198 AS=$ac_cv_prog_AS
11199fi
11200
11201if test -n "$ac_cv_prog_AS"; then
11202 for ncn_progname in as; do
11203 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11204set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11205{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11206$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11207if ${ac_cv_prog_AS+:} false; then :
5213506e 11208 $as_echo_n "(cached) " >&6
278a7a38
AO
11209else
11210 if test -n "$AS"; then
11211 ac_cv_prog_AS="$AS" # Let the user override the test.
11212else
11213as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11214for as_dir in $PATH
11215do
11216 IFS=$as_save_IFS
11217 test -z "$as_dir" && as_dir=.
5213506e 11218 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11219 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11220 ac_cv_prog_AS="${ncn_progname}"
5213506e 11221 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11222 break 2
11223 fi
11224done
5213506e
RW
11225 done
11226IFS=$as_save_IFS
278a7a38
AO
11227
11228fi
11229fi
11230AS=$ac_cv_prog_AS
11231if test -n "$AS"; then
5213506e
RW
11232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
11233$as_echo "$AS" >&6; }
278a7a38 11234else
5213506e
RW
11235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11236$as_echo "no" >&6; }
278a7a38
AO
11237fi
11238
5213506e 11239
278a7a38
AO
11240 done
11241fi
11242
11243for ncn_progname in as; do
2693c0b0
PB
11244 if test -n "$ncn_tool_prefix"; then
11245 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11246set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11248$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11249if ${ac_cv_prog_AS+:} false; then :
5213506e 11250 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11251else
11252 if test -n "$AS"; then
11253 ac_cv_prog_AS="$AS" # Let the user override the test.
0b0dc272 11254else
1c710c3c
DJ
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=.
5213506e 11260 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11262 ac_cv_prog_AS="${ncn_tool_prefix}${ncn_progname}"
5213506e 11263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11264 break 2
11265 fi
11266done
5213506e
RW
11267 done
11268IFS=$as_save_IFS
1c710c3c 11269
ca9f4b81
AO
11270fi
11271fi
1c710c3c 11272AS=$ac_cv_prog_AS
ca9f4b81 11273if test -n "$AS"; then
5213506e
RW
11274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
11275$as_echo "$AS" >&6; }
ca9f4b81 11276else
5213506e
RW
11277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11278$as_echo "no" >&6; }
ca9f4b81
AO
11279fi
11280
5213506e 11281
2693c0b0
PB
11282 fi
11283 if test -z "$ac_cv_prog_AS" && test $build = $host ; then
11284 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11285set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11286{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11287$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11288if ${ac_cv_prog_AS+:} false; then :
5213506e 11289 $as_echo_n "(cached) " >&6
ca9f4b81 11290else
2693c0b0
PB
11291 if test -n "$AS"; then
11292 ac_cv_prog_AS="$AS" # Let the user override the test.
ca9f4b81 11293else
1c710c3c
DJ
11294as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11295for as_dir in $PATH
11296do
11297 IFS=$as_save_IFS
11298 test -z "$as_dir" && as_dir=.
5213506e 11299 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11300 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11301 ac_cv_prog_AS="${ncn_progname}"
5213506e 11302 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11303 break 2
11304 fi
11305done
5213506e
RW
11306 done
11307IFS=$as_save_IFS
1c710c3c 11308
ca9f4b81
AO
11309fi
11310fi
1c710c3c 11311AS=$ac_cv_prog_AS
2693c0b0 11312if test -n "$AS"; then
5213506e
RW
11313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
11314$as_echo "$AS" >&6; }
ca9f4b81 11315else
5213506e
RW
11316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11317$as_echo "no" >&6; }
ca9f4b81 11318fi
1c710c3c 11319
5213506e 11320
2693c0b0
PB
11321 fi
11322 test -n "$ac_cv_prog_AS" && break
11323done
11324
11325if test -z "$ac_cv_prog_AS" ; then
11326 set dummy as
11327 if test $build = $host ; then
11328 AS="$2"
ca9f4b81 11329 else
2693c0b0 11330 AS="${ncn_tool_prefix}$2"
ca9f4b81 11331 fi
ca9f4b81
AO
11332fi
11333
278a7a38
AO
11334
11335
11336if test -n "$DLLTOOL"; then
11337 ac_cv_prog_DLLTOOL=$DLLTOOL
11338elif test -n "$ac_cv_prog_DLLTOOL"; then
11339 DLLTOOL=$ac_cv_prog_DLLTOOL
11340fi
11341
11342if test -n "$ac_cv_prog_DLLTOOL"; then
11343 for ncn_progname in dlltool; do
11344 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11345set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11346{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11347$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11348if ${ac_cv_prog_DLLTOOL+:} false; then :
5213506e 11349 $as_echo_n "(cached) " >&6
278a7a38
AO
11350else
11351 if test -n "$DLLTOOL"; then
11352 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
11353else
11354as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11355for as_dir in $PATH
11356do
11357 IFS=$as_save_IFS
11358 test -z "$as_dir" && as_dir=.
5213506e 11359 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11360 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11361 ac_cv_prog_DLLTOOL="${ncn_progname}"
5213506e 11362 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11363 break 2
11364 fi
11365done
5213506e
RW
11366 done
11367IFS=$as_save_IFS
278a7a38
AO
11368
11369fi
11370fi
11371DLLTOOL=$ac_cv_prog_DLLTOOL
11372if test -n "$DLLTOOL"; then
5213506e
RW
11373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11374$as_echo "$DLLTOOL" >&6; }
278a7a38 11375else
5213506e
RW
11376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11377$as_echo "no" >&6; }
278a7a38
AO
11378fi
11379
5213506e 11380
278a7a38
AO
11381 done
11382fi
11383
11384for ncn_progname in dlltool; do
2693c0b0
PB
11385 if test -n "$ncn_tool_prefix"; then
11386 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11387set dummy ${ncn_tool_prefix}${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_DLLTOOL+:} false; then :
5213506e 11391 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11392else
11393 if test -n "$DLLTOOL"; then
11394 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
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_DLLTOOL="${ncn_tool_prefix}${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 11413DLLTOOL=$ac_cv_prog_DLLTOOL
ca9f4b81 11414if test -n "$DLLTOOL"; then
5213506e
RW
11415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11416$as_echo "$DLLTOOL" >&6; }
ca9f4b81 11417else
5213506e
RW
11418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11419$as_echo "no" >&6; }
ca9f4b81
AO
11420fi
11421
5213506e 11422
2693c0b0
PB
11423 fi
11424 if test -z "$ac_cv_prog_DLLTOOL" && test $build = $host ; then
11425 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11426set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11428$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11429if ${ac_cv_prog_DLLTOOL+:} false; then :
5213506e 11430 $as_echo_n "(cached) " >&6
ca9f4b81 11431else
2693c0b0
PB
11432 if test -n "$DLLTOOL"; then
11433 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
ca9f4b81 11434else
1c710c3c
DJ
11435as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11436for as_dir in $PATH
11437do
11438 IFS=$as_save_IFS
11439 test -z "$as_dir" && as_dir=.
5213506e 11440 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11441 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11442 ac_cv_prog_DLLTOOL="${ncn_progname}"
5213506e 11443 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11444 break 2
11445 fi
11446done
5213506e
RW
11447 done
11448IFS=$as_save_IFS
1c710c3c 11449
ca9f4b81
AO
11450fi
11451fi
1c710c3c 11452DLLTOOL=$ac_cv_prog_DLLTOOL
2693c0b0 11453if test -n "$DLLTOOL"; then
5213506e
RW
11454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
11455$as_echo "$DLLTOOL" >&6; }
ca9f4b81 11456else
5213506e
RW
11457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11458$as_echo "no" >&6; }
ca9f4b81 11459fi
1c710c3c 11460
5213506e 11461
2693c0b0
PB
11462 fi
11463 test -n "$ac_cv_prog_DLLTOOL" && break
11464done
11465
11466if test -z "$ac_cv_prog_DLLTOOL" ; then
11467 set dummy dlltool
11468 if test $build = $host ; then
11469 DLLTOOL="$2"
ca9f4b81 11470 else
2693c0b0 11471 DLLTOOL="${ncn_tool_prefix}$2"
ca9f4b81 11472 fi
ca9f4b81
AO
11473fi
11474
278a7a38
AO
11475
11476
3b5e8ee4
IS
11477if test -n "$DSYMUTIL"; then
11478 ac_cv_prog_DSYMUTIL=$DSYMUTIL
11479elif test -n "$ac_cv_prog_DSYMUTIL"; then
11480 DSYMUTIL=$ac_cv_prog_DSYMUTIL
11481fi
11482
11483if test -n "$ac_cv_prog_DSYMUTIL"; then
11484 for ncn_progname in dsymutil; do
11485 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11486set dummy ${ncn_progname}; ac_word=$2
11487{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11488$as_echo_n "checking for $ac_word... " >&6; }
11489if ${ac_cv_prog_DSYMUTIL+:} false; then :
11490 $as_echo_n "(cached) " >&6
11491else
11492 if test -n "$DSYMUTIL"; then
11493 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
11494else
11495as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11496for as_dir in $PATH
11497do
11498 IFS=$as_save_IFS
11499 test -z "$as_dir" && as_dir=.
11500 for ac_exec_ext in '' $ac_executable_extensions; do
11501 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11502 ac_cv_prog_DSYMUTIL="${ncn_progname}"
11503 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11504 break 2
11505 fi
11506done
11507 done
11508IFS=$as_save_IFS
11509
11510fi
11511fi
11512DSYMUTIL=$ac_cv_prog_DSYMUTIL
11513if test -n "$DSYMUTIL"; then
11514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
11515$as_echo "$DSYMUTIL" >&6; }
11516else
11517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11518$as_echo "no" >&6; }
11519fi
11520
11521
11522 done
11523fi
11524
11525for ncn_progname in dsymutil; do
11526 if test -n "$ncn_tool_prefix"; then
11527 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11528set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
11529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11530$as_echo_n "checking for $ac_word... " >&6; }
11531if ${ac_cv_prog_DSYMUTIL+:} false; then :
11532 $as_echo_n "(cached) " >&6
11533else
11534 if test -n "$DSYMUTIL"; then
11535 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
11536else
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=.
11542 for ac_exec_ext in '' $ac_executable_extensions; do
11543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11544 ac_cv_prog_DSYMUTIL="${ncn_tool_prefix}${ncn_progname}"
11545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11546 break 2
11547 fi
11548done
11549 done
11550IFS=$as_save_IFS
11551
11552fi
11553fi
11554DSYMUTIL=$ac_cv_prog_DSYMUTIL
11555if test -n "$DSYMUTIL"; then
11556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
11557$as_echo "$DSYMUTIL" >&6; }
11558else
11559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11560$as_echo "no" >&6; }
11561fi
11562
11563
11564 fi
11565 if test -z "$ac_cv_prog_DSYMUTIL" && test $build = $host ; then
11566 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11567set dummy ${ncn_progname}; ac_word=$2
11568{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11569$as_echo_n "checking for $ac_word... " >&6; }
11570if ${ac_cv_prog_DSYMUTIL+:} false; then :
11571 $as_echo_n "(cached) " >&6
11572else
11573 if test -n "$DSYMUTIL"; then
11574 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
11575else
11576as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11577for as_dir in $PATH
11578do
11579 IFS=$as_save_IFS
11580 test -z "$as_dir" && as_dir=.
11581 for ac_exec_ext in '' $ac_executable_extensions; do
11582 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11583 ac_cv_prog_DSYMUTIL="${ncn_progname}"
11584 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11585 break 2
11586 fi
11587done
11588 done
11589IFS=$as_save_IFS
11590
11591fi
11592fi
11593DSYMUTIL=$ac_cv_prog_DSYMUTIL
11594if test -n "$DSYMUTIL"; then
11595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
11596$as_echo "$DSYMUTIL" >&6; }
11597else
11598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11599$as_echo "no" >&6; }
11600fi
11601
11602
11603 fi
11604 test -n "$ac_cv_prog_DSYMUTIL" && break
11605done
11606
11607if test -z "$ac_cv_prog_DSYMUTIL" ; then
11608 set dummy dsymutil
11609 if test $build = $host ; then
11610 DSYMUTIL="$2"
11611 else
11612 DSYMUTIL="${ncn_tool_prefix}$2"
11613 fi
11614fi
11615
11616
11617
278a7a38
AO
11618if test -n "$LD"; then
11619 ac_cv_prog_LD=$LD
11620elif test -n "$ac_cv_prog_LD"; then
11621 LD=$ac_cv_prog_LD
11622fi
11623
11624if test -n "$ac_cv_prog_LD"; then
11625 for ncn_progname in ld; do
11626 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11627set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11628{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11629$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11630if ${ac_cv_prog_LD+:} false; then :
5213506e 11631 $as_echo_n "(cached) " >&6
278a7a38
AO
11632else
11633 if test -n "$LD"; then
11634 ac_cv_prog_LD="$LD" # Let the user override the test.
11635else
11636as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11637for as_dir in $PATH
11638do
11639 IFS=$as_save_IFS
11640 test -z "$as_dir" && as_dir=.
5213506e 11641 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11642 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11643 ac_cv_prog_LD="${ncn_progname}"
5213506e 11644 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11645 break 2
11646 fi
11647done
5213506e
RW
11648 done
11649IFS=$as_save_IFS
278a7a38
AO
11650
11651fi
11652fi
11653LD=$ac_cv_prog_LD
11654if test -n "$LD"; then
5213506e
RW
11655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
11656$as_echo "$LD" >&6; }
278a7a38 11657else
5213506e
RW
11658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11659$as_echo "no" >&6; }
278a7a38
AO
11660fi
11661
5213506e 11662
278a7a38
AO
11663 done
11664fi
11665
11666for ncn_progname in ld; do
2693c0b0
PB
11667 if test -n "$ncn_tool_prefix"; then
11668 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11669set dummy ${ncn_tool_prefix}${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_LD+:} false; then :
5213506e 11673 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11674else
11675 if test -n "$LD"; then
11676 ac_cv_prog_LD="$LD" # Let the user override the test.
11677else
1c710c3c
DJ
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
1c710c3c 11685 ac_cv_prog_LD="${ncn_tool_prefix}${ncn_progname}"
5213506e 11686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11687 break 2
11688 fi
11689done
5213506e
RW
11690 done
11691IFS=$as_save_IFS
1c710c3c 11692
ca9f4b81
AO
11693fi
11694fi
1c710c3c 11695LD=$ac_cv_prog_LD
ca9f4b81 11696if test -n "$LD"; then
5213506e
RW
11697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
11698$as_echo "$LD" >&6; }
ca9f4b81 11699else
5213506e
RW
11700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11701$as_echo "no" >&6; }
ca9f4b81
AO
11702fi
11703
5213506e 11704
2693c0b0
PB
11705 fi
11706 if test -z "$ac_cv_prog_LD" && test $build = $host ; then
11707 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11708set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11709{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11710$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11711if ${ac_cv_prog_LD+:} false; then :
5213506e 11712 $as_echo_n "(cached) " >&6
ca9f4b81 11713else
2693c0b0
PB
11714 if test -n "$LD"; then
11715 ac_cv_prog_LD="$LD" # Let the user override the test.
6b65a26d 11716else
1c710c3c
DJ
11717as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11718for as_dir in $PATH
11719do
11720 IFS=$as_save_IFS
11721 test -z "$as_dir" && as_dir=.
5213506e 11722 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11723 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11724 ac_cv_prog_LD="${ncn_progname}"
5213506e 11725 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11726 break 2
11727 fi
11728done
5213506e
RW
11729 done
11730IFS=$as_save_IFS
1c710c3c 11731
ca9f4b81
AO
11732fi
11733fi
1c710c3c 11734LD=$ac_cv_prog_LD
2693c0b0 11735if test -n "$LD"; then
5213506e
RW
11736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
11737$as_echo "$LD" >&6; }
ca9f4b81 11738else
5213506e
RW
11739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11740$as_echo "no" >&6; }
ca9f4b81 11741fi
1c710c3c 11742
5213506e 11743
2693c0b0
PB
11744 fi
11745 test -n "$ac_cv_prog_LD" && break
11746done
11747
11748if test -z "$ac_cv_prog_LD" ; then
11749 set dummy ld
11750 if test $build = $host ; then
11751 LD="$2"
ca9f4b81 11752 else
2693c0b0 11753 LD="${ncn_tool_prefix}$2"
ca9f4b81 11754 fi
ca9f4b81
AO
11755fi
11756
278a7a38
AO
11757
11758
11759if test -n "$LIPO"; then
11760 ac_cv_prog_LIPO=$LIPO
11761elif test -n "$ac_cv_prog_LIPO"; then
11762 LIPO=$ac_cv_prog_LIPO
11763fi
11764
11765if test -n "$ac_cv_prog_LIPO"; then
11766 for ncn_progname in lipo; do
11767 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11768set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11770$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11771if ${ac_cv_prog_LIPO+:} false; then :
5213506e 11772 $as_echo_n "(cached) " >&6
278a7a38
AO
11773else
11774 if test -n "$LIPO"; then
11775 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
11776else
11777as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11778for as_dir in $PATH
11779do
11780 IFS=$as_save_IFS
11781 test -z "$as_dir" && as_dir=.
5213506e 11782 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11783 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11784 ac_cv_prog_LIPO="${ncn_progname}"
5213506e 11785 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
11786 break 2
11787 fi
11788done
5213506e
RW
11789 done
11790IFS=$as_save_IFS
278a7a38
AO
11791
11792fi
11793fi
11794LIPO=$ac_cv_prog_LIPO
11795if test -n "$LIPO"; then
5213506e
RW
11796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
11797$as_echo "$LIPO" >&6; }
278a7a38 11798else
5213506e
RW
11799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11800$as_echo "no" >&6; }
278a7a38
AO
11801fi
11802
5213506e 11803
278a7a38
AO
11804 done
11805fi
11806
11807for ncn_progname in lipo; do
2abefe3d
PB
11808 if test -n "$ncn_tool_prefix"; then
11809 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11810set dummy ${ncn_tool_prefix}${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_LIPO+:} false; then :
5213506e 11814 $as_echo_n "(cached) " >&6
2abefe3d
PB
11815else
11816 if test -n "$LIPO"; then
11817 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
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_LIPO="${ncn_tool_prefix}${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
2abefe3d
PB
11834fi
11835fi
1c710c3c 11836LIPO=$ac_cv_prog_LIPO
2abefe3d 11837if test -n "$LIPO"; then
5213506e
RW
11838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
11839$as_echo "$LIPO" >&6; }
2abefe3d 11840else
5213506e
RW
11841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11842$as_echo "no" >&6; }
2abefe3d
PB
11843fi
11844
5213506e 11845
2abefe3d
PB
11846 fi
11847 if test -z "$ac_cv_prog_LIPO" && test $build = $host ; then
11848 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11849set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11851$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11852if ${ac_cv_prog_LIPO+:} false; then :
5213506e 11853 $as_echo_n "(cached) " >&6
2abefe3d
PB
11854else
11855 if test -n "$LIPO"; then
11856 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
11857else
1c710c3c
DJ
11858as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11859for as_dir in $PATH
11860do
11861 IFS=$as_save_IFS
11862 test -z "$as_dir" && as_dir=.
5213506e 11863 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11864 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 11865 ac_cv_prog_LIPO="${ncn_progname}"
5213506e 11866 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11867 break 2
11868 fi
11869done
5213506e
RW
11870 done
11871IFS=$as_save_IFS
1c710c3c 11872
2abefe3d
PB
11873fi
11874fi
1c710c3c 11875LIPO=$ac_cv_prog_LIPO
2abefe3d 11876if test -n "$LIPO"; then
5213506e
RW
11877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
11878$as_echo "$LIPO" >&6; }
2abefe3d 11879else
5213506e
RW
11880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11881$as_echo "no" >&6; }
2abefe3d 11882fi
1c710c3c 11883
5213506e 11884
2abefe3d
PB
11885 fi
11886 test -n "$ac_cv_prog_LIPO" && break
11887done
11888
11889if test -z "$ac_cv_prog_LIPO" ; then
11890 set dummy lipo
11891 if test $build = $host ; then
11892 LIPO="$2"
11893 else
11894 LIPO="${ncn_tool_prefix}$2"
11895 fi
11896fi
11897
278a7a38
AO
11898
11899
11900if test -n "$NM"; then
11901 ac_cv_prog_NM=$NM
11902elif test -n "$ac_cv_prog_NM"; then
11903 NM=$ac_cv_prog_NM
11904fi
11905
11906if test -n "$ac_cv_prog_NM"; then
11907 for ncn_progname in nm; do
11908 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11909set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11910{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11911$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11912if ${ac_cv_prog_NM+:} false; then :
5213506e 11913 $as_echo_n "(cached) " >&6
ca9f4b81
AO
11914else
11915 if test -n "$NM"; then
11916 ac_cv_prog_NM="$NM" # Let the user override the test.
11917else
1c710c3c
DJ
11918as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11919for as_dir in $PATH
11920do
11921 IFS=$as_save_IFS
11922 test -z "$as_dir" && as_dir=.
5213506e 11923 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11924 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11925 ac_cv_prog_NM="${ncn_progname}"
5213506e 11926 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11927 break 2
11928 fi
11929done
5213506e
RW
11930 done
11931IFS=$as_save_IFS
1c710c3c 11932
ca9f4b81
AO
11933fi
11934fi
1c710c3c 11935NM=$ac_cv_prog_NM
ca9f4b81 11936if test -n "$NM"; then
5213506e
RW
11937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
11938$as_echo "$NM" >&6; }
ca9f4b81 11939else
5213506e
RW
11940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11941$as_echo "no" >&6; }
ca9f4b81
AO
11942fi
11943
5213506e 11944
278a7a38
AO
11945 done
11946fi
11947
11948for ncn_progname in nm; do
11949 if test -n "$ncn_tool_prefix"; then
11950 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
11951set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
11952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11953$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11954if ${ac_cv_prog_NM+:} false; then :
5213506e 11955 $as_echo_n "(cached) " >&6
ca9f4b81 11956else
2693c0b0
PB
11957 if test -n "$NM"; then
11958 ac_cv_prog_NM="$NM" # Let the user override the test.
ca9f4b81 11959else
1c710c3c
DJ
11960as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11961for as_dir in $PATH
11962do
11963 IFS=$as_save_IFS
11964 test -z "$as_dir" && as_dir=.
5213506e 11965 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 11966 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 11967 ac_cv_prog_NM="${ncn_tool_prefix}${ncn_progname}"
5213506e 11968 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
11969 break 2
11970 fi
11971done
5213506e
RW
11972 done
11973IFS=$as_save_IFS
1c710c3c 11974
ca9f4b81
AO
11975fi
11976fi
1c710c3c 11977NM=$ac_cv_prog_NM
2693c0b0 11978if test -n "$NM"; then
5213506e
RW
11979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
11980$as_echo "$NM" >&6; }
ca9f4b81 11981else
5213506e
RW
11982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11983$as_echo "no" >&6; }
ca9f4b81 11984fi
1c710c3c 11985
5213506e 11986
2693c0b0 11987 fi
278a7a38
AO
11988 if test -z "$ac_cv_prog_NM" && test $build = $host ; then
11989 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
11990set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
11991{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11992$as_echo_n "checking for $ac_word... " >&6; }
22e05272 11993if ${ac_cv_prog_NM+:} false; then :
5213506e 11994 $as_echo_n "(cached) " >&6
278a7a38
AO
11995else
11996 if test -n "$NM"; then
11997 ac_cv_prog_NM="$NM" # Let the user override the test.
11998else
11999as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12000for as_dir in $PATH
12001do
12002 IFS=$as_save_IFS
12003 test -z "$as_dir" && as_dir=.
5213506e 12004 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12005 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12006 ac_cv_prog_NM="${ncn_progname}"
5213506e 12007 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12008 break 2
12009 fi
12010done
5213506e
RW
12011 done
12012IFS=$as_save_IFS
278a7a38
AO
12013
12014fi
12015fi
12016NM=$ac_cv_prog_NM
12017if test -n "$NM"; then
5213506e
RW
12018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
12019$as_echo "$NM" >&6; }
278a7a38 12020else
5213506e
RW
12021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12022$as_echo "no" >&6; }
278a7a38
AO
12023fi
12024
5213506e 12025
278a7a38
AO
12026 fi
12027 test -n "$ac_cv_prog_NM" && break
12028done
12029
12030if test -z "$ac_cv_prog_NM" ; then
12031 set dummy nm
12032 if test $build = $host ; then
12033 NM="$2"
12034 else
12035 NM="${ncn_tool_prefix}$2"
12036 fi
12037fi
12038
12039
12040
12041if test -n "$RANLIB"; then
12042 ac_cv_prog_RANLIB=$RANLIB
12043elif test -n "$ac_cv_prog_RANLIB"; then
12044 RANLIB=$ac_cv_prog_RANLIB
12045fi
12046
12047if test -n "$ac_cv_prog_RANLIB"; then
12048 for ncn_progname in ranlib; do
12049 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12050set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12051{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12052$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12053if ${ac_cv_prog_RANLIB+:} false; then :
5213506e 12054 $as_echo_n "(cached) " >&6
278a7a38
AO
12055else
12056 if test -n "$RANLIB"; then
12057 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
12058else
12059as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12060for as_dir in $PATH
12061do
12062 IFS=$as_save_IFS
12063 test -z "$as_dir" && as_dir=.
5213506e 12064 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12065 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12066 ac_cv_prog_RANLIB="${ncn_progname}"
5213506e 12067 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12068 break 2
12069 fi
12070done
5213506e
RW
12071 done
12072IFS=$as_save_IFS
278a7a38
AO
12073
12074fi
12075fi
12076RANLIB=$ac_cv_prog_RANLIB
12077if test -n "$RANLIB"; then
5213506e
RW
12078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
12079$as_echo "$RANLIB" >&6; }
278a7a38 12080else
5213506e
RW
12081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12082$as_echo "no" >&6; }
278a7a38
AO
12083fi
12084
5213506e 12085
278a7a38
AO
12086 done
12087fi
ca9f4b81 12088
278a7a38 12089for ncn_progname in ranlib; do
2693c0b0
PB
12090 if test -n "$ncn_tool_prefix"; then
12091 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12092set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12093{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12094$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12095if ${ac_cv_prog_RANLIB+:} false; then :
5213506e 12096 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12097else
12098 if test -n "$RANLIB"; then
12099 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
12100else
1c710c3c
DJ
12101as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12102for as_dir in $PATH
12103do
12104 IFS=$as_save_IFS
12105 test -z "$as_dir" && as_dir=.
5213506e 12106 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12107 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12108 ac_cv_prog_RANLIB="${ncn_tool_prefix}${ncn_progname}"
5213506e 12109 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12110 break 2
12111 fi
12112done
5213506e
RW
12113 done
12114IFS=$as_save_IFS
1c710c3c 12115
ca9f4b81
AO
12116fi
12117fi
1c710c3c 12118RANLIB=$ac_cv_prog_RANLIB
ca9f4b81 12119if test -n "$RANLIB"; then
5213506e
RW
12120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
12121$as_echo "$RANLIB" >&6; }
ca9f4b81 12122else
5213506e
RW
12123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12124$as_echo "no" >&6; }
ca9f4b81
AO
12125fi
12126
5213506e 12127
2693c0b0
PB
12128 fi
12129 if test -z "$ac_cv_prog_RANLIB" && test $build = $host ; then
12130 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12131set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12132{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12133$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12134if ${ac_cv_prog_RANLIB+:} false; then :
5213506e 12135 $as_echo_n "(cached) " >&6
ca9f4b81 12136else
2693c0b0
PB
12137 if test -n "$RANLIB"; then
12138 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
ca9f4b81 12139else
1c710c3c
DJ
12140as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12141for as_dir in $PATH
12142do
12143 IFS=$as_save_IFS
12144 test -z "$as_dir" && as_dir=.
5213506e 12145 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12146 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12147 ac_cv_prog_RANLIB="${ncn_progname}"
5213506e 12148 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12149 break 2
12150 fi
12151done
5213506e
RW
12152 done
12153IFS=$as_save_IFS
1c710c3c 12154
ca9f4b81
AO
12155fi
12156fi
1c710c3c 12157RANLIB=$ac_cv_prog_RANLIB
2693c0b0 12158if test -n "$RANLIB"; then
5213506e
RW
12159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
12160$as_echo "$RANLIB" >&6; }
ca9f4b81 12161else
5213506e
RW
12162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12163$as_echo "no" >&6; }
ca9f4b81 12164fi
1c710c3c 12165
5213506e 12166
ca9f4b81 12167 fi
2693c0b0
PB
12168 test -n "$ac_cv_prog_RANLIB" && break
12169done
12170
12171if test -z "$ac_cv_prog_RANLIB" ; then
8927b7c0 12172 RANLIB="true"
ca9f4b81
AO
12173fi
12174
278a7a38
AO
12175
12176
12177if test -n "$STRIP"; then
12178 ac_cv_prog_STRIP=$STRIP
12179elif test -n "$ac_cv_prog_STRIP"; then
12180 STRIP=$ac_cv_prog_STRIP
12181fi
12182
12183if test -n "$ac_cv_prog_STRIP"; then
12184 for ncn_progname in strip; do
12185 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12186set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12187{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12188$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12189if ${ac_cv_prog_STRIP+:} false; then :
5213506e 12190 $as_echo_n "(cached) " >&6
278a7a38
AO
12191else
12192 if test -n "$STRIP"; then
12193 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
12194else
12195as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12196for as_dir in $PATH
12197do
12198 IFS=$as_save_IFS
12199 test -z "$as_dir" && as_dir=.
5213506e 12200 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12202 ac_cv_prog_STRIP="${ncn_progname}"
5213506e 12203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12204 break 2
12205 fi
12206done
5213506e
RW
12207 done
12208IFS=$as_save_IFS
278a7a38
AO
12209
12210fi
12211fi
12212STRIP=$ac_cv_prog_STRIP
12213if test -n "$STRIP"; then
5213506e
RW
12214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
12215$as_echo "$STRIP" >&6; }
278a7a38 12216else
5213506e
RW
12217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12218$as_echo "no" >&6; }
278a7a38
AO
12219fi
12220
5213506e 12221
278a7a38
AO
12222 done
12223fi
12224
12225for ncn_progname in strip; do
2abefe3d
PB
12226 if test -n "$ncn_tool_prefix"; then
12227 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12228set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12229{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12230$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12231if ${ac_cv_prog_STRIP+:} false; then :
5213506e 12232 $as_echo_n "(cached) " >&6
2abefe3d
PB
12233else
12234 if test -n "$STRIP"; then
12235 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
12236else
1c710c3c
DJ
12237as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12238for as_dir in $PATH
12239do
12240 IFS=$as_save_IFS
12241 test -z "$as_dir" && as_dir=.
5213506e 12242 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12243 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12244 ac_cv_prog_STRIP="${ncn_tool_prefix}${ncn_progname}"
5213506e 12245 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12246 break 2
12247 fi
12248done
5213506e
RW
12249 done
12250IFS=$as_save_IFS
1c710c3c 12251
2abefe3d
PB
12252fi
12253fi
1c710c3c 12254STRIP=$ac_cv_prog_STRIP
2abefe3d 12255if test -n "$STRIP"; then
5213506e
RW
12256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
12257$as_echo "$STRIP" >&6; }
2abefe3d 12258else
5213506e
RW
12259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12260$as_echo "no" >&6; }
2abefe3d
PB
12261fi
12262
5213506e 12263
2abefe3d
PB
12264 fi
12265 if test -z "$ac_cv_prog_STRIP" && test $build = $host ; then
12266 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12267set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12269$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12270if ${ac_cv_prog_STRIP+:} false; then :
5213506e 12271 $as_echo_n "(cached) " >&6
2abefe3d
PB
12272else
12273 if test -n "$STRIP"; then
12274 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
12275else
1c710c3c
DJ
12276as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12277for as_dir in $PATH
12278do
12279 IFS=$as_save_IFS
12280 test -z "$as_dir" && as_dir=.
5213506e 12281 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12282 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12283 ac_cv_prog_STRIP="${ncn_progname}"
5213506e 12284 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12285 break 2
12286 fi
12287done
5213506e
RW
12288 done
12289IFS=$as_save_IFS
1c710c3c 12290
2abefe3d
PB
12291fi
12292fi
1c710c3c 12293STRIP=$ac_cv_prog_STRIP
2abefe3d 12294if test -n "$STRIP"; then
5213506e
RW
12295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
12296$as_echo "$STRIP" >&6; }
2abefe3d 12297else
5213506e
RW
12298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12299$as_echo "no" >&6; }
2abefe3d 12300fi
1c710c3c 12301
5213506e 12302
2abefe3d
PB
12303 fi
12304 test -n "$ac_cv_prog_STRIP" && break
12305done
12306
12307if test -z "$ac_cv_prog_STRIP" ; then
8927b7c0 12308 STRIP="true"
2abefe3d
PB
12309fi
12310
278a7a38
AO
12311
12312
12313if test -n "$WINDRES"; then
12314 ac_cv_prog_WINDRES=$WINDRES
12315elif test -n "$ac_cv_prog_WINDRES"; then
12316 WINDRES=$ac_cv_prog_WINDRES
12317fi
12318
12319if test -n "$ac_cv_prog_WINDRES"; then
12320 for ncn_progname in windres; do
12321 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12322set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12323{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12324$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12325if ${ac_cv_prog_WINDRES+:} false; then :
5213506e 12326 $as_echo_n "(cached) " >&6
278a7a38
AO
12327else
12328 if test -n "$WINDRES"; then
12329 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
12330else
12331as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12332for as_dir in $PATH
12333do
12334 IFS=$as_save_IFS
12335 test -z "$as_dir" && as_dir=.
5213506e 12336 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12337 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12338 ac_cv_prog_WINDRES="${ncn_progname}"
5213506e 12339 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12340 break 2
12341 fi
12342done
5213506e
RW
12343 done
12344IFS=$as_save_IFS
278a7a38
AO
12345
12346fi
12347fi
12348WINDRES=$ac_cv_prog_WINDRES
12349if test -n "$WINDRES"; then
5213506e
RW
12350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
12351$as_echo "$WINDRES" >&6; }
278a7a38 12352else
5213506e
RW
12353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12354$as_echo "no" >&6; }
278a7a38
AO
12355fi
12356
5213506e 12357
278a7a38
AO
12358 done
12359fi
12360
12361for ncn_progname in windres; do
2693c0b0
PB
12362 if test -n "$ncn_tool_prefix"; then
12363 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12364set dummy ${ncn_tool_prefix}${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_WINDRES+:} false; then :
5213506e 12368 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12369else
12370 if test -n "$WINDRES"; then
12371 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
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_WINDRES="${ncn_tool_prefix}${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 12390WINDRES=$ac_cv_prog_WINDRES
ca9f4b81 12391if test -n "$WINDRES"; then
5213506e
RW
12392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
12393$as_echo "$WINDRES" >&6; }
ca9f4b81 12394else
5213506e
RW
12395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12396$as_echo "no" >&6; }
ca9f4b81
AO
12397fi
12398
5213506e 12399
2693c0b0
PB
12400 fi
12401 if test -z "$ac_cv_prog_WINDRES" && test $build = $host ; then
12402 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12403set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12405$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12406if ${ac_cv_prog_WINDRES+:} false; then :
5213506e 12407 $as_echo_n "(cached) " >&6
ca9f4b81 12408else
2693c0b0
PB
12409 if test -n "$WINDRES"; then
12410 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
ca9f4b81 12411else
1c710c3c
DJ
12412as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12413for as_dir in $PATH
12414do
12415 IFS=$as_save_IFS
12416 test -z "$as_dir" && as_dir=.
5213506e 12417 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12419 ac_cv_prog_WINDRES="${ncn_progname}"
5213506e 12420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12421 break 2
12422 fi
12423done
5213506e
RW
12424 done
12425IFS=$as_save_IFS
1c710c3c 12426
ca9f4b81
AO
12427fi
12428fi
1c710c3c 12429WINDRES=$ac_cv_prog_WINDRES
2693c0b0 12430if test -n "$WINDRES"; then
5213506e
RW
12431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
12432$as_echo "$WINDRES" >&6; }
ca9f4b81 12433else
5213506e
RW
12434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12435$as_echo "no" >&6; }
ca9f4b81 12436fi
1c710c3c 12437
5213506e 12438
2693c0b0
PB
12439 fi
12440 test -n "$ac_cv_prog_WINDRES" && break
12441done
12442
12443if test -z "$ac_cv_prog_WINDRES" ; then
12444 set dummy windres
12445 if test $build = $host ; then
12446 WINDRES="$2"
ca9f4b81 12447 else
2693c0b0 12448 WINDRES="${ncn_tool_prefix}$2"
ca9f4b81 12449 fi
ca9f4b81
AO
12450fi
12451
278a7a38
AO
12452
12453
901119ae
KT
12454if test -n "$WINDMC"; then
12455 ac_cv_prog_WINDMC=$WINDMC
12456elif test -n "$ac_cv_prog_WINDMC"; then
12457 WINDMC=$ac_cv_prog_WINDMC
12458fi
12459
12460if test -n "$ac_cv_prog_WINDMC"; then
12461 for ncn_progname in windmc; do
12462 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12463set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12465$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12466if ${ac_cv_prog_WINDMC+:} false; then :
5213506e 12467 $as_echo_n "(cached) " >&6
901119ae
KT
12468else
12469 if test -n "$WINDMC"; then
12470 ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
12471else
12472as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12473for as_dir in $PATH
12474do
12475 IFS=$as_save_IFS
12476 test -z "$as_dir" && as_dir=.
5213506e 12477 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12478 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 12479 ac_cv_prog_WINDMC="${ncn_progname}"
5213506e 12480 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
12481 break 2
12482 fi
12483done
5213506e
RW
12484 done
12485IFS=$as_save_IFS
901119ae
KT
12486
12487fi
12488fi
12489WINDMC=$ac_cv_prog_WINDMC
12490if test -n "$WINDMC"; then
5213506e
RW
12491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
12492$as_echo "$WINDMC" >&6; }
901119ae 12493else
5213506e
RW
12494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12495$as_echo "no" >&6; }
901119ae
KT
12496fi
12497
5213506e 12498
901119ae
KT
12499 done
12500fi
12501
12502for ncn_progname in windmc; do
12503 if test -n "$ncn_tool_prefix"; then
12504 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12505set dummy ${ncn_tool_prefix}${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_WINDMC+:} false; then :
5213506e 12509 $as_echo_n "(cached) " >&6
901119ae
KT
12510else
12511 if test -n "$WINDMC"; then
12512 ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
12513else
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
901119ae 12521 ac_cv_prog_WINDMC="${ncn_tool_prefix}${ncn_progname}"
5213506e 12522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
12523 break 2
12524 fi
12525done
5213506e
RW
12526 done
12527IFS=$as_save_IFS
901119ae
KT
12528
12529fi
12530fi
12531WINDMC=$ac_cv_prog_WINDMC
12532if test -n "$WINDMC"; then
5213506e
RW
12533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
12534$as_echo "$WINDMC" >&6; }
901119ae 12535else
5213506e
RW
12536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12537$as_echo "no" >&6; }
901119ae
KT
12538fi
12539
5213506e 12540
901119ae
KT
12541 fi
12542 if test -z "$ac_cv_prog_WINDMC" && test $build = $host ; then
12543 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12544set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12545{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12546$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12547if ${ac_cv_prog_WINDMC+:} false; then :
5213506e 12548 $as_echo_n "(cached) " >&6
901119ae
KT
12549else
12550 if test -n "$WINDMC"; then
12551 ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
12552else
12553as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12554for as_dir in $PATH
12555do
12556 IFS=$as_save_IFS
12557 test -z "$as_dir" && as_dir=.
5213506e 12558 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12559 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 12560 ac_cv_prog_WINDMC="${ncn_progname}"
5213506e 12561 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
12562 break 2
12563 fi
12564done
5213506e
RW
12565 done
12566IFS=$as_save_IFS
901119ae
KT
12567
12568fi
12569fi
12570WINDMC=$ac_cv_prog_WINDMC
12571if test -n "$WINDMC"; then
5213506e
RW
12572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
12573$as_echo "$WINDMC" >&6; }
901119ae 12574else
5213506e
RW
12575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12576$as_echo "no" >&6; }
901119ae
KT
12577fi
12578
5213506e 12579
901119ae
KT
12580 fi
12581 test -n "$ac_cv_prog_WINDMC" && break
12582done
12583
12584if test -z "$ac_cv_prog_WINDMC" ; then
12585 set dummy windmc
12586 if test $build = $host ; then
12587 WINDMC="$2"
12588 else
12589 WINDMC="${ncn_tool_prefix}$2"
12590 fi
12591fi
12592
12593
12594
278a7a38
AO
12595if test -n "$OBJCOPY"; then
12596 ac_cv_prog_OBJCOPY=$OBJCOPY
12597elif test -n "$ac_cv_prog_OBJCOPY"; then
12598 OBJCOPY=$ac_cv_prog_OBJCOPY
12599fi
12600
12601if test -n "$ac_cv_prog_OBJCOPY"; then
12602 for ncn_progname in objcopy; do
12603 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12604set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12605{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12606$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12607if ${ac_cv_prog_OBJCOPY+:} false; then :
5213506e 12608 $as_echo_n "(cached) " >&6
278a7a38
AO
12609else
12610 if test -n "$OBJCOPY"; then
12611 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
12612else
12613as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12614for as_dir in $PATH
12615do
12616 IFS=$as_save_IFS
12617 test -z "$as_dir" && as_dir=.
5213506e 12618 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12619 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12620 ac_cv_prog_OBJCOPY="${ncn_progname}"
5213506e 12621 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12622 break 2
12623 fi
12624done
5213506e
RW
12625 done
12626IFS=$as_save_IFS
278a7a38
AO
12627
12628fi
12629fi
12630OBJCOPY=$ac_cv_prog_OBJCOPY
12631if test -n "$OBJCOPY"; then
5213506e
RW
12632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
12633$as_echo "$OBJCOPY" >&6; }
278a7a38 12634else
5213506e
RW
12635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12636$as_echo "no" >&6; }
278a7a38
AO
12637fi
12638
5213506e 12639
278a7a38
AO
12640 done
12641fi
12642
12643for ncn_progname in objcopy; do
2693c0b0
PB
12644 if test -n "$ncn_tool_prefix"; then
12645 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12646set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
12647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12648$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12649if ${ac_cv_prog_OBJCOPY+:} false; then :
5213506e 12650 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12651else
12652 if test -n "$OBJCOPY"; then
12653 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
12654else
1c710c3c
DJ
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=.
5213506e 12660 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12661 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12662 ac_cv_prog_OBJCOPY="${ncn_tool_prefix}${ncn_progname}"
5213506e 12663 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12664 break 2
12665 fi
12666done
5213506e
RW
12667 done
12668IFS=$as_save_IFS
1c710c3c 12669
ca9f4b81
AO
12670fi
12671fi
1c710c3c 12672OBJCOPY=$ac_cv_prog_OBJCOPY
ca9f4b81 12673if test -n "$OBJCOPY"; then
5213506e
RW
12674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
12675$as_echo "$OBJCOPY" >&6; }
ca9f4b81 12676else
5213506e
RW
12677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12678$as_echo "no" >&6; }
ca9f4b81
AO
12679fi
12680
5213506e 12681
2693c0b0
PB
12682 fi
12683 if test -z "$ac_cv_prog_OBJCOPY" && test $build = $host ; then
12684 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12685set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12686{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12687$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12688if ${ac_cv_prog_OBJCOPY+:} false; then :
5213506e 12689 $as_echo_n "(cached) " >&6
ca9f4b81 12690else
2693c0b0
PB
12691 if test -n "$OBJCOPY"; then
12692 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
ca9f4b81 12693else
1c710c3c
DJ
12694as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12695for as_dir in $PATH
12696do
12697 IFS=$as_save_IFS
12698 test -z "$as_dir" && as_dir=.
5213506e 12699 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12700 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12701 ac_cv_prog_OBJCOPY="${ncn_progname}"
5213506e 12702 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12703 break 2
12704 fi
12705done
5213506e
RW
12706 done
12707IFS=$as_save_IFS
1c710c3c 12708
ca9f4b81
AO
12709fi
12710fi
1c710c3c 12711OBJCOPY=$ac_cv_prog_OBJCOPY
2693c0b0 12712if test -n "$OBJCOPY"; then
5213506e
RW
12713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
12714$as_echo "$OBJCOPY" >&6; }
ca9f4b81 12715else
5213506e
RW
12716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12717$as_echo "no" >&6; }
ca9f4b81 12718fi
1c710c3c 12719
5213506e 12720
2693c0b0
PB
12721 fi
12722 test -n "$ac_cv_prog_OBJCOPY" && break
12723done
12724
12725if test -z "$ac_cv_prog_OBJCOPY" ; then
12726 set dummy objcopy
12727 if test $build = $host ; then
12728 OBJCOPY="$2"
ca9f4b81 12729 else
2693c0b0 12730 OBJCOPY="${ncn_tool_prefix}$2"
ca9f4b81 12731 fi
ca9f4b81
AO
12732fi
12733
278a7a38
AO
12734
12735
12736if test -n "$OBJDUMP"; then
12737 ac_cv_prog_OBJDUMP=$OBJDUMP
12738elif test -n "$ac_cv_prog_OBJDUMP"; then
12739 OBJDUMP=$ac_cv_prog_OBJDUMP
12740fi
12741
12742if test -n "$ac_cv_prog_OBJDUMP"; then
12743 for ncn_progname in objdump; do
12744 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12745set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12746{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12747$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12748if ${ac_cv_prog_OBJDUMP+:} false; then :
5213506e 12749 $as_echo_n "(cached) " >&6
278a7a38
AO
12750else
12751 if test -n "$OBJDUMP"; then
12752 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
12753else
12754as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12755for as_dir in $PATH
12756do
12757 IFS=$as_save_IFS
12758 test -z "$as_dir" && as_dir=.
5213506e 12759 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12760 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 12761 ac_cv_prog_OBJDUMP="${ncn_progname}"
5213506e 12762 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
12763 break 2
12764 fi
12765done
5213506e
RW
12766 done
12767IFS=$as_save_IFS
278a7a38
AO
12768
12769fi
12770fi
12771OBJDUMP=$ac_cv_prog_OBJDUMP
12772if test -n "$OBJDUMP"; then
5213506e
RW
12773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
12774$as_echo "$OBJDUMP" >&6; }
278a7a38 12775else
5213506e
RW
12776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12777$as_echo "no" >&6; }
278a7a38
AO
12778fi
12779
5213506e 12780
278a7a38
AO
12781 done
12782fi
12783
12784for ncn_progname in objdump; do
2693c0b0
PB
12785 if test -n "$ncn_tool_prefix"; then
12786 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12787set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
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_OBJDUMP+:} false; then :
5213506e 12791 $as_echo_n "(cached) " >&6
ca9f4b81
AO
12792else
12793 if test -n "$OBJDUMP"; then
12794 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
12795else
1c710c3c
DJ
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=.
5213506e 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
1c710c3c 12803 ac_cv_prog_OBJDUMP="${ncn_tool_prefix}${ncn_progname}"
5213506e 12804 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12805 break 2
12806 fi
12807done
5213506e
RW
12808 done
12809IFS=$as_save_IFS
1c710c3c 12810
ca9f4b81
AO
12811fi
12812fi
1c710c3c 12813OBJDUMP=$ac_cv_prog_OBJDUMP
ca9f4b81 12814if test -n "$OBJDUMP"; then
5213506e
RW
12815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
12816$as_echo "$OBJDUMP" >&6; }
ca9f4b81 12817else
5213506e
RW
12818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12819$as_echo "no" >&6; }
ca9f4b81
AO
12820fi
12821
5213506e 12822
2693c0b0
PB
12823 fi
12824 if test -z "$ac_cv_prog_OBJDUMP" && test $build = $host ; then
12825 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12826set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
12827{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12828$as_echo_n "checking for $ac_word... " >&6; }
22e05272 12829if ${ac_cv_prog_OBJDUMP+:} false; then :
5213506e 12830 $as_echo_n "(cached) " >&6
ca9f4b81 12831else
2693c0b0
PB
12832 if test -n "$OBJDUMP"; then
12833 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
ca9f4b81 12834else
1c710c3c
DJ
12835as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12836for as_dir in $PATH
12837do
12838 IFS=$as_save_IFS
12839 test -z "$as_dir" && as_dir=.
5213506e 12840 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 12841 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 12842 ac_cv_prog_OBJDUMP="${ncn_progname}"
5213506e 12843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
12844 break 2
12845 fi
12846done
5213506e
RW
12847 done
12848IFS=$as_save_IFS
1c710c3c 12849
ca9f4b81
AO
12850fi
12851fi
1c710c3c 12852OBJDUMP=$ac_cv_prog_OBJDUMP
2693c0b0 12853if test -n "$OBJDUMP"; then
5213506e
RW
12854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
12855$as_echo "$OBJDUMP" >&6; }
ca9f4b81 12856else
5213506e
RW
12857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12858$as_echo "no" >&6; }
ca9f4b81 12859fi
1c710c3c 12860
5213506e 12861
2693c0b0
PB
12862 fi
12863 test -n "$ac_cv_prog_OBJDUMP" && break
12864done
12865
12866if test -z "$ac_cv_prog_OBJDUMP" ; then
12867 set dummy objdump
12868 if test $build = $host ; then
12869 OBJDUMP="$2"
ca9f4b81 12870 else
2693c0b0 12871 OBJDUMP="${ncn_tool_prefix}$2"
ca9f4b81 12872 fi
ca9f4b81
AO
12873fi
12874
671aa708
NN
12875
12876
e4a9a572
IS
12877if test -n "$OTOOL"; then
12878 ac_cv_prog_OTOOL=$OTOOL
12879elif test -n "$ac_cv_prog_OTOOL"; then
12880 OTOOL=$ac_cv_prog_OTOOL
12881fi
12882
12883if test -n "$ac_cv_prog_OTOOL"; then
12884 for ncn_progname in otool; do
12885 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12886set dummy ${ncn_progname}; ac_word=$2
12887{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12888$as_echo_n "checking for $ac_word... " >&6; }
12889if ${ac_cv_prog_OTOOL+:} false; then :
12890 $as_echo_n "(cached) " >&6
12891else
12892 if test -n "$OTOOL"; then
12893 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
12894else
12895as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12896for as_dir in $PATH
12897do
12898 IFS=$as_save_IFS
12899 test -z "$as_dir" && as_dir=.
12900 for ac_exec_ext in '' $ac_executable_extensions; do
12901 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12902 ac_cv_prog_OTOOL="${ncn_progname}"
12903 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12904 break 2
12905 fi
12906done
12907 done
12908IFS=$as_save_IFS
12909
12910fi
12911fi
12912OTOOL=$ac_cv_prog_OTOOL
12913if test -n "$OTOOL"; then
12914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
12915$as_echo "$OTOOL" >&6; }
12916else
12917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12918$as_echo "no" >&6; }
12919fi
12920
12921
12922 done
12923fi
12924
12925for ncn_progname in otool; do
12926 if test -n "$ncn_tool_prefix"; then
12927 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
12928set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
12929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12930$as_echo_n "checking for $ac_word... " >&6; }
12931if ${ac_cv_prog_OTOOL+:} false; then :
12932 $as_echo_n "(cached) " >&6
12933else
12934 if test -n "$OTOOL"; then
12935 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
12936else
12937as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12938for as_dir in $PATH
12939do
12940 IFS=$as_save_IFS
12941 test -z "$as_dir" && as_dir=.
12942 for ac_exec_ext in '' $ac_executable_extensions; do
12943 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12944 ac_cv_prog_OTOOL="${ncn_tool_prefix}${ncn_progname}"
12945 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12946 break 2
12947 fi
12948done
12949 done
12950IFS=$as_save_IFS
12951
12952fi
12953fi
12954OTOOL=$ac_cv_prog_OTOOL
12955if test -n "$OTOOL"; then
12956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
12957$as_echo "$OTOOL" >&6; }
12958else
12959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12960$as_echo "no" >&6; }
12961fi
12962
12963
12964 fi
12965 if test -z "$ac_cv_prog_OTOOL" && test $build = $host ; then
12966 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
12967set dummy ${ncn_progname}; ac_word=$2
12968{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12969$as_echo_n "checking for $ac_word... " >&6; }
12970if ${ac_cv_prog_OTOOL+:} false; then :
12971 $as_echo_n "(cached) " >&6
12972else
12973 if test -n "$OTOOL"; then
12974 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
12975else
12976as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12977for as_dir in $PATH
12978do
12979 IFS=$as_save_IFS
12980 test -z "$as_dir" && as_dir=.
12981 for ac_exec_ext in '' $ac_executable_extensions; do
12982 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12983 ac_cv_prog_OTOOL="${ncn_progname}"
12984 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12985 break 2
12986 fi
12987done
12988 done
12989IFS=$as_save_IFS
12990
12991fi
12992fi
12993OTOOL=$ac_cv_prog_OTOOL
12994if test -n "$OTOOL"; then
12995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
12996$as_echo "$OTOOL" >&6; }
12997else
12998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12999$as_echo "no" >&6; }
13000fi
13001
13002
13003 fi
13004 test -n "$ac_cv_prog_OTOOL" && break
13005done
13006
13007if test -z "$ac_cv_prog_OTOOL" ; then
13008 set dummy otool
13009 if test $build = $host ; then
13010 OTOOL="$2"
13011 else
13012 OTOOL="${ncn_tool_prefix}$2"
13013 fi
13014fi
13015
13016
13017
e7a82751
RM
13018if test -n "$READELF"; then
13019 ac_cv_prog_READELF=$READELF
13020elif test -n "$ac_cv_prog_READELF"; then
13021 READELF=$ac_cv_prog_READELF
13022fi
13023
13024if test -n "$ac_cv_prog_READELF"; then
13025 for ncn_progname in readelf; do
13026 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13027set dummy ${ncn_progname}; ac_word=$2
13028{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13029$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13030if ${ac_cv_prog_READELF+:} false; then :
e7a82751
RM
13031 $as_echo_n "(cached) " >&6
13032else
13033 if test -n "$READELF"; then
13034 ac_cv_prog_READELF="$READELF" # Let the user override the test.
13035else
13036as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13037for as_dir in $PATH
13038do
13039 IFS=$as_save_IFS
13040 test -z "$as_dir" && as_dir=.
13041 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
13043 ac_cv_prog_READELF="${ncn_progname}"
13044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13045 break 2
13046 fi
13047done
13048 done
13049IFS=$as_save_IFS
13050
13051fi
13052fi
13053READELF=$ac_cv_prog_READELF
13054if test -n "$READELF"; then
13055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
13056$as_echo "$READELF" >&6; }
13057else
13058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13059$as_echo "no" >&6; }
13060fi
13061
13062
13063 done
13064fi
13065
13066for ncn_progname in readelf; do
13067 if test -n "$ncn_tool_prefix"; then
13068 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
13069set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
13070{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13071$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13072if ${ac_cv_prog_READELF+:} false; then :
e7a82751
RM
13073 $as_echo_n "(cached) " >&6
13074else
13075 if test -n "$READELF"; then
13076 ac_cv_prog_READELF="$READELF" # Let the user override the test.
13077else
13078as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13079for as_dir in $PATH
13080do
13081 IFS=$as_save_IFS
13082 test -z "$as_dir" && as_dir=.
13083 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13084 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
13085 ac_cv_prog_READELF="${ncn_tool_prefix}${ncn_progname}"
13086 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13087 break 2
13088 fi
13089done
13090 done
13091IFS=$as_save_IFS
13092
13093fi
13094fi
13095READELF=$ac_cv_prog_READELF
13096if test -n "$READELF"; then
13097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
13098$as_echo "$READELF" >&6; }
13099else
13100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13101$as_echo "no" >&6; }
13102fi
13103
13104
13105 fi
13106 if test -z "$ac_cv_prog_READELF" && test $build = $host ; then
13107 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13108set dummy ${ncn_progname}; ac_word=$2
13109{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13110$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13111if ${ac_cv_prog_READELF+:} false; then :
e7a82751
RM
13112 $as_echo_n "(cached) " >&6
13113else
13114 if test -n "$READELF"; then
13115 ac_cv_prog_READELF="$READELF" # Let the user override the test.
13116else
13117as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13118for as_dir in $PATH
13119do
13120 IFS=$as_save_IFS
13121 test -z "$as_dir" && as_dir=.
13122 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13123 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
13124 ac_cv_prog_READELF="${ncn_progname}"
13125 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13126 break 2
13127 fi
13128done
13129 done
13130IFS=$as_save_IFS
13131
13132fi
13133fi
13134READELF=$ac_cv_prog_READELF
13135if test -n "$READELF"; then
13136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
13137$as_echo "$READELF" >&6; }
13138else
13139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13140$as_echo "no" >&6; }
13141fi
13142
13143
13144 fi
13145 test -n "$ac_cv_prog_READELF" && break
13146done
13147
13148if test -z "$ac_cv_prog_READELF" ; then
13149 set dummy readelf
13150 if test $build = $host ; then
13151 READELF="$2"
13152 else
13153 READELF="${ncn_tool_prefix}$2"
13154 fi
13155fi
13156
13157
13158
671aa708
NN
13159
13160
13161
5fee5ec3 13162
1ed21e23 13163GDCFLAGS=${GDCFLAGS-${CFLAGS}}
5fee5ec3 13164
1ddd41fd 13165
126f707e
L
13166{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
13167$as_echo_n "checking for -plugin option... " >&6; }
13168
13169plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
13170plugin_option=
13171for plugin in $plugin_names; do
13172 plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
13173 if test x$plugin_so = x$plugin; then
13174 plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
13175 fi
13176 if test x$plugin_so != x$plugin; then
13177 plugin_option="--plugin $plugin_so"
13178 break
13179 fi
13180done
9c7797a8
L
13181if test -n "$ac_tool_prefix"; then
13182 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
13183set dummy ${ac_tool_prefix}ar; ac_word=$2
13184{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13185$as_echo_n "checking for $ac_word... " >&6; }
13186if ${ac_cv_prog_AR+:} false; then :
13187 $as_echo_n "(cached) " >&6
13188else
13189 if test -n "$AR"; then
13190 ac_cv_prog_AR="$AR" # Let the user override the test.
13191else
13192as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13193for as_dir in $PATH
13194do
13195 IFS=$as_save_IFS
13196 test -z "$as_dir" && as_dir=.
13197 for ac_exec_ext in '' $ac_executable_extensions; do
13198 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13199 ac_cv_prog_AR="${ac_tool_prefix}ar"
13200 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13201 break 2
13202 fi
13203done
13204 done
13205IFS=$as_save_IFS
13206
13207fi
13208fi
13209AR=$ac_cv_prog_AR
13210if test -n "$AR"; then
13211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
13212$as_echo "$AR" >&6; }
13213else
13214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13215$as_echo "no" >&6; }
13216fi
13217
13218
13219fi
13220if test -z "$ac_cv_prog_AR"; then
13221 ac_ct_AR=$AR
13222 # Extract the first word of "ar", so it can be a program name with args.
13223set dummy ar; ac_word=$2
13224{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13225$as_echo_n "checking for $ac_word... " >&6; }
13226if ${ac_cv_prog_ac_ct_AR+:} false; then :
13227 $as_echo_n "(cached) " >&6
13228else
13229 if test -n "$ac_ct_AR"; then
13230 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
13231else
13232as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13233for as_dir in $PATH
13234do
13235 IFS=$as_save_IFS
13236 test -z "$as_dir" && as_dir=.
13237 for ac_exec_ext in '' $ac_executable_extensions; do
13238 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13239 ac_cv_prog_ac_ct_AR="ar"
13240 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13241 break 2
13242 fi
13243done
13244 done
13245IFS=$as_save_IFS
13246
13247fi
13248fi
13249ac_ct_AR=$ac_cv_prog_ac_ct_AR
13250if test -n "$ac_ct_AR"; then
13251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
13252$as_echo "$ac_ct_AR" >&6; }
13253else
13254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13255$as_echo "no" >&6; }
13256fi
13257
13258 if test "x$ac_ct_AR" = x; then
13259 AR=""
13260 else
13261 case $cross_compiling:$ac_tool_warned in
13262yes:)
13263{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
13264$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
13265ac_tool_warned=yes ;;
13266esac
13267 AR=$ac_ct_AR
13268 fi
13269else
13270 AR="$ac_cv_prog_AR"
13271fi
13272
13273if test "${AR}" = "" ; then
13274 as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
13275fi
13276touch conftest.c
13277${AR} $plugin_option rc conftest.a conftest.c
13278if test "$?" != 0; then
13279 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
13280$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
13281 plugin_option=
13282fi
13283rm -f conftest.*
126f707e
L
13284if test -n "$plugin_option"; then
13285 PLUGIN_OPTION="$plugin_option"
13286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
13287$as_echo "$plugin_option" >&6; }
13288else
13289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13290$as_echo "no" >&6; }
13291fi
13292
13293AR_PLUGIN_OPTION=
13294RANLIB_PLUGIN_OPTION=
13295if test -n "$PLUGIN_OPTION"; then
13296 if $AR --help 2>&1 | grep -q "\--plugin"; then
13297 AR_PLUGIN_OPTION="$PLUGIN_OPTION"
13298 fi
13299 if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
13300 RANLIB_PLUGIN_OPTION="$PLUGIN_OPTION"
13301 fi
13302fi
13303
13304
13305
2abefe3d 13306# Target tools.
1c710c3c 13307
5213506e
RW
13308# Check whether --with-build-time-tools was given.
13309if test "${with_build_time_tools+set}" = set; then :
13310 withval=$with_build_time_tools; case x"$withval" in
e8b05380
PB
13311 x/*) ;;
13312 *)
13313 with_build_time_tools=
5213506e
RW
13314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: argument to --with-build-time-tools must be an absolute path" >&5
13315$as_echo "$as_me: WARNING: argument to --with-build-time-tools must be an absolute path" >&2;}
e8b05380
PB
13316 ;;
13317 esac
ca9f4b81 13318else
e8b05380 13319 with_build_time_tools=
5213506e
RW
13320fi
13321
ca9f4b81 13322
278a7a38
AO
13323
13324
13325if test -n "$CC_FOR_TARGET"; then
13326 ac_cv_prog_CC_FOR_TARGET=$CC_FOR_TARGET
13327elif test -n "$ac_cv_prog_CC_FOR_TARGET"; then
13328 CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
13329fi
13330
13331if test -n "$ac_cv_prog_CC_FOR_TARGET"; then
13332 for ncn_progname in cc gcc; do
13333 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13334set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13335{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13336$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13337if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
5213506e 13338 $as_echo_n "(cached) " >&6
278a7a38
AO
13339else
13340 if test -n "$CC_FOR_TARGET"; then
13341 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
13342else
13343as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13344for as_dir in $PATH
13345do
13346 IFS=$as_save_IFS
13347 test -z "$as_dir" && as_dir=.
5213506e 13348 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13349 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13350 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
5213506e 13351 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
13352 break 2
13353 fi
13354done
5213506e
RW
13355 done
13356IFS=$as_save_IFS
278a7a38
AO
13357
13358fi
13359fi
13360CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
13361if test -n "$CC_FOR_TARGET"; then
5213506e
RW
13362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
13363$as_echo "$CC_FOR_TARGET" >&6; }
278a7a38 13364else
5213506e
RW
13365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13366$as_echo "no" >&6; }
278a7a38
AO
13367fi
13368
5213506e 13369
278a7a38
AO
13370 done
13371fi
13372
13373if test -z "$ac_cv_prog_CC_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13374 for ncn_progname in cc gcc; do
5213506e
RW
13375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13376$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13377 if test -x $with_build_time_tools/${ncn_progname}; then
13378 ac_cv_prog_CC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13380$as_echo "yes" >&6; }
72a7ab82 13381 break
e8b05380 13382 else
5213506e
RW
13383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13384$as_echo "no" >&6; }
72a7ab82
AP
13385 fi
13386 done
4de997d1
PB
13387fi
13388
e8b05380
PB
13389if test -z "$ac_cv_prog_CC_FOR_TARGET"; then
13390 for ncn_progname in cc gcc; do
13391 if test -n "$ncn_target_tool_prefix"; then
13392 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 13393set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13395$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13396if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
5213506e 13397 $as_echo_n "(cached) " >&6
4de997d1
PB
13398else
13399 if test -n "$CC_FOR_TARGET"; then
13400 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
13401else
1c710c3c
DJ
13402as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13403for as_dir in $PATH
13404do
13405 IFS=$as_save_IFS
13406 test -z "$as_dir" && as_dir=.
5213506e 13407 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13409 ac_cv_prog_CC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13411 break 2
13412 fi
13413done
5213506e
RW
13414 done
13415IFS=$as_save_IFS
1c710c3c 13416
4de997d1
PB
13417fi
13418fi
1c710c3c 13419CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
4de997d1 13420if test -n "$CC_FOR_TARGET"; then
5213506e
RW
13421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
13422$as_echo "$CC_FOR_TARGET" >&6; }
4de997d1 13423else
5213506e
RW
13424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13425$as_echo "no" >&6; }
4de997d1
PB
13426fi
13427
5213506e 13428
e8b05380
PB
13429 fi
13430 if test -z "$ac_cv_prog_CC_FOR_TARGET" && test $build = $target ; then
13431 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 13432set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13433{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13434$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13435if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
5213506e 13436 $as_echo_n "(cached) " >&6
4de997d1 13437else
2693c0b0
PB
13438 if test -n "$CC_FOR_TARGET"; then
13439 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4de997d1 13440else
1c710c3c
DJ
13441as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13442for as_dir in $PATH
13443do
13444 IFS=$as_save_IFS
13445 test -z "$as_dir" && as_dir=.
5213506e 13446 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13447 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13448 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
5213506e 13449 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13450 break 2
13451 fi
13452done
5213506e
RW
13453 done
13454IFS=$as_save_IFS
1c710c3c 13455
4de997d1
PB
13456fi
13457fi
1c710c3c 13458CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
2693c0b0 13459if test -n "$CC_FOR_TARGET"; then
5213506e
RW
13460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
13461$as_echo "$CC_FOR_TARGET" >&6; }
4de997d1 13462else
5213506e
RW
13463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13464$as_echo "no" >&6; }
4de997d1 13465fi
1c710c3c 13466
5213506e 13467
e8b05380
PB
13468 fi
13469 test -n "$ac_cv_prog_CC_FOR_TARGET" && break
13470 done
13471fi
1c710c3c 13472
2693c0b0
PB
13473if test -z "$ac_cv_prog_CC_FOR_TARGET" ; then
13474 set dummy cc gcc
13475 if test $build = $target ; then
13476 CC_FOR_TARGET="$2"
4de997d1 13477 else
2693c0b0 13478 CC_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 13479 fi
1c00b503
PB
13480else
13481 CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
4de997d1
PB
13482fi
13483
278a7a38
AO
13484
13485
13486if test -n "$CXX_FOR_TARGET"; then
13487 ac_cv_prog_CXX_FOR_TARGET=$CXX_FOR_TARGET
13488elif test -n "$ac_cv_prog_CXX_FOR_TARGET"; then
13489 CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
13490fi
13491
13492if test -n "$ac_cv_prog_CXX_FOR_TARGET"; then
13493 for ncn_progname in c++ g++ cxx gxx; do
13494 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13495set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13496{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13497$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13498if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
5213506e 13499 $as_echo_n "(cached) " >&6
278a7a38
AO
13500else
13501 if test -n "$CXX_FOR_TARGET"; then
13502 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
13503else
13504as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13505for as_dir in $PATH
13506do
13507 IFS=$as_save_IFS
13508 test -z "$as_dir" && as_dir=.
5213506e 13509 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13510 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13511 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
5213506e 13512 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
13513 break 2
13514 fi
13515done
5213506e
RW
13516 done
13517IFS=$as_save_IFS
278a7a38
AO
13518
13519fi
13520fi
13521CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
13522if test -n "$CXX_FOR_TARGET"; then
5213506e
RW
13523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
13524$as_echo "$CXX_FOR_TARGET" >&6; }
278a7a38 13525else
5213506e
RW
13526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13527$as_echo "no" >&6; }
278a7a38
AO
13528fi
13529
5213506e 13530
278a7a38
AO
13531 done
13532fi
13533
13534if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13535 for ncn_progname in c++ g++ cxx gxx; do
5213506e
RW
13536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13537$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13538 if test -x $with_build_time_tools/${ncn_progname}; then
13539 ac_cv_prog_CXX_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13541$as_echo "yes" >&6; }
e8b05380
PB
13542 break
13543 else
5213506e
RW
13544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13545$as_echo "no" >&6; }
e8b05380
PB
13546 fi
13547 done
13548fi
13549
13550if test -z "$ac_cv_prog_CXX_FOR_TARGET"; then
13551 for ncn_progname in c++ g++ cxx gxx; do
13552 if test -n "$ncn_target_tool_prefix"; then
13553 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 13554set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13556$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13557if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
5213506e 13558 $as_echo_n "(cached) " >&6
4de997d1
PB
13559else
13560 if test -n "$CXX_FOR_TARGET"; then
13561 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
13562else
1c710c3c
DJ
13563as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13564for as_dir in $PATH
13565do
13566 IFS=$as_save_IFS
13567 test -z "$as_dir" && as_dir=.
5213506e 13568 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13570 ac_cv_prog_CXX_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13572 break 2
13573 fi
13574done
5213506e
RW
13575 done
13576IFS=$as_save_IFS
1c710c3c 13577
4de997d1
PB
13578fi
13579fi
1c710c3c 13580CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
4de997d1 13581if test -n "$CXX_FOR_TARGET"; then
5213506e
RW
13582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
13583$as_echo "$CXX_FOR_TARGET" >&6; }
4de997d1 13584else
5213506e
RW
13585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13586$as_echo "no" >&6; }
4de997d1
PB
13587fi
13588
5213506e 13589
e8b05380
PB
13590 fi
13591 if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test $build = $target ; then
13592 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 13593set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13594{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13595$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13596if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
5213506e 13597 $as_echo_n "(cached) " >&6
4de997d1 13598else
2693c0b0
PB
13599 if test -n "$CXX_FOR_TARGET"; then
13600 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4de997d1 13601else
1c710c3c
DJ
13602as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13603for as_dir in $PATH
13604do
13605 IFS=$as_save_IFS
13606 test -z "$as_dir" && as_dir=.
5213506e 13607 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13609 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
5213506e 13610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13611 break 2
13612 fi
13613done
5213506e
RW
13614 done
13615IFS=$as_save_IFS
1c710c3c 13616
4de997d1
PB
13617fi
13618fi
1c710c3c 13619CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
2693c0b0 13620if test -n "$CXX_FOR_TARGET"; then
5213506e
RW
13621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
13622$as_echo "$CXX_FOR_TARGET" >&6; }
4de997d1 13623else
5213506e
RW
13624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13625$as_echo "no" >&6; }
4de997d1 13626fi
1c710c3c 13627
5213506e 13628
e8b05380
PB
13629 fi
13630 test -n "$ac_cv_prog_CXX_FOR_TARGET" && break
13631 done
13632fi
1c710c3c 13633
2693c0b0
PB
13634if test -z "$ac_cv_prog_CXX_FOR_TARGET" ; then
13635 set dummy c++ g++ cxx gxx
13636 if test $build = $target ; then
13637 CXX_FOR_TARGET="$2"
4de997d1 13638 else
2693c0b0 13639 CXX_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 13640 fi
1c00b503
PB
13641else
13642 CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
ca9f4b81
AO
13643fi
13644
278a7a38
AO
13645
13646
13647if test -n "$GCC_FOR_TARGET"; then
13648 ac_cv_prog_GCC_FOR_TARGET=$GCC_FOR_TARGET
13649elif test -n "$ac_cv_prog_GCC_FOR_TARGET"; then
13650 GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
13651fi
13652
13653if test -n "$ac_cv_prog_GCC_FOR_TARGET"; then
13654 for ncn_progname in gcc; do
13655 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13656set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13658$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13659if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
5213506e 13660 $as_echo_n "(cached) " >&6
278a7a38
AO
13661else
13662 if test -n "$GCC_FOR_TARGET"; then
13663 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
13664else
13665as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13666for as_dir in $PATH
13667do
13668 IFS=$as_save_IFS
13669 test -z "$as_dir" && as_dir=.
5213506e 13670 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13671 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13672 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
5213506e 13673 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
13674 break 2
13675 fi
13676done
5213506e
RW
13677 done
13678IFS=$as_save_IFS
278a7a38
AO
13679
13680fi
13681fi
13682GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
13683if test -n "$GCC_FOR_TARGET"; then
5213506e
RW
13684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
13685$as_echo "$GCC_FOR_TARGET" >&6; }
278a7a38 13686else
5213506e
RW
13687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13688$as_echo "no" >&6; }
278a7a38
AO
13689fi
13690
5213506e 13691
278a7a38
AO
13692 done
13693fi
13694
13695if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13696 for ncn_progname in gcc; do
5213506e
RW
13697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13698$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13699 if test -x $with_build_time_tools/${ncn_progname}; then
13700 ac_cv_prog_GCC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13702$as_echo "yes" >&6; }
e8b05380
PB
13703 break
13704 else
5213506e
RW
13705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13706$as_echo "no" >&6; }
e8b05380
PB
13707 fi
13708 done
13709fi
13710
13711if test -z "$ac_cv_prog_GCC_FOR_TARGET"; then
13712 for ncn_progname in gcc; do
13713 if test -n "$ncn_target_tool_prefix"; then
13714 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 13715set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13716{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13717$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13718if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
5213506e 13719 $as_echo_n "(cached) " >&6
ca9f4b81 13720else
e8b05380
PB
13721 if test -n "$GCC_FOR_TARGET"; then
13722 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 13723else
1c710c3c
DJ
13724as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13725for as_dir in $PATH
13726do
13727 IFS=$as_save_IFS
13728 test -z "$as_dir" && as_dir=.
5213506e 13729 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13730 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13731 ac_cv_prog_GCC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13733 break 2
13734 fi
13735done
5213506e
RW
13736 done
13737IFS=$as_save_IFS
1c710c3c 13738
ca9f4b81
AO
13739fi
13740fi
1c710c3c 13741GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
e8b05380 13742if test -n "$GCC_FOR_TARGET"; then
5213506e
RW
13743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
13744$as_echo "$GCC_FOR_TARGET" >&6; }
ca9f4b81 13745else
5213506e
RW
13746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13747$as_echo "no" >&6; }
ca9f4b81
AO
13748fi
13749
5213506e 13750
e8b05380
PB
13751 fi
13752 if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test $build = $target ; then
13753 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 13754set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13755{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13756$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13757if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
5213506e 13758 $as_echo_n "(cached) " >&6
ca9f4b81 13759else
e8b05380
PB
13760 if test -n "$GCC_FOR_TARGET"; then
13761 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 13762else
1c710c3c
DJ
13763as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13764for as_dir in $PATH
13765do
13766 IFS=$as_save_IFS
13767 test -z "$as_dir" && as_dir=.
5213506e 13768 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13769 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13770 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
5213506e 13771 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13772 break 2
13773 fi
13774done
5213506e
RW
13775 done
13776IFS=$as_save_IFS
1c710c3c 13777
ca9f4b81
AO
13778fi
13779fi
1c710c3c 13780GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
e8b05380 13781if test -n "$GCC_FOR_TARGET"; then
5213506e
RW
13782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
13783$as_echo "$GCC_FOR_TARGET" >&6; }
ca9f4b81 13784else
5213506e
RW
13785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13786$as_echo "no" >&6; }
ca9f4b81 13787fi
1c710c3c 13788
5213506e 13789
e8b05380
PB
13790 fi
13791 test -n "$ac_cv_prog_GCC_FOR_TARGET" && break
13792 done
13793fi
1c710c3c 13794
e8b05380
PB
13795if test -z "$ac_cv_prog_GCC_FOR_TARGET" ; then
13796 GCC_FOR_TARGET="${CC_FOR_TARGET}"
1c00b503
PB
13797else
13798 GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
e8b05380
PB
13799fi
13800
278a7a38
AO
13801
13802
278a7a38
AO
13803if test -n "$GFORTRAN_FOR_TARGET"; then
13804 ac_cv_prog_GFORTRAN_FOR_TARGET=$GFORTRAN_FOR_TARGET
13805elif test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
13806 GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
e8b05380
PB
13807fi
13808
278a7a38
AO
13809if test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
13810 for ncn_progname in gfortran; do
13811 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
e8b05380 13812set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13813{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13814$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13815if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
5213506e 13816 $as_echo_n "(cached) " >&6
e8b05380 13817else
278a7a38
AO
13818 if test -n "$GFORTRAN_FOR_TARGET"; then
13819 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
e8b05380 13820else
1c710c3c
DJ
13821as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13822for as_dir in $PATH
13823do
13824 IFS=$as_save_IFS
13825 test -z "$as_dir" && as_dir=.
5213506e 13826 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13827 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 13828 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
5213506e 13829 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13830 break 2
13831 fi
13832done
5213506e
RW
13833 done
13834IFS=$as_save_IFS
1c710c3c 13835
e8b05380
PB
13836fi
13837fi
278a7a38
AO
13838GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
13839if test -n "$GFORTRAN_FOR_TARGET"; then
5213506e
RW
13840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
13841$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
e8b05380 13842else
5213506e
RW
13843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13844$as_echo "no" >&6; }
e8b05380 13845fi
1c710c3c 13846
5213506e 13847
e8b05380
PB
13848 done
13849fi
1c710c3c 13850
278a7a38 13851if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 13852 for ncn_progname in gfortran; do
5213506e
RW
13853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
13854$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
13855 if test -x $with_build_time_tools/${ncn_progname}; then
13856 ac_cv_prog_GFORTRAN_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
13857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13858$as_echo "yes" >&6; }
e8b05380
PB
13859 break
13860 else
5213506e
RW
13861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13862$as_echo "no" >&6; }
e8b05380
PB
13863 fi
13864 done
13865fi
13866
13867if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
13868 for ncn_progname in gfortran; do
13869 if test -n "$ncn_target_tool_prefix"; then
13870 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
13871set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
13872{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13873$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13874if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
5213506e 13875 $as_echo_n "(cached) " >&6
e8b05380
PB
13876else
13877 if test -n "$GFORTRAN_FOR_TARGET"; then
1c710c3c
DJ
13878 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
13879else
13880as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13881for as_dir in $PATH
13882do
13883 IFS=$as_save_IFS
13884 test -z "$as_dir" && as_dir=.
5213506e 13885 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13886 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13887 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 13888 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13889 break 2
13890 fi
13891done
5213506e
RW
13892 done
13893IFS=$as_save_IFS
1c710c3c 13894
e8b05380
PB
13895fi
13896fi
1c710c3c 13897GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
e8b05380 13898if test -n "$GFORTRAN_FOR_TARGET"; then
5213506e
RW
13899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
13900$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
e8b05380 13901else
5213506e
RW
13902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13903$as_echo "no" >&6; }
e8b05380
PB
13904fi
13905
5213506e 13906
e8b05380
PB
13907 fi
13908 if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test $build = $target ; then
13909 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13910set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
13911{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13912$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13913if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
5213506e 13914 $as_echo_n "(cached) " >&6
e8b05380
PB
13915else
13916 if test -n "$GFORTRAN_FOR_TARGET"; then
13917 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
13918else
1c710c3c
DJ
13919as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13920for as_dir in $PATH
13921do
13922 IFS=$as_save_IFS
13923 test -z "$as_dir" && as_dir=.
5213506e 13924 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13925 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 13926 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
5213506e 13927 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
13928 break 2
13929 fi
13930done
5213506e
RW
13931 done
13932IFS=$as_save_IFS
1c710c3c 13933
e8b05380
PB
13934fi
13935fi
1c710c3c 13936GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
e8b05380 13937if test -n "$GFORTRAN_FOR_TARGET"; then
5213506e
RW
13938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
13939$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
e8b05380 13940else
5213506e
RW
13941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13942$as_echo "no" >&6; }
e8b05380 13943fi
1c710c3c 13944
5213506e 13945
e8b05380
PB
13946 fi
13947 test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET" && break
13948 done
13949fi
1c710c3c 13950
e8b05380
PB
13951if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" ; then
13952 set dummy gfortran
2693c0b0 13953 if test $build = $target ; then
e8b05380 13954 GFORTRAN_FOR_TARGET="$2"
ca9f4b81 13955 else
e8b05380
PB
13956 GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}$2"
13957 fi
1c00b503
PB
13958else
13959 GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
e8b05380
PB
13960fi
13961
13962
13963
632e2a07
ILT
13964if test -n "$GOC_FOR_TARGET"; then
13965 ac_cv_prog_GOC_FOR_TARGET=$GOC_FOR_TARGET
13966elif test -n "$ac_cv_prog_GOC_FOR_TARGET"; then
13967 GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
13968fi
13969
13970if test -n "$ac_cv_prog_GOC_FOR_TARGET"; then
13971 for ncn_progname in gccgo; do
13972 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
13973set dummy ${ncn_progname}; ac_word=$2
13974{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13975$as_echo_n "checking for $ac_word... " >&6; }
22e05272 13976if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
632e2a07
ILT
13977 $as_echo_n "(cached) " >&6
13978else
13979 if test -n "$GOC_FOR_TARGET"; then
13980 ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
13981else
13982as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13983for as_dir in $PATH
13984do
13985 IFS=$as_save_IFS
13986 test -z "$as_dir" && as_dir=.
13987 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 13988 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
632e2a07
ILT
13989 ac_cv_prog_GOC_FOR_TARGET="${ncn_progname}"
13990 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13991 break 2
13992 fi
13993done
13994 done
13995IFS=$as_save_IFS
13996
13997fi
13998fi
13999GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
14000if test -n "$GOC_FOR_TARGET"; then
14001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
14002$as_echo "$GOC_FOR_TARGET" >&6; }
14003else
14004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14005$as_echo "no" >&6; }
14006fi
14007
14008
14009 done
14010fi
14011
14012if test -z "$ac_cv_prog_GOC_FOR_TARGET" && test -n "$with_build_time_tools"; then
14013 for ncn_progname in gccgo; do
14014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14015$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
14016 if test -x $with_build_time_tools/${ncn_progname}; then
14017 ac_cv_prog_GOC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
14018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14019$as_echo "yes" >&6; }
14020 break
14021 else
14022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14023$as_echo "no" >&6; }
14024 fi
14025 done
14026fi
14027
14028if test -z "$ac_cv_prog_GOC_FOR_TARGET"; then
14029 for ncn_progname in gccgo; do
14030 if test -n "$ncn_target_tool_prefix"; then
14031 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14032set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
14033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14034$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14035if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
632e2a07
ILT
14036 $as_echo_n "(cached) " >&6
14037else
14038 if test -n "$GOC_FOR_TARGET"; then
14039 ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
14040else
14041as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14042for as_dir in $PATH
14043do
14044 IFS=$as_save_IFS
14045 test -z "$as_dir" && as_dir=.
14046 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14047 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
632e2a07
ILT
14048 ac_cv_prog_GOC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
14049 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14050 break 2
14051 fi
14052done
14053 done
14054IFS=$as_save_IFS
14055
14056fi
14057fi
14058GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
14059if test -n "$GOC_FOR_TARGET"; then
14060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
14061$as_echo "$GOC_FOR_TARGET" >&6; }
14062else
14063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14064$as_echo "no" >&6; }
14065fi
14066
14067
14068 fi
14069 if test -z "$ac_cv_prog_GOC_FOR_TARGET" && test $build = $target ; then
14070 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14071set dummy ${ncn_progname}; ac_word=$2
14072{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14073$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14074if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
632e2a07
ILT
14075 $as_echo_n "(cached) " >&6
14076else
14077 if test -n "$GOC_FOR_TARGET"; then
14078 ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
14079else
14080as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14081for as_dir in $PATH
14082do
14083 IFS=$as_save_IFS
14084 test -z "$as_dir" && as_dir=.
14085 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14086 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
632e2a07
ILT
14087 ac_cv_prog_GOC_FOR_TARGET="${ncn_progname}"
14088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14089 break 2
14090 fi
14091done
14092 done
14093IFS=$as_save_IFS
14094
14095fi
14096fi
14097GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
14098if test -n "$GOC_FOR_TARGET"; then
14099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
14100$as_echo "$GOC_FOR_TARGET" >&6; }
14101else
14102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14103$as_echo "no" >&6; }
14104fi
14105
14106
14107 fi
14108 test -n "$ac_cv_prog_GOC_FOR_TARGET" && break
14109 done
14110fi
14111
14112if test -z "$ac_cv_prog_GOC_FOR_TARGET" ; then
14113 set dummy gccgo
14114 if test $build = $target ; then
14115 GOC_FOR_TARGET="$2"
14116 else
14117 GOC_FOR_TARGET="${ncn_target_tool_prefix}$2"
14118 fi
14119else
14120 GOC_FOR_TARGET="$ac_cv_prog_GOC_FOR_TARGET"
14121fi
14122
14123
14124
b4c522fa
IB
14125if test -n "$GDC_FOR_TARGET"; then
14126 ac_cv_prog_GDC_FOR_TARGET=$GDC_FOR_TARGET
14127elif test -n "$ac_cv_prog_GDC_FOR_TARGET"; then
14128 GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
14129fi
14130
14131if test -n "$ac_cv_prog_GDC_FOR_TARGET"; then
14132 for ncn_progname in gdc; do
14133 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14134set dummy ${ncn_progname}; ac_word=$2
14135{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14136$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14137if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
b4c522fa
IB
14138 $as_echo_n "(cached) " >&6
14139else
14140 if test -n "$GDC_FOR_TARGET"; then
14141 ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
14142else
14143as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14144for as_dir in $PATH
14145do
14146 IFS=$as_save_IFS
14147 test -z "$as_dir" && as_dir=.
14148 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14149 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b4c522fa
IB
14150 ac_cv_prog_GDC_FOR_TARGET="${ncn_progname}"
14151 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14152 break 2
14153 fi
14154done
14155 done
14156IFS=$as_save_IFS
14157
14158fi
14159fi
14160GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
14161if test -n "$GDC_FOR_TARGET"; then
14162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
14163$as_echo "$GDC_FOR_TARGET" >&6; }
14164else
14165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14166$as_echo "no" >&6; }
14167fi
14168
14169
14170 done
14171fi
14172
14173if test -z "$ac_cv_prog_GDC_FOR_TARGET" && test -n "$with_build_time_tools"; then
14174 for ncn_progname in gdc; do
14175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14176$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
14177 if test -x $with_build_time_tools/${ncn_progname}; then
14178 ac_cv_prog_GDC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
14179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14180$as_echo "yes" >&6; }
14181 break
14182 else
14183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14184$as_echo "no" >&6; }
14185 fi
14186 done
14187fi
14188
14189if test -z "$ac_cv_prog_GDC_FOR_TARGET"; then
14190 for ncn_progname in gdc; do
14191 if test -n "$ncn_target_tool_prefix"; then
14192 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14193set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
14194{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14195$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14196if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
b4c522fa
IB
14197 $as_echo_n "(cached) " >&6
14198else
14199 if test -n "$GDC_FOR_TARGET"; then
14200 ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
14201else
14202as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14203for as_dir in $PATH
14204do
14205 IFS=$as_save_IFS
14206 test -z "$as_dir" && as_dir=.
14207 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14208 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b4c522fa
IB
14209 ac_cv_prog_GDC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
14210 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14211 break 2
14212 fi
14213done
14214 done
14215IFS=$as_save_IFS
14216
14217fi
14218fi
14219GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
14220if test -n "$GDC_FOR_TARGET"; then
14221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
14222$as_echo "$GDC_FOR_TARGET" >&6; }
14223else
14224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14225$as_echo "no" >&6; }
14226fi
14227
14228
14229 fi
14230 if test -z "$ac_cv_prog_GDC_FOR_TARGET" && test $build = $target ; then
14231 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14232set dummy ${ncn_progname}; ac_word=$2
14233{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14234$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14235if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
b4c522fa
IB
14236 $as_echo_n "(cached) " >&6
14237else
14238 if test -n "$GDC_FOR_TARGET"; then
14239 ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
14240else
14241as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14242for as_dir in $PATH
14243do
14244 IFS=$as_save_IFS
14245 test -z "$as_dir" && as_dir=.
14246 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14247 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
b4c522fa
IB
14248 ac_cv_prog_GDC_FOR_TARGET="${ncn_progname}"
14249 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14250 break 2
14251 fi
14252done
14253 done
14254IFS=$as_save_IFS
14255
14256fi
14257fi
14258GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
14259if test -n "$GDC_FOR_TARGET"; then
14260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
14261$as_echo "$GDC_FOR_TARGET" >&6; }
14262else
14263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14264$as_echo "no" >&6; }
14265fi
14266
14267
14268 fi
14269 test -n "$ac_cv_prog_GDC_FOR_TARGET" && break
14270 done
14271fi
14272
14273if test -z "$ac_cv_prog_GDC_FOR_TARGET" ; then
14274 set dummy gdc
14275 if test $build = $target ; then
14276 GDC_FOR_TARGET="$2"
14277 else
14278 GDC_FOR_TARGET="${ncn_target_tool_prefix}$2"
14279 fi
14280else
14281 GDC_FOR_TARGET="$ac_cv_prog_GDC_FOR_TARGET"
14282fi
14283
14284
14285
1eee94d3
GM
14286if test -n "$GM2_FOR_TARGET"; then
14287 ac_cv_prog_GM2_FOR_TARGET=$GM2_FOR_TARGET
14288elif test -n "$ac_cv_prog_GM2_FOR_TARGET"; then
14289 GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
14290fi
14291
14292if test -n "$ac_cv_prog_GM2_FOR_TARGET"; then
14293 for ncn_progname in gm2; do
14294 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14295set dummy ${ncn_progname}; ac_word=$2
14296{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14297$as_echo_n "checking for $ac_word... " >&6; }
14298if ${ac_cv_prog_GM2_FOR_TARGET+:} false; then :
14299 $as_echo_n "(cached) " >&6
14300else
14301 if test -n "$GM2_FOR_TARGET"; then
14302 ac_cv_prog_GM2_FOR_TARGET="$GM2_FOR_TARGET" # Let the user override the test.
14303else
14304as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14305for as_dir in $PATH
14306do
14307 IFS=$as_save_IFS
14308 test -z "$as_dir" && as_dir=.
14309 for ac_exec_ext in '' $ac_executable_extensions; do
14310 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14311 ac_cv_prog_GM2_FOR_TARGET="${ncn_progname}"
14312 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14313 break 2
14314 fi
14315done
14316 done
14317IFS=$as_save_IFS
14318
14319fi
14320fi
14321GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
14322if test -n "$GM2_FOR_TARGET"; then
14323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GM2_FOR_TARGET" >&5
14324$as_echo "$GM2_FOR_TARGET" >&6; }
14325else
14326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14327$as_echo "no" >&6; }
14328fi
14329
14330
14331 done
14332fi
14333
14334if test -z "$ac_cv_prog_GM2_FOR_TARGET" && test -n "$with_build_time_tools"; then
14335 for ncn_progname in gm2; do
14336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14337$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
14338 if test -x $with_build_time_tools/${ncn_progname}; then
14339 ac_cv_prog_GM2_FOR_TARGET=$with_build_time_tools/${ncn_progname}
14340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14341$as_echo "yes" >&6; }
14342 break
14343 else
14344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14345$as_echo "no" >&6; }
14346 fi
14347 done
14348fi
14349
14350if test -z "$ac_cv_prog_GM2_FOR_TARGET"; then
14351 for ncn_progname in gm2; do
14352 if test -n "$ncn_target_tool_prefix"; then
14353 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14354set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
14355{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14356$as_echo_n "checking for $ac_word... " >&6; }
14357if ${ac_cv_prog_GM2_FOR_TARGET+:} false; then :
14358 $as_echo_n "(cached) " >&6
14359else
14360 if test -n "$GM2_FOR_TARGET"; then
14361 ac_cv_prog_GM2_FOR_TARGET="$GM2_FOR_TARGET" # Let the user override the test.
14362else
14363as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14364for as_dir in $PATH
14365do
14366 IFS=$as_save_IFS
14367 test -z "$as_dir" && as_dir=.
14368 for ac_exec_ext in '' $ac_executable_extensions; do
14369 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14370 ac_cv_prog_GM2_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
14371 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14372 break 2
14373 fi
14374done
14375 done
14376IFS=$as_save_IFS
14377
14378fi
14379fi
14380GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
14381if test -n "$GM2_FOR_TARGET"; then
14382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GM2_FOR_TARGET" >&5
14383$as_echo "$GM2_FOR_TARGET" >&6; }
14384else
14385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14386$as_echo "no" >&6; }
14387fi
14388
14389
14390 fi
14391 if test -z "$ac_cv_prog_GM2_FOR_TARGET" && test $build = $target ; then
14392 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14393set dummy ${ncn_progname}; ac_word=$2
14394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14395$as_echo_n "checking for $ac_word... " >&6; }
14396if ${ac_cv_prog_GM2_FOR_TARGET+:} false; then :
14397 $as_echo_n "(cached) " >&6
14398else
14399 if test -n "$GM2_FOR_TARGET"; then
14400 ac_cv_prog_GM2_FOR_TARGET="$GM2_FOR_TARGET" # Let the user override the test.
14401else
14402as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14403for as_dir in $PATH
14404do
14405 IFS=$as_save_IFS
14406 test -z "$as_dir" && as_dir=.
14407 for ac_exec_ext in '' $ac_executable_extensions; do
14408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14409 ac_cv_prog_GM2_FOR_TARGET="${ncn_progname}"
14410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14411 break 2
14412 fi
14413done
14414 done
14415IFS=$as_save_IFS
14416
14417fi
14418fi
14419GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
14420if test -n "$GM2_FOR_TARGET"; then
14421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GM2_FOR_TARGET" >&5
14422$as_echo "$GM2_FOR_TARGET" >&6; }
14423else
14424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14425$as_echo "no" >&6; }
14426fi
14427
14428
14429 fi
14430 test -n "$ac_cv_prog_GM2_FOR_TARGET" && break
14431 done
14432fi
14433
14434if test -z "$ac_cv_prog_GM2_FOR_TARGET" ; then
14435 set dummy gm2
14436 if test $build = $target ; then
14437 GM2_FOR_TARGET="$2"
14438 else
14439 GM2_FOR_TARGET="${ncn_target_tool_prefix}$2"
14440 fi
14441else
14442 GM2_FOR_TARGET="$ac_cv_prog_GM2_FOR_TARGET"
14443fi
14444
14445
14446
e8b05380
PB
14447cat > conftest.c << \EOF
14448#ifdef __GNUC__
14449 gcc_yay;
14450#endif
14451EOF
14452if ($GCC_FOR_TARGET -E conftest.c | grep gcc_yay) > /dev/null 2>&1; then
14453 have_gcc_for_target=yes
14454else
14455 GCC_FOR_TARGET=${ncn_target_tool_prefix}gcc
14456 have_gcc_for_target=no
14457fi
14458rm conftest.c
14459
14460
14461
14462
14463if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
14464 if test -n "$with_build_time_tools"; then
5213506e
RW
14465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ar in $with_build_time_tools" >&5
14466$as_echo_n "checking for ar in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14467 if test -x $with_build_time_tools/ar; then
14468 AR_FOR_TARGET=`cd $with_build_time_tools && pwd`/ar
14469 ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
5213506e
RW
14470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_AR_FOR_TARGET" >&5
14471$as_echo "$ac_cv_path_AR_FOR_TARGET" >&6; }
d1f8db0c 14472 else
5213506e
RW
14473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14474$as_echo "no" >&6; }
d1f8db0c 14475 fi
e8b05380
PB
14476 elif test $build != $host && test $have_gcc_for_target = yes; then
14477 AR_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ar`
1c00b503
PB
14478 test $AR_FOR_TARGET = ar && AR_FOR_TARGET=
14479 test -n "$AR_FOR_TARGET" && ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
e8b05380
PB
14480 fi
14481fi
3e19841a 14482if test -z "$ac_cv_path_AR_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
14483 # Extract the first word of "ar", so it can be a program name with args.
14484set dummy ar; ac_word=$2
5213506e
RW
14485{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14486$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14487if ${ac_cv_path_AR_FOR_TARGET+:} false; then :
5213506e 14488 $as_echo_n "(cached) " >&6
e8b05380 14489else
1c710c3c
DJ
14490 case $AR_FOR_TARGET in
14491 [\\/]* | ?:[\\/]*)
e8b05380
PB
14492 ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
14493 ;;
e8b05380 14494 *)
1c710c3c
DJ
14495 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14496for as_dir in $gcc_cv_tool_dirs
14497do
14498 IFS=$as_save_IFS
14499 test -z "$as_dir" && as_dir=.
5213506e 14500 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14501 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14502 ac_cv_path_AR_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 14503 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14504 break 2
14505 fi
14506done
5213506e
RW
14507 done
14508IFS=$as_save_IFS
1c710c3c 14509
e8b05380
PB
14510 ;;
14511esac
14512fi
1c710c3c 14513AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
e8b05380 14514if test -n "$AR_FOR_TARGET"; then
5213506e
RW
14515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
14516$as_echo "$AR_FOR_TARGET" >&6; }
e8b05380 14517else
5213506e
RW
14518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14519$as_echo "no" >&6; }
4de997d1
PB
14520fi
14521
5213506e 14522
e8b05380
PB
14523fi
14524if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
278a7a38
AO
14525
14526
14527if test -n "$AR_FOR_TARGET"; then
14528 ac_cv_prog_AR_FOR_TARGET=$AR_FOR_TARGET
14529elif test -n "$ac_cv_prog_AR_FOR_TARGET"; then
14530 AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
14531fi
14532
14533if test -n "$ac_cv_prog_AR_FOR_TARGET"; then
14534 for ncn_progname in ar; do
14535 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14536set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14537{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14538$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14539if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
5213506e 14540 $as_echo_n "(cached) " >&6
278a7a38
AO
14541else
14542 if test -n "$AR_FOR_TARGET"; then
14543 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
14544else
14545as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14546for as_dir in $PATH
14547do
14548 IFS=$as_save_IFS
14549 test -z "$as_dir" && as_dir=.
5213506e 14550 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14551 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 14552 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
5213506e 14553 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
14554 break 2
14555 fi
14556done
5213506e
RW
14557 done
14558IFS=$as_save_IFS
278a7a38
AO
14559
14560fi
14561fi
14562AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
14563if test -n "$AR_FOR_TARGET"; then
5213506e
RW
14564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
14565$as_echo "$AR_FOR_TARGET" >&6; }
278a7a38 14566else
5213506e
RW
14567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14568$as_echo "no" >&6; }
278a7a38
AO
14569fi
14570
5213506e 14571
278a7a38
AO
14572 done
14573fi
14574
14575if test -z "$ac_cv_prog_AR_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 14576 for ncn_progname in ar; do
5213506e
RW
14577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14578$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14579 if test -x $with_build_time_tools/${ncn_progname}; then
14580 ac_cv_prog_AR_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
14581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14582$as_echo "yes" >&6; }
e8b05380
PB
14583 break
14584 else
5213506e
RW
14585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14586$as_echo "no" >&6; }
e8b05380
PB
14587 fi
14588 done
14589fi
14590
14591if test -z "$ac_cv_prog_AR_FOR_TARGET"; then
14592 for ncn_progname in ar; do
14593 if test -n "$ncn_target_tool_prefix"; then
14594 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 14595set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
14596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14597$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14598if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
5213506e 14599 $as_echo_n "(cached) " >&6
4de997d1 14600else
e8b05380
PB
14601 if test -n "$AR_FOR_TARGET"; then
14602 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
4de997d1 14603else
1c710c3c
DJ
14604as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14605for as_dir in $PATH
14606do
14607 IFS=$as_save_IFS
14608 test -z "$as_dir" && as_dir=.
5213506e 14609 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14611 ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 14612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14613 break 2
14614 fi
14615done
5213506e
RW
14616 done
14617IFS=$as_save_IFS
1c710c3c 14618
4de997d1
PB
14619fi
14620fi
1c710c3c 14621AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
e8b05380 14622if test -n "$AR_FOR_TARGET"; then
5213506e
RW
14623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
14624$as_echo "$AR_FOR_TARGET" >&6; }
4de997d1 14625else
5213506e
RW
14626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14627$as_echo "no" >&6; }
4de997d1
PB
14628fi
14629
5213506e 14630
e8b05380
PB
14631 fi
14632 if test -z "$ac_cv_prog_AR_FOR_TARGET" && test $build = $target ; then
14633 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14634set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14635{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14636$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14637if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
5213506e 14638 $as_echo_n "(cached) " >&6
e8b05380
PB
14639else
14640 if test -n "$AR_FOR_TARGET"; then
14641 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
14642else
1c710c3c
DJ
14643as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14644for as_dir in $PATH
14645do
14646 IFS=$as_save_IFS
14647 test -z "$as_dir" && as_dir=.
5213506e 14648 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14649 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14650 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
5213506e 14651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14652 break 2
14653 fi
14654done
5213506e
RW
14655 done
14656IFS=$as_save_IFS
1c710c3c 14657
e8b05380
PB
14658fi
14659fi
1c710c3c 14660AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
e8b05380 14661if test -n "$AR_FOR_TARGET"; then
5213506e
RW
14662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
14663$as_echo "$AR_FOR_TARGET" >&6; }
e8b05380 14664else
5213506e
RW
14665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14666$as_echo "no" >&6; }
e8b05380 14667fi
1c710c3c 14668
5213506e 14669
e8b05380
PB
14670 fi
14671 test -n "$ac_cv_prog_AR_FOR_TARGET" && break
14672 done
14673fi
1c710c3c 14674
e8b05380
PB
14675if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
14676 set dummy ar
14677 if test $build = $target ; then
14678 AR_FOR_TARGET="$2"
14679 else
14680 AR_FOR_TARGET="${ncn_target_tool_prefix}$2"
2693c0b0 14681 fi
1c00b503
PB
14682else
14683 AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
e8b05380
PB
14684fi
14685
d1f8db0c
PB
14686else
14687 AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
e8b05380
PB
14688fi
14689
14690
14691
14692
14693if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
14694 if test -n "$with_build_time_tools"; then
5213506e
RW
14695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for as in $with_build_time_tools" >&5
14696$as_echo_n "checking for as in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14697 if test -x $with_build_time_tools/as; then
14698 AS_FOR_TARGET=`cd $with_build_time_tools && pwd`/as
14699 ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
5213506e
RW
14700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_AS_FOR_TARGET" >&5
14701$as_echo "$ac_cv_path_AS_FOR_TARGET" >&6; }
d1f8db0c 14702 else
5213506e
RW
14703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14704$as_echo "no" >&6; }
d1f8db0c 14705 fi
e8b05380
PB
14706 elif test $build != $host && test $have_gcc_for_target = yes; then
14707 AS_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=as`
1c00b503
PB
14708 test $AS_FOR_TARGET = as && AS_FOR_TARGET=
14709 test -n "$AS_FOR_TARGET" && ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
e8b05380
PB
14710 fi
14711fi
3e19841a 14712if test -z "$ac_cv_path_AS_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
14713 # Extract the first word of "as", so it can be a program name with args.
14714set dummy as; ac_word=$2
5213506e
RW
14715{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14716$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14717if ${ac_cv_path_AS_FOR_TARGET+:} false; then :
5213506e 14718 $as_echo_n "(cached) " >&6
e8b05380 14719else
1c710c3c
DJ
14720 case $AS_FOR_TARGET in
14721 [\\/]* | ?:[\\/]*)
e8b05380
PB
14722 ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
14723 ;;
e8b05380 14724 *)
1c710c3c
DJ
14725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14726for as_dir in $gcc_cv_tool_dirs
14727do
14728 IFS=$as_save_IFS
14729 test -z "$as_dir" && as_dir=.
5213506e 14730 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14731 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14732 ac_cv_path_AS_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 14733 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14734 break 2
14735 fi
14736done
5213506e
RW
14737 done
14738IFS=$as_save_IFS
1c710c3c 14739
e8b05380
PB
14740 ;;
14741esac
14742fi
1c710c3c 14743AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
e8b05380 14744if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14746$as_echo "$AS_FOR_TARGET" >&6; }
e8b05380 14747else
5213506e
RW
14748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14749$as_echo "no" >&6; }
e8b05380
PB
14750fi
14751
5213506e 14752
e8b05380
PB
14753fi
14754if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
278a7a38
AO
14755
14756
14757if test -n "$AS_FOR_TARGET"; then
14758 ac_cv_prog_AS_FOR_TARGET=$AS_FOR_TARGET
14759elif test -n "$ac_cv_prog_AS_FOR_TARGET"; then
14760 AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
14761fi
14762
14763if test -n "$ac_cv_prog_AS_FOR_TARGET"; then
14764 for ncn_progname in as; do
14765 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14766set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14767{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14768$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14769if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
5213506e 14770 $as_echo_n "(cached) " >&6
278a7a38
AO
14771else
14772 if test -n "$AS_FOR_TARGET"; then
14773 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
14774else
14775as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14776for as_dir in $PATH
14777do
14778 IFS=$as_save_IFS
14779 test -z "$as_dir" && as_dir=.
5213506e 14780 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14781 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 14782 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
5213506e 14783 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
14784 break 2
14785 fi
14786done
5213506e
RW
14787 done
14788IFS=$as_save_IFS
278a7a38
AO
14789
14790fi
14791fi
14792AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
14793if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14795$as_echo "$AS_FOR_TARGET" >&6; }
278a7a38 14796else
5213506e
RW
14797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14798$as_echo "no" >&6; }
278a7a38
AO
14799fi
14800
5213506e 14801
278a7a38
AO
14802 done
14803fi
14804
14805if test -z "$ac_cv_prog_AS_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 14806 for ncn_progname in as; do
5213506e
RW
14807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
14808$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14809 if test -x $with_build_time_tools/${ncn_progname}; then
14810 ac_cv_prog_AS_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
14811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14812$as_echo "yes" >&6; }
e8b05380
PB
14813 break
14814 else
5213506e
RW
14815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14816$as_echo "no" >&6; }
e8b05380
PB
14817 fi
14818 done
14819fi
14820
14821if test -z "$ac_cv_prog_AS_FOR_TARGET"; then
14822 for ncn_progname in as; do
14823 if test -n "$ncn_target_tool_prefix"; then
14824 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
14825set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
14826{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14827$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14828if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
5213506e 14829 $as_echo_n "(cached) " >&6
e8b05380
PB
14830else
14831 if test -n "$AS_FOR_TARGET"; then
14832 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
14833else
1c710c3c
DJ
14834as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14835for as_dir in $PATH
14836do
14837 IFS=$as_save_IFS
14838 test -z "$as_dir" && as_dir=.
5213506e 14839 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14840 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14841 ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 14842 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14843 break 2
14844 fi
14845done
5213506e
RW
14846 done
14847IFS=$as_save_IFS
1c710c3c 14848
e8b05380
PB
14849fi
14850fi
1c710c3c 14851AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
e8b05380 14852if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14854$as_echo "$AS_FOR_TARGET" >&6; }
e8b05380 14855else
5213506e
RW
14856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14857$as_echo "no" >&6; }
e8b05380
PB
14858fi
14859
5213506e 14860
e8b05380
PB
14861 fi
14862 if test -z "$ac_cv_prog_AS_FOR_TARGET" && test $build = $target ; then
14863 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 14864set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14865{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14866$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14867if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
5213506e 14868 $as_echo_n "(cached) " >&6
4de997d1 14869else
e8b05380
PB
14870 if test -n "$AS_FOR_TARGET"; then
14871 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
4de997d1 14872else
1c710c3c
DJ
14873as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14874for as_dir in $PATH
14875do
14876 IFS=$as_save_IFS
14877 test -z "$as_dir" && as_dir=.
5213506e 14878 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14879 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14880 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
5213506e 14881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14882 break 2
14883 fi
14884done
5213506e
RW
14885 done
14886IFS=$as_save_IFS
1c710c3c 14887
4de997d1
PB
14888fi
14889fi
1c710c3c 14890AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
e8b05380 14891if test -n "$AS_FOR_TARGET"; then
5213506e
RW
14892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
14893$as_echo "$AS_FOR_TARGET" >&6; }
4de997d1 14894else
5213506e
RW
14895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14896$as_echo "no" >&6; }
4de997d1 14897fi
1c710c3c 14898
5213506e 14899
e8b05380
PB
14900 fi
14901 test -n "$ac_cv_prog_AS_FOR_TARGET" && break
14902 done
14903fi
1c710c3c 14904
e8b05380
PB
14905if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
14906 set dummy as
14907 if test $build = $target ; then
14908 AS_FOR_TARGET="$2"
14909 else
14910 AS_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 14911 fi
1c00b503
PB
14912else
14913 AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
e8b05380 14914fi
2693c0b0 14915
d1f8db0c
PB
14916else
14917 AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
4de997d1
PB
14918fi
14919
e8b05380
PB
14920
14921
14922
14923if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
14924 if test -n "$with_build_time_tools"; then
5213506e
RW
14925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlltool in $with_build_time_tools" >&5
14926$as_echo_n "checking for dlltool in $with_build_time_tools... " >&6; }
d1f8db0c
PB
14927 if test -x $with_build_time_tools/dlltool; then
14928 DLLTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dlltool
14929 ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
5213506e
RW
14930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DLLTOOL_FOR_TARGET" >&5
14931$as_echo "$ac_cv_path_DLLTOOL_FOR_TARGET" >&6; }
d1f8db0c 14932 else
5213506e
RW
14933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14934$as_echo "no" >&6; }
d1f8db0c 14935 fi
e8b05380
PB
14936 elif test $build != $host && test $have_gcc_for_target = yes; then
14937 DLLTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dlltool`
1c00b503
PB
14938 test $DLLTOOL_FOR_TARGET = dlltool && DLLTOOL_FOR_TARGET=
14939 test -n "$DLLTOOL_FOR_TARGET" && ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
e8b05380
PB
14940 fi
14941fi
3e19841a 14942if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
14943 # Extract the first word of "dlltool", so it can be a program name with args.
14944set dummy dlltool; ac_word=$2
5213506e
RW
14945{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14946$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14947if ${ac_cv_path_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 14948 $as_echo_n "(cached) " >&6
4de997d1 14949else
1c710c3c
DJ
14950 case $DLLTOOL_FOR_TARGET in
14951 [\\/]* | ?:[\\/]*)
e8b05380
PB
14952 ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a path.
14953 ;;
e8b05380 14954 *)
1c710c3c
DJ
14955 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14956for as_dir in $gcc_cv_tool_dirs
14957do
14958 IFS=$as_save_IFS
14959 test -z "$as_dir" && as_dir=.
5213506e 14960 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 14961 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 14962 ac_cv_path_DLLTOOL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 14963 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
14964 break 2
14965 fi
14966done
5213506e
RW
14967 done
14968IFS=$as_save_IFS
1c710c3c 14969
e8b05380
PB
14970 ;;
14971esac
4de997d1 14972fi
1c710c3c 14973DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
e8b05380 14974if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
14975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
14976$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
4de997d1 14977else
5213506e
RW
14978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14979$as_echo "no" >&6; }
4de997d1
PB
14980fi
14981
5213506e 14982
e8b05380
PB
14983fi
14984if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
278a7a38
AO
14985
14986
14987if test -n "$DLLTOOL_FOR_TARGET"; then
14988 ac_cv_prog_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
14989elif test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
14990 DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
14991fi
14992
14993if test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
14994 for ncn_progname in dlltool; do
14995 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
14996set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
14997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14998$as_echo_n "checking for $ac_word... " >&6; }
22e05272 14999if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 15000 $as_echo_n "(cached) " >&6
278a7a38
AO
15001else
15002 if test -n "$DLLTOOL_FOR_TARGET"; then
15003 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
15004else
15005as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15006for as_dir in $PATH
15007do
15008 IFS=$as_save_IFS
15009 test -z "$as_dir" && as_dir=.
5213506e 15010 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15012 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
5213506e 15013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15014 break 2
15015 fi
15016done
5213506e
RW
15017 done
15018IFS=$as_save_IFS
278a7a38
AO
15019
15020fi
15021fi
15022DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
15023if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
15024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
15025$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
278a7a38 15026else
5213506e
RW
15027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15028$as_echo "no" >&6; }
278a7a38
AO
15029fi
15030
5213506e 15031
278a7a38
AO
15032 done
15033fi
15034
15035if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15036 for ncn_progname in dlltool; do
5213506e
RW
15037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15038$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15039 if test -x $with_build_time_tools/${ncn_progname}; then
15040 ac_cv_prog_DLLTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15042$as_echo "yes" >&6; }
e8b05380
PB
15043 break
15044 else
5213506e
RW
15045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15046$as_echo "no" >&6; }
e8b05380
PB
15047 fi
15048 done
15049fi
15050
15051if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
15052 for ncn_progname in dlltool; do
15053 if test -n "$ncn_target_tool_prefix"; then
15054 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
15055set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15056{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15057$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15058if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 15059 $as_echo_n "(cached) " >&6
4de997d1 15060else
e8b05380
PB
15061 if test -n "$DLLTOOL_FOR_TARGET"; then
15062 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 15063else
1c710c3c
DJ
15064as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15065for as_dir in $PATH
15066do
15067 IFS=$as_save_IFS
15068 test -z "$as_dir" && as_dir=.
5213506e 15069 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15070 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15071 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15072 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15073 break 2
15074 fi
15075done
5213506e
RW
15076 done
15077IFS=$as_save_IFS
1c710c3c 15078
4de997d1
PB
15079fi
15080fi
1c710c3c 15081DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
e8b05380 15082if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
15083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
15084$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
4de997d1 15085else
5213506e
RW
15086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15087$as_echo "no" >&6; }
4de997d1 15088fi
4de997d1 15089
5213506e 15090
e8b05380
PB
15091 fi
15092 if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test $build = $target ; then
15093 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15094set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15095{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15096$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15097if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
5213506e 15098 $as_echo_n "(cached) " >&6
4de997d1 15099else
e8b05380
PB
15100 if test -n "$DLLTOOL_FOR_TARGET"; then
15101 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 15102else
1c710c3c
DJ
15103as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15104for as_dir in $PATH
15105do
15106 IFS=$as_save_IFS
15107 test -z "$as_dir" && as_dir=.
5213506e 15108 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15109 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15110 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
5213506e 15111 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15112 break 2
15113 fi
15114done
5213506e
RW
15115 done
15116IFS=$as_save_IFS
1c710c3c 15117
4de997d1
PB
15118fi
15119fi
1c710c3c 15120DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
e8b05380 15121if test -n "$DLLTOOL_FOR_TARGET"; then
5213506e
RW
15122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
15123$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
4de997d1 15124else
5213506e
RW
15125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15126$as_echo "no" >&6; }
4de997d1 15127fi
1c710c3c 15128
5213506e 15129
e8b05380
PB
15130 fi
15131 test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET" && break
15132 done
15133fi
1c710c3c 15134
e8b05380
PB
15135if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
15136 set dummy dlltool
15137 if test $build = $target ; then
15138 DLLTOOL_FOR_TARGET="$2"
15139 else
15140 DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
15141 fi
1c00b503
PB
15142else
15143 DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
e8b05380
PB
15144fi
15145
d1f8db0c
PB
15146else
15147 DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
e8b05380
PB
15148fi
15149
4de997d1 15150
e8b05380
PB
15151
15152
3b5e8ee4
IS
15153if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
15154 if test -n "$with_build_time_tools"; then
15155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dsymutil in $with_build_time_tools" >&5
15156$as_echo_n "checking for dsymutil in $with_build_time_tools... " >&6; }
15157 if test -x $with_build_time_tools/dsymutil; then
15158 DSYMUTIL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dsymutil
15159 ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
15160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DSYMUTIL_FOR_TARGET" >&5
15161$as_echo "$ac_cv_path_DSYMUTIL_FOR_TARGET" >&6; }
15162 else
15163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15164$as_echo "no" >&6; }
15165 fi
15166 elif test $build != $host && test $have_gcc_for_target = yes; then
15167 DSYMUTIL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dsymutil`
15168 test $DSYMUTIL_FOR_TARGET = dsymutil && DSYMUTIL_FOR_TARGET=
15169 test -n "$DSYMUTIL_FOR_TARGET" && ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
15170 fi
15171fi
15172if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
15173 # Extract the first word of "dsymutil", so it can be a program name with args.
15174set dummy dsymutil; ac_word=$2
15175{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15176$as_echo_n "checking for $ac_word... " >&6; }
15177if ${ac_cv_path_DSYMUTIL_FOR_TARGET+:} false; then :
15178 $as_echo_n "(cached) " >&6
15179else
15180 case $DSYMUTIL_FOR_TARGET in
15181 [\\/]* | ?:[\\/]*)
15182 ac_cv_path_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test with a path.
15183 ;;
15184 *)
15185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15186for as_dir in $gcc_cv_tool_dirs
15187do
15188 IFS=$as_save_IFS
15189 test -z "$as_dir" && as_dir=.
15190 for ac_exec_ext in '' $ac_executable_extensions; do
15191 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15192 ac_cv_path_DSYMUTIL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
15193 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15194 break 2
15195 fi
15196done
15197 done
15198IFS=$as_save_IFS
15199
15200 ;;
15201esac
15202fi
15203DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
15204if test -n "$DSYMUTIL_FOR_TARGET"; then
15205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
15206$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
15207else
15208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15209$as_echo "no" >&6; }
15210fi
15211
15212
15213fi
15214if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
15215
15216
15217if test -n "$DSYMUTIL_FOR_TARGET"; then
15218 ac_cv_prog_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
15219elif test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
15220 DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
15221fi
15222
15223if test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
15224 for ncn_progname in dsymutil; do
15225 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15226set dummy ${ncn_progname}; ac_word=$2
15227{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15228$as_echo_n "checking for $ac_word... " >&6; }
15229if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
15230 $as_echo_n "(cached) " >&6
15231else
15232 if test -n "$DSYMUTIL_FOR_TARGET"; then
15233 ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
15234else
15235as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15236for as_dir in $PATH
15237do
15238 IFS=$as_save_IFS
15239 test -z "$as_dir" && as_dir=.
15240 for ac_exec_ext in '' $ac_executable_extensions; do
15241 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15242 ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
15243 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15244 break 2
15245 fi
15246done
15247 done
15248IFS=$as_save_IFS
15249
15250fi
15251fi
15252DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
15253if test -n "$DSYMUTIL_FOR_TARGET"; then
15254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
15255$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
15256else
15257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15258$as_echo "no" >&6; }
15259fi
15260
15261
15262 done
15263fi
15264
15265if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test -n "$with_build_time_tools"; then
15266 for ncn_progname in dsymutil; do
15267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15268$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
15269 if test -x $with_build_time_tools/${ncn_progname}; then
15270 ac_cv_prog_DSYMUTIL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
15271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15272$as_echo "yes" >&6; }
15273 break
15274 else
15275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15276$as_echo "no" >&6; }
15277 fi
15278 done
15279fi
15280
15281if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
15282 for ncn_progname in dsymutil; do
15283 if test -n "$ncn_target_tool_prefix"; then
15284 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
15285set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
15286{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15287$as_echo_n "checking for $ac_word... " >&6; }
15288if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
15289 $as_echo_n "(cached) " >&6
15290else
15291 if test -n "$DSYMUTIL_FOR_TARGET"; then
15292 ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
15293else
15294as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15295for as_dir in $PATH
15296do
15297 IFS=$as_save_IFS
15298 test -z "$as_dir" && as_dir=.
15299 for ac_exec_ext in '' $ac_executable_extensions; do
15300 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15301 ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
15302 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15303 break 2
15304 fi
15305done
15306 done
15307IFS=$as_save_IFS
15308
15309fi
15310fi
15311DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
15312if test -n "$DSYMUTIL_FOR_TARGET"; then
15313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
15314$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
15315else
15316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15317$as_echo "no" >&6; }
15318fi
15319
15320
15321 fi
15322 if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test $build = $target ; then
15323 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15324set dummy ${ncn_progname}; ac_word=$2
15325{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15326$as_echo_n "checking for $ac_word... " >&6; }
15327if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
15328 $as_echo_n "(cached) " >&6
15329else
15330 if test -n "$DSYMUTIL_FOR_TARGET"; then
15331 ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
15332else
15333as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15334for as_dir in $PATH
15335do
15336 IFS=$as_save_IFS
15337 test -z "$as_dir" && as_dir=.
15338 for ac_exec_ext in '' $ac_executable_extensions; do
15339 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15340 ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
15341 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15342 break 2
15343 fi
15344done
15345 done
15346IFS=$as_save_IFS
15347
15348fi
15349fi
15350DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
15351if test -n "$DSYMUTIL_FOR_TARGET"; then
15352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
15353$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
15354else
15355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15356$as_echo "no" >&6; }
15357fi
15358
15359
15360 fi
15361 test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && break
15362 done
15363fi
15364
15365if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" ; then
15366 set dummy dsymutil
15367 if test $build = $target ; then
15368 DSYMUTIL_FOR_TARGET="$2"
15369 else
15370 DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}$2"
15371 fi
15372else
15373 DSYMUTIL_FOR_TARGET="$ac_cv_prog_DSYMUTIL_FOR_TARGET"
15374fi
15375
15376else
15377 DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
15378fi
15379
15380
15381
15382
e8b05380
PB
15383if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
15384 if test -n "$with_build_time_tools"; then
5213506e
RW
15385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld in $with_build_time_tools" >&5
15386$as_echo_n "checking for ld in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15387 if test -x $with_build_time_tools/ld; then
15388 LD_FOR_TARGET=`cd $with_build_time_tools && pwd`/ld
15389 ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
5213506e
RW
15390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_LD_FOR_TARGET" >&5
15391$as_echo "$ac_cv_path_LD_FOR_TARGET" >&6; }
d1f8db0c 15392 else
5213506e
RW
15393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15394$as_echo "no" >&6; }
d1f8db0c 15395 fi
e8b05380
PB
15396 elif test $build != $host && test $have_gcc_for_target = yes; then
15397 LD_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ld`
1c00b503
PB
15398 test $LD_FOR_TARGET = ld && LD_FOR_TARGET=
15399 test -n "$LD_FOR_TARGET" && ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
2693c0b0 15400 fi
e8b05380 15401fi
3e19841a 15402if test -z "$ac_cv_path_LD_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
15403 # Extract the first word of "ld", so it can be a program name with args.
15404set dummy ld; ac_word=$2
5213506e
RW
15405{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15406$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15407if ${ac_cv_path_LD_FOR_TARGET+:} false; then :
5213506e 15408 $as_echo_n "(cached) " >&6
4de997d1 15409else
1c710c3c
DJ
15410 case $LD_FOR_TARGET in
15411 [\\/]* | ?:[\\/]*)
e8b05380
PB
15412 ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
15413 ;;
e8b05380 15414 *)
1c710c3c
DJ
15415 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15416for as_dir in $gcc_cv_tool_dirs
15417do
15418 IFS=$as_save_IFS
15419 test -z "$as_dir" && as_dir=.
5213506e 15420 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15421 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15422 ac_cv_path_LD_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 15423 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15424 break 2
15425 fi
15426done
5213506e
RW
15427 done
15428IFS=$as_save_IFS
1c710c3c 15429
e8b05380
PB
15430 ;;
15431esac
4de997d1 15432fi
1c710c3c 15433LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
e8b05380 15434if test -n "$LD_FOR_TARGET"; then
5213506e
RW
15435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
15436$as_echo "$LD_FOR_TARGET" >&6; }
4de997d1 15437else
5213506e
RW
15438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15439$as_echo "no" >&6; }
4de997d1 15440fi
2693c0b0 15441
5213506e 15442
e8b05380
PB
15443fi
15444if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
278a7a38
AO
15445
15446
15447if test -n "$LD_FOR_TARGET"; then
15448 ac_cv_prog_LD_FOR_TARGET=$LD_FOR_TARGET
15449elif test -n "$ac_cv_prog_LD_FOR_TARGET"; then
15450 LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
15451fi
15452
15453if test -n "$ac_cv_prog_LD_FOR_TARGET"; then
15454 for ncn_progname in ld; do
15455 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15456set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15457{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15458$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15459if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
5213506e 15460 $as_echo_n "(cached) " >&6
278a7a38
AO
15461else
15462 if test -n "$LD_FOR_TARGET"; then
15463 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
15464else
15465as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15466for as_dir in $PATH
15467do
15468 IFS=$as_save_IFS
15469 test -z "$as_dir" && as_dir=.
5213506e 15470 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15471 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15472 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
5213506e 15473 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15474 break 2
15475 fi
15476done
5213506e
RW
15477 done
15478IFS=$as_save_IFS
278a7a38
AO
15479
15480fi
15481fi
15482LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
15483if test -n "$LD_FOR_TARGET"; then
5213506e
RW
15484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
15485$as_echo "$LD_FOR_TARGET" >&6; }
278a7a38 15486else
5213506e
RW
15487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15488$as_echo "no" >&6; }
278a7a38
AO
15489fi
15490
5213506e 15491
278a7a38
AO
15492 done
15493fi
15494
15495if test -z "$ac_cv_prog_LD_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15496 for ncn_progname in ld; do
5213506e
RW
15497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15498$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15499 if test -x $with_build_time_tools/${ncn_progname}; then
15500 ac_cv_prog_LD_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15502$as_echo "yes" >&6; }
e8b05380
PB
15503 break
15504 else
5213506e
RW
15505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15506$as_echo "no" >&6; }
e8b05380
PB
15507 fi
15508 done
ca9f4b81
AO
15509fi
15510
e8b05380
PB
15511if test -z "$ac_cv_prog_LD_FOR_TARGET"; then
15512 for ncn_progname in ld; do
15513 if test -n "$ncn_target_tool_prefix"; then
15514 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 15515set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15516{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15517$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15518if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
5213506e 15519 $as_echo_n "(cached) " >&6
ca9f4b81 15520else
4de997d1
PB
15521 if test -n "$LD_FOR_TARGET"; then
15522 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 15523else
1c710c3c
DJ
15524as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15525for as_dir in $PATH
15526do
15527 IFS=$as_save_IFS
15528 test -z "$as_dir" && as_dir=.
5213506e 15529 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15530 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15531 ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15532 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15533 break 2
15534 fi
15535done
5213506e
RW
15536 done
15537IFS=$as_save_IFS
1c710c3c 15538
ca9f4b81
AO
15539fi
15540fi
1c710c3c 15541LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
4de997d1 15542if test -n "$LD_FOR_TARGET"; then
5213506e
RW
15543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
15544$as_echo "$LD_FOR_TARGET" >&6; }
ca9f4b81 15545else
5213506e
RW
15546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15547$as_echo "no" >&6; }
ca9f4b81
AO
15548fi
15549
5213506e 15550
e8b05380
PB
15551 fi
15552 if test -z "$ac_cv_prog_LD_FOR_TARGET" && test $build = $target ; then
15553 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 15554set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15556$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15557if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
5213506e 15558 $as_echo_n "(cached) " >&6
ca9f4b81 15559else
2693c0b0
PB
15560 if test -n "$LD_FOR_TARGET"; then
15561 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 15562else
1c710c3c
DJ
15563as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15564for as_dir in $PATH
15565do
15566 IFS=$as_save_IFS
15567 test -z "$as_dir" && as_dir=.
5213506e 15568 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15570 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
5213506e 15571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15572 break 2
15573 fi
15574done
5213506e
RW
15575 done
15576IFS=$as_save_IFS
1c710c3c 15577
ca9f4b81
AO
15578fi
15579fi
1c710c3c 15580LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
2693c0b0 15581if test -n "$LD_FOR_TARGET"; then
5213506e
RW
15582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
15583$as_echo "$LD_FOR_TARGET" >&6; }
ca9f4b81 15584else
5213506e
RW
15585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15586$as_echo "no" >&6; }
ca9f4b81 15587fi
1c710c3c 15588
5213506e 15589
e8b05380
PB
15590 fi
15591 test -n "$ac_cv_prog_LD_FOR_TARGET" && break
15592 done
15593fi
1c710c3c 15594
2693c0b0
PB
15595if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
15596 set dummy ld
15597 if test $build = $target ; then
15598 LD_FOR_TARGET="$2"
ca9f4b81 15599 else
2693c0b0 15600 LD_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 15601 fi
1c00b503
PB
15602else
15603 LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
ca9f4b81
AO
15604fi
15605
d1f8db0c
PB
15606else
15607 LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
e8b05380
PB
15608fi
15609
15610
15611
15612
15613if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
15614 if test -n "$with_build_time_tools"; then
5213506e
RW
15615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lipo in $with_build_time_tools" >&5
15616$as_echo_n "checking for lipo in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15617 if test -x $with_build_time_tools/lipo; then
15618 LIPO_FOR_TARGET=`cd $with_build_time_tools && pwd`/lipo
15619 ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
5213506e
RW
15620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_LIPO_FOR_TARGET" >&5
15621$as_echo "$ac_cv_path_LIPO_FOR_TARGET" >&6; }
d1f8db0c 15622 else
5213506e
RW
15623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15624$as_echo "no" >&6; }
d1f8db0c 15625 fi
e8b05380
PB
15626 elif test $build != $host && test $have_gcc_for_target = yes; then
15627 LIPO_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=lipo`
1c00b503
PB
15628 test $LIPO_FOR_TARGET = lipo && LIPO_FOR_TARGET=
15629 test -n "$LIPO_FOR_TARGET" && ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
e8b05380
PB
15630 fi
15631fi
278a7a38
AO
15632if test -z "$ac_cv_path_LIPO_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
15633 # Extract the first word of "lipo", so it can be a program name with args.
15634set dummy lipo; ac_word=$2
5213506e
RW
15635{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15636$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15637if ${ac_cv_path_LIPO_FOR_TARGET+:} false; then :
5213506e 15638 $as_echo_n "(cached) " >&6
278a7a38
AO
15639else
15640 case $LIPO_FOR_TARGET in
15641 [\\/]* | ?:[\\/]*)
15642 ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a path.
15643 ;;
15644 *)
15645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15646for as_dir in $gcc_cv_tool_dirs
15647do
15648 IFS=$as_save_IFS
15649 test -z "$as_dir" && as_dir=.
5213506e 15650 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15651 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15652 ac_cv_path_LIPO_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 15653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15654 break 2
15655 fi
15656done
5213506e
RW
15657 done
15658IFS=$as_save_IFS
278a7a38
AO
15659
15660 ;;
15661esac
15662fi
15663LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
278a7a38 15664if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15666$as_echo "$LIPO_FOR_TARGET" >&6; }
278a7a38 15667else
5213506e
RW
15668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15669$as_echo "no" >&6; }
278a7a38
AO
15670fi
15671
5213506e 15672
278a7a38
AO
15673fi
15674if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
15675
15676
15677if test -n "$LIPO_FOR_TARGET"; then
15678 ac_cv_prog_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
15679elif test -n "$ac_cv_prog_LIPO_FOR_TARGET"; then
15680 LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
15681fi
15682
15683if test -n "$ac_cv_prog_LIPO_FOR_TARGET"; then
15684 for ncn_progname in lipo; do
15685 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15686set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15688$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15689if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
5213506e 15690 $as_echo_n "(cached) " >&6
e8b05380 15691else
278a7a38
AO
15692 if test -n "$LIPO_FOR_TARGET"; then
15693 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
15694else
15695as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15696for as_dir in $PATH
1c710c3c
DJ
15697do
15698 IFS=$as_save_IFS
15699 test -z "$as_dir" && as_dir=.
5213506e 15700 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15701 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15702 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
5213506e 15703 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15704 break 2
15705 fi
15706done
5213506e
RW
15707 done
15708IFS=$as_save_IFS
1c710c3c 15709
e8b05380 15710fi
278a7a38
AO
15711fi
15712LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
e8b05380 15713if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15715$as_echo "$LIPO_FOR_TARGET" >&6; }
e8b05380 15716else
5213506e
RW
15717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15718$as_echo "no" >&6; }
e8b05380
PB
15719fi
15720
5213506e 15721
278a7a38 15722 done
e8b05380 15723fi
278a7a38
AO
15724
15725if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15726 for ncn_progname in lipo; do
5213506e
RW
15727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15728$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15729 if test -x $with_build_time_tools/${ncn_progname}; then
15730 ac_cv_prog_LIPO_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15732$as_echo "yes" >&6; }
e8b05380
PB
15733 break
15734 else
5213506e
RW
15735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15736$as_echo "no" >&6; }
e8b05380
PB
15737 fi
15738 done
15739fi
15740
15741if test -z "$ac_cv_prog_LIPO_FOR_TARGET"; then
15742 for ncn_progname in lipo; do
15743 if test -n "$ncn_target_tool_prefix"; then
15744 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 15745set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15746{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15747$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15748if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
5213506e 15749 $as_echo_n "(cached) " >&6
040b1c5a
GK
15750else
15751 if test -n "$LIPO_FOR_TARGET"; then
15752 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
15753else
1c710c3c
DJ
15754as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15755for as_dir in $PATH
15756do
15757 IFS=$as_save_IFS
15758 test -z "$as_dir" && as_dir=.
5213506e 15759 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15760 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15761 ac_cv_prog_LIPO_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15762 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15763 break 2
15764 fi
15765done
5213506e
RW
15766 done
15767IFS=$as_save_IFS
1c710c3c 15768
040b1c5a
GK
15769fi
15770fi
1c710c3c 15771LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
040b1c5a 15772if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15774$as_echo "$LIPO_FOR_TARGET" >&6; }
040b1c5a 15775else
5213506e
RW
15776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15777$as_echo "no" >&6; }
040b1c5a
GK
15778fi
15779
5213506e 15780
e8b05380
PB
15781 fi
15782 if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test $build = $target ; then
15783 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 15784set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15786$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15787if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
5213506e 15788 $as_echo_n "(cached) " >&6
040b1c5a
GK
15789else
15790 if test -n "$LIPO_FOR_TARGET"; then
72a7ab82
AP
15791 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
15792else
1c710c3c
DJ
15793as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15794for as_dir in $PATH
15795do
15796 IFS=$as_save_IFS
15797 test -z "$as_dir" && as_dir=.
5213506e 15798 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15799 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15800 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
5213506e 15801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15802 break 2
15803 fi
15804done
5213506e
RW
15805 done
15806IFS=$as_save_IFS
1c710c3c 15807
040b1c5a
GK
15808fi
15809fi
1c710c3c 15810LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
040b1c5a 15811if test -n "$LIPO_FOR_TARGET"; then
5213506e
RW
15812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
15813$as_echo "$LIPO_FOR_TARGET" >&6; }
040b1c5a 15814else
5213506e
RW
15815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15816$as_echo "no" >&6; }
040b1c5a 15817fi
1c710c3c 15818
5213506e 15819
e8b05380
PB
15820 fi
15821 test -n "$ac_cv_prog_LIPO_FOR_TARGET" && break
15822 done
15823fi
1c710c3c 15824
040b1c5a
GK
15825if test -z "$ac_cv_prog_LIPO_FOR_TARGET" ; then
15826 set dummy lipo
15827 if test $build = $target ; then
15828 LIPO_FOR_TARGET="$2"
15829 else
15830 LIPO_FOR_TARGET="${ncn_target_tool_prefix}$2"
15831 fi
1c00b503
PB
15832else
15833 LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
040b1c5a
GK
15834fi
15835
d1f8db0c
PB
15836else
15837 LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
e8b05380
PB
15838fi
15839
15840
15841
15842
15843if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
15844 if test -n "$with_build_time_tools"; then
5213506e
RW
15845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nm in $with_build_time_tools" >&5
15846$as_echo_n "checking for nm in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15847 if test -x $with_build_time_tools/nm; then
15848 NM_FOR_TARGET=`cd $with_build_time_tools && pwd`/nm
15849 ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
5213506e
RW
15850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_NM_FOR_TARGET" >&5
15851$as_echo "$ac_cv_path_NM_FOR_TARGET" >&6; }
d1f8db0c 15852 else
5213506e
RW
15853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15854$as_echo "no" >&6; }
d1f8db0c 15855 fi
e8b05380
PB
15856 elif test $build != $host && test $have_gcc_for_target = yes; then
15857 NM_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=nm`
1c00b503
PB
15858 test $NM_FOR_TARGET = nm && NM_FOR_TARGET=
15859 test -n "$NM_FOR_TARGET" && ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
e8b05380
PB
15860 fi
15861fi
3e19841a 15862if test -z "$ac_cv_path_NM_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
15863 # Extract the first word of "nm", so it can be a program name with args.
15864set dummy nm; ac_word=$2
5213506e
RW
15865{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15866$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15867if ${ac_cv_path_NM_FOR_TARGET+:} false; then :
5213506e 15868 $as_echo_n "(cached) " >&6
e8b05380 15869else
1c710c3c
DJ
15870 case $NM_FOR_TARGET in
15871 [\\/]* | ?:[\\/]*)
e8b05380
PB
15872 ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
15873 ;;
e8b05380 15874 *)
1c710c3c
DJ
15875 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15876for as_dir in $gcc_cv_tool_dirs
15877do
15878 IFS=$as_save_IFS
15879 test -z "$as_dir" && as_dir=.
5213506e 15880 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15881 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15882 ac_cv_path_NM_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 15883 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15884 break 2
15885 fi
15886done
5213506e
RW
15887 done
15888IFS=$as_save_IFS
1c710c3c 15889
e8b05380
PB
15890 ;;
15891esac
15892fi
1c710c3c 15893NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
e8b05380 15894if test -n "$NM_FOR_TARGET"; then
5213506e
RW
15895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
15896$as_echo "$NM_FOR_TARGET" >&6; }
e8b05380 15897else
5213506e
RW
15898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15899$as_echo "no" >&6; }
e8b05380
PB
15900fi
15901
5213506e 15902
e8b05380
PB
15903fi
15904if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
278a7a38
AO
15905
15906
15907if test -n "$NM_FOR_TARGET"; then
15908 ac_cv_prog_NM_FOR_TARGET=$NM_FOR_TARGET
15909elif test -n "$ac_cv_prog_NM_FOR_TARGET"; then
15910 NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
15911fi
15912
15913if test -n "$ac_cv_prog_NM_FOR_TARGET"; then
15914 for ncn_progname in nm; do
15915 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
15916set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
15917{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15918$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15919if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
5213506e 15920 $as_echo_n "(cached) " >&6
278a7a38
AO
15921else
15922 if test -n "$NM_FOR_TARGET"; then
15923 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
15924else
15925as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15926for as_dir in $PATH
15927do
15928 IFS=$as_save_IFS
15929 test -z "$as_dir" && as_dir=.
5213506e 15930 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15931 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 15932 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
5213506e 15933 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
15934 break 2
15935 fi
15936done
5213506e
RW
15937 done
15938IFS=$as_save_IFS
278a7a38
AO
15939
15940fi
15941fi
15942NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
15943if test -n "$NM_FOR_TARGET"; then
5213506e
RW
15944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
15945$as_echo "$NM_FOR_TARGET" >&6; }
278a7a38 15946else
5213506e
RW
15947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15948$as_echo "no" >&6; }
278a7a38
AO
15949fi
15950
5213506e 15951
278a7a38
AO
15952 done
15953fi
15954
15955if test -z "$ac_cv_prog_NM_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 15956 for ncn_progname in nm; do
5213506e
RW
15957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
15958$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
15959 if test -x $with_build_time_tools/${ncn_progname}; then
15960 ac_cv_prog_NM_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
15961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15962$as_echo "yes" >&6; }
e8b05380
PB
15963 break
15964 else
5213506e
RW
15965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15966$as_echo "no" >&6; }
e8b05380
PB
15967 fi
15968 done
15969fi
15970
15971if test -z "$ac_cv_prog_NM_FOR_TARGET"; then
15972 for ncn_progname in nm; do
15973 if test -n "$ncn_target_tool_prefix"; then
15974 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 15975set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
15976{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15977$as_echo_n "checking for $ac_word... " >&6; }
22e05272 15978if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
5213506e 15979 $as_echo_n "(cached) " >&6
ca9f4b81 15980else
4de997d1
PB
15981 if test -n "$NM_FOR_TARGET"; then
15982 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 15983else
1c710c3c
DJ
15984as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15985for as_dir in $PATH
15986do
15987 IFS=$as_save_IFS
15988 test -z "$as_dir" && as_dir=.
5213506e 15989 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 15990 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 15991 ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 15992 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
15993 break 2
15994 fi
15995done
5213506e
RW
15996 done
15997IFS=$as_save_IFS
1c710c3c 15998
ca9f4b81
AO
15999fi
16000fi
1c710c3c 16001NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
4de997d1 16002if test -n "$NM_FOR_TARGET"; then
5213506e
RW
16003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
16004$as_echo "$NM_FOR_TARGET" >&6; }
ca9f4b81 16005else
5213506e
RW
16006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16007$as_echo "no" >&6; }
ca9f4b81
AO
16008fi
16009
5213506e 16010
e8b05380
PB
16011 fi
16012 if test -z "$ac_cv_prog_NM_FOR_TARGET" && test $build = $target ; then
16013 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 16014set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16015{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16016$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16017if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
5213506e 16018 $as_echo_n "(cached) " >&6
ca9f4b81 16019else
2693c0b0
PB
16020 if test -n "$NM_FOR_TARGET"; then
16021 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 16022else
1c710c3c
DJ
16023as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16024for as_dir in $PATH
16025do
16026 IFS=$as_save_IFS
16027 test -z "$as_dir" && as_dir=.
5213506e 16028 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16029 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16030 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
5213506e 16031 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16032 break 2
16033 fi
16034done
5213506e
RW
16035 done
16036IFS=$as_save_IFS
1c710c3c 16037
ca9f4b81
AO
16038fi
16039fi
1c710c3c 16040NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
2693c0b0 16041if test -n "$NM_FOR_TARGET"; then
5213506e
RW
16042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
16043$as_echo "$NM_FOR_TARGET" >&6; }
ca9f4b81 16044else
5213506e
RW
16045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16046$as_echo "no" >&6; }
ca9f4b81 16047fi
1c710c3c 16048
5213506e 16049
e8b05380
PB
16050 fi
16051 test -n "$ac_cv_prog_NM_FOR_TARGET" && break
16052 done
16053fi
1c710c3c 16054
2693c0b0
PB
16055if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
16056 set dummy nm
16057 if test $build = $target ; then
16058 NM_FOR_TARGET="$2"
ca9f4b81 16059 else
2693c0b0 16060 NM_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 16061 fi
1c00b503
PB
16062else
16063 NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
ca9f4b81
AO
16064fi
16065
d1f8db0c
PB
16066else
16067 NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
e8b05380
PB
16068fi
16069
16070
16071
16072
9bccfdf5
AP
16073if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" ; then
16074 if test -n "$with_build_time_tools"; then
16075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objcopy in $with_build_time_tools" >&5
16076$as_echo_n "checking for objcopy in $with_build_time_tools... " >&6; }
16077 if test -x $with_build_time_tools/objcopy; then
16078 OBJCOPY_FOR_TARGET=`cd $with_build_time_tools && pwd`/objcopy
16079 ac_cv_path_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
16080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OBJCOPY_FOR_TARGET" >&5
16081$as_echo "$ac_cv_path_OBJCOPY_FOR_TARGET" >&6; }
16082 else
16083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16084$as_echo "no" >&6; }
16085 fi
16086 elif test $build != $host && test $have_gcc_for_target = yes; then
16087 OBJCOPY_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objcopy`
16088 test $OBJCOPY_FOR_TARGET = objcopy && OBJCOPY_FOR_TARGET=
16089 test -n "$OBJCOPY_FOR_TARGET" && ac_cv_path_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
16090 fi
16091fi
16092if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
16093 # Extract the first word of "objcopy", so it can be a program name with args.
16094set dummy objcopy; ac_word=$2
16095{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16096$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16097if ${ac_cv_path_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
16098 $as_echo_n "(cached) " >&6
16099else
16100 case $OBJCOPY_FOR_TARGET in
16101 [\\/]* | ?:[\\/]*)
16102 ac_cv_path_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test with a path.
16103 ;;
16104 *)
16105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16106for as_dir in $gcc_cv_tool_dirs
16107do
16108 IFS=$as_save_IFS
16109 test -z "$as_dir" && as_dir=.
16110 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16111 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
16112 ac_cv_path_OBJCOPY_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
16113 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16114 break 2
16115 fi
16116done
16117 done
16118IFS=$as_save_IFS
16119
16120 ;;
16121esac
16122fi
16123OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
16124if test -n "$OBJCOPY_FOR_TARGET"; then
16125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
16126$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
16127else
16128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16129$as_echo "no" >&6; }
16130fi
16131
16132
16133fi
16134if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" ; then
16135
16136
16137if test -n "$OBJCOPY_FOR_TARGET"; then
16138 ac_cv_prog_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
16139elif test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
16140 OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
16141fi
16142
16143if test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
16144 for ncn_progname in objcopy; do
16145 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16146set dummy ${ncn_progname}; ac_word=$2
16147{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16148$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16149if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
16150 $as_echo_n "(cached) " >&6
16151else
16152 if test -n "$OBJCOPY_FOR_TARGET"; then
16153 ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
16154else
16155as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16156for as_dir in $PATH
16157do
16158 IFS=$as_save_IFS
16159 test -z "$as_dir" && as_dir=.
16160 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16161 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
16162 ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_progname}"
16163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16164 break 2
16165 fi
16166done
16167 done
16168IFS=$as_save_IFS
16169
16170fi
16171fi
16172OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
16173if test -n "$OBJCOPY_FOR_TARGET"; then
16174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
16175$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
16176else
16177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16178$as_echo "no" >&6; }
16179fi
16180
16181
16182 done
16183fi
16184
16185if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" && test -n "$with_build_time_tools"; then
16186 for ncn_progname in objcopy; do
16187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16188$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
16189 if test -x $with_build_time_tools/${ncn_progname}; then
16190 ac_cv_prog_OBJCOPY_FOR_TARGET=$with_build_time_tools/${ncn_progname}
16191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16192$as_echo "yes" >&6; }
16193 break
16194 else
16195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16196$as_echo "no" >&6; }
16197 fi
16198 done
16199fi
16200
16201if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
16202 for ncn_progname in objcopy; do
16203 if test -n "$ncn_target_tool_prefix"; then
16204 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
16205set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
16206{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16207$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16208if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
16209 $as_echo_n "(cached) " >&6
16210else
16211 if test -n "$OBJCOPY_FOR_TARGET"; then
16212 ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
16213else
16214as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16215for as_dir in $PATH
16216do
16217 IFS=$as_save_IFS
16218 test -z "$as_dir" && as_dir=.
16219 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16220 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
16221 ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
16222 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16223 break 2
16224 fi
16225done
16226 done
16227IFS=$as_save_IFS
16228
16229fi
16230fi
16231OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
16232if test -n "$OBJCOPY_FOR_TARGET"; then
16233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
16234$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
16235else
16236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16237$as_echo "no" >&6; }
16238fi
16239
16240
16241 fi
16242 if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" && test $build = $target ; then
16243 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16244set dummy ${ncn_progname}; ac_word=$2
16245{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16246$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16247if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
9bccfdf5
AP
16248 $as_echo_n "(cached) " >&6
16249else
16250 if test -n "$OBJCOPY_FOR_TARGET"; then
16251 ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
16252else
16253as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16254for as_dir in $PATH
16255do
16256 IFS=$as_save_IFS
16257 test -z "$as_dir" && as_dir=.
16258 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9bccfdf5
AP
16260 ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_progname}"
16261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16262 break 2
16263 fi
16264done
16265 done
16266IFS=$as_save_IFS
16267
16268fi
16269fi
16270OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
16271if test -n "$OBJCOPY_FOR_TARGET"; then
16272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
16273$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
16274else
16275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16276$as_echo "no" >&6; }
16277fi
16278
16279
16280 fi
16281 test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET" && break
16282 done
16283fi
16284
16285if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" ; then
16286 set dummy objcopy
16287 if test $build = $target ; then
16288 OBJCOPY_FOR_TARGET="$2"
16289 else
16290 OBJCOPY_FOR_TARGET="${ncn_target_tool_prefix}$2"
16291 fi
16292else
16293 OBJCOPY_FOR_TARGET="$ac_cv_prog_OBJCOPY_FOR_TARGET"
16294fi
16295
16296else
16297 OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
16298fi
16299
16300
16301
16302
e8b05380
PB
16303if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
16304 if test -n "$with_build_time_tools"; then
5213506e
RW
16305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdump in $with_build_time_tools" >&5
16306$as_echo_n "checking for objdump in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16307 if test -x $with_build_time_tools/objdump; then
16308 OBJDUMP_FOR_TARGET=`cd $with_build_time_tools && pwd`/objdump
16309 ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
5213506e
RW
16310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OBJDUMP_FOR_TARGET" >&5
16311$as_echo "$ac_cv_path_OBJDUMP_FOR_TARGET" >&6; }
d1f8db0c 16312 else
5213506e
RW
16313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16314$as_echo "no" >&6; }
d1f8db0c 16315 fi
e8b05380
PB
16316 elif test $build != $host && test $have_gcc_for_target = yes; then
16317 OBJDUMP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objdump`
1c00b503
PB
16318 test $OBJDUMP_FOR_TARGET = objdump && OBJDUMP_FOR_TARGET=
16319 test -n "$OBJDUMP_FOR_TARGET" && ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
e8b05380
PB
16320 fi
16321fi
3e19841a 16322if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
16323 # Extract the first word of "objdump", so it can be a program name with args.
16324set dummy objdump; ac_word=$2
5213506e
RW
16325{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16326$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16327if ${ac_cv_path_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 16328 $as_echo_n "(cached) " >&6
e8b05380 16329else
1c710c3c
DJ
16330 case $OBJDUMP_FOR_TARGET in
16331 [\\/]* | ?:[\\/]*)
e8b05380
PB
16332 ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a path.
16333 ;;
e8b05380 16334 *)
1c710c3c
DJ
16335 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16336for as_dir in $gcc_cv_tool_dirs
16337do
16338 IFS=$as_save_IFS
16339 test -z "$as_dir" && as_dir=.
5213506e 16340 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16341 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16342 ac_cv_path_OBJDUMP_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 16343 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16344 break 2
16345 fi
16346done
5213506e
RW
16347 done
16348IFS=$as_save_IFS
1c710c3c 16349
e8b05380
PB
16350 ;;
16351esac
16352fi
1c710c3c 16353OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
e8b05380 16354if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
16355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
16356$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
e8b05380 16357else
5213506e
RW
16358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16359$as_echo "no" >&6; }
e8b05380
PB
16360fi
16361
5213506e 16362
e8b05380
PB
16363fi
16364if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
278a7a38
AO
16365
16366
16367if test -n "$OBJDUMP_FOR_TARGET"; then
16368 ac_cv_prog_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
16369elif test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
16370 OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
16371fi
16372
16373if test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
16374 for ncn_progname in objdump; do
16375 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16376set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16377{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16378$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16379if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 16380 $as_echo_n "(cached) " >&6
278a7a38
AO
16381else
16382 if test -n "$OBJDUMP_FOR_TARGET"; then
16383 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
16384else
16385as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16386for as_dir in $PATH
16387do
16388 IFS=$as_save_IFS
16389 test -z "$as_dir" && as_dir=.
5213506e 16390 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16391 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 16392 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
5213506e 16393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
16394 break 2
16395 fi
16396done
5213506e
RW
16397 done
16398IFS=$as_save_IFS
278a7a38
AO
16399
16400fi
16401fi
16402OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
16403if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
16404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
16405$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
278a7a38 16406else
5213506e
RW
16407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16408$as_echo "no" >&6; }
278a7a38
AO
16409fi
16410
5213506e 16411
278a7a38
AO
16412 done
16413fi
16414
16415if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 16416 for ncn_progname in objdump; do
5213506e
RW
16417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16418$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16419 if test -x $with_build_time_tools/${ncn_progname}; then
16420 ac_cv_prog_OBJDUMP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
16421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16422$as_echo "yes" >&6; }
e8b05380
PB
16423 break
16424 else
5213506e
RW
16425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16426$as_echo "no" >&6; }
e8b05380
PB
16427 fi
16428 done
16429fi
16430
16431if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
16432 for ncn_progname in objdump; do
16433 if test -n "$ncn_target_tool_prefix"; then
16434 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 16435set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
16436{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16437$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16438if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 16439 $as_echo_n "(cached) " >&6
d739199a
DJ
16440else
16441 if test -n "$OBJDUMP_FOR_TARGET"; then
16442 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
16443else
1c710c3c
DJ
16444as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16445for as_dir in $PATH
16446do
16447 IFS=$as_save_IFS
16448 test -z "$as_dir" && as_dir=.
5213506e 16449 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16450 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16451 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 16452 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16453 break 2
16454 fi
16455done
5213506e
RW
16456 done
16457IFS=$as_save_IFS
1c710c3c 16458
d739199a
DJ
16459fi
16460fi
1c710c3c 16461OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
d739199a 16462if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
16463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
16464$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
d739199a 16465else
5213506e
RW
16466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16467$as_echo "no" >&6; }
d739199a
DJ
16468fi
16469
5213506e 16470
e8b05380
PB
16471 fi
16472 if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test $build = $target ; then
16473 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
d739199a 16474set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16475{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16476$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16477if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
5213506e 16478 $as_echo_n "(cached) " >&6
d739199a
DJ
16479else
16480 if test -n "$OBJDUMP_FOR_TARGET"; then
16481 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
16482else
1c710c3c
DJ
16483as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16484for as_dir in $PATH
16485do
16486 IFS=$as_save_IFS
16487 test -z "$as_dir" && as_dir=.
5213506e 16488 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16489 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16490 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
5213506e 16491 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16492 break 2
16493 fi
16494done
5213506e
RW
16495 done
16496IFS=$as_save_IFS
1c710c3c 16497
d739199a
DJ
16498fi
16499fi
1c710c3c 16500OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
d739199a 16501if test -n "$OBJDUMP_FOR_TARGET"; then
5213506e
RW
16502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
16503$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
d739199a 16504else
5213506e
RW
16505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16506$as_echo "no" >&6; }
d739199a 16507fi
1c710c3c 16508
5213506e 16509
e8b05380
PB
16510 fi
16511 test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET" && break
16512 done
16513fi
1c710c3c 16514
d739199a
DJ
16515if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" ; then
16516 set dummy objdump
16517 if test $build = $target ; then
16518 OBJDUMP_FOR_TARGET="$2"
16519 else
16520 OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}$2"
16521 fi
1c00b503
PB
16522else
16523 OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
d739199a
DJ
16524fi
16525
d1f8db0c
PB
16526else
16527 OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
e8b05380
PB
16528fi
16529
16530
16531
16532
e4a9a572
IS
16533if test -z "$ac_cv_path_OTOOL_FOR_TARGET" ; then
16534 if test -n "$with_build_time_tools"; then
16535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for otool in $with_build_time_tools" >&5
16536$as_echo_n "checking for otool in $with_build_time_tools... " >&6; }
16537 if test -x $with_build_time_tools/otool; then
16538 OTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/otool
16539 ac_cv_path_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
16540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OTOOL_FOR_TARGET" >&5
16541$as_echo "$ac_cv_path_OTOOL_FOR_TARGET" >&6; }
16542 else
16543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16544$as_echo "no" >&6; }
16545 fi
16546 elif test $build != $host && test $have_gcc_for_target = yes; then
16547 OTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=otool`
16548 test $OTOOL_FOR_TARGET = otool && OTOOL_FOR_TARGET=
16549 test -n "$OTOOL_FOR_TARGET" && ac_cv_path_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
16550 fi
16551fi
16552if test -z "$ac_cv_path_OTOOL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
16553 # Extract the first word of "otool", so it can be a program name with args.
16554set dummy otool; ac_word=$2
16555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16556$as_echo_n "checking for $ac_word... " >&6; }
16557if ${ac_cv_path_OTOOL_FOR_TARGET+:} false; then :
16558 $as_echo_n "(cached) " >&6
16559else
16560 case $OTOOL_FOR_TARGET in
16561 [\\/]* | ?:[\\/]*)
16562 ac_cv_path_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test with a path.
16563 ;;
16564 *)
16565 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16566for as_dir in $gcc_cv_tool_dirs
16567do
16568 IFS=$as_save_IFS
16569 test -z "$as_dir" && as_dir=.
16570 for ac_exec_ext in '' $ac_executable_extensions; do
16571 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16572 ac_cv_path_OTOOL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
16573 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16574 break 2
16575 fi
16576done
16577 done
16578IFS=$as_save_IFS
16579
16580 ;;
16581esac
16582fi
16583OTOOL_FOR_TARGET=$ac_cv_path_OTOOL_FOR_TARGET
16584if test -n "$OTOOL_FOR_TARGET"; then
16585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16586$as_echo "$OTOOL_FOR_TARGET" >&6; }
16587else
16588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16589$as_echo "no" >&6; }
16590fi
16591
16592
16593fi
16594if test -z "$ac_cv_path_OTOOL_FOR_TARGET" ; then
16595
16596
16597if test -n "$OTOOL_FOR_TARGET"; then
16598 ac_cv_prog_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
16599elif test -n "$ac_cv_prog_OTOOL_FOR_TARGET"; then
16600 OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16601fi
16602
16603if test -n "$ac_cv_prog_OTOOL_FOR_TARGET"; then
16604 for ncn_progname in otool; do
16605 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16606set dummy ${ncn_progname}; ac_word=$2
16607{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16608$as_echo_n "checking for $ac_word... " >&6; }
16609if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
16610 $as_echo_n "(cached) " >&6
16611else
16612 if test -n "$OTOOL_FOR_TARGET"; then
16613 ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
16614else
16615as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16616for as_dir in $PATH
16617do
16618 IFS=$as_save_IFS
16619 test -z "$as_dir" && as_dir=.
16620 for ac_exec_ext in '' $ac_executable_extensions; do
16621 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16622 ac_cv_prog_OTOOL_FOR_TARGET="${ncn_progname}"
16623 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16624 break 2
16625 fi
16626done
16627 done
16628IFS=$as_save_IFS
16629
16630fi
16631fi
16632OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16633if test -n "$OTOOL_FOR_TARGET"; then
16634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16635$as_echo "$OTOOL_FOR_TARGET" >&6; }
16636else
16637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16638$as_echo "no" >&6; }
16639fi
16640
16641
16642 done
16643fi
16644
16645if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" && test -n "$with_build_time_tools"; then
16646 for ncn_progname in otool; do
16647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16648$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
16649 if test -x $with_build_time_tools/${ncn_progname}; then
16650 ac_cv_prog_OTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
16651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16652$as_echo "yes" >&6; }
16653 break
16654 else
16655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16656$as_echo "no" >&6; }
16657 fi
16658 done
16659fi
16660
16661if test -z "$ac_cv_prog_OTOOL_FOR_TARGET"; then
16662 for ncn_progname in otool; do
16663 if test -n "$ncn_target_tool_prefix"; then
16664 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
16665set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
16666{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16667$as_echo_n "checking for $ac_word... " >&6; }
16668if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
16669 $as_echo_n "(cached) " >&6
16670else
16671 if test -n "$OTOOL_FOR_TARGET"; then
16672 ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
16673else
16674as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16675for as_dir in $PATH
16676do
16677 IFS=$as_save_IFS
16678 test -z "$as_dir" && as_dir=.
16679 for ac_exec_ext in '' $ac_executable_extensions; do
16680 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16681 ac_cv_prog_OTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
16682 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16683 break 2
16684 fi
16685done
16686 done
16687IFS=$as_save_IFS
16688
16689fi
16690fi
16691OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16692if test -n "$OTOOL_FOR_TARGET"; then
16693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16694$as_echo "$OTOOL_FOR_TARGET" >&6; }
16695else
16696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16697$as_echo "no" >&6; }
16698fi
16699
16700
16701 fi
16702 if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" && test $build = $target ; then
16703 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16704set dummy ${ncn_progname}; ac_word=$2
16705{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16706$as_echo_n "checking for $ac_word... " >&6; }
16707if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
16708 $as_echo_n "(cached) " >&6
16709else
16710 if test -n "$OTOOL_FOR_TARGET"; then
16711 ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
16712else
16713as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16714for as_dir in $PATH
16715do
16716 IFS=$as_save_IFS
16717 test -z "$as_dir" && as_dir=.
16718 for ac_exec_ext in '' $ac_executable_extensions; do
16719 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16720 ac_cv_prog_OTOOL_FOR_TARGET="${ncn_progname}"
16721 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16722 break 2
16723 fi
16724done
16725 done
16726IFS=$as_save_IFS
16727
16728fi
16729fi
16730OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
16731if test -n "$OTOOL_FOR_TARGET"; then
16732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
16733$as_echo "$OTOOL_FOR_TARGET" >&6; }
16734else
16735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16736$as_echo "no" >&6; }
16737fi
16738
16739
16740 fi
16741 test -n "$ac_cv_prog_OTOOL_FOR_TARGET" && break
16742 done
16743fi
16744
16745if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" ; then
16746 set dummy otool
16747 if test $build = $target ; then
16748 OTOOL_FOR_TARGET="$2"
16749 else
16750 OTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
16751 fi
16752else
16753 OTOOL_FOR_TARGET="$ac_cv_prog_OTOOL_FOR_TARGET"
16754fi
16755
16756else
16757 OTOOL_FOR_TARGET=$ac_cv_path_OTOOL_FOR_TARGET
16758fi
16759
16760
16761
16762
e8b05380
PB
16763if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
16764 if test -n "$with_build_time_tools"; then
5213506e
RW
16765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ranlib in $with_build_time_tools" >&5
16766$as_echo_n "checking for ranlib in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16767 if test -x $with_build_time_tools/ranlib; then
16768 RANLIB_FOR_TARGET=`cd $with_build_time_tools && pwd`/ranlib
16769 ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
5213506e
RW
16770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_RANLIB_FOR_TARGET" >&5
16771$as_echo "$ac_cv_path_RANLIB_FOR_TARGET" >&6; }
d1f8db0c 16772 else
5213506e
RW
16773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16774$as_echo "no" >&6; }
d1f8db0c 16775 fi
e8b05380
PB
16776 elif test $build != $host && test $have_gcc_for_target = yes; then
16777 RANLIB_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ranlib`
1c00b503
PB
16778 test $RANLIB_FOR_TARGET = ranlib && RANLIB_FOR_TARGET=
16779 test -n "$RANLIB_FOR_TARGET" && ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
e8b05380
PB
16780 fi
16781fi
3e19841a 16782if test -z "$ac_cv_path_RANLIB_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
16783 # Extract the first word of "ranlib", so it can be a program name with args.
16784set dummy ranlib; ac_word=$2
5213506e
RW
16785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16786$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16787if ${ac_cv_path_RANLIB_FOR_TARGET+:} false; then :
5213506e 16788 $as_echo_n "(cached) " >&6
e8b05380 16789else
1c710c3c
DJ
16790 case $RANLIB_FOR_TARGET in
16791 [\\/]* | ?:[\\/]*)
e8b05380
PB
16792 ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
16793 ;;
e8b05380 16794 *)
1c710c3c
DJ
16795 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16796for as_dir in $gcc_cv_tool_dirs
16797do
16798 IFS=$as_save_IFS
16799 test -z "$as_dir" && as_dir=.
5213506e 16800 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16801 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16802 ac_cv_path_RANLIB_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 16803 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16804 break 2
16805 fi
16806done
5213506e
RW
16807 done
16808IFS=$as_save_IFS
1c710c3c 16809
e8b05380
PB
16810 ;;
16811esac
16812fi
1c710c3c 16813RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
e8b05380 16814if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16816$as_echo "$RANLIB_FOR_TARGET" >&6; }
e8b05380 16817else
5213506e
RW
16818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16819$as_echo "no" >&6; }
e8b05380
PB
16820fi
16821
5213506e 16822
e8b05380
PB
16823fi
16824if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
278a7a38
AO
16825
16826
16827if test -n "$RANLIB_FOR_TARGET"; then
16828 ac_cv_prog_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
16829elif test -n "$ac_cv_prog_RANLIB_FOR_TARGET"; then
16830 RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
16831fi
16832
16833if test -n "$ac_cv_prog_RANLIB_FOR_TARGET"; then
16834 for ncn_progname in ranlib; do
16835 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
16836set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16837{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16838$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16839if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
5213506e 16840 $as_echo_n "(cached) " >&6
278a7a38
AO
16841else
16842 if test -n "$RANLIB_FOR_TARGET"; then
16843 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
16844else
16845as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16846for as_dir in $PATH
16847do
16848 IFS=$as_save_IFS
16849 test -z "$as_dir" && as_dir=.
5213506e 16850 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16851 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 16852 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
5213506e 16853 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
16854 break 2
16855 fi
16856done
5213506e
RW
16857 done
16858IFS=$as_save_IFS
278a7a38
AO
16859
16860fi
16861fi
16862RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
16863if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16865$as_echo "$RANLIB_FOR_TARGET" >&6; }
278a7a38 16866else
5213506e
RW
16867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16868$as_echo "no" >&6; }
278a7a38
AO
16869fi
16870
5213506e 16871
278a7a38
AO
16872 done
16873fi
16874
16875if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 16876 for ncn_progname in ranlib; do
5213506e
RW
16877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
16878$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
16879 if test -x $with_build_time_tools/${ncn_progname}; then
16880 ac_cv_prog_RANLIB_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
16881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16882$as_echo "yes" >&6; }
e8b05380
PB
16883 break
16884 else
5213506e
RW
16885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16886$as_echo "no" >&6; }
e8b05380
PB
16887 fi
16888 done
16889fi
16890
16891if test -z "$ac_cv_prog_RANLIB_FOR_TARGET"; then
16892 for ncn_progname in ranlib; do
16893 if test -n "$ncn_target_tool_prefix"; then
16894 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
d739199a 16895set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
16896{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16897$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16898if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
5213506e 16899 $as_echo_n "(cached) " >&6
ca9f4b81 16900else
4de997d1
PB
16901 if test -n "$RANLIB_FOR_TARGET"; then
16902 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 16903else
1c710c3c
DJ
16904as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16905for as_dir in $PATH
16906do
16907 IFS=$as_save_IFS
16908 test -z "$as_dir" && as_dir=.
5213506e 16909 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16910 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16911 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 16912 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16913 break 2
16914 fi
16915done
5213506e
RW
16916 done
16917IFS=$as_save_IFS
1c710c3c 16918
ca9f4b81
AO
16919fi
16920fi
1c710c3c 16921RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
4de997d1 16922if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16924$as_echo "$RANLIB_FOR_TARGET" >&6; }
ca9f4b81 16925else
5213506e
RW
16926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16927$as_echo "no" >&6; }
ca9f4b81
AO
16928fi
16929
5213506e 16930
e8b05380
PB
16931 fi
16932 if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test $build = $target ; then
16933 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 16934set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
16935{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16936$as_echo_n "checking for $ac_word... " >&6; }
22e05272 16937if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
5213506e 16938 $as_echo_n "(cached) " >&6
ca9f4b81 16939else
2693c0b0
PB
16940 if test -n "$RANLIB_FOR_TARGET"; then
16941 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 16942else
1c710c3c
DJ
16943as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16944for as_dir in $PATH
16945do
16946 IFS=$as_save_IFS
16947 test -z "$as_dir" && as_dir=.
5213506e 16948 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 16949 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 16950 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
5213506e 16951 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
16952 break 2
16953 fi
16954done
5213506e
RW
16955 done
16956IFS=$as_save_IFS
1c710c3c 16957
ca9f4b81
AO
16958fi
16959fi
1c710c3c 16960RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
2693c0b0 16961if test -n "$RANLIB_FOR_TARGET"; then
5213506e
RW
16962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
16963$as_echo "$RANLIB_FOR_TARGET" >&6; }
ca9f4b81 16964else
5213506e
RW
16965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16966$as_echo "no" >&6; }
ca9f4b81 16967fi
1c710c3c 16968
5213506e 16969
e8b05380
PB
16970 fi
16971 test -n "$ac_cv_prog_RANLIB_FOR_TARGET" && break
16972 done
16973fi
1c710c3c 16974
e8b05380
PB
16975if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
16976 set dummy ranlib
16977 if test $build = $target ; then
16978 RANLIB_FOR_TARGET="$2"
16979 else
16980 RANLIB_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 16981 fi
1c00b503
PB
16982else
16983 RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
e8b05380 16984fi
2693c0b0 16985
d1f8db0c
PB
16986else
16987 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
ca9f4b81
AO
16988fi
16989
e8b05380
PB
16990
16991
16992
e7a82751
RM
16993if test -z "$ac_cv_path_READELF_FOR_TARGET" ; then
16994 if test -n "$with_build_time_tools"; then
16995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readelf in $with_build_time_tools" >&5
16996$as_echo_n "checking for readelf in $with_build_time_tools... " >&6; }
16997 if test -x $with_build_time_tools/readelf; then
16998 READELF_FOR_TARGET=`cd $with_build_time_tools && pwd`/readelf
16999 ac_cv_path_READELF_FOR_TARGET=$READELF_FOR_TARGET
17000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_READELF_FOR_TARGET" >&5
17001$as_echo "$ac_cv_path_READELF_FOR_TARGET" >&6; }
17002 else
17003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17004$as_echo "no" >&6; }
17005 fi
17006 elif test $build != $host && test $have_gcc_for_target = yes; then
17007 READELF_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=readelf`
17008 test $READELF_FOR_TARGET = readelf && READELF_FOR_TARGET=
17009 test -n "$READELF_FOR_TARGET" && ac_cv_path_READELF_FOR_TARGET=$READELF_FOR_TARGET
17010 fi
17011fi
17012if test -z "$ac_cv_path_READELF_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
17013 # Extract the first word of "readelf", so it can be a program name with args.
17014set dummy readelf; ac_word=$2
17015{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17016$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17017if ${ac_cv_path_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
17018 $as_echo_n "(cached) " >&6
17019else
17020 case $READELF_FOR_TARGET in
17021 [\\/]* | ?:[\\/]*)
17022 ac_cv_path_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test with a path.
17023 ;;
17024 *)
17025 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17026for as_dir in $gcc_cv_tool_dirs
17027do
17028 IFS=$as_save_IFS
17029 test -z "$as_dir" && as_dir=.
17030 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17031 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
17032 ac_cv_path_READELF_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
17033 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17034 break 2
17035 fi
17036done
17037 done
17038IFS=$as_save_IFS
17039
17040 ;;
17041esac
17042fi
17043READELF_FOR_TARGET=$ac_cv_path_READELF_FOR_TARGET
17044if test -n "$READELF_FOR_TARGET"; then
17045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
17046$as_echo "$READELF_FOR_TARGET" >&6; }
17047else
17048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17049$as_echo "no" >&6; }
17050fi
17051
17052
17053fi
17054if test -z "$ac_cv_path_READELF_FOR_TARGET" ; then
17055
17056
17057if test -n "$READELF_FOR_TARGET"; then
17058 ac_cv_prog_READELF_FOR_TARGET=$READELF_FOR_TARGET
17059elif test -n "$ac_cv_prog_READELF_FOR_TARGET"; then
17060 READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
17061fi
17062
17063if test -n "$ac_cv_prog_READELF_FOR_TARGET"; then
17064 for ncn_progname in readelf; do
17065 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17066set dummy ${ncn_progname}; ac_word=$2
17067{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17068$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17069if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
17070 $as_echo_n "(cached) " >&6
17071else
17072 if test -n "$READELF_FOR_TARGET"; then
17073 ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
17074else
17075as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17076for as_dir in $PATH
17077do
17078 IFS=$as_save_IFS
17079 test -z "$as_dir" && as_dir=.
17080 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
17082 ac_cv_prog_READELF_FOR_TARGET="${ncn_progname}"
17083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17084 break 2
17085 fi
17086done
17087 done
17088IFS=$as_save_IFS
17089
17090fi
17091fi
17092READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
17093if test -n "$READELF_FOR_TARGET"; then
17094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
17095$as_echo "$READELF_FOR_TARGET" >&6; }
17096else
17097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17098$as_echo "no" >&6; }
17099fi
17100
17101
17102 done
17103fi
17104
17105if test -z "$ac_cv_prog_READELF_FOR_TARGET" && test -n "$with_build_time_tools"; then
17106 for ncn_progname in readelf; do
17107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
17108$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
17109 if test -x $with_build_time_tools/${ncn_progname}; then
17110 ac_cv_prog_READELF_FOR_TARGET=$with_build_time_tools/${ncn_progname}
17111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17112$as_echo "yes" >&6; }
17113 break
17114 else
17115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17116$as_echo "no" >&6; }
17117 fi
17118 done
17119fi
17120
17121if test -z "$ac_cv_prog_READELF_FOR_TARGET"; then
17122 for ncn_progname in readelf; do
17123 if test -n "$ncn_target_tool_prefix"; then
17124 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
17125set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
17126{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17127$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17128if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
17129 $as_echo_n "(cached) " >&6
17130else
17131 if test -n "$READELF_FOR_TARGET"; then
17132 ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
17133else
17134as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17135for as_dir in $PATH
17136do
17137 IFS=$as_save_IFS
17138 test -z "$as_dir" && as_dir=.
17139 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17140 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
17141 ac_cv_prog_READELF_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
17142 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17143 break 2
17144 fi
17145done
17146 done
17147IFS=$as_save_IFS
17148
17149fi
17150fi
17151READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
17152if test -n "$READELF_FOR_TARGET"; then
17153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
17154$as_echo "$READELF_FOR_TARGET" >&6; }
17155else
17156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17157$as_echo "no" >&6; }
17158fi
17159
17160
17161 fi
17162 if test -z "$ac_cv_prog_READELF_FOR_TARGET" && test $build = $target ; then
17163 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17164set dummy ${ncn_progname}; ac_word=$2
17165{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17166$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17167if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
e7a82751
RM
17168 $as_echo_n "(cached) " >&6
17169else
17170 if test -n "$READELF_FOR_TARGET"; then
17171 ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
17172else
17173as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17174for as_dir in $PATH
17175do
17176 IFS=$as_save_IFS
17177 test -z "$as_dir" && as_dir=.
17178 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17179 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
e7a82751
RM
17180 ac_cv_prog_READELF_FOR_TARGET="${ncn_progname}"
17181 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17182 break 2
17183 fi
17184done
17185 done
17186IFS=$as_save_IFS
17187
17188fi
17189fi
17190READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
17191if test -n "$READELF_FOR_TARGET"; then
17192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
17193$as_echo "$READELF_FOR_TARGET" >&6; }
17194else
17195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17196$as_echo "no" >&6; }
17197fi
17198
17199
17200 fi
17201 test -n "$ac_cv_prog_READELF_FOR_TARGET" && break
17202 done
17203fi
17204
17205if test -z "$ac_cv_prog_READELF_FOR_TARGET" ; then
17206 set dummy readelf
17207 if test $build = $target ; then
17208 READELF_FOR_TARGET="$2"
17209 else
17210 READELF_FOR_TARGET="${ncn_target_tool_prefix}$2"
17211 fi
17212else
17213 READELF_FOR_TARGET="$ac_cv_prog_READELF_FOR_TARGET"
17214fi
17215
17216else
17217 READELF_FOR_TARGET=$ac_cv_path_READELF_FOR_TARGET
17218fi
17219
17220
17221
17222
e8b05380
PB
17223if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
17224 if test -n "$with_build_time_tools"; then
5213506e
RW
17225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strip in $with_build_time_tools" >&5
17226$as_echo_n "checking for strip in $with_build_time_tools... " >&6; }
d1f8db0c
PB
17227 if test -x $with_build_time_tools/strip; then
17228 STRIP_FOR_TARGET=`cd $with_build_time_tools && pwd`/strip
17229 ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
5213506e
RW
17230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_STRIP_FOR_TARGET" >&5
17231$as_echo "$ac_cv_path_STRIP_FOR_TARGET" >&6; }
d1f8db0c 17232 else
5213506e
RW
17233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17234$as_echo "no" >&6; }
d1f8db0c 17235 fi
e8b05380
PB
17236 elif test $build != $host && test $have_gcc_for_target = yes; then
17237 STRIP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=strip`
1c00b503
PB
17238 test $STRIP_FOR_TARGET = strip && STRIP_FOR_TARGET=
17239 test -n "$STRIP_FOR_TARGET" && ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
e8b05380
PB
17240 fi
17241fi
3e19841a 17242if test -z "$ac_cv_path_STRIP_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
17243 # Extract the first word of "strip", so it can be a program name with args.
17244set dummy strip; ac_word=$2
5213506e
RW
17245{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17246$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17247if ${ac_cv_path_STRIP_FOR_TARGET+:} false; then :
5213506e 17248 $as_echo_n "(cached) " >&6
e8b05380 17249else
1c710c3c
DJ
17250 case $STRIP_FOR_TARGET in
17251 [\\/]* | ?:[\\/]*)
e8b05380
PB
17252 ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a path.
17253 ;;
e8b05380 17254 *)
1c710c3c
DJ
17255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17256for as_dir in $gcc_cv_tool_dirs
17257do
17258 IFS=$as_save_IFS
17259 test -z "$as_dir" && as_dir=.
5213506e 17260 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17262 ac_cv_path_STRIP_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 17263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17264 break 2
17265 fi
17266done
5213506e
RW
17267 done
17268IFS=$as_save_IFS
1c710c3c 17269
e8b05380
PB
17270 ;;
17271esac
17272fi
1c710c3c 17273STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
e8b05380 17274if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
17275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
17276$as_echo "$STRIP_FOR_TARGET" >&6; }
e8b05380 17277else
5213506e
RW
17278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17279$as_echo "no" >&6; }
e8b05380
PB
17280fi
17281
5213506e 17282
e8b05380
PB
17283fi
17284if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
278a7a38
AO
17285
17286
17287if test -n "$STRIP_FOR_TARGET"; then
17288 ac_cv_prog_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
17289elif test -n "$ac_cv_prog_STRIP_FOR_TARGET"; then
17290 STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
17291fi
17292
17293if test -n "$ac_cv_prog_STRIP_FOR_TARGET"; then
17294 for ncn_progname in strip; do
17295 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17296set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17297{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17298$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17299if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
5213506e 17300 $as_echo_n "(cached) " >&6
278a7a38
AO
17301else
17302 if test -n "$STRIP_FOR_TARGET"; then
17303 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
17304else
17305as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17306for as_dir in $PATH
17307do
17308 IFS=$as_save_IFS
17309 test -z "$as_dir" && as_dir=.
5213506e 17310 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17311 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 17312 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
5213506e 17313 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
17314 break 2
17315 fi
17316done
5213506e
RW
17317 done
17318IFS=$as_save_IFS
278a7a38
AO
17319
17320fi
17321fi
17322STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
17323if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
17324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
17325$as_echo "$STRIP_FOR_TARGET" >&6; }
278a7a38 17326else
5213506e
RW
17327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17328$as_echo "no" >&6; }
278a7a38
AO
17329fi
17330
5213506e 17331
278a7a38
AO
17332 done
17333fi
17334
17335if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 17336 for ncn_progname in strip; do
5213506e
RW
17337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
17338$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
17339 if test -x $with_build_time_tools/${ncn_progname}; then
17340 ac_cv_prog_STRIP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
17341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17342$as_echo "yes" >&6; }
e8b05380
PB
17343 break
17344 else
5213506e
RW
17345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17346$as_echo "no" >&6; }
e8b05380
PB
17347 fi
17348 done
17349fi
17350
17351if test -z "$ac_cv_prog_STRIP_FOR_TARGET"; then
17352 for ncn_progname in strip; do
17353 if test -n "$ncn_target_tool_prefix"; then
17354 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 17355set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
17356{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17357$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17358if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
5213506e 17359 $as_echo_n "(cached) " >&6
af71363e
AS
17360else
17361 if test -n "$STRIP_FOR_TARGET"; then
1c710c3c
DJ
17362 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
17363else
17364as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17365for as_dir in $PATH
17366do
17367 IFS=$as_save_IFS
17368 test -z "$as_dir" && as_dir=.
5213506e 17369 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17370 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17371 ac_cv_prog_STRIP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 17372 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17373 break 2
17374 fi
17375done
5213506e
RW
17376 done
17377IFS=$as_save_IFS
1c710c3c 17378
040b1c5a
GK
17379fi
17380fi
1c710c3c 17381STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
040b1c5a 17382if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
17383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
17384$as_echo "$STRIP_FOR_TARGET" >&6; }
040b1c5a 17385else
5213506e
RW
17386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17387$as_echo "no" >&6; }
040b1c5a
GK
17388fi
17389
5213506e 17390
e8b05380
PB
17391 fi
17392 if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test $build = $target ; then
17393 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 17394set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17395{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17396$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17397if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
5213506e 17398 $as_echo_n "(cached) " >&6
040b1c5a
GK
17399else
17400 if test -n "$STRIP_FOR_TARGET"; then
17401 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
17402else
1c710c3c
DJ
17403as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17404for as_dir in $PATH
17405do
17406 IFS=$as_save_IFS
17407 test -z "$as_dir" && as_dir=.
5213506e 17408 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17409 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17410 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
5213506e 17411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17412 break 2
17413 fi
17414done
5213506e
RW
17415 done
17416IFS=$as_save_IFS
1c710c3c 17417
040b1c5a
GK
17418fi
17419fi
1c710c3c 17420STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
040b1c5a 17421if test -n "$STRIP_FOR_TARGET"; then
5213506e
RW
17422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
17423$as_echo "$STRIP_FOR_TARGET" >&6; }
040b1c5a 17424else
5213506e
RW
17425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17426$as_echo "no" >&6; }
040b1c5a 17427fi
1c710c3c 17428
5213506e 17429
e8b05380
PB
17430 fi
17431 test -n "$ac_cv_prog_STRIP_FOR_TARGET" && break
17432 done
17433fi
1c710c3c 17434
040b1c5a
GK
17435if test -z "$ac_cv_prog_STRIP_FOR_TARGET" ; then
17436 set dummy strip
17437 if test $build = $target ; then
17438 STRIP_FOR_TARGET="$2"
17439 else
17440 STRIP_FOR_TARGET="${ncn_target_tool_prefix}$2"
17441 fi
1c00b503
PB
17442else
17443 STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
040b1c5a
GK
17444fi
17445
d1f8db0c
PB
17446else
17447 STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
e8b05380
PB
17448fi
17449
17450
17451
17452
17453if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
17454 if test -n "$with_build_time_tools"; then
5213506e
RW
17455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windres in $with_build_time_tools" >&5
17456$as_echo_n "checking for windres in $with_build_time_tools... " >&6; }
d1f8db0c
PB
17457 if test -x $with_build_time_tools/windres; then
17458 WINDRES_FOR_TARGET=`cd $with_build_time_tools && pwd`/windres
17459 ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
5213506e
RW
17460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_WINDRES_FOR_TARGET" >&5
17461$as_echo "$ac_cv_path_WINDRES_FOR_TARGET" >&6; }
d1f8db0c 17462 else
5213506e
RW
17463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17464$as_echo "no" >&6; }
d1f8db0c 17465 fi
e8b05380
PB
17466 elif test $build != $host && test $have_gcc_for_target = yes; then
17467 WINDRES_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windres`
1c00b503
PB
17468 test $WINDRES_FOR_TARGET = windres && WINDRES_FOR_TARGET=
17469 test -n "$WINDRES_FOR_TARGET" && ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
e8b05380
PB
17470 fi
17471fi
3e19841a 17472if test -z "$ac_cv_path_WINDRES_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
e8b05380
PB
17473 # Extract the first word of "windres", so it can be a program name with args.
17474set dummy windres; ac_word=$2
5213506e
RW
17475{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17476$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17477if ${ac_cv_path_WINDRES_FOR_TARGET+:} false; then :
5213506e 17478 $as_echo_n "(cached) " >&6
e8b05380 17479else
1c710c3c
DJ
17480 case $WINDRES_FOR_TARGET in
17481 [\\/]* | ?:[\\/]*)
e8b05380
PB
17482 ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a path.
17483 ;;
e8b05380 17484 *)
1c710c3c
DJ
17485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17486for as_dir in $gcc_cv_tool_dirs
17487do
17488 IFS=$as_save_IFS
17489 test -z "$as_dir" && as_dir=.
5213506e 17490 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17491 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17492 ac_cv_path_WINDRES_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 17493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17494 break 2
17495 fi
17496done
5213506e
RW
17497 done
17498IFS=$as_save_IFS
1c710c3c 17499
e8b05380
PB
17500 ;;
17501esac
17502fi
1c710c3c 17503WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
e8b05380 17504if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
17505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
17506$as_echo "$WINDRES_FOR_TARGET" >&6; }
e8b05380 17507else
5213506e
RW
17508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17509$as_echo "no" >&6; }
e8b05380
PB
17510fi
17511
5213506e 17512
e8b05380
PB
17513fi
17514if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
278a7a38
AO
17515
17516
17517if test -n "$WINDRES_FOR_TARGET"; then
17518 ac_cv_prog_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
17519elif test -n "$ac_cv_prog_WINDRES_FOR_TARGET"; then
17520 WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
17521fi
17522
17523if test -n "$ac_cv_prog_WINDRES_FOR_TARGET"; then
17524 for ncn_progname in windres; do
17525 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17526set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17527{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17528$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17529if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
5213506e 17530 $as_echo_n "(cached) " >&6
278a7a38
AO
17531else
17532 if test -n "$WINDRES_FOR_TARGET"; then
17533 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
17534else
17535as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17536for as_dir in $PATH
17537do
17538 IFS=$as_save_IFS
17539 test -z "$as_dir" && as_dir=.
5213506e 17540 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17541 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
278a7a38 17542 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
5213506e 17543 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
278a7a38
AO
17544 break 2
17545 fi
17546done
5213506e
RW
17547 done
17548IFS=$as_save_IFS
278a7a38
AO
17549
17550fi
17551fi
17552WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
17553if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
17554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
17555$as_echo "$WINDRES_FOR_TARGET" >&6; }
278a7a38 17556else
5213506e
RW
17557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17558$as_echo "no" >&6; }
278a7a38
AO
17559fi
17560
5213506e 17561
278a7a38
AO
17562 done
17563fi
17564
17565if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test -n "$with_build_time_tools"; then
e8b05380 17566 for ncn_progname in windres; do
5213506e
RW
17567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
17568$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
d1f8db0c
PB
17569 if test -x $with_build_time_tools/${ncn_progname}; then
17570 ac_cv_prog_WINDRES_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
17571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17572$as_echo "yes" >&6; }
e8b05380
PB
17573 break
17574 else
5213506e
RW
17575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17576$as_echo "no" >&6; }
e8b05380
PB
17577 fi
17578 done
17579fi
17580
17581if test -z "$ac_cv_prog_WINDRES_FOR_TARGET"; then
17582 for ncn_progname in windres; do
17583 if test -n "$ncn_target_tool_prefix"; then
17584 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 17585set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
17586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17587$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17588if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
5213506e 17589 $as_echo_n "(cached) " >&6
ca9f4b81 17590else
4de997d1
PB
17591 if test -n "$WINDRES_FOR_TARGET"; then
17592 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 17593else
1c710c3c
DJ
17594as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17595for as_dir in $PATH
17596do
17597 IFS=$as_save_IFS
17598 test -z "$as_dir" && as_dir=.
5213506e 17599 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17601 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 17602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17603 break 2
17604 fi
17605done
5213506e
RW
17606 done
17607IFS=$as_save_IFS
1c710c3c 17608
ca9f4b81
AO
17609fi
17610fi
1c710c3c 17611WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
4de997d1 17612if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
17613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
17614$as_echo "$WINDRES_FOR_TARGET" >&6; }
ca9f4b81 17615else
5213506e
RW
17616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17617$as_echo "no" >&6; }
ca9f4b81
AO
17618fi
17619
5213506e 17620
e8b05380
PB
17621 fi
17622 if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test $build = $target ; then
17623 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 17624set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17625{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17626$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17627if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
5213506e 17628 $as_echo_n "(cached) " >&6
ca9f4b81 17629else
2693c0b0
PB
17630 if test -n "$WINDRES_FOR_TARGET"; then
17631 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 17632else
1c710c3c
DJ
17633as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17634for as_dir in $PATH
17635do
17636 IFS=$as_save_IFS
17637 test -z "$as_dir" && as_dir=.
5213506e 17638 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17639 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1c710c3c 17640 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
5213506e 17641 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
1c710c3c
DJ
17642 break 2
17643 fi
17644done
5213506e
RW
17645 done
17646IFS=$as_save_IFS
1c710c3c 17647
ca9f4b81
AO
17648fi
17649fi
1c710c3c 17650WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
2693c0b0 17651if test -n "$WINDRES_FOR_TARGET"; then
5213506e
RW
17652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
17653$as_echo "$WINDRES_FOR_TARGET" >&6; }
ca9f4b81 17654else
5213506e
RW
17655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17656$as_echo "no" >&6; }
ca9f4b81 17657fi
1c710c3c 17658
5213506e 17659
e8b05380
PB
17660 fi
17661 test -n "$ac_cv_prog_WINDRES_FOR_TARGET" && break
17662 done
17663fi
1c710c3c 17664
2693c0b0
PB
17665if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
17666 set dummy windres
17667 if test $build = $target ; then
17668 WINDRES_FOR_TARGET="$2"
ca9f4b81 17669 else
2693c0b0 17670 WINDRES_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 17671 fi
1c00b503
PB
17672else
17673 WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
ca9f4b81
AO
17674fi
17675
d1f8db0c
PB
17676else
17677 WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
e8b05380
PB
17678fi
17679
4977bab6 17680
901119ae
KT
17681
17682
17683if test -z "$ac_cv_path_WINDMC_FOR_TARGET" ; then
17684 if test -n "$with_build_time_tools"; then
5213506e
RW
17685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windmc in $with_build_time_tools" >&5
17686$as_echo_n "checking for windmc in $with_build_time_tools... " >&6; }
901119ae
KT
17687 if test -x $with_build_time_tools/windmc; then
17688 WINDMC_FOR_TARGET=`cd $with_build_time_tools && pwd`/windmc
17689 ac_cv_path_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
5213506e
RW
17690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_WINDMC_FOR_TARGET" >&5
17691$as_echo "$ac_cv_path_WINDMC_FOR_TARGET" >&6; }
901119ae 17692 else
5213506e
RW
17693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17694$as_echo "no" >&6; }
901119ae
KT
17695 fi
17696 elif test $build != $host && test $have_gcc_for_target = yes; then
17697 WINDMC_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windmc`
1c00b503
PB
17698 test $WINDMC_FOR_TARGET = windmc && WINDMC_FOR_TARGET=
17699 test -n "$WINDMC_FOR_TARGET" && ac_cv_path_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
901119ae
KT
17700 fi
17701fi
17702if test -z "$ac_cv_path_WINDMC_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
17703 # Extract the first word of "windmc", so it can be a program name with args.
17704set dummy windmc; ac_word=$2
5213506e
RW
17705{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17706$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17707if ${ac_cv_path_WINDMC_FOR_TARGET+:} false; then :
5213506e 17708 $as_echo_n "(cached) " >&6
901119ae
KT
17709else
17710 case $WINDMC_FOR_TARGET in
17711 [\\/]* | ?:[\\/]*)
17712 ac_cv_path_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test with a path.
17713 ;;
17714 *)
17715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17716for as_dir in $gcc_cv_tool_dirs
17717do
17718 IFS=$as_save_IFS
17719 test -z "$as_dir" && as_dir=.
5213506e 17720 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17721 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17722 ac_cv_path_WINDMC_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
5213506e 17723 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17724 break 2
17725 fi
17726done
5213506e
RW
17727 done
17728IFS=$as_save_IFS
901119ae
KT
17729
17730 ;;
17731esac
17732fi
17733WINDMC_FOR_TARGET=$ac_cv_path_WINDMC_FOR_TARGET
901119ae 17734if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17736$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17737else
5213506e
RW
17738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17739$as_echo "no" >&6; }
901119ae
KT
17740fi
17741
5213506e 17742
901119ae
KT
17743fi
17744if test -z "$ac_cv_path_WINDMC_FOR_TARGET" ; then
17745
17746
17747if test -n "$WINDMC_FOR_TARGET"; then
17748 ac_cv_prog_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
17749elif test -n "$ac_cv_prog_WINDMC_FOR_TARGET"; then
17750 WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17751fi
17752
17753if test -n "$ac_cv_prog_WINDMC_FOR_TARGET"; then
17754 for ncn_progname in windmc; do
17755 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17756set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17757{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17758$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17759if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
5213506e 17760 $as_echo_n "(cached) " >&6
901119ae
KT
17761else
17762 if test -n "$WINDMC_FOR_TARGET"; then
17763 ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
17764else
17765as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17766for as_dir in $PATH
17767do
17768 IFS=$as_save_IFS
17769 test -z "$as_dir" && as_dir=.
5213506e 17770 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17771 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17772 ac_cv_prog_WINDMC_FOR_TARGET="${ncn_progname}"
5213506e 17773 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17774 break 2
17775 fi
17776done
5213506e
RW
17777 done
17778IFS=$as_save_IFS
901119ae
KT
17779
17780fi
17781fi
17782WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17783if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17785$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17786else
5213506e
RW
17787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17788$as_echo "no" >&6; }
901119ae
KT
17789fi
17790
5213506e 17791
901119ae
KT
17792 done
17793fi
17794
17795if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" && test -n "$with_build_time_tools"; then
17796 for ncn_progname in windmc; do
5213506e
RW
17797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
17798$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
901119ae
KT
17799 if test -x $with_build_time_tools/${ncn_progname}; then
17800 ac_cv_prog_WINDMC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
5213506e
RW
17801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17802$as_echo "yes" >&6; }
901119ae
KT
17803 break
17804 else
5213506e
RW
17805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17806$as_echo "no" >&6; }
901119ae
KT
17807 fi
17808 done
17809fi
17810
17811if test -z "$ac_cv_prog_WINDMC_FOR_TARGET"; then
17812 for ncn_progname in windmc; do
17813 if test -n "$ncn_target_tool_prefix"; then
17814 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
17815set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5213506e
RW
17816{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17817$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17818if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
5213506e 17819 $as_echo_n "(cached) " >&6
901119ae
KT
17820else
17821 if test -n "$WINDMC_FOR_TARGET"; then
17822 ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
17823else
17824as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17825for as_dir in $PATH
17826do
17827 IFS=$as_save_IFS
17828 test -z "$as_dir" && as_dir=.
5213506e 17829 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17830 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17831 ac_cv_prog_WINDMC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5213506e 17832 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17833 break 2
17834 fi
17835done
5213506e
RW
17836 done
17837IFS=$as_save_IFS
901119ae
KT
17838
17839fi
17840fi
17841WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17842if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17844$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17845else
5213506e
RW
17846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17847$as_echo "no" >&6; }
901119ae
KT
17848fi
17849
5213506e 17850
901119ae
KT
17851 fi
17852 if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" && test $build = $target ; then
17853 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
17854set dummy ${ncn_progname}; ac_word=$2
5213506e
RW
17855{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17856$as_echo_n "checking for $ac_word... " >&6; }
22e05272 17857if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
5213506e 17858 $as_echo_n "(cached) " >&6
901119ae
KT
17859else
17860 if test -n "$WINDMC_FOR_TARGET"; then
17861 ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
17862else
17863as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17864for as_dir in $PATH
17865do
17866 IFS=$as_save_IFS
17867 test -z "$as_dir" && as_dir=.
5213506e 17868 for ac_exec_ext in '' $ac_executable_extensions; do
22e05272 17869 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
901119ae 17870 ac_cv_prog_WINDMC_FOR_TARGET="${ncn_progname}"
5213506e 17871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
901119ae
KT
17872 break 2
17873 fi
17874done
5213506e
RW
17875 done
17876IFS=$as_save_IFS
901119ae
KT
17877
17878fi
17879fi
17880WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
17881if test -n "$WINDMC_FOR_TARGET"; then
5213506e
RW
17882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
17883$as_echo "$WINDMC_FOR_TARGET" >&6; }
901119ae 17884else
5213506e
RW
17885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17886$as_echo "no" >&6; }
901119ae
KT
17887fi
17888
5213506e 17889
901119ae
KT
17890 fi
17891 test -n "$ac_cv_prog_WINDMC_FOR_TARGET" && break
17892 done
17893fi
17894
17895if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" ; then
17896 set dummy windmc
17897 if test $build = $target ; then
17898 WINDMC_FOR_TARGET="$2"
17899 else
17900 WINDMC_FOR_TARGET="${ncn_target_tool_prefix}$2"
17901 fi
1c00b503
PB
17902else
17903 WINDMC_FOR_TARGET="$ac_cv_prog_WINDMC_FOR_TARGET"
901119ae
KT
17904fi
17905
17906else
17907 WINDMC_FOR_TARGET=$ac_cv_path_WINDMC_FOR_TARGET
17908fi
17909
17910
2abefe3d
PB
17911RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET"
17912
5213506e
RW
17913{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ar" >&5
17914$as_echo_n "checking where to find the target ar... " >&6; }
2abefe3d 17915if test "x${build}" != "x${host}" ; then
e8b05380
PB
17916 if expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
17917 # We already found the complete path
172e41aa 17918 ac_dir=`dirname $AR_FOR_TARGET`
5213506e
RW
17919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17920$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17921 else
17922 # Canadian cross, just use what we found
5213506e
RW
17923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17924$as_echo "pre-installed" >&6; }
e8b05380 17925 fi
2abefe3d
PB
17926else
17927 ok=yes
17928 case " ${configdirs} " in
17929 *" binutils "*) ;;
17930 *) ok=no ;;
17931 esac
1c710c3c 17932
2abefe3d
PB
17933 if test $ok = yes; then
17934 # An in-tree tool is available and we can use it
17935 AR_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ar'
5213506e
RW
17936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17937$as_echo "just compiled" >&6; }
e8b05380
PB
17938 elif expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
17939 # We already found the complete path
172e41aa 17940 ac_dir=`dirname $AR_FOR_TARGET`
5213506e
RW
17941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17942$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17943 elif test "x$target" = "x$host"; then
17944 # We can use an host tool
17945 AR_FOR_TARGET='$(AR)'
5213506e
RW
17946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17947$as_echo "host tool" >&6; }
2abefe3d
PB
17948 else
17949 # We need a cross tool
5213506e
RW
17950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17951$as_echo "pre-installed" >&6; }
2abefe3d
PB
17952 fi
17953fi
0b0dc272 17954
5213506e
RW
17955{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target as" >&5
17956$as_echo_n "checking where to find the target as... " >&6; }
2abefe3d 17957if test "x${build}" != "x${host}" ; then
e8b05380
PB
17958 if expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
17959 # We already found the complete path
172e41aa 17960 ac_dir=`dirname $AS_FOR_TARGET`
5213506e
RW
17961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17962$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
17963 else
17964 # Canadian cross, just use what we found
5213506e
RW
17965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17966$as_echo "pre-installed" >&6; }
e8b05380 17967 fi
2abefe3d
PB
17968else
17969 ok=yes
17970 case " ${configdirs} " in
17971 *" gas "*) ;;
17972 *) ok=no ;;
17973 esac
1c710c3c 17974
2abefe3d
PB
17975 if test $ok = yes; then
17976 # An in-tree tool is available and we can use it
17977 AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gas/as-new'
5213506e
RW
17978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
17979$as_echo "just compiled" >&6; }
e8b05380
PB
17980 elif expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
17981 # We already found the complete path
172e41aa 17982 ac_dir=`dirname $AS_FOR_TARGET`
5213506e
RW
17983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
17984$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
17985 elif test "x$target" = "x$host"; then
17986 # We can use an host tool
17987 AS_FOR_TARGET='$(AS)'
5213506e
RW
17988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
17989$as_echo "host tool" >&6; }
2abefe3d
PB
17990 else
17991 # We need a cross tool
5213506e
RW
17992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
17993$as_echo "pre-installed" >&6; }
2abefe3d
PB
17994 fi
17995fi
0b0dc272 17996
5213506e
RW
17997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target cc" >&5
17998$as_echo_n "checking where to find the target cc... " >&6; }
2abefe3d 17999if test "x${build}" != "x${host}" ; then
e8b05380
PB
18000 if expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
18001 # We already found the complete path
172e41aa 18002 ac_dir=`dirname $CC_FOR_TARGET`
5213506e
RW
18003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18004$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18005 else
18006 # Canadian cross, just use what we found
5213506e
RW
18007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18008$as_echo "pre-installed" >&6; }
e8b05380 18009 fi
2abefe3d
PB
18010else
18011 ok=yes
18012 case " ${configdirs} " in
18013 *" gcc "*) ;;
18014 *) ok=no ;;
18015 esac
1c710c3c 18016
2abefe3d
PB
18017 if test $ok = yes; then
18018 # An in-tree tool is available and we can use it
18019 CC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
5213506e
RW
18020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18021$as_echo "just compiled" >&6; }
e8b05380
PB
18022 elif expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
18023 # We already found the complete path
172e41aa 18024 ac_dir=`dirname $CC_FOR_TARGET`
5213506e
RW
18025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18026$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18027 elif test "x$target" = "x$host"; then
18028 # We can use an host tool
18029 CC_FOR_TARGET='$(CC)'
5213506e
RW
18030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18031$as_echo "host tool" >&6; }
2abefe3d
PB
18032 else
18033 # We need a cross tool
5213506e
RW
18034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18035$as_echo "pre-installed" >&6; }
2abefe3d
PB
18036 fi
18037fi
0b0dc272 18038
5213506e
RW
18039{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target c++" >&5
18040$as_echo_n "checking where to find the target c++... " >&6; }
2abefe3d 18041if test "x${build}" != "x${host}" ; then
e8b05380
PB
18042 if expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
18043 # We already found the complete path
172e41aa 18044 ac_dir=`dirname $CXX_FOR_TARGET`
5213506e
RW
18045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18046$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18047 else
18048 # Canadian cross, just use what we found
5213506e
RW
18049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18050$as_echo "pre-installed" >&6; }
e8b05380 18051 fi
2abefe3d
PB
18052else
18053 ok=yes
18054 case " ${configdirs} " in
18055 *" gcc "*) ;;
18056 *) ok=no ;;
18057 esac
18058 case ,${enable_languages}, in
18059 *,c++,*) ;;
18060 *) ok=no ;;
18061 esac
18062 if test $ok = yes; then
18063 # An in-tree tool is available and we can use it
2077db1b 18064 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
18065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18066$as_echo "just compiled" >&6; }
e8b05380
PB
18067 elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
18068 # We already found the complete path
172e41aa 18069 ac_dir=`dirname $CXX_FOR_TARGET`
5213506e
RW
18070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18071$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18072 elif test "x$target" = "x$host"; then
18073 # We can use an host tool
18074 CXX_FOR_TARGET='$(CXX)'
5213506e
RW
18075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18076$as_echo "host tool" >&6; }
2abefe3d
PB
18077 else
18078 # We need a cross tool
5213506e
RW
18079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18080$as_echo "pre-installed" >&6; }
2abefe3d
PB
18081 fi
18082fi
0b0dc272 18083
5213506e
RW
18084{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target c++ for libstdc++" >&5
18085$as_echo_n "checking where to find the target c++ for libstdc++... " >&6; }
2abefe3d 18086if test "x${build}" != "x${host}" ; then
e8b05380
PB
18087 if expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
18088 # We already found the complete path
172e41aa 18089 ac_dir=`dirname $RAW_CXX_FOR_TARGET`
5213506e
RW
18090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18091$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18092 else
18093 # Canadian cross, just use what we found
5213506e
RW
18094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18095$as_echo "pre-installed" >&6; }
e8b05380 18096 fi
2abefe3d
PB
18097else
18098 ok=yes
18099 case " ${configdirs} " in
18100 *" gcc "*) ;;
18101 *) ok=no ;;
18102 esac
18103 case ,${enable_languages}, in
18104 *,c++,*) ;;
18105 *) ok=no ;;
18106 esac
18107 if test $ok = yes; then
18108 # An in-tree tool is available and we can use it
2077db1b 18109 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
18110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18111$as_echo "just compiled" >&6; }
e8b05380
PB
18112 elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
18113 # We already found the complete path
172e41aa 18114 ac_dir=`dirname $RAW_CXX_FOR_TARGET`
5213506e
RW
18115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18116$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18117 elif test "x$target" = "x$host"; then
18118 # We can use an host tool
18119 RAW_CXX_FOR_TARGET='$(CXX)'
5213506e
RW
18120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18121$as_echo "host tool" >&6; }
2abefe3d
PB
18122 else
18123 # We need a cross tool
5213506e
RW
18124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18125$as_echo "pre-installed" >&6; }
2abefe3d
PB
18126 fi
18127fi
0b0dc272 18128
5213506e
RW
18129{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dlltool" >&5
18130$as_echo_n "checking where to find the target dlltool... " >&6; }
2abefe3d 18131if test "x${build}" != "x${host}" ; then
e8b05380
PB
18132 if expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
18133 # We already found the complete path
172e41aa 18134 ac_dir=`dirname $DLLTOOL_FOR_TARGET`
5213506e
RW
18135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18136$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18137 else
18138 # Canadian cross, just use what we found
5213506e
RW
18139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18140$as_echo "pre-installed" >&6; }
e8b05380 18141 fi
2abefe3d
PB
18142else
18143 ok=yes
18144 case " ${configdirs} " in
18145 *" binutils "*) ;;
18146 *) ok=no ;;
18147 esac
1c710c3c 18148
2abefe3d
PB
18149 if test $ok = yes; then
18150 # An in-tree tool is available and we can use it
18151 DLLTOOL_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/dlltool'
5213506e
RW
18152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18153$as_echo "just compiled" >&6; }
e8b05380
PB
18154 elif expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
18155 # We already found the complete path
172e41aa 18156 ac_dir=`dirname $DLLTOOL_FOR_TARGET`
5213506e
RW
18157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18158$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18159 elif test "x$target" = "x$host"; then
18160 # We can use an host tool
18161 DLLTOOL_FOR_TARGET='$(DLLTOOL)'
5213506e
RW
18162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18163$as_echo "host tool" >&6; }
2abefe3d
PB
18164 else
18165 # We need a cross tool
5213506e
RW
18166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18167$as_echo "pre-installed" >&6; }
2abefe3d
PB
18168 fi
18169fi
0b0dc272 18170
3b5e8ee4
IS
18171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dsymutil" >&5
18172$as_echo_n "checking where to find the target dsymutil... " >&6; }
18173if test "x${build}" != "x${host}" ; then
18174 if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
18175 # We already found the complete path
18176 ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
18177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18178$as_echo "pre-installed in $ac_dir" >&6; }
18179 else
18180 # Canadian cross, just use what we found
18181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18182$as_echo "pre-installed" >&6; }
18183 fi
18184else
18185 if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
18186 # We already found the complete path
18187 ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
18188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18189$as_echo "pre-installed in $ac_dir" >&6; }
18190 elif test "x$target" = "x$host"; then
18191 # We can use an host tool
18192 DSYMUTIL_FOR_TARGET='$(DSYMUTIL)'
18193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18194$as_echo "host tool" >&6; }
18195 else
18196 # We need a cross tool
18197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18198$as_echo "pre-installed" >&6; }
18199 fi
18200fi
18201
5213506e
RW
18202{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gcc" >&5
18203$as_echo_n "checking where to find the target gcc... " >&6; }
2abefe3d 18204if test "x${build}" != "x${host}" ; then
e8b05380
PB
18205 if expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
18206 # We already found the complete path
172e41aa 18207 ac_dir=`dirname $GCC_FOR_TARGET`
5213506e
RW
18208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18209$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18210 else
18211 # Canadian cross, just use what we found
5213506e
RW
18212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18213$as_echo "pre-installed" >&6; }
e8b05380 18214 fi
2abefe3d
PB
18215else
18216 ok=yes
18217 case " ${configdirs} " in
18218 *" gcc "*) ;;
18219 *) ok=no ;;
18220 esac
1c710c3c 18221
2abefe3d
PB
18222 if test $ok = yes; then
18223 # An in-tree tool is available and we can use it
18224 GCC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
5213506e
RW
18225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18226$as_echo "just compiled" >&6; }
e8b05380
PB
18227 elif expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
18228 # We already found the complete path
172e41aa 18229 ac_dir=`dirname $GCC_FOR_TARGET`
5213506e
RW
18230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18231$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18232 elif test "x$target" = "x$host"; then
18233 # We can use an host tool
18234 GCC_FOR_TARGET='$()'
5213506e
RW
18235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18236$as_echo "host tool" >&6; }
2abefe3d
PB
18237 else
18238 # We need a cross tool
5213506e
RW
18239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18240$as_echo "pre-installed" >&6; }
2abefe3d
PB
18241 fi
18242fi
0b0dc272 18243
5213506e
RW
18244{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gfortran" >&5
18245$as_echo_n "checking where to find the target gfortran... " >&6; }
2abefe3d 18246if test "x${build}" != "x${host}" ; then
e8b05380
PB
18247 if expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
18248 # We already found the complete path
172e41aa 18249 ac_dir=`dirname $GFORTRAN_FOR_TARGET`
5213506e
RW
18250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18251$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18252 else
18253 # Canadian cross, just use what we found
5213506e
RW
18254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18255$as_echo "pre-installed" >&6; }
e8b05380 18256 fi
2abefe3d
PB
18257else
18258 ok=yes
18259 case " ${configdirs} " in
18260 *" gcc "*) ;;
18261 *) ok=no ;;
18262 esac
18263 case ,${enable_languages}, in
18264 *,fortran,*) ;;
18265 *) ok=no ;;
18266 esac
18267 if test $ok = yes; then
18268 # An in-tree tool is available and we can use it
18269 GFORTRAN_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/'
5213506e
RW
18270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18271$as_echo "just compiled" >&6; }
e8b05380
PB
18272 elif expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
18273 # We already found the complete path
172e41aa 18274 ac_dir=`dirname $GFORTRAN_FOR_TARGET`
5213506e
RW
18275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18276$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18277 elif test "x$target" = "x$host"; then
18278 # We can use an host tool
18279 GFORTRAN_FOR_TARGET='$(GFORTRAN)'
5213506e
RW
18280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18281$as_echo "host tool" >&6; }
2abefe3d
PB
18282 else
18283 # We need a cross tool
5213506e
RW
18284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18285$as_echo "pre-installed" >&6; }
2abefe3d
PB
18286 fi
18287fi
0b0dc272 18288
632e2a07
ILT
18289{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gccgo" >&5
18290$as_echo_n "checking where to find the target gccgo... " >&6; }
18291if test "x${build}" != "x${host}" ; then
18292 if expr "x$GOC_FOR_TARGET" : "x/" > /dev/null; then
18293 # We already found the complete path
18294 ac_dir=`dirname $GOC_FOR_TARGET`
18295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18296$as_echo "pre-installed in $ac_dir" >&6; }
18297 else
18298 # Canadian cross, just use what we found
18299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18300$as_echo "pre-installed" >&6; }
18301 fi
18302else
18303 ok=yes
18304 case " ${configdirs} " in
18305 *" gcc "*) ;;
18306 *) ok=no ;;
18307 esac
18308 case ,${enable_languages}, in
18309 *,go,*) ;;
18310 *) ok=no ;;
18311 esac
18312 if test $ok = yes; then
18313 # An in-tree tool is available and we can use it
18314 GOC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gccgo -B$$r/$(HOST_SUBDIR)/gcc/'
18315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18316$as_echo "just compiled" >&6; }
18317 elif expr "x$GOC_FOR_TARGET" : "x/" > /dev/null; then
18318 # We already found the complete path
18319 ac_dir=`dirname $GOC_FOR_TARGET`
18320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18321$as_echo "pre-installed in $ac_dir" >&6; }
18322 elif test "x$target" = "x$host"; then
18323 # We can use an host tool
18324 GOC_FOR_TARGET='$(GOC)'
18325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18326$as_echo "host tool" >&6; }
18327 else
18328 # We need a cross tool
18329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18330$as_echo "pre-installed" >&6; }
18331 fi
18332fi
18333
b4c522fa
IB
18334{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gdc" >&5
18335$as_echo_n "checking where to find the target gdc... " >&6; }
18336if test "x${build}" != "x${host}" ; then
18337 if expr "x$GDC_FOR_TARGET" : "x/" > /dev/null; then
18338 # We already found the complete path
18339 ac_dir=`dirname $GDC_FOR_TARGET`
18340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18341$as_echo "pre-installed in $ac_dir" >&6; }
18342 else
18343 # Canadian cross, just use what we found
18344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18345$as_echo "pre-installed" >&6; }
18346 fi
18347else
18348 ok=yes
18349 case " ${configdirs} " in
18350 *" gcc "*) ;;
18351 *) ok=no ;;
18352 esac
18353 case ,${enable_languages}, in
18354 *,d,*) ;;
18355 *) ok=no ;;
18356 esac
18357 if test $ok = yes; then
18358 # An in-tree tool is available and we can use it
18359 GDC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gdc -B$$r/$(HOST_SUBDIR)/gcc/'
18360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18361$as_echo "just compiled" >&6; }
18362 elif expr "x$GDC_FOR_TARGET" : "x/" > /dev/null; then
18363 # We already found the complete path
18364 ac_dir=`dirname $GDC_FOR_TARGET`
18365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18366$as_echo "pre-installed in $ac_dir" >&6; }
18367 elif test "x$target" = "x$host"; then
18368 # We can use an host tool
18369 GDC_FOR_TARGET='$(GDC)'
18370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18371$as_echo "host tool" >&6; }
18372 else
18373 # We need a cross tool
18374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18375$as_echo "pre-installed" >&6; }
18376 fi
18377fi
18378
1eee94d3
GM
18379{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gm2" >&5
18380$as_echo_n "checking where to find the target gm2... " >&6; }
18381if test "x${build}" != "x${host}" ; then
18382 if expr "x$GM2_FOR_TARGET" : "x/" > /dev/null; then
18383 # We already found the complete path
18384 ac_dir=`dirname $GM2_FOR_TARGET`
18385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18386$as_echo "pre-installed in $ac_dir" >&6; }
18387 else
18388 # Canadian cross, just use what we found
18389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18390$as_echo "pre-installed" >&6; }
18391 fi
18392else
18393 ok=yes
18394 case " ${configdirs} " in
18395 *" gcc "*) ;;
18396 *) ok=no ;;
18397 esac
18398 case ,${enable_languages}, in
18399 *,m2,*) ;;
18400 *) ok=no ;;
18401 esac
18402 if test $ok = yes; then
18403 # An in-tree tool is available and we can use it
18404 GM2_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gm2 -B$$r/$(HOST_SUBDIR)/gcc/'
18405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18406$as_echo "just compiled" >&6; }
18407 elif expr "x$GM2_FOR_TARGET" : "x/" > /dev/null; then
18408 # We already found the complete path
18409 ac_dir=`dirname $GM2_FOR_TARGET`
18410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18411$as_echo "pre-installed in $ac_dir" >&6; }
18412 elif test "x$target" = "x$host"; then
18413 # We can use an host tool
18414 GM2_FOR_TARGET='$(GM2)'
18415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18416$as_echo "host tool" >&6; }
18417 else
18418 # We need a cross tool
18419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18420$as_echo "pre-installed" >&6; }
18421 fi
18422fi
18423
5213506e
RW
18424{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ld" >&5
18425$as_echo_n "checking where to find the target ld... " >&6; }
2abefe3d 18426if test "x${build}" != "x${host}" ; then
e8b05380
PB
18427 if expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
18428 # We already found the complete path
172e41aa 18429 ac_dir=`dirname $LD_FOR_TARGET`
5213506e
RW
18430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18431$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18432 else
18433 # Canadian cross, just use what we found
5213506e
RW
18434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18435$as_echo "pre-installed" >&6; }
e8b05380 18436 fi
2abefe3d
PB
18437else
18438 ok=yes
18439 case " ${configdirs} " in
18440 *" ld "*) ;;
18441 *) ok=no ;;
18442 esac
1c710c3c 18443
2abefe3d
PB
18444 if test $ok = yes; then
18445 # An in-tree tool is available and we can use it
18446 LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/ld/ld-new'
5213506e
RW
18447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18448$as_echo "just compiled" >&6; }
e8b05380
PB
18449 elif expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
18450 # We already found the complete path
172e41aa 18451 ac_dir=`dirname $LD_FOR_TARGET`
5213506e
RW
18452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18453$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18454 elif test "x$target" = "x$host"; then
18455 # We can use an host tool
18456 LD_FOR_TARGET='$(LD)'
5213506e
RW
18457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18458$as_echo "host tool" >&6; }
2abefe3d
PB
18459 else
18460 # We need a cross tool
5213506e
RW
18461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18462$as_echo "pre-installed" >&6; }
2abefe3d
PB
18463 fi
18464fi
0b0dc272 18465
5213506e
RW
18466{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target lipo" >&5
18467$as_echo_n "checking where to find the target lipo... " >&6; }
2abefe3d 18468if test "x${build}" != "x${host}" ; then
e8b05380
PB
18469 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
18470 # We already found the complete path
172e41aa 18471 ac_dir=`dirname $LIPO_FOR_TARGET`
5213506e
RW
18472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18473$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18474 else
18475 # Canadian cross, just use what we found
5213506e
RW
18476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18477$as_echo "pre-installed" >&6; }
e8b05380 18478 fi
2abefe3d 18479else
e8b05380
PB
18480 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
18481 # We already found the complete path
172e41aa 18482 ac_dir=`dirname $LIPO_FOR_TARGET`
5213506e
RW
18483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18484$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380 18485 elif test "x$target" = "x$host"; then
2abefe3d
PB
18486 # We can use an host tool
18487 LIPO_FOR_TARGET='$(LIPO)'
5213506e
RW
18488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18489$as_echo "host tool" >&6; }
2abefe3d
PB
18490 else
18491 # We need a cross tool
5213506e
RW
18492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18493$as_echo "pre-installed" >&6; }
2abefe3d
PB
18494 fi
18495fi
0b0dc272 18496
5213506e
RW
18497{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target nm" >&5
18498$as_echo_n "checking where to find the target nm... " >&6; }
2abefe3d 18499if test "x${build}" != "x${host}" ; then
e8b05380
PB
18500 if expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
18501 # We already found the complete path
172e41aa 18502 ac_dir=`dirname $NM_FOR_TARGET`
5213506e
RW
18503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18504$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18505 else
18506 # Canadian cross, just use what we found
5213506e
RW
18507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18508$as_echo "pre-installed" >&6; }
e8b05380 18509 fi
2abefe3d
PB
18510else
18511 ok=yes
18512 case " ${configdirs} " in
18513 *" binutils "*) ;;
18514 *) ok=no ;;
18515 esac
1c710c3c 18516
2abefe3d
PB
18517 if test $ok = yes; then
18518 # An in-tree tool is available and we can use it
18519 NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/nm-new'
5213506e
RW
18520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18521$as_echo "just compiled" >&6; }
e8b05380
PB
18522 elif expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
18523 # We already found the complete path
172e41aa 18524 ac_dir=`dirname $NM_FOR_TARGET`
5213506e
RW
18525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18526$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18527 elif test "x$target" = "x$host"; then
18528 # We can use an host tool
18529 NM_FOR_TARGET='$(NM)'
5213506e
RW
18530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18531$as_echo "host tool" >&6; }
2abefe3d
PB
18532 else
18533 # We need a cross tool
5213506e
RW
18534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18535$as_echo "pre-installed" >&6; }
2abefe3d
PB
18536 fi
18537fi
0b0dc272 18538
9bccfdf5
AP
18539{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target objcopy" >&5
18540$as_echo_n "checking where to find the target objcopy... " >&6; }
18541if test "x${build}" != "x${host}" ; then
18542 if expr "x$OBJCOPY_FOR_TARGET" : "x/" > /dev/null; then
18543 # We already found the complete path
18544 ac_dir=`dirname $OBJCOPY_FOR_TARGET`
18545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18546$as_echo "pre-installed in $ac_dir" >&6; }
18547 else
18548 # Canadian cross, just use what we found
18549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18550$as_echo "pre-installed" >&6; }
18551 fi
18552else
18553 ok=yes
18554 case " ${configdirs} " in
18555 *" binutils "*) ;;
18556 *) ok=no ;;
18557 esac
18558
18559 if test $ok = yes; then
18560 # An in-tree tool is available and we can use it
18561 OBJCOPY_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objcopy'
18562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18563$as_echo "just compiled" >&6; }
18564 elif expr "x$OBJCOPY_FOR_TARGET" : "x/" > /dev/null; then
18565 # We already found the complete path
18566 ac_dir=`dirname $OBJCOPY_FOR_TARGET`
18567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18568$as_echo "pre-installed in $ac_dir" >&6; }
18569 elif test "x$target" = "x$host"; then
18570 # We can use an host tool
ec8fd1c0 18571 OBJCOPY_FOR_TARGET='$(OBJCOPY)'
9bccfdf5
AP
18572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18573$as_echo "host tool" >&6; }
18574 else
18575 # We need a cross tool
18576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18577$as_echo "pre-installed" >&6; }
18578 fi
18579fi
18580
5213506e
RW
18581{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target objdump" >&5
18582$as_echo_n "checking where to find the target objdump... " >&6; }
2abefe3d 18583if test "x${build}" != "x${host}" ; then
e8b05380
PB
18584 if expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
18585 # We already found the complete path
172e41aa 18586 ac_dir=`dirname $OBJDUMP_FOR_TARGET`
5213506e
RW
18587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18588$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18589 else
18590 # Canadian cross, just use what we found
5213506e
RW
18591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18592$as_echo "pre-installed" >&6; }
e8b05380 18593 fi
2abefe3d
PB
18594else
18595 ok=yes
18596 case " ${configdirs} " in
18597 *" binutils "*) ;;
18598 *) ok=no ;;
18599 esac
1c710c3c 18600
2abefe3d
PB
18601 if test $ok = yes; then
18602 # An in-tree tool is available and we can use it
18603 OBJDUMP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objdump'
5213506e
RW
18604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18605$as_echo "just compiled" >&6; }
e8b05380
PB
18606 elif expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
18607 # We already found the complete path
172e41aa 18608 ac_dir=`dirname $OBJDUMP_FOR_TARGET`
5213506e
RW
18609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18610$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18611 elif test "x$target" = "x$host"; then
18612 # We can use an host tool
18613 OBJDUMP_FOR_TARGET='$(OBJDUMP)'
5213506e
RW
18614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18615$as_echo "host tool" >&6; }
2abefe3d
PB
18616 else
18617 # We need a cross tool
5213506e
RW
18618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18619$as_echo "pre-installed" >&6; }
2abefe3d
PB
18620 fi
18621fi
0b0dc272 18622
e4a9a572
IS
18623{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target otool" >&5
18624$as_echo_n "checking where to find the target otool... " >&6; }
18625if test "x${build}" != "x${host}" ; then
18626 if expr "x$OTOOL_FOR_TARGET" : "x/" > /dev/null; then
18627 # We already found the complete path
18628 ac_dir=`dirname $OTOOL_FOR_TARGET`
18629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18630$as_echo "pre-installed in $ac_dir" >&6; }
18631 else
18632 # Canadian cross, just use what we found
18633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18634$as_echo "pre-installed" >&6; }
18635 fi
18636else
18637 if expr "x$OTOOL_FOR_TARGET" : "x/" > /dev/null; then
18638 # We already found the complete path
18639 ac_dir=`dirname $OTOOL_FOR_TARGET`
18640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18641$as_echo "pre-installed in $ac_dir" >&6; }
18642 elif test "x$target" = "x$host"; then
18643 # We can use an host tool
18644 OTOOL_FOR_TARGET='$(OTOOL)'
18645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18646$as_echo "host tool" >&6; }
18647 else
18648 # We need a cross tool
18649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18650$as_echo "pre-installed" >&6; }
18651 fi
18652fi
18653
5213506e
RW
18654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ranlib" >&5
18655$as_echo_n "checking where to find the target ranlib... " >&6; }
2abefe3d 18656if test "x${build}" != "x${host}" ; then
e8b05380
PB
18657 if expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
18658 # We already found the complete path
172e41aa 18659 ac_dir=`dirname $RANLIB_FOR_TARGET`
5213506e
RW
18660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18661$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18662 else
18663 # Canadian cross, just use what we found
5213506e
RW
18664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18665$as_echo "pre-installed" >&6; }
e8b05380 18666 fi
2abefe3d
PB
18667else
18668 ok=yes
18669 case " ${configdirs} " in
18670 *" binutils "*) ;;
18671 *) ok=no ;;
18672 esac
1c710c3c 18673
2abefe3d
PB
18674 if test $ok = yes; then
18675 # An in-tree tool is available and we can use it
18676 RANLIB_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ranlib'
5213506e
RW
18677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18678$as_echo "just compiled" >&6; }
e8b05380
PB
18679 elif expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
18680 # We already found the complete path
172e41aa 18681 ac_dir=`dirname $RANLIB_FOR_TARGET`
5213506e
RW
18682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18683$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18684 elif test "x$target" = "x$host"; then
18685 # We can use an host tool
18686 RANLIB_FOR_TARGET='$(RANLIB)'
5213506e
RW
18687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18688$as_echo "host tool" >&6; }
2abefe3d
PB
18689 else
18690 # We need a cross tool
5213506e
RW
18691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18692$as_echo "pre-installed" >&6; }
2abefe3d
PB
18693 fi
18694fi
0b0dc272 18695
e7a82751
RM
18696{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target readelf" >&5
18697$as_echo_n "checking where to find the target readelf... " >&6; }
18698if test "x${build}" != "x${host}" ; then
18699 if expr "x$READELF_FOR_TARGET" : "x/" > /dev/null; then
18700 # We already found the complete path
18701 ac_dir=`dirname $READELF_FOR_TARGET`
18702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18703$as_echo "pre-installed in $ac_dir" >&6; }
18704 else
18705 # Canadian cross, just use what we found
18706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18707$as_echo "pre-installed" >&6; }
18708 fi
18709else
18710 ok=yes
18711 case " ${configdirs} " in
18712 *" binutils "*) ;;
18713 *) ok=no ;;
18714 esac
18715
18716 if test $ok = yes; then
18717 # An in-tree tool is available and we can use it
18718 READELF_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/readelf'
18719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18720$as_echo "just compiled" >&6; }
18721 elif expr "x$READELF_FOR_TARGET" : "x/" > /dev/null; then
18722 # We already found the complete path
18723 ac_dir=`dirname $READELF_FOR_TARGET`
18724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18725$as_echo "pre-installed in $ac_dir" >&6; }
18726 elif test "x$target" = "x$host"; then
18727 # We can use an host tool
18728 READELF_FOR_TARGET='$(READELF)'
18729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18730$as_echo "host tool" >&6; }
18731 else
18732 # We need a cross tool
18733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18734$as_echo "pre-installed" >&6; }
18735 fi
18736fi
18737
5213506e
RW
18738{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target strip" >&5
18739$as_echo_n "checking where to find the target strip... " >&6; }
2abefe3d 18740if test "x${build}" != "x${host}" ; then
e8b05380
PB
18741 if expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
18742 # We already found the complete path
172e41aa 18743 ac_dir=`dirname $STRIP_FOR_TARGET`
5213506e
RW
18744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18745$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18746 else
18747 # Canadian cross, just use what we found
5213506e
RW
18748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18749$as_echo "pre-installed" >&6; }
e8b05380 18750 fi
2abefe3d
PB
18751else
18752 ok=yes
18753 case " ${configdirs} " in
18754 *" binutils "*) ;;
18755 *) ok=no ;;
18756 esac
1c710c3c 18757
2abefe3d
PB
18758 if test $ok = yes; then
18759 # An in-tree tool is available and we can use it
455c8f48 18760 STRIP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/strip-new'
5213506e
RW
18761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18762$as_echo "just compiled" >&6; }
e8b05380
PB
18763 elif expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
18764 # We already found the complete path
172e41aa 18765 ac_dir=`dirname $STRIP_FOR_TARGET`
5213506e
RW
18766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18767$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18768 elif test "x$target" = "x$host"; then
18769 # We can use an host tool
18770 STRIP_FOR_TARGET='$(STRIP)'
5213506e
RW
18771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18772$as_echo "host tool" >&6; }
2abefe3d
PB
18773 else
18774 # We need a cross tool
5213506e
RW
18775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18776$as_echo "pre-installed" >&6; }
2abefe3d
PB
18777 fi
18778fi
0b0dc272 18779
5213506e
RW
18780{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target windres" >&5
18781$as_echo_n "checking where to find the target windres... " >&6; }
2abefe3d 18782if test "x${build}" != "x${host}" ; then
e8b05380
PB
18783 if expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
18784 # We already found the complete path
172e41aa 18785 ac_dir=`dirname $WINDRES_FOR_TARGET`
5213506e
RW
18786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18787$as_echo "pre-installed in $ac_dir" >&6; }
e8b05380
PB
18788 else
18789 # Canadian cross, just use what we found
5213506e
RW
18790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18791$as_echo "pre-installed" >&6; }
e8b05380 18792 fi
2abefe3d
PB
18793else
18794 ok=yes
18795 case " ${configdirs} " in
18796 *" binutils "*) ;;
18797 *) ok=no ;;
18798 esac
1c710c3c 18799
2abefe3d
PB
18800 if test $ok = yes; then
18801 # An in-tree tool is available and we can use it
18802 WINDRES_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windres'
5213506e
RW
18803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18804$as_echo "just compiled" >&6; }
e8b05380
PB
18805 elif expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
18806 # We already found the complete path
172e41aa 18807 ac_dir=`dirname $WINDRES_FOR_TARGET`
5213506e
RW
18808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18809$as_echo "pre-installed in $ac_dir" >&6; }
2abefe3d
PB
18810 elif test "x$target" = "x$host"; then
18811 # We can use an host tool
18812 WINDRES_FOR_TARGET='$(WINDRES)'
5213506e
RW
18813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18814$as_echo "host tool" >&6; }
2abefe3d
PB
18815 else
18816 # We need a cross tool
5213506e
RW
18817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18818$as_echo "pre-installed" >&6; }
2abefe3d 18819 fi
671aa708 18820fi
be912515 18821
5213506e
RW
18822{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target windmc" >&5
18823$as_echo_n "checking where to find the target windmc... " >&6; }
901119ae
KT
18824if test "x${build}" != "x${host}" ; then
18825 if expr "x$WINDMC_FOR_TARGET" : "x/" > /dev/null; then
18826 # We already found the complete path
18827 ac_dir=`dirname $WINDMC_FOR_TARGET`
5213506e
RW
18828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18829$as_echo "pre-installed in $ac_dir" >&6; }
901119ae
KT
18830 else
18831 # Canadian cross, just use what we found
5213506e
RW
18832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18833$as_echo "pre-installed" >&6; }
901119ae
KT
18834 fi
18835else
18836 ok=yes
18837 case " ${configdirs} " in
18838 *" binutils "*) ;;
18839 *) ok=no ;;
18840 esac
18841
18842 if test $ok = yes; then
18843 # An in-tree tool is available and we can use it
18844 WINDMC_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windmc'
5213506e
RW
18845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
18846$as_echo "just compiled" >&6; }
901119ae
KT
18847 elif expr "x$WINDMC_FOR_TARGET" : "x/" > /dev/null; then
18848 # We already found the complete path
18849 ac_dir=`dirname $WINDMC_FOR_TARGET`
5213506e
RW
18850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
18851$as_echo "pre-installed in $ac_dir" >&6; }
901119ae
KT
18852 elif test "x$target" = "x$host"; then
18853 # We can use an host tool
18854 WINDMC_FOR_TARGET='$(WINDMC)'
5213506e
RW
18855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
18856$as_echo "host tool" >&6; }
901119ae
KT
18857 else
18858 # We need a cross tool
5213506e
RW
18859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
18860$as_echo "pre-installed" >&6; }
901119ae
KT
18861 fi
18862fi
18863
be912515
NN
18864
18865
2abefe3d 18866
0b0dc272 18867
671aa708
NN
18868# Certain tools may need extra flags.
18869AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
18870RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
18871NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
18872
2abefe3d
PB
18873# When building target libraries, except in a Canadian cross, we use
18874# the same toolchain as the compiler we just built.
18875COMPILER_AS_FOR_TARGET='$(AS_FOR_TARGET)'
18876COMPILER_LD_FOR_TARGET='$(LD_FOR_TARGET)'
18877COMPILER_NM_FOR_TARGET='$(NM_FOR_TARGET)'
18878if test $host = $build; then
18879 case " $configdirs " in
18880 *" gcc "*)
18881 COMPILER_AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/as'
18882 COMPILER_LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/collect-ld'
18883 COMPILER_NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/nm'${extra_nmflags_for_target}
18884 ;;
18885 esac
18886fi
18887
18888
18889
18890
18891
5213506e
RW
18892{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
18893$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
18894# Check whether --enable-maintainer-mode was given.
18895if test "${enable_maintainer_mode+set}" = set; then :
18896 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
ee03dc5e
AO
18897else
18898 USE_MAINTAINER_MODE=no
5213506e
RW
18899fi
18900
18901{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
18902$as_echo "$USE_MAINTAINER_MODE" >&6; }
ee03dc5e
AO
18903
18904
18905if test "$USE_MAINTAINER_MODE" = yes; then
18906 MAINTAINER_MODE_TRUE=
18907 MAINTAINER_MODE_FALSE='#'
18908else
18909 MAINTAINER_MODE_TRUE='#'
18910 MAINTAINER_MODE_FALSE=
1c710c3c 18911fi
ee03dc5e
AO
18912MAINT=$MAINTAINER_MODE_TRUE
18913
2805b53a
NN
18914# ---------------------
18915# GCC bootstrap support
18916# ---------------------
18917
18918# Stage specific cflags for build.
18919stage1_cflags="-g"
18920case $build in
18921 vax-*-*)
18922 case ${GCC} in
18923 yes) stage1_cflags="-g -Wa,-J" ;;
18924 *) stage1_cflags="-g -J" ;;
18925 esac ;;
2805b53a
NN
18926esac
18927
0b50988a 18928
2805b53a 18929
8efea775 18930# Enable --enable-checking in stage1 of the compiler.
5213506e
RW
18931# Check whether --enable-stage1-checking was given.
18932if test "${enable_stage1_checking+set}" = set; then :
18933 enableval=$enable_stage1_checking; stage1_checking=--enable-checking=${enable_stage1_checking}
8efea775 18934else
e643dc23 18935 if test "x$enable_checking" = xno || test "x$enable_checking" = x; then
c10b5ea0
JJ
18936 # For --disable-checking or implicit --enable-checking=release, avoid
18937 # setting --enable-checking=gc in the default stage1 checking for LTO
18938 # bootstraps. See PR62077.
c10b5ea0
JJ
18939 case $BUILD_CONFIG in
18940 *lto*)
7db11a5a
JJ
18941 stage1_checking=--enable-checking=release,misc,gimple,rtlflag,tree,types;;
18942 *)
18943 stage1_checking=--enable-checking=yes,types;;
c10b5ea0 18944 esac
7db11a5a
JJ
18945 if test "x$enable_checking" = x && \
18946 test -d ${srcdir}/gcc && \
18947 test x"`cat ${srcdir}/gcc/DEV-PHASE`" = xexperimental; then
c100769b 18948 stage1_checking=--enable-checking=yes,types,extra
7db11a5a 18949 fi
8efea775 18950else
e643dc23 18951 stage1_checking=--enable-checking=$enable_checking,types
8efea775 18952fi
5213506e 18953fi
8efea775
PB
18954
18955
2aeb72e9 18956
5213506e
RW
18957# Enable -Werror in bootstrap stage2 and later.
18958# Check whether --enable-werror was given.
18959if test "${enable_werror+set}" = set; then :
18960 enableval=$enable_werror;
09a9c095
NN
18961case ${enable_werror} in
18962 yes) stage2_werror_flag="--enable-werror-always" ;;
18963 *) stage2_werror_flag="" ;;
2805b53a
NN
18964esac
18965
afd88efc
ML
18966else
18967
01c712cb
ML
18968if test -d ${srcdir}/gcc && test x"`cat $srcdir/gcc/DEV-PHASE`" = xexperimental; then
18969 case $BUILD_CONFIG in
18970 bootstrap-debug)
18971 stage2_werror_flag="--enable-werror-always" ;;
18972 "")
18973 stage2_werror_flag="--enable-werror-always" ;;
18974 esac
18975fi
18976
afd88efc
ML
18977fi
18978
18979
01c712cb 18980
2805b53a 18981
f2689b09
SE
18982# Specify what files to not compare during bootstrap.
18983
18984compare_exclusions="gcc/cc*-checksum\$(objext) | gcc/ada/*tools/*"
1eee94d3
GM
18985compare_exclusions="$compare_exclusions | gcc/m2/gm2-compiler-boot/M2Version*"
18986compare_exclusions="$compare_exclusions | gcc/m2/gm2-compiler-boot/SYSTEM*"
18987compare_exclusions="$compare_exclusions | gcc/m2/gm2version*"
f2689b09
SE
18988case "$target" in
18989 hppa*64*-*-hpux*) ;;
4f943869 18990 powerpc*-ibm-aix*) compare_exclusions="$compare_exclusions | *libgomp*\$(objext)" ;;
f2689b09
SE
18991esac
18992
18993
5213506e
RW
18994ac_config_files="$ac_config_files Makefile"
18995
1c710c3c 18996cat >confcache <<\_ACEOF
671aa708
NN
18997# This file is a shell script that caches the results of configure
18998# tests run on this system so they can be shared between configure
1c710c3c
DJ
18999# scripts and configure runs, see configure's option --config-cache.
19000# It is not useful on other systems. If it contains results you don't
19001# want to keep, you may remove or edit it.
671aa708 19002#
1c710c3c
DJ
19003# config.status only pays attention to the cache file if you give it
19004# the --recheck option to rerun configure.
671aa708 19005#
1c710c3c
DJ
19006# `ac_cv_env_foo' variables (set or unset) will be overridden when
19007# loading this file, other *unset* `ac_cv_foo' will be assigned the
19008# following values.
19009
19010_ACEOF
19011
671aa708
NN
19012# The following way of writing the cache mishandles newlines in values,
19013# but we know of no workaround that is simple, portable, and efficient.
5213506e 19014# So, we kill variables containing newlines.
671aa708
NN
19015# Ultrix sh set writes to stderr and can't be redirected directly,
19016# and sets the high bit in the cache file unless we assign to the vars.
5213506e
RW
19017(
19018 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19019 eval ac_val=\$$ac_var
19020 case $ac_val in #(
19021 *${as_nl}*)
19022 case $ac_var in #(
19023 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19024$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19025 esac
19026 case $ac_var in #(
19027 _ | IFS | as_nl) ;; #(
19028 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19029 *) { eval $ac_var=; unset $ac_var;} ;;
19030 esac ;;
19031 esac
19032 done
19033
1c710c3c 19034 (set) 2>&1 |
5213506e
RW
19035 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19036 *${as_nl}ac_space=\ *)
19037 # `set' does not quote correctly, so add quotes: double-quote
19038 # substitution turns \\\\ into \\, and sed turns \\ into \.
1c710c3c
DJ
19039 sed -n \
19040 "s/'/'\\\\''/g;
19041 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
5213506e 19042 ;; #(
1c710c3c
DJ
19043 *)
19044 # `set' quotes correctly as required by POSIX, so do not add quotes.
5213506e 19045 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1c710c3c 19046 ;;
5213506e
RW
19047 esac |
19048 sort
19049) |
1c710c3c 19050 sed '
5213506e 19051 /^ac_cv_env_/b end
1c710c3c 19052 t clear
5213506e 19053 :clear
1c710c3c
DJ
19054 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19055 t end
5213506e
RW
19056 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19057 :end' >>confcache
19058if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19059 if test -w "$cache_file"; then
22e05272 19060 if test "x$cache_file" != "x/dev/null"; then
5213506e
RW
19061 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19062$as_echo "$as_me: updating cache $cache_file" >&6;}
22e05272
JM
19063 if test ! -f "$cache_file" || test -h "$cache_file"; then
19064 cat confcache >"$cache_file"
19065 else
19066 case $cache_file in #(
19067 */* | ?:*)
19068 mv -f confcache "$cache_file"$$ &&
19069 mv -f "$cache_file"$$ "$cache_file" ;; #(
19070 *)
19071 mv -f confcache "$cache_file" ;;
19072 esac
19073 fi
19074 fi
671aa708 19075 else
5213506e
RW
19076 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19077$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
671aa708 19078 fi
4977bab6 19079fi
671aa708 19080rm -f confcache
79c06341 19081
671aa708
NN
19082test "x$prefix" = xNONE && prefix=$ac_default_prefix
19083# Let make expand exec_prefix.
19084test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4e77e8f1 19085
671aa708
NN
19086# Transform confdefs.h into DEFS.
19087# Protect against shell expansion while executing Makefile rules.
19088# Protect against Makefile macro expansion.
1c710c3c
DJ
19089#
19090# If the first sed substitution is executed (which looks for macros that
5213506e 19091# take arguments), then branch to the quote section. Otherwise,
1c710c3c 19092# look for a macro that doesn't take arguments.
5213506e
RW
19093ac_script='
19094:mline
19095/\\$/{
19096 N
19097 s,\\\n,,
19098 b mline
19099}
1c710c3c 19100t clear
5213506e
RW
19101:clear
19102s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g
1c710c3c 19103t quote
5213506e 19104s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g
1c710c3c 19105t quote
5213506e
RW
19106b any
19107:quote
19108s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g
19109s/\[/\\&/g
19110s/\]/\\&/g
19111s/\$/$$/g
19112H
19113:any
19114${
19115 g
19116 s/^\n//
19117 s/\n/ /g
19118 p
19119}
19120'
19121DEFS=`sed -n "$ac_script" confdefs.h`
1c710c3c
DJ
19122
19123
19124ac_libobjs=
19125ac_ltlibobjs=
22e05272 19126U=
1c710c3c
DJ
19127for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
19128 # 1. Remove the extension, and $U if already installed.
5213506e
RW
19129 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
19130 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
19131 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
19132 # will be set to the directory where LIBOBJS objects are built.
19133 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
19134 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
1c710c3c
DJ
19135done
19136LIBOBJS=$ac_libobjs
fb0103e5 19137
1c710c3c 19138LTLIBOBJS=$ac_ltlibobjs
0b0dc272 19139
af71363e 19140
1c710c3c 19141
22e05272 19142: "${CONFIG_STATUS=./config.status}"
5213506e 19143ac_write_fail=0
1c710c3c
DJ
19144ac_clean_files_save=$ac_clean_files
19145ac_clean_files="$ac_clean_files $CONFIG_STATUS"
5213506e
RW
19146{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
19147$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
19148as_write_fail=0
19149cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
1c710c3c
DJ
19150#! $SHELL
19151# Generated by $as_me.
671aa708 19152# Run this file to recreate the current configuration.
671aa708 19153# Compiler output produced by configure, useful for debugging
1c710c3c 19154# configure, is in config.log if it exists.
0b0dc272 19155
1c710c3c
DJ
19156debug=false
19157ac_cs_recheck=false
19158ac_cs_silent=false
1c710c3c 19159
5213506e
RW
19160SHELL=\${CONFIG_SHELL-$SHELL}
19161export SHELL
19162_ASEOF
19163cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
19164## -------------------- ##
19165## M4sh Initialization. ##
19166## -------------------- ##
19167
19168# Be more Bourne compatible
19169DUALCASE=1; export DUALCASE # for MKS sh
19170if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
1c710c3c
DJ
19171 emulate sh
19172 NULLCMD=:
5213506e 19173 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
1c710c3c
DJ
19174 # is contrary to our usage. Disable this feature.
19175 alias -g '${1+"$@"}'='"$@"'
5213506e
RW
19176 setopt NO_GLOB_SUBST
19177else
19178 case `(set -o) 2>/dev/null` in #(
19179 *posix*) :
19180 set -o posix ;; #(
19181 *) :
19182 ;;
19183esac
1c710c3c 19184fi
1c710c3c 19185
5213506e
RW
19186
19187as_nl='
19188'
19189export as_nl
19190# Printing a long string crashes Solaris 7 /usr/bin/printf.
19191as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
19192as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
19193as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
19194# Prefer a ksh shell builtin over an external printf program on Solaris,
19195# but without wasting forks for bash or zsh.
19196if test -z "$BASH_VERSION$ZSH_VERSION" \
19197 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
19198 as_echo='print -r --'
19199 as_echo_n='print -rn --'
19200elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
19201 as_echo='printf %s\n'
19202 as_echo_n='printf %s'
19203else
19204 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
19205 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
19206 as_echo_n='/usr/ucb/echo -n'
19207 else
19208 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
19209 as_echo_n_body='eval
19210 arg=$1;
19211 case $arg in #(
19212 *"$as_nl"*)
19213 expr "X$arg" : "X\\(.*\\)$as_nl";
19214 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
19215 esac;
19216 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
19217 '
19218 export as_echo_n_body
19219 as_echo_n='sh -c $as_echo_n_body as_echo'
19220 fi
19221 export as_echo_body
19222 as_echo='sh -c $as_echo_body as_echo'
1c710c3c
DJ
19223fi
19224
5213506e
RW
19225# The user is always right.
19226if test "${PATH_SEPARATOR+set}" != set; then
19227 PATH_SEPARATOR=:
19228 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
19229 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
19230 PATH_SEPARATOR=';'
19231 }
19232fi
19233
19234
19235# IFS
19236# We need space, tab and new line, in precisely that order. Quoting is
19237# there to prevent editors from complaining about space-tab.
19238# (If _AS_PATH_WALK were called with IFS unset, it would disable word
19239# splitting by setting IFS to empty value.)
19240IFS=" "" $as_nl"
19241
19242# Find who we are. Look in the path if we contain no directory separator.
22e05272 19243as_myself=
5213506e
RW
19244case $0 in #((
19245 *[\\/]* ) as_myself=$0 ;;
19246 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19247for as_dir in $PATH
19248do
19249 IFS=$as_save_IFS
19250 test -z "$as_dir" && as_dir=.
19251 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19252 done
19253IFS=$as_save_IFS
19254
19255 ;;
19256esac
19257# We did not find ourselves, most probably we were run as `sh COMMAND'
19258# in which case we are not to be found in the path.
19259if test "x$as_myself" = x; then
19260 as_myself=$0
19261fi
19262if test ! -f "$as_myself"; then
19263 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
19264 exit 1
19265fi
1c710c3c 19266
5213506e
RW
19267# Unset variables that we do not need and which cause bugs (e.g. in
19268# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
19269# suppresses any "Segmentation fault" message there. '((' could
19270# trigger a bug in pdksh 5.2.14.
19271for as_var in BASH_ENV ENV MAIL MAILPATH
19272do eval test x\${$as_var+set} = xset \
19273 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
19274done
1c710c3c
DJ
19275PS1='$ '
19276PS2='> '
19277PS4='+ '
19278
19279# NLS nuisances.
5213506e
RW
19280LC_ALL=C
19281export LC_ALL
19282LANGUAGE=C
19283export LANGUAGE
19284
19285# CDPATH.
19286(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
19287
19288
22e05272
JM
19289# as_fn_error STATUS ERROR [LINENO LOG_FD]
19290# ----------------------------------------
5213506e
RW
19291# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
19292# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
22e05272 19293# script with STATUS, using 1 if that was 0.
5213506e
RW
19294as_fn_error ()
19295{
22e05272
JM
19296 as_status=$1; test $as_status -eq 0 && as_status=1
19297 if test "$4"; then
19298 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
19299 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
1c710c3c 19300 fi
22e05272 19301 $as_echo "$as_me: error: $2" >&2
5213506e
RW
19302 as_fn_exit $as_status
19303} # as_fn_error
19304
19305
19306# as_fn_set_status STATUS
19307# -----------------------
19308# Set $? to STATUS, without forking.
19309as_fn_set_status ()
19310{
19311 return $1
19312} # as_fn_set_status
19313
19314# as_fn_exit STATUS
19315# -----------------
19316# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
19317as_fn_exit ()
19318{
19319 set +e
19320 as_fn_set_status $1
19321 exit $1
19322} # as_fn_exit
19323
19324# as_fn_unset VAR
19325# ---------------
19326# Portably unset VAR.
19327as_fn_unset ()
19328{
19329 { eval $1=; unset $1;}
19330}
19331as_unset=as_fn_unset
19332# as_fn_append VAR VALUE
19333# ----------------------
19334# Append the text in VALUE to the end of the definition contained in VAR. Take
19335# advantage of any shell optimizations that allow amortized linear growth over
19336# repeated appends, instead of the typical quadratic growth present in naive
19337# implementations.
19338if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
19339 eval 'as_fn_append ()
19340 {
19341 eval $1+=\$2
19342 }'
19343else
19344 as_fn_append ()
19345 {
19346 eval $1=\$$1\$2
19347 }
19348fi # as_fn_append
19349
19350# as_fn_arith ARG...
19351# ------------------
19352# Perform arithmetic evaluation on the ARGs, and store the result in the
19353# global $as_val. Take advantage of shells that can avoid forks. The arguments
19354# must be portable across $(()) and expr.
19355if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
19356 eval 'as_fn_arith ()
19357 {
19358 as_val=$(( $* ))
19359 }'
19360else
19361 as_fn_arith ()
19362 {
19363 as_val=`expr "$@" || test $? -eq 1`
19364 }
19365fi # as_fn_arith
19366
1c710c3c 19367
5213506e
RW
19368if expr a : '\(a\)' >/dev/null 2>&1 &&
19369 test "X`expr 00001 : '.*\(...\)'`" = X001; then
1c710c3c
DJ
19370 as_expr=expr
19371else
19372 as_expr=false
19373fi
19374
5213506e 19375if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
1c710c3c
DJ
19376 as_basename=basename
19377else
19378 as_basename=false
19379fi
19380
5213506e
RW
19381if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
19382 as_dirname=dirname
19383else
19384 as_dirname=false
19385fi
1c710c3c 19386
5213506e 19387as_me=`$as_basename -- "$0" ||
1c710c3c
DJ
19388$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19389 X"$0" : 'X\(//\)$' \| \
5213506e
RW
19390 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
19391$as_echo X/"$0" |
19392 sed '/^.*\/\([^/][^/]*\)\/*$/{
19393 s//\1/
19394 q
19395 }
19396 /^X\/\(\/\/\)$/{
19397 s//\1/
19398 q
19399 }
19400 /^X\/\(\/\).*/{
19401 s//\1/
19402 q
19403 }
19404 s/.*/./; q'`
2aeb72e9 19405
2aeb72e9
DD
19406# Avoid depending upon Character Ranges.
19407as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19408as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19409as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19410as_cr_digits='0123456789'
19411as_cr_alnum=$as_cr_Letters$as_cr_digits
19412
5213506e
RW
19413ECHO_C= ECHO_N= ECHO_T=
19414case `echo -n x` in #(((((
19415-n*)
19416 case `echo 'xy\c'` in
19417 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
19418 xy) ECHO_C='\c';;
19419 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
19420 ECHO_T=' ';;
19421 esac;;
19422*)
19423 ECHO_N='-n';;
1c710c3c
DJ
19424esac
19425
5213506e
RW
19426rm -f conf$$ conf$$.exe conf$$.file
19427if test -d conf$$.dir; then
19428 rm -f conf$$.dir/conf$$.file
1c710c3c 19429else
5213506e
RW
19430 rm -f conf$$.dir
19431 mkdir conf$$.dir 2>/dev/null
1c710c3c 19432fi
5213506e
RW
19433if (echo >conf$$.file) 2>/dev/null; then
19434 if ln -s conf$$.file conf$$ 2>/dev/null; then
2aeb72e9 19435 as_ln_s='ln -s'
5213506e
RW
19436 # ... but there are two gotchas:
19437 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
19438 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
22e05272 19439 # In both cases, we have to default to `cp -pR'.
5213506e 19440 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
22e05272 19441 as_ln_s='cp -pR'
5213506e
RW
19442 elif ln conf$$.file conf$$ 2>/dev/null; then
19443 as_ln_s=ln
19444 else
22e05272 19445 as_ln_s='cp -pR'
2aeb72e9 19446 fi
1c710c3c 19447else
22e05272 19448 as_ln_s='cp -pR'
1c710c3c 19449fi
5213506e
RW
19450rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
19451rmdir conf$$.dir 2>/dev/null
19452
19453
19454# as_fn_mkdir_p
19455# -------------
19456# Create "$as_dir" as a directory, including parents if necessary.
19457as_fn_mkdir_p ()
19458{
19459
19460 case $as_dir in #(
19461 -*) as_dir=./$as_dir;;
19462 esac
19463 test -d "$as_dir" || eval $as_mkdir_p || {
19464 as_dirs=
19465 while :; do
19466 case $as_dir in #(
19467 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
19468 *) as_qdir=$as_dir;;
19469 esac
19470 as_dirs="'$as_qdir' $as_dirs"
19471 as_dir=`$as_dirname -- "$as_dir" ||
19472$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19473 X"$as_dir" : 'X\(//\)[^/]' \| \
19474 X"$as_dir" : 'X\(//\)$' \| \
19475 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
19476$as_echo X"$as_dir" |
19477 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19478 s//\1/
19479 q
19480 }
19481 /^X\(\/\/\)[^/].*/{
19482 s//\1/
19483 q
19484 }
19485 /^X\(\/\/\)$/{
19486 s//\1/
19487 q
19488 }
19489 /^X\(\/\).*/{
19490 s//\1/
19491 q
19492 }
19493 s/.*/./; q'`
19494 test -d "$as_dir" && break
19495 done
19496 test -z "$as_dirs" || eval "mkdir $as_dirs"
22e05272 19497 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
5213506e 19498
1c710c3c 19499
5213506e 19500} # as_fn_mkdir_p
1c710c3c 19501if mkdir -p . 2>/dev/null; then
5213506e 19502 as_mkdir_p='mkdir -p "$as_dir"'
1c710c3c
DJ
19503else
19504 test -d ./-p && rmdir ./-p
19505 as_mkdir_p=false
19506fi
19507
22e05272
JM
19508
19509# as_fn_executable_p FILE
19510# -----------------------
19511# Test if FILE is an executable regular file.
19512as_fn_executable_p ()
19513{
19514 test -f "$1" && test -x "$1"
19515} # as_fn_executable_p
19516as_test_x='test -x'
19517as_executable_p=as_fn_executable_p
1c710c3c
DJ
19518
19519# Sed expression to map a string onto a valid CPP name.
19520as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
19521
19522# Sed expression to map a string onto a valid variable name.
19523as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
19524
19525
1c710c3c 19526exec 6>&1
5213506e
RW
19527## ----------------------------------- ##
19528## Main body of $CONFIG_STATUS script. ##
19529## ----------------------------------- ##
19530_ASEOF
19531test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
19532
19533cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19534# Save the log message, to keep $0 and so on meaningful, and to
1c710c3c 19535# report actual input values of CONFIG_FILES etc. instead of their
5213506e
RW
19536# values after options handling.
19537ac_log="
1c710c3c 19538This file was extended by $as_me, which was
22e05272 19539generated by GNU Autoconf 2.69. Invocation command line was
1c710c3c
DJ
19540
19541 CONFIG_FILES = $CONFIG_FILES
19542 CONFIG_HEADERS = $CONFIG_HEADERS
19543 CONFIG_LINKS = $CONFIG_LINKS
19544 CONFIG_COMMANDS = $CONFIG_COMMANDS
19545 $ $0 $@
19546
5213506e
RW
19547on `(hostname || uname -n) 2>/dev/null | sed 1q`
19548"
19549
1c710c3c
DJ
19550_ACEOF
19551
5213506e
RW
19552case $ac_config_files in *"
19553"*) set x $ac_config_files; shift; ac_config_files=$*;;
19554esac
1c710c3c 19555
2aeb72e9 19556
2aeb72e9 19557
5213506e
RW
19558cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19559# Files that config.status was made for.
19560config_files="$ac_config_files"
1c710c3c 19561
5213506e 19562_ACEOF
2aeb72e9 19563
5213506e 19564cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1c710c3c 19565ac_cs_usage="\
5213506e
RW
19566\`$as_me' instantiates files and other configuration actions
19567from templates according to the current configuration. Unless the files
19568and actions are specified as TAGs, all are instantiated by default.
1c710c3c 19569
5213506e 19570Usage: $0 [OPTION]... [TAG]...
1c710c3c
DJ
19571
19572 -h, --help print this help, then exit
5213506e 19573 -V, --version print version number and configuration settings, then exit
22e05272 19574 --config print configuration, then exit
5213506e
RW
19575 -q, --quiet, --silent
19576 do not print progress messages
1c710c3c
DJ
19577 -d, --debug don't remove temporary files
19578 --recheck update $as_me by reconfiguring in the same conditions
5213506e
RW
19579 --file=FILE[:TEMPLATE]
19580 instantiate the configuration file FILE
1c710c3c
DJ
19581
19582Configuration files:
19583$config_files
19584
5213506e 19585Report bugs to the package provider."
2aeb72e9 19586
5213506e
RW
19587_ACEOF
19588cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22e05272 19589ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
1c710c3c
DJ
19590ac_cs_version="\\
19591config.status
22e05272
JM
19592configured by $0, generated by GNU Autoconf 2.69,
19593 with options \\"\$ac_cs_config\\"
1c710c3c 19594
22e05272 19595Copyright (C) 2012 Free Software Foundation, Inc.
1c710c3c
DJ
19596This config.status script is free software; the Free Software Foundation
19597gives unlimited permission to copy, distribute and modify it."
5213506e
RW
19598
19599ac_pwd='$ac_pwd'
19600srcdir='$srcdir'
19601INSTALL='$INSTALL'
87264276 19602AWK='$AWK'
5213506e 19603test -n "\$AWK" || AWK=awk
1c710c3c
DJ
19604_ACEOF
19605
5213506e
RW
19606cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19607# The default lists apply if the user does not specify any file.
1c710c3c
DJ
19608ac_need_defaults=:
19609while test $# != 0
a4b9e93e 19610do
1c710c3c 19611 case $1 in
22e05272 19612 --*=?*)
5213506e
RW
19613 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19614 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
1c710c3c
DJ
19615 ac_shift=:
19616 ;;
22e05272
JM
19617 --*=)
19618 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19619 ac_optarg=
19620 ac_shift=:
19621 ;;
5213506e 19622 *)
1c710c3c
DJ
19623 ac_option=$1
19624 ac_optarg=$2
19625 ac_shift=shift
19626 ;;
1c710c3c
DJ
19627 esac
19628
19629 case $ac_option in
19630 # Handling of the options.
671aa708 19631 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1c710c3c 19632 ac_cs_recheck=: ;;
5213506e
RW
19633 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
19634 $as_echo "$ac_cs_version"; exit ;;
22e05272
JM
19635 --config | --confi | --conf | --con | --co | --c )
19636 $as_echo "$ac_cs_config"; exit ;;
5213506e 19637 --debug | --debu | --deb | --de | --d | -d )
1c710c3c
DJ
19638 debug=: ;;
19639 --file | --fil | --fi | --f )
19640 $ac_shift
5213506e
RW
19641 case $ac_optarg in
19642 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22e05272 19643 '') as_fn_error $? "missing file argument" ;;
5213506e
RW
19644 esac
19645 as_fn_append CONFIG_FILES " '$ac_optarg'"
2aeb72e9 19646 ac_need_defaults=false;;
5213506e
RW
19647 --he | --h | --help | --hel | -h )
19648 $as_echo "$ac_cs_usage"; exit ;;
1c710c3c
DJ
19649 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
19650 | -silent | --silent | --silen | --sile | --sil | --si | --s)
19651 ac_cs_silent=: ;;
19652
19653 # This is an error.
22e05272 19654 -*) as_fn_error $? "unrecognized option: \`$1'
5213506e 19655Try \`$0 --help' for more information." ;;
1c710c3c 19656
5213506e
RW
19657 *) as_fn_append ac_config_targets " $1"
19658 ac_need_defaults=false ;;
1c710c3c 19659
0b0dc272 19660 esac
1c710c3c 19661 shift
0b0dc272
AM
19662done
19663
1c710c3c 19664ac_configure_extra_args=
0b0dc272 19665
1c710c3c
DJ
19666if $ac_cs_silent; then
19667 exec 6>/dev/null
19668 ac_configure_extra_args="$ac_configure_extra_args --silent"
19669fi
0b0dc272 19670
1c710c3c 19671_ACEOF
5213506e 19672cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
1c710c3c 19673if \$ac_cs_recheck; then
22e05272 19674 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
5213506e
RW
19675 shift
19676 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
19677 CONFIG_SHELL='$SHELL'
19678 export CONFIG_SHELL
19679 exec "\$@"
1c710c3c
DJ
19680fi
19681
19682_ACEOF
5213506e
RW
19683cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19684exec 5>>config.log
19685{
19686 echo
19687 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19688## Running $as_me. ##
19689_ASBOX
19690 $as_echo "$ac_log"
19691} >&5
1c710c3c 19692
5213506e
RW
19693_ACEOF
19694cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
3e54529c
RW
19695#
19696# INIT-COMMANDS
19697#
19698extrasub_build="$extrasub_build"
19699 extrasub_host="$extrasub_host"
19700 extrasub_target="$extrasub_target"
19701
5213506e 19702_ACEOF
1c710c3c 19703
5213506e 19704cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
11a67599 19705
5213506e 19706# Handling of arguments.
1c710c3c
DJ
19707for ac_config_target in $ac_config_targets
19708do
5213506e
RW
19709 case $ac_config_target in
19710 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
19711
22e05272 19712 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
1c710c3c
DJ
19713 esac
19714done
19715
5213506e 19716
1c710c3c
DJ
19717# If the user did not use the arguments to specify the items to instantiate,
19718# then the envvar interface is used. Set only those that are not.
19719# We use the long form for the default assignment because of an extremely
19720# bizarre bug on SunOS 4.1.3.
19721if $ac_need_defaults; then
19722 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19723fi
19724
19725# Have a temporary directory for convenience. Make it in the build tree
5213506e 19726# simply because there is no reason against having it here, and in addition,
1c710c3c 19727# creating and moving files from /tmp can sometimes cause problems.
5213506e
RW
19728# Hook for its removal unless debugging.
19729# Note that there is a small window in which the directory will not be cleaned:
19730# after its creation but before its name has been assigned to `$tmp'.
1c710c3c
DJ
19731$debug ||
19732{
22e05272 19733 tmp= ac_tmp=
5213506e 19734 trap 'exit_status=$?
22e05272
JM
19735 : "${ac_tmp:=$tmp}"
19736 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
5213506e
RW
19737' 0
19738 trap 'as_fn_exit 1' 1 2 13 15
1c710c3c 19739}
1c710c3c
DJ
19740# Create a (secure) tmp directory for tmp files.
19741
19742{
5213506e 19743 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
22e05272 19744 test -d "$tmp"
1c710c3c
DJ
19745} ||
19746{
5213506e
RW
19747 tmp=./conf$$-$RANDOM
19748 (umask 077 && mkdir "$tmp")
22e05272
JM
19749} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
19750ac_tmp=$tmp
5213506e
RW
19751
19752# Set up the scripts for CONFIG_FILES section.
19753# No need to generate them if there are no CONFIG_FILES.
19754# This happens for instance with `./config.status config.h'.
19755if test -n "$CONFIG_FILES"; then
19756
19757if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
19758 ac_cs_awk_getline=:
19759 ac_cs_awk_pipe_init=
19760 ac_cs_awk_read_file='
19761 while ((getline aline < (F[key])) > 0)
19762 print(aline)
19763 close(F[key])'
19764 ac_cs_awk_pipe_fini=
19765else
19766 ac_cs_awk_getline=false
19767 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
19768 ac_cs_awk_read_file='
19769 print "|#_!!_#|"
19770 print "cat " F[key] " &&"
19771 '$ac_cs_awk_pipe_init
19772 # The final `:' finishes the AND list.
19773 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
19774fi
19775ac_cr=`echo X | tr X '\015'`
19776# On cygwin, bash can eat \r inside `` if the user requested igncr.
19777# But we know of no other shell where ac_cr would be empty at this
19778# point, so we can use a bashism as a fallback.
19779if test "x$ac_cr" = x; then
19780 eval ac_cr=\$\'\\r\'
19781fi
19782ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
19783if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
22e05272 19784 ac_cs_awk_cr='\\r'
5213506e
RW
19785else
19786 ac_cs_awk_cr=$ac_cr
19787fi
19788
22e05272 19789echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
5213506e
RW
19790_ACEOF
19791
19792# Create commands to substitute file output variables.
1c710c3c 19793{
5213506e 19794 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
22e05272 19795 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
5213506e
RW
19796 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
19797 echo "_ACAWK" &&
19798 echo "_ACEOF"
19799} >conf$$files.sh &&
19800. ./conf$$files.sh ||
22e05272 19801 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
5213506e 19802rm -f conf$$files.sh
1c710c3c 19803
5213506e
RW
19804{
19805 echo "cat >conf$$subs.awk <<_ACEOF" &&
19806 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
19807 echo "_ACEOF"
19808} >conf$$subs.sh ||
22e05272
JM
19809 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19810ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
5213506e
RW
19811ac_delim='%!_!# '
19812for ac_last_try in false false false false false :; do
19813 . ./conf$$subs.sh ||
22e05272 19814 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
5213506e
RW
19815
19816 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
19817 if test $ac_delim_n = $ac_delim_num; then
19818 break
19819 elif $ac_last_try; then
22e05272 19820 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
5213506e
RW
19821 else
19822 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19823 fi
19824done
19825rm -f conf$$subs.sh
19826
19827cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22e05272 19828cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
2aeb72e9 19829_ACEOF
5213506e
RW
19830sed -n '
19831h
19832s/^/S["/; s/!.*/"]=/
19833p
19834g
19835s/^[^!]*!//
19836:repl
19837t repl
19838s/'"$ac_delim"'$//
19839t delim
19840:nl
19841h
22e05272 19842s/\(.\{148\}\)..*/\1/
5213506e
RW
19843t more1
19844s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
19845p
19846n
19847b repl
19848:more1
19849s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19850p
19851g
19852s/.\{148\}//
19853t nl
19854:delim
19855h
22e05272 19856s/\(.\{148\}\)..*/\1/
5213506e
RW
19857t more2
19858s/["\\]/\\&/g; s/^/"/; s/$/"/
19859p
19860b
19861:more2
19862s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19863p
19864g
19865s/.\{148\}//
19866t delim
19867' <conf$$subs.awk | sed '
19868/^[^""]/{
19869 N
19870 s/\n//
19871}
19872' >>$CONFIG_STATUS || ac_write_fail=1
19873rm -f conf$$subs.awk
19874cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19875_ACAWK
22e05272 19876cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
5213506e
RW
19877 for (key in S) S_is_set[key] = 1
19878 FS = "\a"
19879 \$ac_cs_awk_pipe_init
19880}
19881{
19882 line = $ 0
19883 nfields = split(line, field, "@")
19884 substed = 0
19885 len = length(field[1])
19886 for (i = 2; i < nfields; i++) {
19887 key = field[i]
19888 keylen = length(key)
19889 if (S_is_set[key]) {
19890 value = S[key]
19891 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
19892 len += length(value) + length(field[++i])
19893 substed = 1
19894 } else
19895 len += 1 + keylen
19896 }
19897 if (nfields == 3 && !substed) {
19898 key = field[2]
19899 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
19900 \$ac_cs_awk_read_file
19901 next
19902 }
19903 }
19904 print line
19905}
19906\$ac_cs_awk_pipe_fini
19907_ACAWK
19908_ACEOF
19909cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19910if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
19911 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
19912else
19913 cat
22e05272
JM
19914fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
19915 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
5213506e
RW
19916_ACEOF
19917
22e05272
JM
19918# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
19919# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
5213506e
RW
19920# trailing colons and then remove the whole line if VPATH becomes empty
19921# (actually we leave an empty line to preserve line numbers).
19922if test "x$srcdir" = x.; then
22e05272
JM
19923 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
19924h
19925s///
19926s/^/:/
19927s/[ ]*$/:/
19928s/:\$(srcdir):/:/g
19929s/:\${srcdir}:/:/g
19930s/:@srcdir@:/:/g
19931s/^:*//
5213506e 19932s/:*$//
22e05272
JM
19933x
19934s/\(=[ ]*\).*/\1/
19935G
19936s/\n//
5213506e
RW
19937s/^[^=]*=[ ]*$//
19938}'
19939fi
2aeb72e9 19940
5213506e
RW
19941cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19942fi # test -n "$CONFIG_FILES"
2aeb72e9 19943
1c710c3c 19944
5213506e
RW
19945eval set X " :F $CONFIG_FILES "
19946shift
19947for ac_tag
19948do
19949 case $ac_tag in
19950 :[FHLC]) ac_mode=$ac_tag; continue;;
19951 esac
19952 case $ac_mode$ac_tag in
19953 :[FHL]*:*);;
22e05272 19954 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
5213506e
RW
19955 :[FH]-) ac_tag=-:-;;
19956 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
19957 esac
19958 ac_save_IFS=$IFS
19959 IFS=:
19960 set x $ac_tag
19961 IFS=$ac_save_IFS
19962 shift
19963 ac_file=$1
19964 shift
79c06341 19965
5213506e
RW
19966 case $ac_mode in
19967 :L) ac_source=$1;;
19968 :[FH])
19969 ac_file_inputs=
19970 for ac_f
19971 do
19972 case $ac_f in
22e05272 19973 -) ac_f="$ac_tmp/stdin";;
5213506e
RW
19974 *) # Look for the file first in the build tree, then in the source tree
19975 # (if the path is not absolute). The absolute path cannot be DOS-style,
19976 # because $ac_f cannot contain `:'.
19977 test -f "$ac_f" ||
19978 case $ac_f in
19979 [\\/$]*) false;;
19980 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
19981 esac ||
22e05272 19982 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
5213506e
RW
19983 esac
19984 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
19985 as_fn_append ac_file_inputs " '$ac_f'"
19986 done
1c710c3c 19987
5213506e
RW
19988 # Let's still pretend it is `configure' which instantiates (i.e., don't
19989 # use $as_me), people would be surprised to read:
19990 # /* config.h. Generated by config.status. */
19991 configure_input='Generated from '`
19992 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
19993 `' by configure.'
19994 if test x"$ac_file" != x-; then
19995 configure_input="$ac_file. $configure_input"
19996 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
19997$as_echo "$as_me: creating $ac_file" >&6;}
2aeb72e9 19998 fi
5213506e
RW
19999 # Neutralize special characters interpreted by sed in replacement strings.
20000 case $configure_input in #(
20001 *\&* | *\|* | *\\* )
20002 ac_sed_conf_input=`$as_echo "$configure_input" |
20003 sed 's/[\\\\&|]/\\\\&/g'`;; #(
20004 *) ac_sed_conf_input=$configure_input;;
20005 esac
11a67599 20006
5213506e 20007 case $ac_tag in
22e05272
JM
20008 *:-:* | *:-) cat >"$ac_tmp/stdin" \
20009 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
5213506e
RW
20010 esac
20011 ;;
11a67599
ZW
20012 esac
20013
5213506e 20014 ac_dir=`$as_dirname -- "$ac_file" ||
1c710c3c
DJ
20015$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20016 X"$ac_file" : 'X\(//\)[^/]' \| \
20017 X"$ac_file" : 'X\(//\)$' \| \
5213506e
RW
20018 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
20019$as_echo X"$ac_file" |
20020 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20021 s//\1/
20022 q
20023 }
20024 /^X\(\/\/\)[^/].*/{
20025 s//\1/
20026 q
20027 }
20028 /^X\(\/\/\)$/{
20029 s//\1/
20030 q
20031 }
20032 /^X\(\/\).*/{
20033 s//\1/
20034 q
20035 }
20036 s/.*/./; q'`
20037 as_dir="$ac_dir"; as_fn_mkdir_p
1c710c3c 20038 ac_builddir=.
0b0dc272 20039
5213506e
RW
20040case "$ac_dir" in
20041.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
20042*)
20043 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
20044 # A ".." for each directory in $ac_dir_suffix.
20045 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
20046 case $ac_top_builddir_sub in
20047 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
20048 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
20049 esac ;;
20050esac
20051ac_abs_top_builddir=$ac_pwd
20052ac_abs_builddir=$ac_pwd$ac_dir_suffix
20053# for backward compatibility:
20054ac_top_builddir=$ac_top_build_prefix
1c710c3c
DJ
20055
20056case $srcdir in
5213506e 20057 .) # We are building in place.
1c710c3c 20058 ac_srcdir=.
5213506e
RW
20059 ac_top_srcdir=$ac_top_builddir_sub
20060 ac_abs_top_srcdir=$ac_pwd ;;
20061 [\\/]* | ?:[\\/]* ) # Absolute name.
1c710c3c 20062 ac_srcdir=$srcdir$ac_dir_suffix;
5213506e
RW
20063 ac_top_srcdir=$srcdir
20064 ac_abs_top_srcdir=$srcdir ;;
20065 *) # Relative name.
20066 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
20067 ac_top_srcdir=$ac_top_build_prefix$srcdir
20068 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1c710c3c 20069esac
5213506e 20070ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
a4b9e93e 20071
0b0dc272 20072
5213506e
RW
20073 case $ac_mode in
20074 :F)
20075 #
20076 # CONFIG_FILE
20077 #
1c710c3c
DJ
20078
20079 case $INSTALL in
20080 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
5213506e 20081 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
671aa708 20082 esac
5213506e 20083_ACEOF
11a67599 20084
5213506e
RW
20085cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20086# If the template does not know about datarootdir, expand it.
20087# FIXME: This hack should be removed a few years after 2.60.
20088ac_datarootdir_hack=; ac_datarootdir_seen=
20089ac_sed_dataroot='
20090/datarootdir/ {
20091 p
20092 q
20093}
20094/@datadir@/p
20095/@docdir@/p
20096/@infodir@/p
20097/@localedir@/p
20098/@mandir@/p'
20099case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
20100*datarootdir*) ac_datarootdir_seen=yes;;
20101*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
20102 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
20103$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
11a67599 20104_ACEOF
5213506e
RW
20105cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20106 ac_datarootdir_hack='
20107 s&@datadir@&$datadir&g
20108 s&@docdir@&$docdir&g
20109 s&@infodir@&$infodir&g
20110 s&@localedir@&$localedir&g
20111 s&@mandir@&$mandir&g
20112 s&\\\${datarootdir}&$datarootdir&g' ;;
20113esac
20114_ACEOF
20115
20116# Neutralize VPATH when `$srcdir' = `.'.
20117# Shell code in configure.ac might set extrasub.
20118# FIXME: do we really want to maintain this feature?
20119cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20120ac_sed_extra="$ac_vpsub
1c710c3c
DJ
20121$extrasub
20122_ACEOF
5213506e 20123cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
1c710c3c
DJ
20124:t
20125/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
5213506e
RW
20126s|@configure_input@|$ac_sed_conf_input|;t t
20127s&@top_builddir@&$ac_top_builddir_sub&;t t
20128s&@top_build_prefix@&$ac_top_build_prefix&;t t
20129s&@srcdir@&$ac_srcdir&;t t
20130s&@abs_srcdir@&$ac_abs_srcdir&;t t
20131s&@top_srcdir@&$ac_top_srcdir&;t t
20132s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
20133s&@builddir@&$ac_builddir&;t t
20134s&@abs_builddir@&$ac_abs_builddir&;t t
20135s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
20136s&@INSTALL@&$ac_INSTALL&;t t
20137$ac_datarootdir_hack
20138"
20139eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
20140if $ac_cs_awk_getline; then
22e05272 20141 $AWK -f "$ac_tmp/subs.awk"
5213506e 20142else
22e05272
JM
20143 $AWK -f "$ac_tmp/subs.awk" | $SHELL
20144fi \
20145 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
5213506e
RW
20146
20147test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
22e05272
JM
20148 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
20149 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
20150 "$ac_tmp/out"`; test -z "$ac_out"; } &&
5213506e 20151 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22e05272 20152which seems to be undefined. Please make sure it is defined" >&5
5213506e 20153$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22e05272 20154which seems to be undefined. Please make sure it is defined" >&2;}
5213506e 20155
22e05272 20156 rm -f "$ac_tmp/stdin"
5213506e 20157 case $ac_file in
22e05272
JM
20158 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
20159 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
5213506e 20160 esac \
22e05272 20161 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
5213506e 20162 ;;
11a67599 20163
11a67599 20164
79c06341 20165
5213506e
RW
20166 esac
20167
3e54529c
RW
20168
20169 case $ac_file$ac_mode in
20170 "Makefile":F) sed "$extrasub_build" Makefile |
20171 sed "$extrasub_host" |
20172 sed "$extrasub_target" > mf$$
20173 mv -f mf$$ Makefile ;;
20174
20175 esac
5213506e
RW
20176done # for ac_tag
20177
20178
20179as_fn_exit 0
1c710c3c 20180_ACEOF
1c710c3c
DJ
20181ac_clean_files=$ac_clean_files_save
20182
5213506e 20183test $ac_write_fail = 0 ||
22e05272 20184 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
5213506e 20185
1c710c3c
DJ
20186
20187# configure is writing to config.log, and then calls config.status.
20188# config.status does its own redirection, appending to config.log.
20189# Unfortunately, on DOS this fails, as config.log is still kept open
20190# by configure, so config.status won't be able to write to it; its
20191# output is simply discarded. So we exec the FD to /dev/null,
20192# effectively closing config.log, so it can be properly (re)opened and
20193# appended to by config.status. When coming back to configure, we
20194# need to make the FD available again.
20195if test "$no_create" != yes; then
20196 ac_cs_success=:
20197 ac_config_status_args=
20198 test "$silent" = yes &&
20199 ac_config_status_args="$ac_config_status_args --quiet"
20200 exec 5>/dev/null
20201 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
20202 exec 5>>config.log
20203 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20204 # would make configure fail if this is the last instruction.
22e05272 20205 $ac_cs_success || as_fn_exit 1
5213506e
RW
20206fi
20207if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
20208 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
20209$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
1c710c3c 20210fi
79c06341 20211