]> git.ipfire.org Git - thirdparty/gcc.git/blame - configure
gcc/testsuite/
[thirdparty/gcc.git] / configure
CommitLineData
671aa708 1#! /bin/sh
af71363e 2
671aa708 3# Guess values for system-dependent variables and create Makefiles.
af71363e
AS
4# Generated automatically using autoconf version 2.13
5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
671aa708
NN
6#
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
0b0dc272 9
af71363e
AS
10# Defaults:
11ac_help=
671aa708 12ac_default_prefix=/usr/local
af71363e
AS
13# Any additions from configure.in:
14ac_help="$ac_help
15 --with-build-libsubdir=[DIR] Directory where to find libraries for build system"
16ac_help="$ac_help
17 --enable-libada Builds libada directory"
18ac_help="$ac_help
19 --enable-libssp Builds libssp directory"
20ac_help="$ac_help
21 --with-mpfr-dir=PATH This option has been REMOVED"
22ac_help="$ac_help
23 --with-mpfr=PATH Specify prefix directory for installed MPFR package
24 Equivalent to --with-mpfr-include=PATH/include
25 plus --with-mpfr-lib=PATH/lib"
26ac_help="$ac_help
27 --with-mpfr-include=PATH
28 Specify directory for installed MPFR include files"
29ac_help="$ac_help
30 --with-mpfr-lib=PATH Specify the directory for the installed MPFR library"
31ac_help="$ac_help
32 --with-gmp-dir=PATH This option has been REMOVED"
33ac_help="$ac_help
34 --with-gmp=PATH Specify prefix directory for the installed GMP package
35 Equivalent to --with-gmp-include=PATH/include
36 plus --with-gmp-lib=PATH/lib"
37ac_help="$ac_help
38 --with-gmp-include=PATH Specify directory for installed GMP include files"
39ac_help="$ac_help
40 --with-gmp-lib=PATH Specify the directory for the installed GMP library"
e1888513
PB
41ac_help="$ac_help
42 --enable-stage1-languages[=all] choose additional languages to build during
43 stage1. Mostly useful for compiler development."
af71363e
AS
44ac_help="$ac_help
45 --enable-objc-gc enable the use of Boehm's garbage collector with
46 the GNU Objective-C runtime."
47ac_help="$ac_help
48 --with-build-sysroot=sysroot
49 use sysroot as the system root during the build"
50ac_help="$ac_help
51 --enable-bootstrap Enable bootstrapping [yes if native build]"
52ac_help="$ac_help
53 --enable-serial-[{host,target,build}-]configure
54 Force sequential configuration of
55 sub-packages for the host, target or build
56 machine, or all sub-packages"
57ac_help="$ac_help
58 --with-build-time-tools=path
59 use given path to find target tools during the build"
60ac_help="$ac_help
61 --enable-maintainer-mode enable make rules and dependencies not useful
62 (and sometimes confusing) to the casual installer"
63ac_help="$ac_help
64 --enable-stage1-checking[=all] choose additional checking for stage1
65 of the compiler."
66ac_help="$ac_help
67 --enable-werror enable -Werror in bootstrap stage2 and later"
68ac_help="$ac_help
69 --with-datarootdir Use datarootdir as the data root directory."
70ac_help="$ac_help
71 --with-docdir Install documentation in this directory."
72ac_help="$ac_help
73 --with-htmldir Install html in this directory."
671aa708
NN
74
75# Initialize some variables set by options.
76# The variables have the same names as the options, with
77# dashes changed to underlines.
af71363e
AS
78build=NONE
79cache_file=./config.cache
671aa708 80exec_prefix=NONE
af71363e 81host=NONE
671aa708 82no_create=
af71363e 83nonopt=NONE
671aa708
NN
84no_recursion=
85prefix=NONE
86program_prefix=NONE
87program_suffix=NONE
88program_transform_name=s,x,x,
89silent=
90site=
91srcdir=
af71363e 92target=NONE
671aa708
NN
93verbose=
94x_includes=NONE
95x_libraries=NONE
96bindir='${exec_prefix}/bin'
97sbindir='${exec_prefix}/sbin'
98libexecdir='${exec_prefix}/libexec'
99datadir='${prefix}/share'
100sysconfdir='${prefix}/etc'
101sharedstatedir='${prefix}/com'
102localstatedir='${prefix}/var'
103libdir='${exec_prefix}/lib'
104includedir='${prefix}/include'
105oldincludedir='/usr/include'
106infodir='${prefix}/info'
107mandir='${prefix}/man'
79c06341 108
af71363e
AS
109# Initialize some other variables.
110subdirs=
111MFLAGS= MAKEFLAGS=
112SHELL=${CONFIG_SHELL-/bin/sh}
113# Maximum number of lines to put in a shell here document.
114ac_max_here_lines=12
115
671aa708
NN
116ac_prev=
117for ac_option
118do
af71363e 119
671aa708
NN
120 # If the previous option needs an argument, assign it.
121 if test -n "$ac_prev"; then
122 eval "$ac_prev=\$ac_option"
123 ac_prev=
124 continue
125 fi
79c06341 126
af71363e
AS
127 case "$ac_option" in
128 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
129 *) ac_optarg= ;;
130 esac
671aa708
NN
131
132 # Accept the important Cygnus configure options, so we can diagnose typos.
133
af71363e 134 case "$ac_option" in
671aa708
NN
135
136 -bindir | --bindir | --bindi | --bind | --bin | --bi)
137 ac_prev=bindir ;;
138 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
af71363e 139 bindir="$ac_optarg" ;;
671aa708
NN
140
141 -build | --build | --buil | --bui | --bu)
af71363e 142 ac_prev=build ;;
671aa708 143 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
af71363e 144 build="$ac_optarg" ;;
671aa708
NN
145
146 -cache-file | --cache-file | --cache-fil | --cache-fi \
147 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
148 ac_prev=cache_file ;;
149 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
150 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
af71363e 151 cache_file="$ac_optarg" ;;
671aa708
NN
152
153 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
154 ac_prev=datadir ;;
155 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
156 | --da=*)
af71363e 157 datadir="$ac_optarg" ;;
671aa708
NN
158
159 -disable-* | --disable-*)
af71363e 160 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
671aa708 161 # Reject names that are not valid shell variable names.
af71363e
AS
162 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
163 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
164 fi
165 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
166 eval "enable_${ac_feature}=no" ;;
671aa708
NN
167
168 -enable-* | --enable-*)
af71363e 169 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
671aa708 170 # Reject names that are not valid shell variable names.
af71363e
AS
171 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
172 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
173 fi
174 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
175 case "$ac_option" in
176 *=*) ;;
671aa708
NN
177 *) ac_optarg=yes ;;
178 esac
af71363e 179 eval "enable_${ac_feature}='$ac_optarg'" ;;
671aa708
NN
180
181 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
182 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
183 | --exec | --exe | --ex)
184 ac_prev=exec_prefix ;;
185 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
186 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
187 | --exec=* | --exe=* | --ex=*)
af71363e 188 exec_prefix="$ac_optarg" ;;
671aa708
NN
189
190 -gas | --gas | --ga | --g)
191 # Obsolete; use --with-gas.
192 with_gas=yes ;;
193
af71363e
AS
194 -help | --help | --hel | --he)
195 # Omit some internal or obsolete options to make the list less imposing.
196 # This message is too long to be a string in the A/UX 3.1 sh.
197 cat << EOF
198Usage: configure [options] [host]
199Options: [defaults in brackets after descriptions]
200Configuration:
201 --cache-file=FILE cache test results in FILE
202 --help print this message
203 --no-create do not create output files
204 --quiet, --silent do not print \`checking...' messages
205 --version print the version of autoconf that created configure
206Directory and file names:
207 --prefix=PREFIX install architecture-independent files in PREFIX
208 [$ac_default_prefix]
209 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
210 [same as prefix]
211 --bindir=DIR user executables in DIR [EPREFIX/bin]
212 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
213 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
214 --datadir=DIR read-only architecture-independent data in DIR
215 [PREFIX/share]
216 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
217 --sharedstatedir=DIR modifiable architecture-independent data in DIR
218 [PREFIX/com]
219 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
220 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
221 --includedir=DIR C header files in DIR [PREFIX/include]
222 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
223 --infodir=DIR info documentation in DIR [PREFIX/info]
224 --mandir=DIR man documentation in DIR [PREFIX/man]
225 --srcdir=DIR find the sources in DIR [configure dir or ..]
226 --program-prefix=PREFIX prepend PREFIX to installed program names
227 --program-suffix=SUFFIX append SUFFIX to installed program names
228 --program-transform-name=PROGRAM
229 run sed PROGRAM on installed program names
230EOF
231 cat << EOF
232Host type:
233 --build=BUILD configure for building on BUILD [BUILD=HOST]
234 --host=HOST configure for HOST [guessed]
235 --target=TARGET configure for TARGET [TARGET=HOST]
236Features and packages:
237 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
238 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
239 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
240 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
241 --x-includes=DIR X include files are in DIR
242 --x-libraries=DIR X library files are in DIR
243EOF
244 if test -n "$ac_help"; then
245 echo "--enable and --with options recognized:$ac_help"
246 fi
247 exit 0 ;;
671aa708
NN
248
249 -host | --host | --hos | --ho)
af71363e 250 ac_prev=host ;;
671aa708 251 -host=* | --host=* | --hos=* | --ho=*)
af71363e 252 host="$ac_optarg" ;;
671aa708
NN
253
254 -includedir | --includedir | --includedi | --included | --include \
255 | --includ | --inclu | --incl | --inc)
256 ac_prev=includedir ;;
257 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
258 | --includ=* | --inclu=* | --incl=* | --inc=*)
af71363e 259 includedir="$ac_optarg" ;;
671aa708
NN
260
261 -infodir | --infodir | --infodi | --infod | --info | --inf)
262 ac_prev=infodir ;;
263 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
af71363e 264 infodir="$ac_optarg" ;;
671aa708
NN
265
266 -libdir | --libdir | --libdi | --libd)
267 ac_prev=libdir ;;
268 -libdir=* | --libdir=* | --libdi=* | --libd=*)
af71363e 269 libdir="$ac_optarg" ;;
671aa708
NN
270
271 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
272 | --libexe | --libex | --libe)
273 ac_prev=libexecdir ;;
274 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
275 | --libexe=* | --libex=* | --libe=*)
af71363e 276 libexecdir="$ac_optarg" ;;
671aa708
NN
277
278 -localstatedir | --localstatedir | --localstatedi | --localstated \
279 | --localstate | --localstat | --localsta | --localst \
280 | --locals | --local | --loca | --loc | --lo)
281 ac_prev=localstatedir ;;
282 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
283 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
284 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
af71363e 285 localstatedir="$ac_optarg" ;;
671aa708
NN
286
287 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
288 ac_prev=mandir ;;
289 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
af71363e 290 mandir="$ac_optarg" ;;
671aa708
NN
291
292 -nfp | --nfp | --nf)
293 # Obsolete; use --without-fp.
294 with_fp=no ;;
295
296 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
af71363e 297 | --no-cr | --no-c)
671aa708
NN
298 no_create=yes ;;
299
300 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
301 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
302 no_recursion=yes ;;
303
304 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
305 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
306 | --oldin | --oldi | --old | --ol | --o)
307 ac_prev=oldincludedir ;;
308 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
309 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
310 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
af71363e 311 oldincludedir="$ac_optarg" ;;
671aa708
NN
312
313 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
314 ac_prev=prefix ;;
315 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
af71363e 316 prefix="$ac_optarg" ;;
671aa708
NN
317
318 -program-prefix | --program-prefix | --program-prefi | --program-pref \
319 | --program-pre | --program-pr | --program-p)
320 ac_prev=program_prefix ;;
321 -program-prefix=* | --program-prefix=* | --program-prefi=* \
322 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
af71363e 323 program_prefix="$ac_optarg" ;;
671aa708
NN
324
325 -program-suffix | --program-suffix | --program-suffi | --program-suff \
326 | --program-suf | --program-su | --program-s)
327 ac_prev=program_suffix ;;
328 -program-suffix=* | --program-suffix=* | --program-suffi=* \
329 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
af71363e 330 program_suffix="$ac_optarg" ;;
671aa708
NN
331
332 -program-transform-name | --program-transform-name \
333 | --program-transform-nam | --program-transform-na \
334 | --program-transform-n | --program-transform- \
335 | --program-transform | --program-transfor \
336 | --program-transfo | --program-transf \
337 | --program-trans | --program-tran \
338 | --progr-tra | --program-tr | --program-t)
339 ac_prev=program_transform_name ;;
340 -program-transform-name=* | --program-transform-name=* \
341 | --program-transform-nam=* | --program-transform-na=* \
342 | --program-transform-n=* | --program-transform-=* \
343 | --program-transform=* | --program-transfor=* \
344 | --program-transfo=* | --program-transf=* \
345 | --program-trans=* | --program-tran=* \
346 | --progr-tra=* | --program-tr=* | --program-t=*)
af71363e 347 program_transform_name="$ac_optarg" ;;
671aa708
NN
348
349 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
350 | -silent | --silent | --silen | --sile | --sil)
351 silent=yes ;;
352
353 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
354 ac_prev=sbindir ;;
355 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
356 | --sbi=* | --sb=*)
af71363e 357 sbindir="$ac_optarg" ;;
671aa708
NN
358
359 -sharedstatedir | --sharedstatedir | --sharedstatedi \
360 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
361 | --sharedst | --shareds | --shared | --share | --shar \
362 | --sha | --sh)
363 ac_prev=sharedstatedir ;;
364 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
365 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
366 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
367 | --sha=* | --sh=*)
af71363e 368 sharedstatedir="$ac_optarg" ;;
671aa708
NN
369
370 -site | --site | --sit)
371 ac_prev=site ;;
372 -site=* | --site=* | --sit=*)
af71363e 373 site="$ac_optarg" ;;
671aa708
NN
374
375 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
376 ac_prev=srcdir ;;
377 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
af71363e 378 srcdir="$ac_optarg" ;;
671aa708
NN
379
380 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
381 | --syscon | --sysco | --sysc | --sys | --sy)
382 ac_prev=sysconfdir ;;
383 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
384 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
af71363e 385 sysconfdir="$ac_optarg" ;;
671aa708
NN
386
387 -target | --target | --targe | --targ | --tar | --ta | --t)
af71363e 388 ac_prev=target ;;
671aa708 389 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
af71363e 390 target="$ac_optarg" ;;
671aa708
NN
391
392 -v | -verbose | --verbose | --verbos | --verbo | --verb)
393 verbose=yes ;;
394
af71363e
AS
395 -version | --version | --versio | --versi | --vers)
396 echo "configure generated by autoconf version 2.13"
397 exit 0 ;;
671aa708
NN
398
399 -with-* | --with-*)
af71363e 400 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
671aa708 401 # Reject names that are not valid shell variable names.
af71363e
AS
402 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
403 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
404 fi
671aa708 405 ac_package=`echo $ac_package| sed 's/-/_/g'`
af71363e
AS
406 case "$ac_option" in
407 *=*) ;;
671aa708
NN
408 *) ac_optarg=yes ;;
409 esac
af71363e 410 eval "with_${ac_package}='$ac_optarg'" ;;
671aa708
NN
411
412 -without-* | --without-*)
af71363e 413 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
671aa708 414 # Reject names that are not valid shell variable names.
af71363e
AS
415 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
416 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
417 fi
418 ac_package=`echo $ac_package| sed 's/-/_/g'`
419 eval "with_${ac_package}=no" ;;
671aa708
NN
420
421 --x)
422 # Obsolete; use --with-x.
423 with_x=yes ;;
424
425 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
426 | --x-incl | --x-inc | --x-in | --x-i)
427 ac_prev=x_includes ;;
428 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
429 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
af71363e 430 x_includes="$ac_optarg" ;;
671aa708
NN
431
432 -x-libraries | --x-libraries | --x-librarie | --x-librari \
433 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
434 ac_prev=x_libraries ;;
435 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
436 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
af71363e 437 x_libraries="$ac_optarg" ;;
671aa708 438
af71363e 439 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
671aa708
NN
440 ;;
441
442 *)
af71363e
AS
443 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
444 echo "configure: warning: $ac_option: invalid host type" 1>&2
445 fi
446 if test "x$nonopt" != xNONE; then
447 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
448 fi
449 nonopt="$ac_option"
671aa708
NN
450 ;;
451
452 esac
453done
454
455if test -n "$ac_prev"; then
af71363e 456 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
fb0103e5 457fi
671aa708 458
af71363e
AS
459trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
460
461# File descriptor usage:
462# 0 standard input
463# 1 file creation
464# 2 errors and warnings
465# 3 some systems may open it to /dev/tty
466# 4 used on the Kubota Titan
467# 6 checking for... messages and results
468# 5 compiler messages saved in config.log
469if test "$silent" = yes; then
470 exec 6>/dev/null
471else
472 exec 6>&1
473fi
474exec 5>./config.log
475
476echo "\
477This file contains any messages produced by compilers while
478running configure, to aid debugging if configure makes a mistake.
479" 1>&5
fb0103e5 480
af71363e
AS
481# Strip out --no-create and --no-recursion so they do not pile up.
482# Also quote any args containing shell metacharacters.
483ac_configure_args=
484for ac_arg
671aa708 485do
af71363e
AS
486 case "$ac_arg" in
487 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
488 | --no-cr | --no-c) ;;
489 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
490 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
491 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
492 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
493 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
671aa708
NN
494 esac
495done
496
af71363e
AS
497# NLS nuisances.
498# Only set these to C if already set. These must not be set unconditionally
499# because not all systems understand e.g. LANG=C (notably SCO).
500# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
501# Non-C LC_CTYPE values break the ctype check.
502if test "${LANG+set}" = set; then LANG=C; export LANG; fi
503if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
504if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
505if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
0b0dc272 506
af71363e
AS
507# confdefs.h avoids OS command line length limits that DEFS can exceed.
508rm -rf conftest* confdefs.h
509# AIX cpp loses on an empty file, so make sure it contains at least a newline.
510echo > confdefs.h
671aa708 511
af71363e
AS
512# A filename unique to this package, relative to the directory that
513# configure is in, which we can look for to find out if srcdir is correct.
514ac_unique_file=move-if-change
671aa708
NN
515
516# Find the source files, if location was not specified.
517if test -z "$srcdir"; then
518 ac_srcdir_defaulted=yes
519 # Try the directory containing this script, then its parent.
af71363e
AS
520 ac_prog=$0
521 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
522 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
671aa708
NN
523 srcdir=$ac_confdir
524 if test ! -r $srcdir/$ac_unique_file; then
525 srcdir=..
526 fi
527else
528 ac_srcdir_defaulted=no
529fi
530if test ! -r $srcdir/$ac_unique_file; then
531 if test "$ac_srcdir_defaulted" = yes; then
af71363e 532 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
671aa708 533 else
af71363e
AS
534 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
535 fi
0b0dc272 536fi
af71363e 537srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
0b0dc272 538
671aa708 539# Prefer explicitly selected file to automatically selected ones.
bba5e0ca
EB
540if test -z "$CONFIG_SITE"; then
541 if test "x$prefix" != xNONE; then
542 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
543 else
544 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
671aa708
NN
545 fi
546fi
547for ac_site_file in $CONFIG_SITE; do
548 if test -r "$ac_site_file"; then
af71363e 549 echo "loading site script $ac_site_file"
671aa708
NN
550 . "$ac_site_file"
551 fi
552done
553
554if test -r "$cache_file"; then
af71363e
AS
555 echo "loading cache $cache_file"
556 . $cache_file
671aa708 557else
af71363e
AS
558 echo "creating cache $cache_file"
559 > $cache_file
671aa708
NN
560fi
561
562ac_ext=c
af71363e 563# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
671aa708 564ac_cpp='$CPP $CPPFLAGS'
af71363e
AS
565ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
566ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
567cross_compiling=$ac_cv_prog_cc_cross
568
569ac_exeext=
570ac_objext=o
571if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
572 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
573 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
574 ac_n= ac_c='
575' ac_t=' '
576 else
577 ac_n=-n ac_c= ac_t=
578 fi
579else
580 ac_n= ac_c='\c' ac_t=
581fi
671aa708
NN
582
583
d02c69be 584
671aa708 585ac_aux_dir=
4c4a5bbc 586for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
671aa708
NN
587 if test -f $ac_dir/install-sh; then
588 ac_aux_dir=$ac_dir
589 ac_install_sh="$ac_aux_dir/install-sh -c"
590 break
591 elif test -f $ac_dir/install.sh; then
592 ac_aux_dir=$ac_dir
593 ac_install_sh="$ac_aux_dir/install.sh -c"
594 break
595 fi
596done
597if test -z "$ac_aux_dir"; then
af71363e 598 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
671aa708 599fi
af71363e
AS
600ac_config_guess=$ac_aux_dir/config.guess
601ac_config_sub=$ac_aux_dir/config.sub
602ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
671aa708
NN
603
604
af71363e
AS
605# Do some error checking and defaulting for the host and target type.
606# The inputs are:
607# configure --host=HOST --target=TARGET --build=BUILD NONOPT
608#
609# The rules are:
610# 1. You are not allowed to specify --host, --target, and nonopt at the
611# same time.
612# 2. Host defaults to nonopt.
613# 3. If nonopt is not specified, then host defaults to the current host,
614# as determined by config.guess.
615# 4. Target and build default to nonopt.
616# 5. If nonopt is not specified, then target and build default to host.
671aa708
NN
617
618# The aliases save the names the user supplied, while $host etc.
619# will get canonicalized.
af71363e
AS
620case $host---$target---$nonopt in
621NONE---*---* | *---NONE---* | *---*---NONE) ;;
622*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
623esac
624
625
626# Make sure we can run config.sub.
627if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
628else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
629fi
630
631echo $ac_n "checking host system type""... $ac_c" 1>&6
e1888513 632echo "configure:633: checking host system type" >&5
af71363e
AS
633
634host_alias=$host
635case "$host_alias" in
636NONE)
637 case $nonopt in
638 NONE)
639 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
640 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
641 fi ;;
642 *) host_alias=$nonopt ;;
643 esac ;;
644esac
645
646host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
647host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
648host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
649host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
650echo "$ac_t""$host" 1>&6
651
652echo $ac_n "checking target system type""... $ac_c" 1>&6
e1888513 653echo "configure:654: checking target system type" >&5
af71363e
AS
654
655target_alias=$target
656case "$target_alias" in
657NONE)
658 case $nonopt in
659 NONE) target_alias=$host_alias ;;
660 *) target_alias=$nonopt ;;
661 esac ;;
662esac
663
664target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
665target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
666target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
667target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
668echo "$ac_t""$target" 1>&6
669
670echo $ac_n "checking build system type""... $ac_c" 1>&6
e1888513 671echo "configure:672: checking build system type" >&5
af71363e
AS
672
673build_alias=$build
674case "$build_alias" in
675NONE)
676 case $nonopt in
677 NONE) build_alias=$host_alias ;;
678 *) build_alias=$nonopt ;;
679 esac ;;
680esac
681
682build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
683build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
684build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
685build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
686echo "$ac_t""$build" 1>&6
687
688test "$host_alias" != "$target_alias" &&
671aa708
NN
689 test "$program_prefix$program_suffix$program_transform_name" = \
690 NONENONEs,x,x, &&
691 program_prefix=${target_alias}-
af71363e
AS
692
693if test "$program_transform_name" = s,x,x,; then
694 program_transform_name=
695else
696 # Double any \ or $. echo might interpret backslashes.
697 cat <<\EOF_SED > conftestsed
698s,\\,\\\\,g; s,\$,$$,g
699EOF_SED
700 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
701 rm -f conftestsed
702fi
671aa708 703test "$program_prefix" != NONE &&
af71363e 704 program_transform_name="s,^,${program_prefix},; $program_transform_name"
671aa708
NN
705# Use a double $ so make ignores it.
706test "$program_suffix" != NONE &&
af71363e
AS
707 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
708
709# sed with no file args requires a program.
710test "$program_transform_name" = "" && program_transform_name="s,x,x,"
671aa708
NN
711
712
775956d0
NN
713# Get 'install' or 'install-sh' and its variants.
714# Find a good install program. We prefer a C program (faster),
715# so one script is as good as another. But avoid the broken or
716# incompatible versions:
717# SysV /etc/install, /usr/sbin/install
718# SunOS /usr/etc/install
719# IRIX /sbin/install
720# AIX /bin/install
721# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
722# AFS /usr/afsws/bin/install, which mishandles nonexistent args
723# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
724# ./install, which can be erroneously created by make from ./install.sh.
af71363e 725echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
e1888513 726echo "configure:727: checking for a BSD compatible install" >&5
775956d0 727if test -z "$INSTALL"; then
af71363e
AS
728if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
729 echo $ac_n "(cached) $ac_c" 1>&6
730else
731 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
732 for ac_dir in $PATH; do
733 # Account for people who put trailing slashes in PATH elements.
734 case "$ac_dir/" in
735 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
736 *)
737 # OSF1 and SCO ODT 3.0 have their own names for install.
738 # Don't use installbsd from OSF since it installs stuff as root
739 # by default.
740 for ac_prog in ginstall scoinst install; do
741 if test -f $ac_dir/$ac_prog; then
775956d0 742 if test $ac_prog = install &&
af71363e 743 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
775956d0
NN
744 # AIX install. It has an incompatible calling convention.
745 :
746 else
af71363e
AS
747 ac_cv_path_install="$ac_dir/$ac_prog -c"
748 break 2
775956d0
NN
749 fi
750 fi
751 done
af71363e
AS
752 ;;
753 esac
754 done
755 IFS="$ac_save_IFS"
775956d0
NN
756
757fi
758 if test "${ac_cv_path_install+set}" = set; then
af71363e 759 INSTALL="$ac_cv_path_install"
775956d0
NN
760 else
761 # As a last resort, use the slow shell script. We don't cache a
762 # path for INSTALL within a source directory, because that will
763 # break other packages using the cache if that directory is
764 # removed, or if the path is relative.
af71363e 765 INSTALL="$ac_install_sh"
775956d0
NN
766 fi
767fi
af71363e 768echo "$ac_t""$INSTALL" 1>&6
775956d0
NN
769
770# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
771# It thinks the first close brace ends the variable substitution.
772test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
773
af71363e 774test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
775956d0
NN
775
776test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
777
af71363e 778echo $ac_n "checking whether ln works""... $ac_c" 1>&6
e1888513 779echo "configure:780: checking whether ln works" >&5
af71363e
AS
780if eval "test \"`echo '$''{'acx_cv_prog_LN'+set}'`\" = set"; then
781 echo $ac_n "(cached) $ac_c" 1>&6
ad6717df
PB
782else
783 rm -f conftestdata_t
784echo >conftestdata_f
785if ln conftestdata_f conftestdata_t 2>/dev/null
786then
787 acx_cv_prog_LN=ln
788else
789 acx_cv_prog_LN=no
790fi
791rm -f conftestdata_f conftestdata_t
792
793fi
794if test $acx_cv_prog_LN = no; then
795 LN="cp"
af71363e 796 echo "$ac_t""no, using $LN" 1>&6
ad6717df
PB
797else
798 LN="$acx_cv_prog_LN"
af71363e 799 echo "$ac_t""yes" 1>&6
ad6717df
PB
800fi
801
af71363e 802echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
e1888513 803echo "configure:804: checking whether ln -s works" >&5
af71363e
AS
804if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
805 echo $ac_n "(cached) $ac_c" 1>&6
fb0103e5 806else
af71363e
AS
807 rm -f conftestdata
808if ln -s X conftestdata 2>/dev/null
809then
810 rm -f conftestdata
811 ac_cv_prog_LN_S="ln -s"
812else
813 ac_cv_prog_LN_S=ln
814fi
815fi
816LN_S="$ac_cv_prog_LN_S"
817if test "$ac_cv_prog_LN_S" = "ln -s"; then
818 echo "$ac_t""yes" 1>&6
819else
820 echo "$ac_t""no" 1>&6
148907ea
PB
821fi
822
775956d0 823
79c06341 824### we might need to use some other shell than /bin/sh for running subshells
79c06341
JL
825### If we are on Windows, search for the shell. This will permit people
826### to not have /bin/sh, but to be able to see /SOME/PATH/sh configure
827### without also having to set CONFIG_SHELL. This code will work when
828### using bash, which sets OSTYPE.
829case "${OSTYPE}" in
830*win32*)
671aa708
NN
831 if test x${CONFIG_SHELL} = x ; then
832 if test ! -f /bin/sh ; then
833 if test x${SHELL} != x && test -f ${SHELL} ; then
79c06341
JL
834 CONFIG_SHELL=${SHELL}
835 export CONFIG_SHELL
836 else
837 for prog in sh sh.exe bash bash.exe; do
838 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
839 for dir in $PATH; do
840 test -z "$dir" && dir=.
841 if test -f $dir/$prog; then
842 CONFIG_SHELL=$dir/$prog
843 export CONFIG_SHELL
844 break
845 fi
846 done
847 IFS="$save_ifs"
848 test -n "${CONFIG_SHELL}" && break
849 done
850 fi
851 fi
852 fi
853 ;;
854esac
855
856config_shell=${CONFIG_SHELL-/bin/sh}
857
79c06341
JL
858progname=$0
859# if PWD already has a value, it is probably wrong.
671aa708 860if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
79c06341 861
b348267b 862# Export original configure arguments for use by sub-configures. These
eeae7b41
DJ
863# will be expanded by make, so quote '$'.
864tmp="$progname $@"
865sed -e 's,\$,$$,g' <<EOF_SED > conftestsed.out
866$tmp
b348267b 867EOF_SED
eeae7b41
DJ
868TOPLEVEL_CONFIGURE_ARGUMENTS=`cat conftestsed.out`
869rm -f conftestsed.out
3dfabf63 870
cc1e60ea 871
671aa708 872moveifchange=${srcdir}/move-if-change
79c06341 873
ee6a22df
L
874srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
875
876# We pass INSTALL explicitly to sub-makes. Make sure that it is not
877# a relative path.
878if test "$INSTALL" = "${srcdir}/install-sh -c"; then
879 INSTALL="${srcpwd}/install-sh -c"
880fi
881
671aa708
NN
882# Set srcdir to "." if that's what it is.
883# This is important for multilib support.
884pwd=`${PWDCMD-pwd}`
671aa708
NN
885if test "${pwd}" = "${srcpwd}" ; then
886 srcdir=.
79c06341
JL
887fi
888
671aa708 889topsrcdir=$srcpwd
5d4a5ee6 890
671aa708 891extra_host_args=
afabd8e6 892
671aa708
NN
893### To add a new directory to the tree, first choose whether it is a target
894### or a host dependent tool. Then put it into the appropriate list
895### (library or tools, host or target), doing a dependency sort.
79c06341 896
af71363e 897# Subdirs will be configured in the order listed in build_configdirs,
671aa708 898# configdirs, or target_configdirs; see the serialization section below.
79c06341 899
af71363e
AS
900# Dependency sorting is only needed when *configuration* must be done in
901# a particular order. In all cases a dependency should be specified in
671aa708 902# the Makefile, whether or not it's implicitly specified here.
79c06341 903
671aa708
NN
904# Double entries in build_configdirs, configdirs, or target_configdirs may
905# cause circular dependencies and break everything horribly.
79c06341 906
23f6b2f9
PB
907# these library is used by various programs built for the build
908# environment
909#
910build_libs="build-libiberty"
911
912# these tools are built for the build environment
71b5d516 913build_tools="build-texinfo build-byacc build-flex build-bison build-m4 build-fixincludes"
23f6b2f9 914
671aa708
NN
915# these libraries are used by various programs built for the host environment
916#
e69bf64b 917host_libs="intl mmalloc libiberty opcodes bfd readline tcl tk itcl libgui zlib libcpp libdecnumber gmp mpfr"
671aa708 918
671aa708
NN
919# these tools are built for the host environment
920# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
921# know that we are building the simulator.
922# binutils, gas and ld appear in that order because it makes sense to run
923# "make check" in that particular order.
5395b47b 924host_tools="texinfo byacc flex bison binutils gas ld fixincludes gcc sid sim gdb make patch prms send-pr gprof etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool diff rcs fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl gawk findutils gettext zip fastjar gnattools"
671aa708
NN
925
926# libgcj represents the runtime libraries only used by gcj.
927libgcj="target-libffi \
671aa708
NN
928 target-zlib \
929 target-qthreads \
930 target-libjava"
931
932# these libraries are built for the target environment, and are built after
933# the host libraries and the host tools (which may be a cross compiler)
934#
4dbda6f0 935target_libraries="target-libiberty \
fa958513 936 target-libgcc \
671aa708
NN
937 target-libgloss \
938 target-newlib \
cb543528 939 target-libstdc++-v3 \
6de9cd9a 940 target-libmudflap \
77008252 941 target-libssp \
6de9cd9a 942 target-libgfortran \
7cd0cf9c 943 target-boehm-gc \
77d187bc 944 ${libgcj} \
d9cdb878 945 target-libobjc \
953ff289
DN
946 target-libada \
947 target-libgomp"
671aa708 948
4dbda6f0
NN
949# these tools are built using the target libraries, and are intended to
950# run only in the target environment
671aa708 951#
4dbda6f0 952# note: any program that *uses* libraries that are in the "target_libraries"
671aa708
NN
953# list belongs in this list. those programs are also very likely
954# candidates for the "native_only" list which follows
955#
97286f7f 956target_tools="target-examples target-groff target-gperf target-rda"
79c06341 957
671aa708 958################################################################################
79c06341 959
671aa708
NN
960## All tools belong in one of the four categories, and are assigned above
961## We assign ${configdirs} this way to remove all embedded newlines. This
962## is important because configure will choke if they ever get through.
963## ${configdirs} is directories we build using the host tools.
964## ${target_configdirs} is directories we build using the target tools.
671aa708 965configdirs=`echo ${host_libs} ${host_tools}`
4dbda6f0 966target_configdirs=`echo ${target_libraries} ${target_tools}`
71b5d516 967build_configdirs=`echo ${build_libs} ${build_tools}`
8b87bb96 968
671aa708 969################################################################################
79c06341 970
671aa708 971srcname="gnu development package"
79c06341 972
671aa708
NN
973# This gets set non-empty for some net releases of packages.
974appdirs=""
79c06341 975
671aa708
NN
976# Define is_cross_compiler to save on calls to 'test'.
977is_cross_compiler=
978if test x"${host}" = x"${target}" ; then
979 is_cross_compiler=no
79c06341 980else
671aa708 981 is_cross_compiler=yes
af71363e 982fi
79c06341 983
b4acb5ef 984# Find the build and target subdir names.
8b87bb96
NN
985 case ${build_alias} in
986 "") build_noncanonical=${build} ;;
987 *) build_noncanonical=${build_alias} ;;
988esac
989
990 case ${host_alias} in
991 "") host_noncanonical=${build_noncanonical} ;;
992 *) host_noncanonical=${host_alias} ;;
993esac
994
995 case ${target_alias} in
996 "") target_noncanonical=${host_noncanonical} ;;
997 *) target_noncanonical=${target_alias} ;;
998esac
999
af71363e 1000
2e9e6f68
DJ
1001# post-stage1 host modules use a different CC_FOR_BUILD so, in order to
1002# have matching libraries, they should use host libraries: Makefile.tpl
1003# arranges to pass --with-build-libsubdir=$(HOST_SUBDIR).
1004# However, they still use the build modules, because the corresponding
1005# host modules (e.g. bison) are only built for the host when bootstrap
1006# finishes. So:
1007# - build_subdir is where we find build modules, and never changes.
1008# - build_libsubdir is where we find build libraries, and can be overridden.
1009
1010# Prefix 'build-' so this never conflicts with target_subdir.
8b87bb96 1011build_subdir="build-${build_noncanonical}"
2e9e6f68
DJ
1012# Check whether --with-build-libsubdir or --without-build-libsubdir was given.
1013if test "${with_build_libsubdir+set}" = set; then
1014 withval="$with_build_libsubdir"
1015 build_libsubdir="$withval"
1016else
1017 build_libsubdir="$build_subdir"
af71363e
AS
1018fi
1019
215c351a
PB
1020# --srcdir=. covers the toplevel, while "test -d" covers the subdirectories
1021if ( test $srcdir = . && test -d gcc ) \
1022 || test -d $srcdir/../host-${host_noncanonical}; then
1023 host_subdir="host-${host_noncanonical}"
1024else
1025 host_subdir=.
1026fi
8b87bb96
NN
1027# No prefix.
1028target_subdir=${target_noncanonical}
af71363e 1029
79c06341 1030
671aa708
NN
1031# Skipdirs are removed silently.
1032skipdirs=
1033# Noconfigdirs are removed loudly.
1034noconfigdirs=""
79c06341 1035
671aa708
NN
1036use_gnu_ld=
1037# Make sure we don't let GNU ld be added if we didn't want it.
1038if test x$with_gnu_ld = xno ; then
1039 use_gnu_ld=no
1040 noconfigdirs="$noconfigdirs ld"
79c06341
JL
1041fi
1042
671aa708
NN
1043use_gnu_as=
1044# Make sure we don't let GNU as be added if we didn't want it.
1045if test x$with_gnu_as = xno ; then
1046 use_gnu_as=no
1047 noconfigdirs="$noconfigdirs gas"
79c06341
JL
1048fi
1049
af71363e 1050# some tools are so dependent upon X11 that if we're not building with X,
671aa708 1051# it's not even worth trying to configure, much less build, that tool.
79c06341 1052
671aa708
NN
1053case ${with_x} in
1054 yes | "") ;; # the default value for this tree is that X11 is available
1055 no)
b4f96efe 1056 skipdirs="${skipdirs} tk itcl libgui"
671aa708 1057 # We won't be able to build gdbtk without X.
af71363e 1058 enable_gdbtk=no
671aa708
NN
1059 ;;
1060 *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
1061esac
79c06341 1062
671aa708 1063# Some tools are only suitable for building in a "native" situation.
af71363e 1064# Remove these if host!=target.
9e299237 1065native_only="autoconf automake libtool fileutils find gawk gettext gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff target-groff guile perl time ash bash bzip2 prms gnuserv target-gperf"
79c06341 1066
671aa708
NN
1067# Similarly, some are only suitable for cross toolchains.
1068# Remove these if host=target.
1069cross_only="target-libgloss target-newlib target-opcodes"
1070
1071case $is_cross_compiler in
1072 no) skipdirs="${skipdirs} ${cross_only}" ;;
1073 yes) skipdirs="${skipdirs} ${native_only}" ;;
1074esac
79c06341 1075
671aa708
NN
1076# If both --with-headers and --with-libs are specified, default to
1077# --without-newlib.
ee6a22df
L
1078if test x"${with_headers}" != x && test x"${with_headers}" != xno \
1079 && test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
671aa708
NN
1080 if test x"${with_newlib}" = x ; then
1081 with_newlib=no
1082 fi
79c06341
JL
1083fi
1084
671aa708
NN
1085# Recognize --with-newlib/--without-newlib.
1086case ${with_newlib} in
1087 no) skipdirs="${skipdirs} target-newlib" ;;
1088 yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
1089esac
79c06341 1090
671aa708 1091# Configure extra directories which are host specific
79c06341 1092
671aa708
NN
1093case "${host}" in
1094 *-cygwin*)
1095 configdirs="$configdirs libtermcap" ;;
1096esac
79c06341 1097
4fab7234
HPN
1098# A target can indicate whether a language isn't supported for some reason.
1099# Only spaces may be used in this macro; not newlines or tabs.
1100unsupported_languages=
1101
af71363e 1102# Remove more programs from consideration, based on the host or
671aa708
NN
1103# target this usually means that a port of the program doesn't
1104# exist yet.
ec8d6ddc 1105
671aa708
NN
1106case "${host}" in
1107 hppa*64*-*-*)
1108 noconfigdirs="$noconfigdirs byacc"
1109 ;;
f2a0e225 1110 i[3456789]86-*-vsta)
b4f96efe 1111 noconfigdirs="$noconfigdirs tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl gnuserv gettext"
671aa708 1112 ;;
f2a0e225 1113 i[3456789]86-*-go32* | i[3456789]86-*-msdosdjgpp*)
b4f96efe 1114 noconfigdirs="$noconfigdirs tcl tk expect dejagnu send-pr uudecode guile itcl gnuserv libffi"
3aa83176 1115 ;;
95af8923
KT
1116 x86_64-*-mingw*)
1117 noconfigdirs="$noconfigdirs expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool newlib"
1118 ;;
f2a0e225 1119 i[3456789]86-*-mingw32*)
b4f96efe 1120 # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl gnuserv"
b91f0a41 1121 noconfigdirs="$noconfigdirs expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool newlib"
3aa83176 1122 ;;
f2a0e225 1123 i[3456789]86-*-beos*)
b4f96efe 1124 noconfigdirs="$noconfigdirs tk itcl libgui gdb"
3aa83176 1125 ;;
671aa708 1126 *-*-cygwin*)
a22c2d8d 1127 noconfigdirs="$noconfigdirs autoconf automake send-pr rcs guile perl"
671aa708
NN
1128 ;;
1129 *-*-netbsd*)
a22c2d8d 1130 noconfigdirs="$noconfigdirs rcs"
671aa708
NN
1131 ;;
1132 ppc*-*-pe)
b4f96efe 1133 noconfigdirs="$noconfigdirs patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl gnuserv"
671aa708
NN
1134 ;;
1135 powerpc-*-beos*)
b4f96efe 1136 noconfigdirs="$noconfigdirs tk itcl libgui gdb dejagnu readline"
671aa708 1137 ;;
671aa708 1138esac
ec8d6ddc 1139
6de9cd9a 1140
d9cdb878
AC
1141# Check whether --enable-libada or --disable-libada was given.
1142if test "${enable_libada+set}" = set; then
1143 enableval="$enable_libada"
1144 ENABLE_LIBADA=$enableval
1145else
1146 ENABLE_LIBADA=yes
af71363e
AS
1147fi
1148
d9cdb878 1149if test "${ENABLE_LIBADA}" != "yes" ; then
5395b47b 1150 noconfigdirs="$noconfigdirs gnattools"
d9cdb878
AC
1151fi
1152
ef0087a7
KH
1153# Check whether --enable-libssp or --disable-libssp was given.
1154if test "${enable_libssp+set}" = set; then
1155 enableval="$enable_libssp"
1156 ENABLE_LIBSSP=$enableval
1157else
1158 ENABLE_LIBSSP=yes
af71363e
AS
1159fi
1160
ef0087a7 1161
671aa708
NN
1162# Save it here so that, even in case of --enable-libgcj, if the Java
1163# front-end isn't enabled, we still get libgcj disabled.
1164libgcj_saved=$libgcj
1165case $enable_libgcj in
1166yes)
1167 # If we reset it here, it won't get added to noconfigdirs in the
1168 # target-specific build rules, so it will be forcibly enabled
1169 # (unless the Java language itself isn't enabled).
1170 libgcj=
1171 ;;
1172no)
1173 # Make sure we get it printed in the list of not supported target libs.
1174 noconfigdirs="$noconfigdirs ${libgcj}"
1175 ;;
1176esac
ec8d6ddc 1177
6de9cd9a 1178
27079765
AH
1179# Disable libmudflap on some systems.
1180if test x$enable_libmudflap = x ; then
dfcada9a 1181 case "${target}" in
670cbfcf 1182 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
98a5bb3b 1183 # Enable libmudflap by default in GNU and friends.
dfcada9a 1184 ;;
a3e8d8b4
LR
1185 *-*-freebsd*)
1186 # Enable libmudflap by default in FreeBSD.
1187 ;;
dfcada9a
MM
1188 *)
1189 # Disable it by default everywhere else.
1190 noconfigdirs="$noconfigdirs target-libmudflap"
1191 ;;
1192 esac
27079765 1193fi
6de9cd9a 1194
27079765
AH
1195# Disable libgomp on non POSIX hosted systems.
1196if test x$enable_libgomp = x ; then
953ff289
DN
1197 # Enable libgomp by default on hosted POSIX systems.
1198 case "${target}" in
670cbfcf 1199 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
953ff289
DN
1200 ;;
1201 *-*-netbsd* | *-*-freebsd* | *-*-openbsd*)
1202 ;;
04879af3 1203 *-*-solaris2* | *-*-sysv4* | *-*-irix6* | *-*-osf* | *-*-hpux11*)
953ff289 1204 ;;
cac90078 1205 *-*-darwin* | *-*-aix*)
953ff289
DN
1206 ;;
1207 *)
1208 noconfigdirs="$noconfigdirs target-libgomp"
1209 ;;
1210 esac
27079765 1211fi
953ff289 1212
6de9cd9a 1213
671aa708
NN
1214case "${target}" in
1215 *-*-chorusos)
cb253473 1216 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
671aa708 1217 ;;
42c1cd8a 1218 powerpc-*-darwin* | i[3456789]86-*-darwin*)
55eb837d 1219 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
9c8f9ec2 1220 noconfigdirs="$noconfigdirs sim target-rda"
940cde4d 1221 ;;
42c1cd8a
AT
1222 *-*-darwin*)
1223 noconfigdirs="$noconfigdirs ld gas gdb gprof"
1224 noconfigdirs="$noconfigdirs sim target-rda"
1225 noconfigdirs="$noconfigdirs ${libgcj}"
1226 ;;
671aa708 1227 *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
cb253473 1228 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
671aa708 1229 ;;
c3f84f61 1230 *-*-freebsd*)
6de9cd9a
DN
1231 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1232 if test "x$with_gmp" = x && test "x$with_gmp_dir" = x \
1233 && test -f /usr/local/include/gmp.h; then
1234 with_gmp=/usr/local
1235 fi
1236
1237 # Skip some stuff that's unsupported on some FreeBSD configurations.
1238 case "${target}" in
1239 i*86-*-*) ;;
1240 alpha*-*-*) ;;
1241 *)
cb253473 1242 noconfigdirs="$noconfigdirs ${libgcj}"
6de9cd9a
DN
1243 ;;
1244 esac
1245 ;;
ef4e7569
US
1246 *-*-kaos*)
1247 # Remove unsupported stuff on all kaOS configurations.
cb253473 1248 skipdirs="target-libiberty ${libgcj} target-libstdc++-v3 target-librx"
ef4e7569
US
1249 skipdirs="$skipdirs target-libobjc target-examples target-groff target-gperf"
1250 skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
1251 noconfigdirs="$noconfigdirs target-libgloss"
1252 ;;
671aa708
NN
1253 *-*-netbsd*)
1254 # Skip some stuff on all NetBSD configurations.
1255 noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss"
1256
1257 # Skip some stuff that's unsupported on some NetBSD configurations.
1258 case "${target}" in
1259 i*86-*-netbsdelf*) ;;
0590b963 1260 arm*-*-netbsdelf*) ;;
671aa708 1261 *)
cb253473 1262 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1263 ;;
1264 esac
1265 ;;
61fec9ff 1266 *-*-netware*)
cb253473 1267 noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss ${libgcj} target-libmudflap"
671aa708
NN
1268 ;;
1269 *-*-rtems*)
cb253473 1270 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708 1271 ;;
a8ba31f2
EC
1272 # The tpf target doesn't support gdb yet.
1273 *-*-tpf*)
cb253473 1274 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty ${libgcj} target-libmudflap gdb tcl tk libgui itcl"
a8ba31f2 1275 ;;
5785c0ed 1276 *-*-uclinux*)
cb253473 1277 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-rda ${libgcj}"
5785c0ed 1278 ;;
671aa708 1279 *-*-vxworks*)
cb253473 1280 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty target-libstdc++-v3 ${libgcj}"
671aa708
NN
1281 ;;
1282 alpha*-dec-osf*)
1283 # ld works, but does not support shared libraries.
1284 # newlib is not 64 bit ready. I'm not sure about fileutils.
1285 # gas doesn't generate exception information.
1286 noconfigdirs="$noconfigdirs gas ld fileutils target-newlib target-libgloss"
1287 ;;
1288 alpha*-*-*vms*)
cb253473 1289 noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss ${libgcj}"
671aa708
NN
1290 ;;
1291 alpha*-*-linux*)
1292 # newlib is not 64 bit ready
1293 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1294 ;;
671aa708
NN
1295 alpha*-*-*)
1296 # newlib is not 64 bit ready
cb253473 1297 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
671aa708 1298 ;;
33952f6f 1299 am33_2.0-*-linux*)
cb253473 1300 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
33952f6f 1301 ;;
671aa708 1302 sh-*-linux*)
cb253473 1303 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
af71363e 1304 ;;
671aa708 1305 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
cb253473 1306 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1307 noconfigdirs="$noconfigdirs target-examples"
1308 noconfigdirs="$noconfigdirs target-libiberty texinfo send-pr"
b4f96efe 1309 noconfigdirs="$noconfigdirs tcl tk itcl libgui sim"
671aa708
NN
1310 noconfigdirs="$noconfigdirs expect dejagnu"
1311 # the C++ libraries don't build on top of CE's C libraries
cb543528 1312 noconfigdirs="$noconfigdirs target-libstdc++-v3"
671aa708
NN
1313 noconfigdirs="$noconfigdirs target-newlib"
1314 case "${host}" in
1315 *-*-cygwin*) ;; # keep gdb and readline
aa9c3ab4 1316 *) noconfigdirs="$noconfigdirs gdb readline"
671aa708
NN
1317 ;;
1318 esac
1319 ;;
1320 arc-*-*)
cb253473 1321 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708 1322 ;;
ee6a22df 1323 arm-semi-aof )
ee6a22df 1324 ;;
671aa708 1325 arm-*-coff | strongarm-*-coff | xscale-*-coff)
cb253473 1326 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708 1327 ;;
b3f8d95d 1328 arm-*-elf* | strongarm-*-elf* | xscale-*-elf* | arm*-*-eabi* )
671aa708
NN
1329 noconfigdirs="$noconfigdirs target-libffi target-qthreads"
1330 ;;
077fc835
KH
1331 arm*-*-linux-gnueabi)
1332 noconfigdirs="$noconfigdirs target-libffi target-qthreads"
1333 noconfigdirs="$noconfigdirs target-libjava target-libobjc"
1334 ;;
972974fc 1335 arm*-*-symbianelf*)
cb253473 1336 noconfigdirs="$noconfigdirs ${libgcj} target-libiberty"
972974fc 1337 ;;
671aa708 1338 arm-*-pe*)
cb253473 1339 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708 1340 ;;
671aa708 1341 thumb-*-coff)
cb253473 1342 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708
NN
1343 ;;
1344 thumb-*-elf)
cb253473 1345 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708 1346 ;;
671aa708 1347 thumb-*-pe)
cb253473 1348 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708
NN
1349 ;;
1350 arm-*-riscix*)
cb253473 1351 noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
671aa708
NN
1352 ;;
1353 avr-*-*)
cb253473 1354 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
671aa708 1355 ;;
6b65a26d 1356 bfin-*-*)
8b3c6c5a 1357 noconfigdirs="$noconfigdirs gdb"
61efc800 1358 if test x${is_cross_compiler} != xno ; then
6b65a26d
CM
1359 target_configdirs="${target_configdirs} target-bsp target-cygmon"
1360 fi
1361 ;;
671aa708 1362 c4x-*-* | tic4x-*-*)
cb253473 1363 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
671aa708
NN
1364 ;;
1365 c54x*-*-* | tic54x-*-*)
cb253473 1366 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} gcc gdb newlib"
671aa708 1367 ;;
40d64b5a 1368 cris-*-* | crisv32-*-*)
4fab7234 1369 unsupported_languages="$unsupported_languages java"
40d64b5a 1370 case "${target}" in
c2e0d3a9 1371 *-*-aout)
7f26dfa3 1372 unsupported_languages="$unsupported_languages fortran"
4fab7234 1373 noconfigdirs="$noconfigdirs target-libffi target-boehm-gc";;
c2e0d3a9 1374 *-*-elf)
7f26dfa3 1375 unsupported_languages="$unsupported_languages fortran"
789ec619 1376 noconfigdirs="$noconfigdirs target-boehm-gc";;
c2e0d3a9 1377 *-*-linux*)
789ec619 1378 noconfigdirs="$noconfigdirs target-newlib target-libgloss";;
40d64b5a 1379 *)
7f26dfa3 1380 unsupported_languages="$unsupported_languages fortran"
cb253473 1381 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss";;
40d64b5a 1382 esac
671aa708 1383 ;;
25b656e7 1384 crx-*-*)
cb253473 1385 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-mudflap ${libgcj}"
25b656e7 1386 ;;
671aa708 1387 d10v-*-*)
cb253473 1388 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
671aa708
NN
1389 ;;
1390 d30v-*-*)
cb253473 1391 noconfigdirs="$noconfigdirs ${libgcj} gdb"
671aa708
NN
1392 ;;
1393 fr30-*-elf*)
cb253473 1394 noconfigdirs="$noconfigdirs ${libgcj} gdb"
671aa708
NN
1395 ;;
1396 frv-*-*)
cb253473 1397 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1398 ;;
1399 h8300*-*-*)
cb253473 1400 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708
NN
1401 ;;
1402 h8500-*-*)
cb253473 1403 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
671aa708 1404 ;;
ee6a22df 1405 hppa1.1-*-osf* | hppa1.1-*-bsd* )
ee6a22df 1406 ;;
671aa708
NN
1407 hppa*64*-*-linux* | parisc*64*-*-linux*)
1408 # In this case, it's because the hppa64-linux target is for
1409 # the kernel only at this point and has no libc, and thus no
1410 # headers, crt*.o, etc., all of which are needed by these.
1411 noconfigdirs="$noconfigdirs target-zlib"
1412 ;;
3e732ba0
JDA
1413 parisc*-*-linux* | hppa*-*-linux*)
1414 ;;
671aa708 1415 hppa*-*-*elf* | \
671aa708
NN
1416 hppa*-*-lites* | \
1417 hppa*-*-openbsd* | \
1418 hppa*64*-*-*)
cb253473 1419 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708 1420 ;;
2a332582
JDA
1421 hppa*-hp-hpux11*)
1422 noconfigdirs="$noconfigdirs ld shellutils"
1423 ;;
671aa708
NN
1424 hppa*-*-*)
1425 # According to Alexandre Oliva <aoliva@redhat.com>, libjava won't
1426 # build on HP-UX 10.20.
cb253473 1427 noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
671aa708 1428 ;;
fb87ad5d 1429 i960-*-*)
cb253473 1430 noconfigdirs="$noconfigdirs ${libgcj} gdb"
fb87ad5d 1431 ;;
671aa708
NN
1432 ia64*-*-elf*)
1433 # No gdb support yet.
b4f96efe 1434 noconfigdirs="$noconfigdirs readline mmalloc libgui itcl gdb"
671aa708
NN
1435 ;;
1436 ia64*-**-hpux*)
1437 # No gdb or ld support yet.
cb253473 1438 noconfigdirs="$noconfigdirs ${libgcj} readline mmalloc libgui itcl gdb ld"
671aa708 1439 ;;
ee6a22df 1440 i370-*-opened*)
ee6a22df 1441 ;;
f2a0e225 1442 i[3456789]86-*-coff | i[3456789]86-*-elf)
cb253473 1443 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708 1444 ;;
f2a0e225 1445 i[3456789]86-*-linux*)
671aa708
NN
1446 # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
1447 # not build java stuff by default.
1448 case "${target}" in
1449 *-*-*libc1*)
cb253473 1450 noconfigdirs="$noconfigdirs ${libgcj}";;
671aa708
NN
1451 esac
1452
1453 # This section makes it possible to build newlib natively on linux.
1454 # If we are using a cross compiler then don't configure newlib.
1455 if test x${is_cross_compiler} != xno ; then
3aa83176 1456 noconfigdirs="$noconfigdirs target-newlib"
671aa708
NN
1457 fi
1458 noconfigdirs="$noconfigdirs target-libgloss"
1459 # If we are not using a cross compiler, do configure newlib.
1460 # Note however, that newlib will only be configured in this situation
1461 # if the --with-newlib option has been given, because otherwise
1462 # 'target-newlib' will appear in skipdirs.
1463 ;;
f2a0e225 1464 i[3456789]86-*-mingw32*)
b91f0a41
CV
1465 target_configdirs="$target_configdirs target-winsup"
1466 noconfigdirs="$noconfigdirs expect target-libgloss target-newlib ${libgcj}"
af71363e 1467 ;;
95af8923
KT
1468 x86_64-*-mingw*)
1469 target_configdirs="$target_configdirs target-winsup"
1470 noconfigdirs="$noconfigdirs expect target-libgloss target-newlib ${libgcj}"
1471 ;;
671aa708
NN
1472 *-*-cygwin*)
1473 target_configdirs="$target_configdirs target-libtermcap target-winsup"
cb253473 1474 noconfigdirs="$noconfigdirs target-gperf target-libgloss ${libgcj}"
801e2270 1475 # always build newlib if winsup directory is present.
b91f0a41 1476 if test -d "$srcdir/winsup/cygwin"; then
801e2270 1477 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
ee6a22df 1478 elif test -d "$srcdir/newlib"; then
b91f0a41 1479 echo "Warning: winsup/cygwin is missing so newlib can't be built."
801e2270 1480 fi
af71363e 1481 ;;
ee6a22df
L
1482 i[3456789]86-moss-msdos | i[3456789]86-*-moss* | \
1483 i[3456789]86-*-uwin* | i[3456789]86-*-interix* )
ee6a22df 1484 ;;
f2a0e225 1485 i[3456789]86-*-pe)
cb253473 1486 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
671aa708 1487 ;;
f2a0e225 1488 i[3456789]86-*-sco3.2v5*)
671aa708
NN
1489 # The linker does not yet know about weak symbols in COFF,
1490 # and is not configured to handle mixed ELF and COFF.
cb253473 1491 noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
671aa708 1492 ;;
f2a0e225 1493 i[3456789]86-*-sco*)
cb253473 1494 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
671aa708 1495 ;;
f2a0e225 1496 i[3456789]86-*-solaris2*)
671aa708
NN
1497 noconfigdirs="$noconfigdirs target-libgloss"
1498 ;;
f2a0e225 1499 i[3456789]86-*-sysv4*)
cb253473 1500 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708 1501 ;;
f2a0e225 1502 i[3456789]86-*-beos*)
cb253473 1503 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
3aa83176 1504 ;;
d1f8db0c
PB
1505 i[3456789]86-*-rdos*)
1506 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
1507 ;;
fb87ad5d 1508 m32r-*-*)
cb253473 1509 noconfigdirs="$noconfigdirs ${libgcj}"
fb87ad5d 1510 ;;
671aa708 1511 m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
cb253473 1512 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
671aa708
NN
1513 ;;
1514 m68k-*-elf*)
cb253473 1515 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1516 ;;
1517 m68k-*-coff*)
cb253473 1518 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1519 ;;
1520 mcore-*-pe*)
1521 # The EPOC C++ environment does not support exceptions or rtti,
1522 # and so building libstdc++-v3 tends not to always work.
1523 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1524 ;;
1525 mmix-*-*)
4fab7234 1526 noconfigdirs="$noconfigdirs target-libffi target-boehm-gc gdb libgloss"
7f26dfa3 1527 unsupported_languages="$unsupported_languages fortran java"
671aa708
NN
1528 ;;
1529 mn10200-*-*)
cb253473 1530 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1531 ;;
1532 mn10300-*-*)
cb253473 1533 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708 1534 ;;
ab34901f 1535 mt-*-*)
79dd769c
AH
1536 noconfigdirs="$noconfigdirs sim"
1537 ;;
671aa708
NN
1538 powerpc-*-aix*)
1539 # copied from rs6000-*-* entry
cb253473 1540 noconfigdirs="$noconfigdirs gprof target-libgloss target-libssp ${libgcj}"
671aa708
NN
1541 ;;
1542 powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
1543 target_configdirs="$target_configdirs target-winsup"
cb253473 1544 noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl gnuserv ${libgcj}"
671aa708
NN
1545 # always build newlib.
1546 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
1547 ;;
1548 # This is temporary until we can link against shared libraries
1549 powerpcle-*-solaris*)
cb253473 1550 noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl gnuserv ${libgcj}"
671aa708
NN
1551 ;;
1552 powerpc-*-beos*)
cb253473 1553 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
671aa708 1554 ;;
671aa708 1555 powerpc-*-eabi)
cb253473 1556 noconfigdirs="$noconfigdirs ${libgcj}"
ee6a22df
L
1557 ;;
1558 powerpc-*-eabi* | powerpcle-*-eabi* | powerpc-*-rtems* )
671aa708 1559 ;;
671aa708 1560 rs6000-*-lynxos*)
cb253473 1561 noconfigdirs="$noconfigdirs target-newlib gprof ${libgcj}"
671aa708
NN
1562 ;;
1563 rs6000-*-aix*)
cb253473 1564 noconfigdirs="$noconfigdirs gprof target-libgloss target-libssp ${libgcj}"
671aa708
NN
1565 ;;
1566 rs6000-*-*)
cb253473 1567 noconfigdirs="$noconfigdirs gprof ${libgcj}"
671aa708
NN
1568 ;;
1569 m68k-apollo-*)
cb253473 1570 noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
671aa708
NN
1571 ;;
1572 mips*-*-irix5*)
cb253473 1573 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
671aa708
NN
1574 ;;
1575 mips*-*-irix6*)
671aa708
NN
1576 # Linking libjava exceeds command-line length limits on at least
1577 # IRIX 6.2, but not on IRIX 6.5.
1578 # Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
1579 # <oldham@codesourcery.com>
cb253473 1580 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
671aa708 1581 ;;
671aa708 1582 mips*-*-bsd*)
cb253473 1583 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
671aa708 1584 ;;
d0fe5ad3 1585 mips64*-*-linux*)
1ee4c5a0 1586 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
d0fe5ad3 1587 ;;
671aa708
NN
1588 mips*-*-linux*)
1589 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1590 ;;
1591 mips*-*-*)
cb253473 1592 noconfigdirs="$noconfigdirs gprof ${libgcj}"
671aa708
NN
1593 ;;
1594 romp-*-*)
cb253473 1595 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
671aa708 1596 ;;
669f01d8 1597 sh-*-* | sh64-*-*)
671aa708 1598 case "${host}" in
f2a0e225
KC
1599 i[3456789]86-*-vsta) ;; # don't add gprof back in
1600 i[3456789]86-*-go32*) ;; # don't add gprof back in
1601 i[3456789]86-*-msdosdjgpp*) ;; # don't add gprof back in
671aa708
NN
1602 *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
1603 esac
cb253473 1604 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708 1605 ;;
671aa708 1606 sparc-*-elf*)
cb253473 1607 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1608 ;;
1609 sparc64-*-elf*)
cb253473 1610 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1611 ;;
1612 sparclite-*-*)
cb253473 1613 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1614 ;;
1615 sparc-*-sunos4*)
cb253473 1616 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1617 if test x${is_cross_compiler} != xno ; then
1618 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
1619 else
1620 use_gnu_ld=no
1621 fi
1622 ;;
bba5e0ca 1623 sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
cb253473 1624 noconfigdirs="$noconfigdirs ${libgcj}"
bba5e0ca 1625 ;;
671aa708
NN
1626 sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
1627 ;;
85d9c13c 1628 spu-*-*)
ea6f5c57 1629 skipdirs="target-libssp"
85d9c13c 1630 ;;
671aa708 1631 v810-*-*)
cb253473 1632 noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libstdc++-v3 opcodes target-libgloss ${libgcj}"
671aa708
NN
1633 ;;
1634 v850-*-*)
cb253473 1635 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708
NN
1636 ;;
1637 v850e-*-*)
cb253473 1638 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708
NN
1639 ;;
1640 v850ea-*-*)
cb253473 1641 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
671aa708
NN
1642 ;;
1643 vax-*-vms)
cb253473 1644 noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
671aa708
NN
1645 ;;
1646 vax-*-*)
cb253473 1647 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
671aa708 1648 ;;
0d4f1b4e 1649 xtensa-*-*)
cb253473 1650 noconfigdirs="$noconfigdirs ${libgcj}"
0d4f1b4e 1651 ;;
671aa708 1652 ip2k-*-*)
cb253473 1653 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
671aa708 1654 ;;
c3f84f61 1655 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
671aa708
NN
1656 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1657 ;;
1658 *-*-lynxos*)
cb253473 1659 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
af71363e 1660 ;;
671aa708 1661 *-*-*)
cb253473 1662 noconfigdirs="$noconfigdirs ${libgcj}"
671aa708
NN
1663 ;;
1664esac
79c06341 1665
671aa708
NN
1666# If we aren't building newlib, then don't build libgloss, since libgloss
1667# depends upon some newlib header files.
1668case "${noconfigdirs}" in
1669 *target-libgloss*) ;;
1670 *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
1671esac
1672
671aa708
NN
1673# Work in distributions that contain no compiler tools, like Autoconf.
1674tentative_cc=""
1675host_makefile_frag=/dev/null
1676if test -d ${srcdir}/config ; then
1677case "${host}" in
1678 m68k-hp-hpux*)
1679 # Avoid "too much defining" errors from HPUX compiler.
1680 tentative_cc="cc -Wp,-H256000"
1681 # If "ar" in $PATH is GNU ar, the symbol table may need rebuilding.
1682 # If it's HP/UX ar, this should be harmless.
1683 RANLIB="ar ts"
1684 ;;
1685 m68k-apollo-sysv*)
1686 tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
1687 ;;
1688 m68k-apollo-bsd*)
1689 #None of the Apollo compilers can compile gas or binutils. The preprocessor
1690 # chokes on bfd, the compiler won't let you assign integers to enums, and
1691 # other problems. Defining CC to gcc is a questionable way to say "don't use
1692 # the apollo compiler" (the preferred version of GCC could be called cc,
1693 # or whatever), but I'm not sure leaving CC as cc is any better...
1694 #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
1695 # Used to have BISON=yacc.
1696 tentative_cc=gcc
1697 ;;
1698 m88k-dg-dgux*)
1699 tentative_cc="gcc -Wall -ansi -D__using_DGUX"
671aa708
NN
1700 ;;
1701 m88k-harris-cxux*)
1702 # Under CX/UX, we want to tell the compiler to use ANSI mode.
1703 tentative_cc="cc -Xa"
1704 host_makefile_frag="config/mh-cxux"
1705 ;;
1706 m88k-motorola-sysv*)
1707 ;;
1708 mips*-dec-ultrix*)
1709 tentative_cc="cc -Wf,-XNg1000"
1710 host_makefile_frag="config/mh-decstation"
1711 ;;
1712 mips*-nec-sysv4*)
1713 # The C compiler on NEC MIPS SVR4 needs bigger tables.
1714 tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
1715 host_makefile_frag="config/mh-necv4"
1716 ;;
1717 mips*-sgi-irix4*)
1718 # Tell compiler to use K&R C. We can't compile under the SGI Ansi
1719 # environment. Also bump switch table size so that cp-parse will
1720 # compile. Bump string length limit so linker builds.
1721 tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
1722 ;;
1723 mips*-*-sysv4*)
1724 host_makefile_frag="config/mh-sysv4"
1725 ;;
1726 mips*-*-sysv*)
1727 # This is for a MIPS running RISC/os 4.52C.
1728
1729 # This is needed for GDB, but needs to be in the top-level make because
1730 # if a library is compiled with the bsd headers and gets linked with the
1731 # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
1732 # a different size).
1733 # ptrace(2) apparently has problems in the BSD environment. No workaround is
1734 # known except to select the sysv environment. Could we use /proc instead?
1735 # These "sysv environments" and "bsd environments" often end up being a pain.
1736 #
1737 # This is not part of CFLAGS because perhaps not all C compilers have this
1738 # option.
1739 tentative_cc="cc -systype sysv"
1740 ;;
1741 i370-ibm-opened*)
1742 tentative_cc="c89"
1743 ;;
f2a0e225 1744 i[3456789]86-*-sysv5*)
671aa708
NN
1745 host_makefile_frag="config/mh-sysv5"
1746 ;;
f2a0e225 1747 i[3456789]86-*-dgux*)
671aa708
NN
1748 tentative_cc="gcc -Wall -ansi -D__using_DGUX"
1749 host_makefile_frag="config/mh-dgux386"
1750 ;;
f2a0e225 1751 i[3456789]86-ncr-sysv4.3*)
671aa708
NN
1752 # The MetaWare compiler will generate a copyright message unless you
1753 # turn it off by adding the -Hnocopyr flag.
1754 tentative_cc="cc -Hnocopyr"
1755 ;;
f2a0e225 1756 i[3456789]86-ncr-sysv4*)
671aa708
NN
1757 # for an NCR 3000 (i486/SVR4) system.
1758 # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
1759 # This compiler not only emits obnoxious copyright messages every time
1760 # you run it, but it chokes and dies on a whole bunch of GNU source
1761 # files. Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
1762 tentative_cc="/usr/ccs/ATT/cc"
1763 host_makefile_frag="config/mh-ncr3000"
1764 ;;
f2a0e225 1765 i[3456789]86-*-sco3.2v5*)
671aa708 1766 ;;
f2a0e225 1767 i[3456789]86-*-sco*)
671aa708
NN
1768 # The native C compiler botches some simple uses of const. Unfortunately,
1769 # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
1770 tentative_cc="cc -Dconst="
1771 host_makefile_frag="config/mh-sco"
1772 ;;
f2a0e225 1773 i[3456789]86-*-udk*)
671aa708
NN
1774 host_makefile_frag="config/mh-sysv5"
1775 ;;
f2a0e225 1776 i[3456789]86-*-solaris2*)
671aa708
NN
1777 host_makefile_frag="config/mh-sysv4"
1778 ;;
f2a0e225 1779 i[3456789]86-*-msdosdjgpp*)
671aa708
NN
1780 host_makefile_frag="config/mh-djgpp"
1781 ;;
1782 *-cygwin*)
1783 host_makefile_frag="config/mh-cygwin"
1784 ;;
1785 *-mingw32*)
671aa708 1786 ;;
95af8923
KT
1787 *-mingw64*)
1788 ;;
671aa708
NN
1789 *-interix*)
1790 host_makefile_frag="config/mh-interix"
1791 ;;
1792 vax-*-ultrix2*)
1793 # The old BSD pcc isn't up to compiling parts of gdb so use gcc
1794 tentative_cc=gcc
1795 ;;
1796 *-*-solaris2*)
1797 host_makefile_frag="config/mh-solaris"
1798 ;;
1799 m68k-sun-sunos*)
1800 # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
1801 # without overflowing the jump tables (-J says to use a 32 bit table)
1802 tentative_cc="cc -J"
1803 ;;
1804 *-hp-hpux*)
1805 tentative_cc="cc -Wp,-H256000"
1806 ;;
1807 *-*-hiux*)
1808 tentative_cc="cc -Wp,-H256000"
1809 ;;
1810 rs6000-*-lynxos*)
1811 # /bin/cc is less than useful for our purposes. Always use GCC
1812 tentative_cc="/usr/cygnus/progressive/bin/gcc"
1813 host_makefile_frag="config/mh-lynxrs6k"
1814 ;;
45f366ab 1815 powerpc-*-darwin*)
be8fff81
RB
1816 host_makefile_frag="config/mh-ppc-darwin"
1817 ;;
d19bca38
PB
1818 powerpc-*-aix*)
1819 host_makefile_frag="config/mh-ppc-aix"
1820 ;;
1821 rs6000-*-aix*)
1822 host_makefile_frag="config/mh-ppc-aix"
1823 ;;
671aa708
NN
1824 *-*-lynxos*)
1825 # /bin/cc is less than useful for our purposes. Always use GCC
1826 tentative_cc="/bin/gcc"
1827 ;;
1828 *-*-sysv4*)
1829 host_makefile_frag="config/mh-sysv4"
1830 ;;
95c53c62
RS
1831 # This is placed last to prevent interfering with the cases above.
1832 i[3456789]86-*-*)
1833 # Build the stage2 and stage3 compilers with -fomit-frame-pointer.
1834 host_makefile_frag="config/mh-x86omitfp"
1835 ;;
671aa708
NN
1836esac
1837fi
1838
55ffb5ed
NN
1839# If we aren't going to be using gcc, see if we can extract a definition
1840# of CC from the fragment.
1841# Actually, use the 'pre-extracted' version above.
1842if test -z "${CC}" && test "${build}" = "${host}" ; then
1843 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
1844 found=
1845 for dir in $PATH; do
1846 test -z "$dir" && dir=.
1847 if test -f $dir/gcc; then
1848 found=yes
1849 break
1850 fi
1851 done
1852 IFS="$save_ifs"
1853 if test -z "${found}" && test -n "${tentative_cc}" ; then
1854 CC=$tentative_cc
1855 fi
1856fi
1857
1858if test "${build}" != "${host}" ; then
1859 # If we are doing a Canadian Cross, in which the host and build systems
1860 # are not the same, we set reasonable default values for the tools.
1861
55ffb5ed
NN
1862 CC=${CC-${host_alias}-gcc}
1863 CFLAGS=${CFLAGS-"-g -O2"}
1864 CXX=${CXX-${host_alias}-c++}
1865 CXXFLAGS=${CXXFLAGS-"-g -O2"}
1866 CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
55ffb5ed
NN
1867
1868else
fb0103e5
RG
1869 # Set reasonable default values for some tools even if not Canadian.
1870 # Of course, these are different reasonable default values, originally
1871 # specified directly in the Makefile.
1872 # We don't export, so that autoconf can do its job.
1873 # Note that all these settings are above the fragment inclusion point
1874 # in Makefile.in, so can still be overridden by fragments.
1875 # This is all going to change when we autoconfiscate...
a4b9e93e 1876
fb0103e5
RG
1877 CC_FOR_BUILD="\$(CC)"
1878 # Extract the first word of "gcc", so it can be a program name with args.
1879set dummy gcc; ac_word=$2
af71363e 1880echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
95af8923 1881echo "configure:1882: checking for $ac_word" >&5
af71363e
AS
1882if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1883 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed
NN
1884else
1885 if test -n "$CC"; then
1886 ac_cv_prog_CC="$CC" # Let the user override the test.
1887else
af71363e
AS
1888 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1889 ac_dummy="$PATH"
1890 for ac_dir in $ac_dummy; do
1891 test -z "$ac_dir" && ac_dir=.
1892 if test -f $ac_dir/$ac_word; then
1893 ac_cv_prog_CC="gcc"
1894 break
1895 fi
1896 done
1897 IFS="$ac_save_ifs"
0b0dc272 1898fi
0b0dc272 1899fi
af71363e
AS
1900CC="$ac_cv_prog_CC"
1901if test -n "$CC"; then
1902 echo "$ac_t""$CC" 1>&6
0b0dc272 1903else
af71363e 1904 echo "$ac_t""no" 1>&6
0b0dc272
AM
1905fi
1906
55ffb5ed
NN
1907if test -z "$CC"; then
1908 # Extract the first word of "cc", so it can be a program name with args.
1909set dummy cc; ac_word=$2
af71363e 1910echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
95af8923 1911echo "configure:1912: checking for $ac_word" >&5
af71363e
AS
1912if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1913 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed
NN
1914else
1915 if test -n "$CC"; then
1916 ac_cv_prog_CC="$CC" # Let the user override the test.
1917else
af71363e 1918 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
0b0dc272 1919 ac_prog_rejected=no
af71363e
AS
1920 ac_dummy="$PATH"
1921 for ac_dir in $ac_dummy; do
1922 test -z "$ac_dir" && ac_dir=.
1923 if test -f $ac_dir/$ac_word; then
1924 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1925 ac_prog_rejected=yes
1926 continue
1927 fi
1928 ac_cv_prog_CC="cc"
1929 break
1930 fi
1931 done
1932 IFS="$ac_save_ifs"
55ffb5ed
NN
1933if test $ac_prog_rejected = yes; then
1934 # We found a bogon in the path, so make sure we never use it.
1935 set dummy $ac_cv_prog_CC
1936 shift
af71363e 1937 if test $# -gt 0; then
55ffb5ed
NN
1938 # We chose a different compiler from the bogus one.
1939 # However, it has the same basename, so the bogon will be chosen
1940 # first if we set CC to just the basename; use the full file name.
1941 shift
af71363e
AS
1942 set dummy "$ac_dir/$ac_word" "$@"
1943 shift
1944 ac_cv_prog_CC="$@"
55ffb5ed
NN
1945 fi
1946fi
1947fi
1948fi
af71363e 1949CC="$ac_cv_prog_CC"
55ffb5ed 1950if test -n "$CC"; then
af71363e 1951 echo "$ac_t""$CC" 1>&6
55ffb5ed 1952else
af71363e 1953 echo "$ac_t""no" 1>&6
55ffb5ed
NN
1954fi
1955
af71363e
AS
1956 if test -z "$CC"; then
1957 case "`uname -s`" in
1958 *win32* | *WIN32*)
1959 # Extract the first word of "cl", so it can be a program name with args.
1960set dummy cl; ac_word=$2
1961echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
95af8923 1962echo "configure:1963: checking for $ac_word" >&5
af71363e
AS
1963if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1964 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed
NN
1965else
1966 if test -n "$CC"; then
1967 ac_cv_prog_CC="$CC" # Let the user override the test.
1968else
af71363e
AS
1969 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1970 ac_dummy="$PATH"
1971 for ac_dir in $ac_dummy; do
1972 test -z "$ac_dir" && ac_dir=.
1973 if test -f $ac_dir/$ac_word; then
1974 ac_cv_prog_CC="cl"
1975 break
1976 fi
1977 done
1978 IFS="$ac_save_ifs"
55ffb5ed
NN
1979fi
1980fi
af71363e 1981CC="$ac_cv_prog_CC"
55ffb5ed 1982if test -n "$CC"; then
af71363e 1983 echo "$ac_t""$CC" 1>&6
a4b9e93e 1984else
af71363e 1985 echo "$ac_t""no" 1>&6
55ffb5ed 1986fi
af71363e
AS
1987 ;;
1988 esac
0b0dc272 1989 fi
af71363e 1990 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
fb0103e5 1991fi
af71363e
AS
1992
1993echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
95af8923 1994echo "configure:1995: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
af71363e
AS
1995
1996ac_ext=c
1997# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1998ac_cpp='$CPP $CPPFLAGS'
1999ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2000ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2001cross_compiling=$ac_cv_prog_cc_cross
2002
2003cat > conftest.$ac_ext << EOF
2004
95af8923 2005#line 2006 "configure"
af71363e
AS
2006#include "confdefs.h"
2007
2008main(){return(0);}
2009EOF
95af8923 2010if { (eval echo configure:2011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
af71363e
AS
2011 ac_cv_prog_cc_works=yes
2012 # If we can't run a trivial program, we are probably using a cross compiler.
2013 if (./conftest; exit) 2>/dev/null; then
2014 ac_cv_prog_cc_cross=no
2015 else
2016 ac_cv_prog_cc_cross=yes
2017 fi
55ffb5ed 2018else
af71363e
AS
2019 echo "configure: failed program was:" >&5
2020 cat conftest.$ac_ext >&5
2021 ac_cv_prog_cc_works=no
fb0103e5 2022fi
af71363e
AS
2023rm -fr conftest*
2024ac_ext=c
2025# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2026ac_cpp='$CPP $CPPFLAGS'
2027ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2028ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2029cross_compiling=$ac_cv_prog_cc_cross
a4b9e93e 2030
af71363e
AS
2031echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
2032if test $ac_cv_prog_cc_works = no; then
2033 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
2034fi
2035echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
95af8923 2036echo "configure:2037: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
af71363e
AS
2037echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
2038cross_compiling=$ac_cv_prog_cc_cross
0b0dc272 2039
af71363e 2040echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
95af8923 2041echo "configure:2042: checking whether we are using GNU C" >&5
af71363e
AS
2042if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
2043 echo $ac_n "(cached) $ac_c" 1>&6
0b0dc272 2044else
af71363e
AS
2045 cat > conftest.c <<EOF
2046#ifdef __GNUC__
2047 yes;
2048#endif
2049EOF
95af8923 2050if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2051: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
af71363e 2051 ac_cv_prog_gcc=yes
0b0dc272 2052else
af71363e
AS
2053 ac_cv_prog_gcc=no
2054fi
2055fi
2056
2057echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2058
2059if test $ac_cv_prog_gcc = yes; then
2060 GCC=yes
fb0103e5 2061else
af71363e
AS
2062 GCC=
2063fi
0b0dc272 2064
af71363e
AS
2065ac_test_CFLAGS="${CFLAGS+set}"
2066ac_save_CFLAGS="$CFLAGS"
2067CFLAGS=
2068echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
95af8923 2069echo "configure:2070: checking whether ${CC-cc} accepts -g" >&5
af71363e
AS
2070if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2071 echo $ac_n "(cached) $ac_c" 1>&6
2072else
2073 echo 'void f(){}' > conftest.c
2074if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
55ffb5ed
NN
2075 ac_cv_prog_cc_g=yes
2076else
af71363e 2077 ac_cv_prog_cc_g=no
a4b9e93e 2078fi
af71363e
AS
2079rm -f conftest*
2080
0b0dc272 2081fi
af71363e
AS
2082
2083echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
55ffb5ed 2084if test "$ac_test_CFLAGS" = set; then
af71363e 2085 CFLAGS="$ac_save_CFLAGS"
55ffb5ed
NN
2086elif test $ac_cv_prog_cc_g = yes; then
2087 if test "$GCC" = yes; then
2088 CFLAGS="-g -O2"
2089 else
2090 CFLAGS="-g"
2091 fi
2092else
2093 if test "$GCC" = yes; then
2094 CFLAGS="-O2"
2095 else
2096 CFLAGS=
2097 fi
2098fi
2099
2100
23f6b2f9
PB
2101 # We must set the default linker to the linker used by gcc for the correct
2102 # operation of libtool. If LD is not defined and we are using gcc, try to
2103 # set the LD default to the ld used by gcc.
2104 if test -z "$LD"; then
2105 if test "$GCC" = yes; then
2106 case $build in
2107 *-*-mingw*)
2108 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
2109 *)
2110 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
2111 esac
2112 case $gcc_prog_ld in
2113 # Accept absolute paths.
2114 [\\/]* | [A-Za-z]:[\\/]*)
2115 LD="$gcc_prog_ld" ;;
2116 esac
2117 fi
2118 fi
2119
2120 CXX=${CXX-"c++"}
2121 CFLAGS=${CFLAGS-"-g"}
2122 CXXFLAGS=${CXXFLAGS-"-g -O2"}
2123fi
2124
af71363e
AS
2125if test $host != $build; then
2126 ac_tool_prefix=${host_alias}-
2127else
2128 ac_tool_prefix=
2129fi
23f6b2f9
PB
2130
2131
55ffb5ed 2132
af71363e 2133# Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args.
55ffb5ed 2134set dummy ${ac_tool_prefix}gnatbind; ac_word=$2
af71363e 2135echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
95af8923 2136echo "configure:2137: checking for $ac_word" >&5
af71363e
AS
2137if eval "test \"`echo '$''{'ac_cv_prog_GNATBIND'+set}'`\" = set"; then
2138 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed
NN
2139else
2140 if test -n "$GNATBIND"; then
2141 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
2142else
af71363e
AS
2143 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2144 ac_dummy="$PATH"
2145 for ac_dir in $ac_dummy; do
2146 test -z "$ac_dir" && ac_dir=.
2147 if test -f $ac_dir/$ac_word; then
2148 ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind"
2149 break
2150 fi
2151 done
2152 IFS="$ac_save_ifs"
55ffb5ed
NN
2153fi
2154fi
af71363e 2155GNATBIND="$ac_cv_prog_GNATBIND"
55ffb5ed 2156if test -n "$GNATBIND"; then
af71363e 2157 echo "$ac_t""$GNATBIND" 1>&6
55ffb5ed 2158else
af71363e 2159 echo "$ac_t""no" 1>&6
55ffb5ed
NN
2160fi
2161
af71363e 2162
55ffb5ed 2163if test -z "$ac_cv_prog_GNATBIND"; then
af71363e 2164if test -n "$ac_tool_prefix"; then
55ffb5ed
NN
2165 # Extract the first word of "gnatbind", so it can be a program name with args.
2166set dummy gnatbind; ac_word=$2
af71363e 2167echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
95af8923 2168echo "configure:2169: checking for $ac_word" >&5
af71363e
AS
2169if eval "test \"`echo '$''{'ac_cv_prog_GNATBIND'+set}'`\" = set"; then
2170 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed 2171else
af71363e
AS
2172 if test -n "$GNATBIND"; then
2173 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
55ffb5ed 2174else
af71363e
AS
2175 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2176 ac_dummy="$PATH"
2177 for ac_dir in $ac_dummy; do
2178 test -z "$ac_dir" && ac_dir=.
2179 if test -f $ac_dir/$ac_word; then
2180 ac_cv_prog_GNATBIND="gnatbind"
2181 break
2182 fi
2183 done
2184 IFS="$ac_save_ifs"
2185 test -z "$ac_cv_prog_GNATBIND" && ac_cv_prog_GNATBIND="no"
55ffb5ed
NN
2186fi
2187fi
af71363e
AS
2188GNATBIND="$ac_cv_prog_GNATBIND"
2189if test -n "$GNATBIND"; then
2190 echo "$ac_t""$GNATBIND" 1>&6
55ffb5ed 2191else
af71363e 2192 echo "$ac_t""no" 1>&6
55ffb5ed
NN
2193fi
2194
2195else
af71363e
AS
2196 GNATBIND="no"
2197fi
55ffb5ed
NN
2198fi
2199
5305be7e
RG
2200# Extract the first word of "${ac_tool_prefix}gnatmake", so it can be a program name with args.
2201set dummy ${ac_tool_prefix}gnatmake; ac_word=$2
2202echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2203echo "configure:2204: checking for $ac_word" >&5
2204if eval "test \"`echo '$''{'ac_cv_prog_GNATMAKE'+set}'`\" = set"; then
2205 echo $ac_n "(cached) $ac_c" 1>&6
2206else
2207 if test -n "$GNATMAKE"; then
2208 ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test.
2209else
2210 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2211 ac_dummy="$PATH"
2212 for ac_dir in $ac_dummy; do
2213 test -z "$ac_dir" && ac_dir=.
2214 if test -f $ac_dir/$ac_word; then
2215 ac_cv_prog_GNATMAKE="${ac_tool_prefix}gnatmake"
2216 break
2217 fi
2218 done
2219 IFS="$ac_save_ifs"
2220fi
2221fi
2222GNATMAKE="$ac_cv_prog_GNATMAKE"
2223if test -n "$GNATMAKE"; then
2224 echo "$ac_t""$GNATMAKE" 1>&6
2225else
2226 echo "$ac_t""no" 1>&6
2227fi
2228
2229
2230if test -z "$ac_cv_prog_GNATMAKE"; then
2231if test -n "$ac_tool_prefix"; then
2232 # Extract the first word of "gnatmake", so it can be a program name with args.
2233set dummy gnatmake; ac_word=$2
2234echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2235echo "configure:2236: checking for $ac_word" >&5
2236if eval "test \"`echo '$''{'ac_cv_prog_GNATMAKE'+set}'`\" = set"; then
2237 echo $ac_n "(cached) $ac_c" 1>&6
2238else
2239 if test -n "$GNATMAKE"; then
2240 ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test.
2241else
2242 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2243 ac_dummy="$PATH"
2244 for ac_dir in $ac_dummy; do
2245 test -z "$ac_dir" && ac_dir=.
2246 if test -f $ac_dir/$ac_word; then
2247 ac_cv_prog_GNATMAKE="gnatmake"
2248 break
2249 fi
2250 done
2251 IFS="$ac_save_ifs"
2252 test -z "$ac_cv_prog_GNATMAKE" && ac_cv_prog_GNATMAKE="no"
2253fi
2254fi
2255GNATMAKE="$ac_cv_prog_GNATMAKE"
2256if test -n "$GNATMAKE"; then
2257 echo "$ac_t""$GNATMAKE" 1>&6
2258else
2259 echo "$ac_t""no" 1>&6
2260fi
2261
2262else
2263 GNATMAKE="no"
2264fi
2265fi
2266
af71363e 2267echo $ac_n "checking whether compiler driver understands Ada""... $ac_c" 1>&6
5305be7e 2268echo "configure:2269: checking whether compiler driver understands Ada" >&5
af71363e
AS
2269if eval "test \"`echo '$''{'acx_cv_cc_gcc_supports_ada'+set}'`\" = set"; then
2270 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed
NN
2271else
2272 cat >conftest.adb <<EOF
2273procedure conftest is begin null; end conftest;
2274EOF
2275acx_cv_cc_gcc_supports_ada=no
2276# There is a bug in old released versions of GCC which causes the
2277# driver to exit successfully when the appropriate language module
2278# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
2279# Therefore we must check for the error message as well as an
2280# unsuccessful exit.
1db673ca
RO
2281# Other compilers, like HP Tru64 UNIX cc, exit successfully when
2282# given a .adb file, but produce no object file. So we must check
2283# if an object file was really produced to guard against this.
55ffb5ed 2284errors=`(${CC} -c conftest.adb) 2>&1 || echo failure`
1db673ca 2285if test x"$errors" = x && test -f conftest.$ac_objext; then
55ffb5ed 2286 acx_cv_cc_gcc_supports_ada=yes
55ffb5ed
NN
2287fi
2288rm -f conftest.*
2289fi
af71363e
AS
2290
2291echo "$ac_t""$acx_cv_cc_gcc_supports_ada" 1>&6
55ffb5ed 2292
5305be7e 2293if test x$GNATBIND != xno && test x$GNATMAKE != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
55ffb5ed
NN
2294 have_gnat=yes
2295else
2296 have_gnat=no
2297fi
2298
af71363e 2299echo $ac_n "checking how to compare bootstrapped objects""... $ac_c" 1>&6
5305be7e 2300echo "configure:2301: checking how to compare bootstrapped objects" >&5
af71363e
AS
2301if eval "test \"`echo '$''{'gcc_cv_prog_cmp_skip'+set}'`\" = set"; then
2302 echo $ac_n "(cached) $ac_c" 1>&6
a76494aa
PB
2303else
2304 echo abfoo >t1
2305 echo cdfoo >t2
2306 gcc_cv_prog_cmp_skip='tail +16c $$f1 > tmp-foo1; tail +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
6cf1ac42
PB
2307 if cmp t1 t2 2 2 > /dev/null 2>&1; then
2308 if cmp t1 t2 1 1 > /dev/null 2>&1; then
2309 :
2310 else
2311 gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
2312 fi
2313 fi
a76494aa
PB
2314 if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
2315 if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
6cf1ac42 2316 :
a76494aa
PB
2317 else
2318 gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
2319 fi
2320 fi
2321 rm t1 t2
2322
2323fi
af71363e
AS
2324
2325echo "$ac_t""$gcc_cv_prog_cmp_skip" 1>&6
a76494aa
PB
2326do_compare="$gcc_cv_prog_cmp_skip"
2327
2328
55ffb5ed 2329
bebf829d 2330# Check for GMP and MPFR
e69bf64b 2331gmplibs="-lmpfr -lgmp"
6de9cd9a 2332gmpinc=
e69bf64b
PB
2333have_gmp=no
2334
bebf829d
PB
2335# Specify a location for mpfr
2336# check for this first so it ends up on the link line before gmp.
2337# Check whether --with-mpfr-dir or --without-mpfr-dir was given.
2338if test "${with_mpfr_dir+set}" = set; then
2339 withval="$with_mpfr_dir"
af71363e
AS
2340 { echo "configure: error: The --with-mpfr-dir=PATH option has been removed.
2341Use --with-mpfr=PATH or --with-mpfr-include=PATH plus --with-mpfr-lib=PATH" 1>&2; exit 1; }
2342fi
bebf829d
PB
2343
2344
bebf829d
PB
2345# Check whether --with-mpfr or --without-mpfr was given.
2346if test "${with_mpfr+set}" = set; then
2347 withval="$with_mpfr"
af71363e
AS
2348 :
2349fi
bebf829d 2350
8a877c9c
KG
2351# Check whether --with-mpfr_include or --without-mpfr_include was given.
2352if test "${with_mpfr_include+set}" = set; then
2353 withval="$with_mpfr_include"
af71363e
AS
2354 :
2355fi
8a877c9c
KG
2356
2357# Check whether --with-mpfr_lib or --without-mpfr_lib was given.
2358if test "${with_mpfr_lib+set}" = set; then
2359 withval="$with_mpfr_lib"
af71363e
AS
2360 :
2361fi
8a877c9c 2362
bebf829d
PB
2363
2364if test "x$with_mpfr" != x; then
2365 gmplibs="-L$with_mpfr/lib $gmplibs"
2366 gmpinc="-I$with_mpfr/include"
2367fi
8a877c9c
KG
2368if test "x$with_mpfr_include" != x; then
2369 gmpinc="-I$with_mpfr_include"
2370fi
2371if test "x$with_mpfr_lib" != x; then
2372 gmplibs="-L$with_mpfr_lib $gmplibs"
2373fi
e69bf64b
PB
2374if test "x$with_mpfr$with_mpfr_include$with_mpfr_lib" = x && test -d ${srcdir}/mpfr; then
2375 gmplibs='-L$$r/$(HOST_SUBDIR)/mpfr/.libs -L$$r/$(HOST_SUBDIR)/mpfr/_libs '"$gmplibs"
2376 gmpinc='-I$$r/$(HOST_SUBDIR)/mpfr -I$$s/mpfr '"$gmpinc"
2377 # Do not test the mpfr version. Assume that it is sufficient, since
2378 # it is in the source tree, and the library has not been built yet
2379 # but it would be included on the link line in the version check below
2380 # hence making the test fail.
2381 have_gmp=yes
2382fi
bebf829d 2383
6de9cd9a
DN
2384# Specify a location for gmp
2385# Check whether --with-gmp-dir or --without-gmp-dir was given.
2386if test "${with_gmp_dir+set}" = set; then
2387 withval="$with_gmp_dir"
af71363e
AS
2388 { echo "configure: error: The --with-gmp-dir=PATH option has been removed.
2389Use --with-gmp=PATH or --with-gmp-include=PATH plus --with-gmp-lib=PATH" 1>&2; exit 1; }
2390fi
6de9cd9a 2391
6de9cd9a
DN
2392
2393# Check whether --with-gmp or --without-gmp was given.
2394if test "${with_gmp+set}" = set; then
2395 withval="$with_gmp"
af71363e
AS
2396 :
2397fi
6de9cd9a 2398
8a877c9c
KG
2399# Check whether --with-gmp_include or --without-gmp_include was given.
2400if test "${with_gmp_include+set}" = set; then
2401 withval="$with_gmp_include"
af71363e
AS
2402 :
2403fi
8a877c9c
KG
2404
2405# Check whether --with-gmp_lib or --without-gmp_lib was given.
2406if test "${with_gmp_lib+set}" = set; then
2407 withval="$with_gmp_lib"
af71363e
AS
2408 :
2409fi
8a877c9c
KG
2410
2411
6de9cd9a 2412
bebf829d
PB
2413if test "x$with_gmp" != x; then
2414 gmplibs="-L$with_gmp/lib $gmplibs"
2415 gmpinc="-I$with_gmp/include $gmpinc"
6de9cd9a 2416fi
8a877c9c
KG
2417if test "x$with_gmp_include" != x; then
2418 gmpinc="-I$with_gmp_include $gmpinc"
2419fi
2420if test "x$with_gmp_lib" != x; then
2421 gmplibs="-L$with_gmp_lib $gmplibs"
2422fi
e69bf64b
PB
2423if test "x$with_gmp$with_gmp_include$with_gmp_lib" = x && test -d ${srcdir}/gmp; then
2424 gmplibs='-L$$r/$(HOST_SUBDIR)/gmp/.libs -L$$r/$(HOST_SUBDIR)/gmp/_libs '"$gmplibs"
2425 gmpinc='-I$$r/$(HOST_SUBDIR)/gmp -I$$s/gmp '"$gmpinc"
2426 # Do not test the gmp version. Assume that it is sufficient, since
2427 # it is in the source tree, and the library has not been built yet
2428 # but it would be included on the link line in the version check below
2429 # hence making the test fail.
2430 have_gmp=yes
2431fi
6de9cd9a 2432
d943d7c4 2433if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then
e69bf64b
PB
2434 have_gmp=yes
2435 saved_CFLAGS="$CFLAGS"
2436 CFLAGS="$CFLAGS $gmpinc"
2437 # Check GMP actually works
2438 echo $ac_n "checking for correct version of gmp.h""... $ac_c" 1>&6
5305be7e 2439echo "configure:2440: checking for correct version of gmp.h" >&5
e69bf64b 2440 cat > conftest.$ac_ext <<EOF
5305be7e 2441#line 2442 "configure"
af71363e 2442#include "confdefs.h"
6de9cd9a 2443#include "gmp.h"
af71363e 2444int main() {
6de9cd9a 2445
e69bf64b
PB
2446 #if __GNU_MP_VERSION < 4 || (__GNU_MP_VERSION == 4 && __GNU_MP_VERSION_MINOR < 1)
2447 choke me
2448 #endif
2449
af71363e
AS
2450; return 0; }
2451EOF
5305be7e 2452if { (eval echo configure:2453: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
af71363e
AS
2453 rm -rf conftest*
2454 echo "$ac_t""yes" 1>&6
2455else
2456 echo "configure: failed program was:" >&5
2457 cat conftest.$ac_ext >&5
2458 rm -rf conftest*
2459 echo "$ac_t""no" 1>&6; have_gmp=no
2460fi
2461rm -f conftest*
6de9cd9a 2462
e69bf64b
PB
2463 if test x"$have_gmp" = xyes; then
2464 saved_LIBS="$LIBS"
2465 LIBS="$LIBS $gmplibs"
2466 echo $ac_n "checking for correct version of mpfr.h""... $ac_c" 1>&6
5305be7e 2467echo "configure:2468: checking for correct version of mpfr.h" >&5
e69bf64b 2468 cat > conftest.$ac_ext <<EOF
5305be7e 2469#line 2470 "configure"
af71363e 2470#include "confdefs.h"
70ec446f 2471#include <gmp.h>
e69bf64b 2472 #include <mpfr.h>
af71363e 2473int main() {
e48d66a9 2474
e69bf64b
PB
2475 #if MPFR_VERSION < MPFR_VERSION_NUM(2,2,0)
2476 choke me
2477 #endif
2478 mpfr_t n; mpfr_init(n);
2479 mpfr_t x; mpfr_init(x);
2480 int t;
2481 mpfr_atan2 (n, n, x, GMP_RNDN);
2482 mpfr_erfc (n, x, GMP_RNDN);
2483 mpfr_subnormalize (x, t, GMP_RNDN);
2484
af71363e
AS
2485; return 0; }
2486EOF
5305be7e 2487if { (eval echo configure:2488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
a3993f33
KG
2488 rm -rf conftest*
2489 cat > conftest.$ac_ext <<EOF
5305be7e 2490#line 2491 "configure"
a3993f33
KG
2491#include "confdefs.h"
2492#include <gmp.h>
e69bf64b 2493 #include <mpfr.h>
a3993f33
KG
2494int main() {
2495
e69bf64b
PB
2496 #if MPFR_VERSION < MPFR_VERSION_NUM(2,2,1)
2497 choke me
2498 #endif
2499 mpfr_t n; mpfr_init(n);
2500
a3993f33
KG
2501; return 0; }
2502EOF
5305be7e 2503if { (eval echo configure:2504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
af71363e
AS
2504 rm -rf conftest*
2505 echo "$ac_t""yes" 1>&6
a3993f33
KG
2506else
2507 echo "configure: failed program was:" >&5
2508 cat conftest.$ac_ext >&5
2509 rm -rf conftest*
2510 echo "$ac_t""buggy but acceptable" 1>&6
2511fi
2512rm -f conftest*
af71363e
AS
2513else
2514 echo "configure: failed program was:" >&5
2515 cat conftest.$ac_ext >&5
2516 rm -rf conftest*
2517 echo "$ac_t""no" 1>&6; have_gmp=no
2518fi
2519rm -f conftest*
e69bf64b
PB
2520 LIBS="$saved_LIBS"
2521 fi
2522 CFLAGS="$saved_CFLAGS"
6de9cd9a 2523
e69bf64b
PB
2524 if test x$have_gmp != xyes; then
2525 { echo "configure: error: Building GCC requires GMP 4.1+ and MPFR 2.2.1+.
ca558912
KG
2526Try the --with-gmp and/or --with-mpfr options to specify their locations.
2527Copies of these libraries' source code can be found at their respective
2528hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
dbee1fb3
KG
2529See also http://gcc.gnu.org/install/prerequisites.html for additional info.
2530If you obtained GMP and/or MPFR from a vendor distribution package, make
2531sure that you have installed both the libraries and the header files.
af71363e 2532They may be located in separate packages." 1>&2; exit 1; }
e69bf64b 2533 fi
70ec446f
KG
2534fi
2535
bebf829d 2536# Flags needed for both GMP and/or MPFR
6de9cd9a
DN
2537
2538
2539
1e0f07d3 2540# By default, C is the only stage 1 language.
e1888513 2541stage1_languages=,c,
2805b53a 2542
55ffb5ed
NN
2543# Figure out what language subdirectories are present.
2544# Look if the user specified --enable-languages="..."; if not, use
2545# the environment variable $LANGUAGES if defined. $LANGUAGES might
2546# go away some day.
2547# NB: embedded tabs in this IF block -- do not untabify
2548if test -d ${srcdir}/gcc; then
2549 if test x"${enable_languages+set}" != xset; then
2550 if test x"${LANGUAGES+set}" = xset; then
2551 enable_languages="${LANGUAGES}"
2552 echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
2553 else
2554 enable_languages=all
2555 fi
2556 else
2557 if test x"${enable_languages}" = x ||
2558 test x"${enable_languages}" = xyes;
2559 then
2560 echo configure.in: --enable-languages needs at least one language argument 1>&2
2561 exit 1
2562 fi
2563 fi
2564 enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
2565
7f26dfa3
FXC
2566 # 'f95' is the old name for the 'fortran' language. We issue a warning
2567 # and make the substitution.
2568 case ,${enable_languages}, in
2569 *,f95,*)
2570 echo configure.in: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
2571 enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
2572 ;;
2573 esac
2574
55ffb5ed
NN
2575 # First scan to see if an enabled language requires some other language.
2576 # We assume that a given config-lang.in will list all the language
2577 # front ends it requires, even if some are required indirectly.
2578 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
2579 case ${lang_frag} in
2580 ..) ;;
2581 # The odd quoting in the next line works around
2582 # an apparent bug in bash 1.12 on linux.
2583 ${srcdir}/gcc/[*]/config-lang.in) ;;
2584 *)
2585 # From the config-lang.in, get $language, $lang_requires
2586 language=
2587 lang_requires=
2588 . ${lang_frag}
2589 for other in ${lang_requires} ; do
2590 case ,${enable_languages}, in
2591 *,$other,*) ;;
2592 *,all,*) ;;
2593 *,$language,*)
2594 echo " \`$other' language required by \`$language'; enabling" 1>&2
2595 enable_languages="${enable_languages},${other}"
2596 ;;
2597 esac
2598 done
2599 ;;
2600 esac
2601 done
2602
e1888513 2603 new_enable_languages=,c,
55ffb5ed 2604 missing_languages=`echo ",$enable_languages," | sed -e s/,all,/,/ -e s/,c,/,/ `
e1888513 2605 potential_languages=,c,
55ffb5ed
NN
2606
2607 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
2608 case ${lang_frag} in
2609 ..) ;;
2610 # The odd quoting in the next line works around
2611 # an apparent bug in bash 1.12 on linux.
2612 ${srcdir}/gcc/[*]/config-lang.in) ;;
2613 *)
af71363e 2614 # From the config-lang.in, get $language, $target_libs,
2805b53a 2615 # $lang_dirs, $boot_language, and $build_by_default
55ffb5ed
NN
2616 language=
2617 target_libs=
2618 lang_dirs=
1546bb64 2619 subdir_requires=
e1888513
PB
2620 boot_language=no
2621 build_by_default=yes
55ffb5ed 2622 . ${lang_frag}
e1888513
PB
2623 if test x${language} = x; then
2624 echo "${lang_frag} doesn't set \$language." 1>&2
2625 exit 1
2626 fi
2627
2628 case ,${enable_languages}, in
2629 *,${language},*)
55ffb5ed
NN
2630 # Language was explicitly selected; include it.
2631 add_this_lang=yes
2632 ;;
e1888513
PB
2633 *,all,*)
2634 # 'all' was selected, select it if it is a default language
2635 add_this_lang=${build_by_default}
55ffb5ed
NN
2636 ;;
2637 *)
2638 add_this_lang=no
2639 ;;
2640 esac
6de9cd9a 2641
1546bb64 2642 # Disable languages that need other directories if these aren't available.
95695ad3 2643 for i in $subdir_requires; do
b6348cb3 2644 test -f "$srcdir/gcc/$i/config-lang.in" && continue
1546bb64
PB
2645 case ,${enable_languages}, in
2646 *,${language},*)
2647 # Specifically requested language; tell them.
af71363e 2648 { echo "configure: error: The gcc/$i directory contains parts of $language but is missing" 1>&2; exit 1; }
1546bb64
PB
2649 ;;
2650 *)
2651 # Silently disable.
e1888513 2652 add_this_lang=unsupported
1546bb64
PB
2653 ;;
2654 esac
2655 done
2656
e1888513
PB
2657 # Disable Ada if no preexisting GNAT is available.
2658 case ,${enable_languages},:${language}:${have_gnat} in
2659 *,${language},*:ada:no)
2660 # Specifically requested language; tell them.
2661 { echo "configure: error: GNAT is required to build $language" 1>&2; exit 1; }
2662 ;;
2663 *:ada:no)
2664 # Silently disable.
2665 add_this_lang=unsupported
2666 ;;
2667 esac
2668
4fab7234
HPN
2669 # Disable a language that is unsupported by the target.
2670 case " $unsupported_languages " in
2671 *" $language "*)
e1888513 2672 add_this_lang=unsupported
4fab7234
HPN
2673 ;;
2674 esac
2675
6de9cd9a 2676 case $add_this_lang in
e1888513 2677 unsupported)
55ffb5ed 2678 # Remove language-dependent dirs.
2805b53a
NN
2679 eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
2680 ;;
e1888513
PB
2681 no)
2682 # Remove language-dependent dirs; still show language as supported.
2683 eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
2684 potential_languages="${potential_languages}${language},"
2685 ;;
2686 yes)
2687 new_enable_languages="${new_enable_languages}${language},"
2688 potential_languages="${potential_languages}${language},"
2805b53a
NN
2689 missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
2690 case ${boot_language} in
2691 yes)
340de83f 2692 # Add to (comma-separated) list of stage 1 languages.
e1888513 2693 stage1_languages="${stage1_languages}${language},"
2805b53a
NN
2694 ;;
2695 esac
2696 ;;
55ffb5ed
NN
2697 esac
2698 ;;
2699 esac
2700 done
2701
e1888513
PB
2702 # Check whether --enable-stage1-languages or --disable-stage1-languages was given.
2703if test "${enable_stage1_languages+set}" = set; then
2704 enableval="$enable_stage1_languages"
2705 case ,${enable_stage1_languages}, in
2706 ,no,|,,)
2707 # Set it to something that will have no effect in the loop below
2708 enable_stage1_languages=c ;;
2709 ,yes,)
2710 enable_stage1_languages=`echo $new_enable_languages | \
2711 sed -e "s/^,//" -e "s/,$//" ` ;;
2712 *,all,*)
2713 enable_stage1_languages=`echo ,$enable_stage1_languages, | \
2714 sed -e "s/,all,/$new_enable_languages/" -e "s/^,//" -e "s/,$//" ` ;;
2715 esac
2716
2717 # Add "good" languages from enable_stage1_languages to stage1_languages,
2718 # while "bad" languages go in missing_languages. Leave no duplicates.
2719 for i in `echo $enable_stage1_languages | sed 's/,/ /g' `; do
2720 case $potential_languages in
2721 *,$i,*)
2722 case $stage1_languages in
2723 *,$i,*) ;;
2724 *) stage1_languages="$stage1_languages$i," ;;
2725 esac ;;
2726 *)
2727 case $missing_languages in
2728 *,$i,*) ;;
2729 *) missing_languages="$missing_languages$i," ;;
2730 esac ;;
2731 esac
2732 done
2733fi
2734
2735
2736 # Remove leading/trailing commas that were added for simplicity
2737 potential_languages=`echo "$potential_languages" | sed -e "s/^,//" -e "s/,$//"`
79b4b7d2 2738 missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
e1888513
PB
2739 stage1_languages=`echo "$stage1_languages" | sed -e "s/^,//" -e "s/,$//"`
2740 new_enable_languages=`echo "$new_enable_languages" | sed -e "s/^,//" -e "s/,$//"`
2741
55ffb5ed 2742 if test "x$missing_languages" != x; then
af71363e 2743 { echo "configure: error:
0cf085e4 2744The following requested languages could not be built: ${missing_languages}
e1888513 2745Supported languages are: ${potential_languages}" 1>&2; exit 1; }
55ffb5ed 2746 fi
55ffb5ed
NN
2747 if test "x$new_enable_languages" != "x$enable_languages"; then
2748 echo The following languages will be built: ${new_enable_languages}
e1888513 2749 enable_languages="$new_enable_languages"
55ffb5ed 2750 fi
e1888513
PB
2751
2752
6bbec498 2753 ac_configure_args=`echo " $ac_configure_args" | sed -e 's/ --enable-languages=[^ ]*//' -e 's/$/ --enable-languages='"$enable_languages"/ `
55ffb5ed
NN
2754fi
2755
27079765
AH
2756# Handle --disable-<component> generically.
2757for dir in $configdirs $build_configdirs $target_configdirs ; do
2758 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g -e s/-/_/g`
2759 if eval test x\${enable_${dirname}} "=" xno ; then
2760 noconfigdirs="$noconfigdirs $dir"
2761 fi
2762done
2763
7cd0cf9c
DA
2764# Check for Boehm's garbage collector
2765# Check whether --enable-objc-gc or --disable-objc-gc was given.
2766if test "${enable_objc_gc+set}" = set; then
2767 enableval="$enable_objc_gc"
2768 case ,${enable_languages},:${enable_objc_gc}:${noconfigdirs} in
2769 *,objc,*:*:yes:*target-boehm-gc*)
af71363e 2770 { echo "configure: error: Boehm's garbage collector was requested yet not supported in this configuration" 1>&2; exit 1; }
7cd0cf9c
DA
2771 ;;
2772esac
af71363e
AS
2773fi
2774
7cd0cf9c
DA
2775
2776# Make sure we only build Boehm's garbage collector if required.
2a79fd67
DA
2777case ,${enable_languages},:${enable_objc_gc} in
2778 *,objc,*:yes)
7cd0cf9c
DA
2779 # Keep target-boehm-gc if requested for Objective-C.
2780 ;;
7cd0cf9c 2781 *)
2a79fd67
DA
2782 # Otherwise remove target-boehm-gc depending on target-libjava.
2783 if echo " ${noconfigdirs} " | grep "target-libjava" >/dev/null 2>&1; then
2784 noconfigdirs="$noconfigdirs target-boehm-gc"
2785 fi
7cd0cf9c
DA
2786 ;;
2787esac
2788
ee6a22df
L
2789# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
2790# $build_configdirs and $target_configdirs.
55ffb5ed
NN
2791# If we have the source for $noconfigdirs entries, add them to $notsupp.
2792
2793notsupp=""
2794for dir in . $skipdirs $noconfigdirs ; do
ee6a22df 2795 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
55ffb5ed
NN
2796 if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2797 configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
2798 if test -r $srcdir/$dirname/configure ; then
2799 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2800 true
2801 else
2802 notsupp="$notsupp $dir"
2803 fi
2804 fi
2805 fi
ee6a22df
L
2806 if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2807 build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
2808 if test -r $srcdir/$dirname/configure ; then
2809 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2810 true
2811 else
2812 notsupp="$notsupp $dir"
2813 fi
2814 fi
2815 fi
55ffb5ed
NN
2816 if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2817 target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
2818 if test -r $srcdir/$dirname/configure ; then
2819 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2820 true
2821 else
2822 notsupp="$notsupp $dir"
2823 fi
2824 fi
2825 fi
2826done
2827
2828# Sometimes the tools are distributed with libiberty but with no other
2829# libraries. In that case, we don't want to build target-libiberty.
54fdc474 2830# Don't let libgcc imply libiberty either.
55ffb5ed 2831if test -n "${target_configdirs}" ; then
54fdc474 2832 libgcc=
55ffb5ed
NN
2833 others=
2834 for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
54fdc474
DJ
2835 if test "$i" = "libgcc"; then
2836 libgcc=target-libgcc
2837 elif test "$i" != "libiberty" ; then
55ffb5ed
NN
2838 if test -r $srcdir/$i/configure ; then
2839 others=yes;
2840 break;
2841 fi
2842 fi
2843 done
2844 if test -z "${others}" ; then
54fdc474 2845 target_configdirs=$libgcc
55ffb5ed
NN
2846 fi
2847fi
2848
2849# Quietly strip out all directories which aren't configurable in this tree.
2850# This relies on all configurable subdirectories being autoconfiscated, which
2851# is now the case.
23f6b2f9
PB
2852build_configdirs_all="$build_configdirs"
2853build_configdirs=
2854for i in ${build_configdirs_all} ; do
af71363e 2855 j=`echo $i | sed -e s/build-//g`
23f6b2f9
PB
2856 if test -f ${srcdir}/$j/configure ; then
2857 build_configdirs="${build_configdirs} $i"
2858 fi
2859done
2860
55ffb5ed
NN
2861configdirs_all="$configdirs"
2862configdirs=
2863for i in ${configdirs_all} ; do
2864 if test -f ${srcdir}/$i/configure ; then
2865 configdirs="${configdirs} $i"
2866 fi
2867done
23f6b2f9 2868
55ffb5ed
NN
2869target_configdirs_all="$target_configdirs"
2870target_configdirs=
2871for i in ${target_configdirs_all} ; do
af71363e 2872 j=`echo $i | sed -e s/target-//g`
55ffb5ed
NN
2873 if test -f ${srcdir}/$j/configure ; then
2874 target_configdirs="${target_configdirs} $i"
2875 fi
2876done
2877
2878# Produce a warning message for the subdirs we can't configure.
2879# This isn't especially interesting in the Cygnus tree, but in the individual
2880# FSF releases, it's important to let people know when their machine isn't
2881# supported by the one or two programs in a package.
2882
2883if test -n "${notsupp}" && test -z "${norecursion}" ; then
2884 # If $appdirs is non-empty, at least one of those directories must still
2885 # be configured, or we error out. (E.g., if the gas release supports a
2886 # specified target in some subdirs but not the gas subdir, we shouldn't
2887 # pretend that all is well.)
2888 if test -n "$appdirs" ; then
2889 for dir in $appdirs ; do
2890 if test -r $dir/Makefile.in ; then
2891 if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2892 appdirs=""
2893 break
2894 fi
23f6b2f9 2895 if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
55ffb5ed
NN
2896 appdirs=""
2897 break
2898 fi
2899 fi
2900 done
2901 if test -n "$appdirs" ; then
2902 echo "*** This configuration is not supported by this package." 1>&2
2903 exit 1
2904 fi
2905 fi
2906 # Okay, some application will build, or we don't care to check. Still
2907 # notify of subdirs not getting built.
2908 echo "*** This configuration is not supported in the following subdirectories:" 1>&2
2909 echo " ${notsupp}" 1>&2
2910 echo " (Any other directories should still work fine.)" 1>&2
2911fi
2912
2913case "$host" in
2914 *msdosdjgpp*)
2915 enable_gdbtk=no ;;
2916esac
2917
2918copy_dirs=
2919
526635cb
MM
2920# Check whether --with-build-sysroot or --without-build-sysroot was given.
2921if test "${with_build_sysroot+set}" = set; then
2922 withval="$with_build_sysroot"
2923 if test x"$withval" != x ; then
2924 SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
2925 fi
2926else
2927 SYSROOT_CFLAGS_FOR_TARGET=
af71363e
AS
2928fi
2929
526635cb
MM
2930
2931
55ffb5ed
NN
2932# Handle --with-headers=XXX. If the value is not "yes", the contents of
2933# the named directory are copied to $(tooldir)/sys-include.
2934if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
2935 if test x${is_cross_compiler} = xno ; then
2936 echo 1>&2 '***' --with-headers is only supported when cross compiling
2937 exit 1
2938 fi
2939 if test x"${with_headers}" != xyes ; then
2940 case "${exec_prefixoption}" in
2941 "") x=${prefix} ;;
2942 *) x=${exec_prefix} ;;
2943 esac
2944 copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
2945 fi
2946fi
2947
2948# Handle --with-libs=XXX. If the value is not "yes", the contents of
2949# the name directories are copied to $(tooldir)/lib. Multiple directories
2950# are permitted.
2951if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
2952 if test x${is_cross_compiler} = xno ; then
2953 echo 1>&2 '***' --with-libs is only supported when cross compiling
2954 exit 1
2955 fi
2956 if test x"${with_libs}" != xyes ; then
2957 # Copy the libraries in reverse order, so that files in the first named
2958 # library override files in subsequent libraries.
2959 case "${exec_prefixoption}" in
2960 "") x=${prefix} ;;
2961 *) x=${exec_prefix} ;;
2962 esac
2963 for l in ${with_libs}; do
2964 copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
2965 done
2966 fi
2967fi
2968
e8b05380
PB
2969# Set with_gnu_as and with_gnu_ld as appropriate.
2970#
2971# This is done by determining whether or not the appropriate directory
2972# is available, and by checking whether or not specific configurations
2973# have requested that this magic not happen.
af71363e
AS
2974#
2975# The command line options always override the explicit settings in
e8b05380
PB
2976# configure.in, and the settings in configure.in override this magic.
2977#
af71363e 2978# If the default for a toolchain is to use GNU as and ld, and you don't
e8b05380
PB
2979# want to do that, then you should use the --without-gnu-as and
2980# --without-gnu-ld options for the configure script.
2981
2982if test x${use_gnu_as} = x &&
2983 echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
2984 with_gnu_as=yes
2985 extra_host_args="$extra_host_args --with-gnu-as"
2986fi
2987
2988if test x${use_gnu_ld} = x &&
2989 echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
2990 with_gnu_ld=yes
2991 extra_host_args="$extra_host_args --with-gnu-ld"
2992fi
2993
2994# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
2995# can detect this case.
2996
2997if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
2998 with_newlib=yes
2999 extra_host_args="$extra_host_args --with-newlib"
3000fi
3001
55ffb5ed
NN
3002# Handle ${copy_dirs}
3003set fnord ${copy_dirs}
3004shift
3005while test $# != 0 ; do
3006 if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
3007 :
3008 else
3009 echo Copying $1 to $2
3010
3011 # Use the install script to create the directory and all required
3012 # parent directories.
3013 if test -d $2 ; then
3014 :
3015 else
3016 echo >config.temp
3017 ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
3018 fi
3019
3020 # Copy the directory, assuming we have tar.
3021 # FIXME: Should we use B in the second tar? Not all systems support it.
3022 (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
3023
3024 # It is the responsibility of the user to correctly adjust all
3025 # symlinks. If somebody can figure out how to handle them correctly
3026 # here, feel free to add the code.
3027
3028 echo $1 > $2/COPIED
3029 fi
3030 shift; shift
3031done
3032
e8b05380
PB
3033# Determine a target-dependent exec_prefix that the installed
3034# gcc will search in. Keep this list sorted by triplet, with
3035# the *-*-osname triplets last.
3036md_exec_prefix=
3037case "${target}" in
3038 alpha*-*-*vms*)
3039 md_exec_prefix=/gnu/lib/gcc-lib
3040 ;;
3041 i3456786-pc-msdosdjgpp*)
3042 md_exec_prefix=/dev/env/DJDIR/bin
3043 ;;
3044 i3456786-*-sco3.2v5*)
3045 if test $with_gnu_as = yes; then
3046 md_exec_prefix=/usr/gnu/bin
3047 else
3048 md_exec_prefix=/usr/ccs/bin/elf
3049 fi
3050 ;;
3051
3052 mn10300-*-* | \
3053 powerpc-*-chorusos* | \
3054 powerpc*-*-eabi* | \
3055 powerpc*-*-sysv* | \
3056 powerpc*-*-kaos* | \
3057 s390x-ibm-tpf*)
3058 md_exec_prefix=/usr/ccs/bin
3059 ;;
3060 sparc64-*-elf*)
3061 ;;
3062 v850*-*-*)
3063 md_exec_prefix=/usr/ccs/bin
3064 ;;
3065 xtensa-*-elf*)
3066 ;;
3067
3068 *-*-beos* | \
3069 *-*-elf* | \
3070 *-*-hpux* | \
3071 *-*-netware* | \
3072 *-*-nto-qnx* | \
3073 *-*-rtems* | \
3074 *-*-solaris2* | \
3075 *-*-sysv45* | \
3076 *-*-vxworks* | \
3077 *-wrs-windiss)
3078 md_exec_prefix=/usr/ccs/bin
3079 ;;
3080esac
3081
671aa708
NN
3082extra_arflags_for_target=
3083extra_nmflags_for_target=
3084extra_ranlibflags_for_target=
3085target_makefile_frag=/dev/null
3086case "${target}" in
58e24147
AM
3087 spu-*-*)
3088 target_makefile_frag="config/mt-spu"
3089 ;;
61fec9ff 3090 *-*-netware*)
671aa708
NN
3091 target_makefile_frag="config/mt-netware"
3092 ;;
98a5bb3b
RM
3093 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
3094 target_makefile_frag="config/mt-gnu"
671aa708
NN
3095 ;;
3096 *-*-aix4.[3456789]* | *-*-aix[56789].*)
af71363e 3097 # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
671aa708
NN
3098 # commands to handle both 32-bit and 64-bit objects. These flags are
3099 # harmless if we're using GNU nm or ar.
3100 extra_arflags_for_target=" -X32_64"
3101 extra_nmflags_for_target=" -B -X32_64"
3102 ;;
3103 *-*-darwin*)
3104 # ranlib from Darwin requires the -c flag to look at common symbols.
3105 extra_ranlibflags_for_target=" -c"
3106 ;;
3107 mips*-*-pe | sh*-*-pe | *arm-wince-pe)
3108 target_makefile_frag="config/mt-wince"
3109 ;;
3110esac
3111
3112alphaieee_frag=/dev/null
3113case $target in
3114 alpha*-*-*)
3115 # This just makes sure to use the -mieee option to build target libs.
3116 # This should probably be set individually by each library.
3117 alphaieee_frag="config/mt-alphaieee"
3118 ;;
3119esac
3120
3121# If --enable-target-optspace always use -Os instead of -O2 to build
3122# the target libraries, similarly if it is not specified, use -Os
3123# on selected platforms.
3124ospace_frag=/dev/null
3125case "${enable_target_optspace}:${target}" in
3126 yes:*)
3127 ospace_frag="config/mt-ospace"
3128 ;;
3129 :d30v-*)
3130 ospace_frag="config/mt-d30v"
3131 ;;
3132 :m32r-* | :d10v-* | :fr30-*)
3133 ospace_frag="config/mt-ospace"
3134 ;;
3135 no:* | :*)
3136 ;;
3137 *)
3138 echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
3139 ;;
3140esac
3141
671aa708
NN
3142# Default to using --with-stabs for certain targets.
3143if test x${with_stabs} = x ; then
3144 case "${target}" in
89a95129 3145 mips*-*-irix[56]*)
671aa708
NN
3146 ;;
3147 mips*-*-* | alpha*-*-osf*)
3148 with_stabs=yes;
3149 extra_host_args="${extra_host_args} --with-stabs"
3150 ;;
3151 esac
3152fi
3153
3154# hpux11 in 64bit mode has libraries in a weird place. Arrange to find
3155# them automatically.
3156case "${host}" in
af71363e 3157 hppa*64*-*-hpux11*)
671aa708
NN
3158 extra_host_args="$extra_host_args -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
3159 ;;
3160esac
3161
671aa708
NN
3162# Some systems (e.g., one of the i386-aix systems the gas testers are
3163# using) don't handle "\$" correctly, so don't use it here.
df445104 3164tooldir='${exec_prefix}'/${target_alias}
671aa708
NN
3165build_tooldir=${tooldir}
3166
671aa708
NN
3167# Create a .gdbinit file which runs the one in srcdir
3168# and tells GDB to look there for source files.
3169
3170if test -r ${srcdir}/.gdbinit ; then
3171 case ${srcdir} in
3172 .) ;;
3173 *) cat > ./.gdbinit <<EOF
3174# ${NO_EDIT}
3175dir ${srcdir}
3176dir .
3177source ${srcdir}/.gdbinit
3178EOF
3179 ;;
3180 esac
3181fi
3182
671aa708
NN
3183# Make sure that the compiler is able to generate an executable. If it
3184# can't, we are probably in trouble. We don't care whether we can run the
3185# executable--we might be using a cross compiler--we only care whether it
3186# can be created. At this point the main configure script has set CC.
3187we_are_ok=no
3188echo "int main () { return 0; }" > conftest.c
3189${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
3190if test $? = 0 ; then
3191 if test -s conftest || test -s conftest.exe ; then
3192 we_are_ok=yes
3193 fi
af71363e 3194fi
671aa708
NN
3195case $we_are_ok in
3196 no)
3197 echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
3198 echo 1>&2 "*** You must set the environment variable CC to a working compiler."
3199 rm -f conftest*
3200 exit 1
3201 ;;
3202esac
3203rm -f conftest*
3204
3205# The Solaris /usr/ucb/cc compiler does not appear to work.
3206case "${host}" in
3207 sparc-sun-solaris2*)
3208 CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
3209 if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
3210 could_use=
3211 test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
3212 if test -d /opt/cygnus/bin ; then
3213 if test "$could_use" = "" ; then
3214 could_use="/opt/cygnus/bin"
3215 else
3216 could_use="$could_use or /opt/cygnus/bin"
3217 fi
3218 fi
3219 if test "$could_use" = "" ; then
3220 echo "Warning: compilation may fail because you're using"
3221 echo "/usr/ucb/cc. You should change your PATH or CC "
3222 echo "variable and rerun configure."
3223 else
3224 echo "Warning: compilation may fail because you're using"
3225 echo "/usr/ucb/cc, when you should use the C compiler from"
3226 echo "$could_use. You should change your"
3227 echo "PATH or CC variable and rerun configure."
3228 fi
3229 fi
3230 ;;
3231esac
3232
671aa708
NN
3233case "${host}" in
3234 *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
256f7136 3235 *-*-darwin* | *-*-rhapsody* ) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
671aa708
NN
3236 *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
3237esac
3238
3239# Record target_configdirs and the configure arguments for target and
3240# build configuration in Makefile.
3241target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
23f6b2f9 3242build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
671aa708 3243
671aa708
NN
3244# Determine whether gdb needs tk/tcl or not.
3245# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
3246# and in that case we want gdb to be built without tk. Ugh!
3247# In fact I believe gdb is the *only* package directly dependent on tk,
3248# so we should be able to put the 'maybe's in unconditionally and
3249# leave out the maybe dependencies when enable_gdbtk is false. I'm not
3250# 100% sure that that's safe though.
e914a571 3251
b4f96efe 3252gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
671aa708
NN
3253case "$enable_gdbtk" in
3254 no)
3255 GDB_TK="" ;;
e914a571
AC
3256 yes)
3257 GDB_TK="${gdb_tk}" ;;
671aa708 3258 *)
e914a571
AC
3259 # Only add the dependency on gdbtk when GDBtk is part of the gdb
3260 # distro. Eventually someone will fix this and move Insight, nee
3261 # gdbtk to a separate directory.
3262 if test -d ${srcdir}/gdb/gdbtk ; then
3263 GDB_TK="${gdb_tk}"
3264 else
3265 GDB_TK=""
3266 fi
3267 ;;
671aa708 3268esac
ef9db8d5
DJ
3269CONFIGURE_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-configure-/g`
3270INSTALL_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-install-/g`
671aa708 3271
60975492 3272# Strip out unwanted targets.
8b87bb96
NN
3273
3274# While at that, we remove Makefiles if we were started for recursive
3275# configuration, so that the top-level Makefile reconfigures them,
3276# like we used to do when configure itself was recursive.
8b87bb96 3277
60975492
PB
3278# Loop over modules. $extrasub must be used with care, limiting as
3279# much as possible the usage of range addresses. That's because autoconf
3280# splits the sed script to overcome limits in the number of commands,
3281# and relying on carefully-timed sed passes may turn out to be very hard
3282# to maintain later. In this particular case, you just have to be careful
3283# not to nest @if/@endif pairs, because configure will not warn you at all.
8b87bb96 3284
f516a7da
PB
3285# Check whether --enable-bootstrap or --disable-bootstrap was given.
3286if test "${enable_bootstrap+set}" = set; then
3287 enableval="$enable_bootstrap"
af71363e 3288 :
f516a7da 3289else
ce521a9c 3290 enable_bootstrap=default
af71363e
AS
3291fi
3292
f516a7da 3293
ce521a9c
PB
3294# Issue errors and warnings for invalid/strange bootstrap combinations.
3295case "$configdirs" in
3296 *gcc*) have_compiler=yes ;;
3297 *) have_compiler=no ;;
3298esac
3299
3300case "$have_compiler:$host:$target:$enable_bootstrap" in
3301 *:*:*:no) ;;
3302
1ca26cd2 3303 # Default behavior. Enable bootstrap if we have a compiler
ce521a9c
PB
3304 # and we are in a native configuration.
3305 yes:$build:$build:default)
1ca26cd2 3306 enable_bootstrap=yes ;;
ce521a9c
PB
3307
3308 *:*:*:default)
3309 enable_bootstrap=no ;;
3310
3311 # We have a compiler and we are in a native configuration, bootstrap is ok
2d309510 3312 yes:$build:$build:yes)
ce521a9c
PB
3313 ;;
3314
3315 # Other configurations, but we have a compiler. Assume the user knows
3316 # what he's doing.
2d309510 3317 yes:*:*:yes)
af71363e 3318 echo "configure: warning: trying to bootstrap a cross compiler" 1>&2
ce521a9c
PB
3319 ;;
3320
3321 # No compiler: if they passed --enable-bootstrap explicitly, fail
2d309510 3322 no:*:*:yes)
af71363e 3323 { echo "configure: error: cannot bootstrap without a compiler" 1>&2; exit 1; } ;;
ce521a9c
PB
3324
3325 # Fail if wrong command line
3326 *)
af71363e 3327 { echo "configure: error: invalid option for --enable-bootstrap" 1>&2; exit 1; }
ce521a9c
PB
3328 ;;
3329esac
3330
3331# Adjust the toplevel makefile according to whether bootstrap was selected.
f516a7da
PB
3332case "$enable_bootstrap" in
3333 yes)
5607edfd 3334 bootstrap_suffix=bootstrap ;;
f516a7da 3335 no)
5607edfd 3336 bootstrap_suffix=no-bootstrap ;;
f516a7da
PB
3337esac
3338
23f6b2f9 3339for module in ${build_configdirs} ; do
5607edfd
PB
3340 if test -z "${no_recursion}" \
3341 && test -f ${build_subdir}/${module}/Makefile; then
3342 echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
3343 rm -f ${build_subdir}/${module}/Makefile
3344 fi
3345 extrasub="$extrasub
3346/^@if build-$module\$/d
3347/^@endif build-$module\$/d
3348/^@if build-$module-$bootstrap_suffix\$/d
3349/^@endif build-$module-$bootstrap_suffix\$/d"
3350done
3351for module in ${configdirs} ; do
a6fbc1e2 3352 if test -z "${no_recursion}"; then
f063a9ed 3353 for file in stage*-${module}/Makefile prev-${module}/Makefile ${module}/Makefile; do
a6fbc1e2
AS
3354 if test -f ${file}; then
3355 echo 1>&2 "*** removing ${file} to force reconfigure"
3356 rm -f ${file}
3357 fi
3358 done
5607edfd
PB
3359 fi
3360 extrasub="$extrasub
3361/^@if $module\$/d
3362/^@endif $module\$/d
3363/^@if $module-$bootstrap_suffix\$/d
3364/^@endif $module-$bootstrap_suffix\$/d"
3365done
3366for module in ${target_configdirs} ; do
3367 if test -z "${no_recursion}" \
3368 && test -f ${target_subdir}/${module}/Makefile; then
3369 echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
3370 rm -f ${target_subdir}/${module}/Makefile
3371 fi
3372 extrasub="$extrasub
3373/^@if target-$module\$/d
3374/^@endif target-$module\$/d
3375/^@if target-$module-$bootstrap_suffix\$/d
3376/^@endif target-$module-$bootstrap_suffix\$/d"
3377done
3378
60975492
PB
3379extrasub="$extrasub
3380/^@if /,/^@endif /d"
671aa708
NN
3381
3382# Create the serialization dependencies. This uses a temporary file.
3383
ade82b16
AO
3384# Check whether --enable-serial-configure or --disable-serial-configure was given.
3385if test "${enable_serial_configure+set}" = set; then
3386 enableval="$enable_serial_configure"
af71363e
AS
3387 :
3388fi
ade82b16
AO
3389
3390
bf1d3e81
NN
3391case ${enable_serial_configure} in
3392 yes)
3393 enable_serial_build_configure=yes
3394 enable_serial_host_configure=yes
3395 enable_serial_target_configure=yes
3396 ;;
3397esac
3398
671aa708
NN
3399# These force 'configure's to be done one at a time, to avoid problems
3400# with contention over a shared config.cache.
3401rm -f serdep.tmp
ade82b16 3402echo '# serdep.tmp' > serdep.tmp
671aa708 3403olditem=
bf1d3e81 3404test "x${enable_serial_build_configure}" = xyes &&
671aa708
NN
3405for item in ${build_configdirs} ; do
3406 case ${olditem} in
3407 "") ;;
ade82b16 3408 *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
671aa708
NN
3409 esac
3410 olditem=${item}
3411done
3412olditem=
bf1d3e81 3413test "x${enable_serial_host_configure}" = xyes &&
671aa708
NN
3414for item in ${configdirs} ; do
3415 case ${olditem} in
3416 "") ;;
ade82b16 3417 *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
671aa708
NN
3418 esac
3419 olditem=${item}
3420done
3421olditem=
bf1d3e81 3422test "x${enable_serial_target_configure}" = xyes &&
671aa708
NN
3423for item in ${target_configdirs} ; do
3424 case ${olditem} in
3425 "") ;;
ade82b16 3426 *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
671aa708
NN
3427 esac
3428 olditem=${item}
3429done
3430serialization_dependencies=serdep.tmp
3431
3432
ade82b16
AO
3433# Base args. Strip norecursion, cache-file, srcdir, host, build,
3434# target and nonopt. These are the ones we might not want to pass
43bb47c2
DJ
3435# down to subconfigures. Also strip program-prefix, program-suffix,
3436# and program-transform-name, so that we can pass down a consistent
3437# program-transform-name. If autoconf has put single quotes around
3438# any of these arguments (because they contain shell metacharacters)
3439# then this will fail; in practice this only happens for
3440# --program-transform-name, so be sure to override --program-transform-name
3441# at the end of the argument list.
3442# These will be expanded by make, so quote '$'.
b348267b 3443cat <<\EOF_SED > conftestsed
9104315a
NN
3444s/ --no[^ ]*/ /g
3445s/ --c[a-z-]*[= ][^ ]*//g
3446s/ --sr[a-z-]*[= ][^ ]*//g
3447s/ --ho[a-z-]*[= ][^ ]*//g
3448s/ --bu[a-z-]*[= ][^ ]*//g
3449s/ --t[a-z-]*[= ][^ ]*//g
3450s/ --program-[pst][a-z-]*[= ][^ ]*//g
3451s/ -cache-file[= ][^ ]*//g
3452s/ -srcdir[= ][^ ]*//g
3453s/ -host[= ][^ ]*//g
3454s/ -build[= ][^ ]*//g
3455s/ -target[= ][^ ]*//g
3456s/ -program-prefix[= ][^ ]*//g
3457s/ -program-suffix[= ][^ ]*//g
3458s/ -program-transform-name[= ][^ ]*//g
b348267b
GK
3459s/ [^' -][^ ]* / /
3460s/^ *//;s/ *$//
eeae7b41
DJ
3461s,\$,$$,g
3462EOF_SED
3463sed -f conftestsed <<EOF_SED > conftestsed.out
af71363e 3464 ${ac_configure_args}
b348267b 3465EOF_SED
eeae7b41
DJ
3466baseargs=`cat conftestsed.out`
3467rm -f conftestsed conftestsed.out
671aa708 3468
43bb47c2
DJ
3469# Add in --program-transform-name, after --program-prefix and
3470# --program-suffix have been applied to it. Autoconf has already
3471# doubled dollar signs and backslashes in program_transform_name; we want
3472# the backslashes un-doubled, and then the entire thing wrapped in single
af71363e 3473# quotes, because this will be expanded first by make and then by the shell.
43bb47c2
DJ
3474# Also, because we want to override the logic in subdir configure scripts to
3475# choose program_transform_name, replace any s,x,x, with s,y,y,.
3476sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
3477${program_transform_name}
3478EOF_SED
3479gcc_transform_name=`cat conftestsed.out`
3480rm -f conftestsed.out
3481baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
3482
671aa708
NN
3483# For the build-side libraries, we just need to pretend we're native,
3484# and not use the same cache file. Multilibs are neither needed nor
3485# desired.
e69bf64b 3486build_configargs="--cache-file=../config.cache ${baseargs}"
671aa708
NN
3487
3488# For host modules, accept cache file option, or specification as blank.
3489case "${cache_file}" in
3490"") # empty
3491 cache_file_option="" ;;
3492/* | [A-Za-z]:[\\/]* ) # absolute path
3493 cache_file_option="--cache-file=${cache_file}" ;;
3494*) # relative path
3495 cache_file_option="--cache-file=../${cache_file}" ;;
3496esac
3497
09438bde
NN
3498# Host dirs don't like to share a cache file either, horribly enough.
3499# This seems to be due to autoconf 2.5x stupidity.
e69bf64b 3500host_configargs="--cache-file=./config.cache ${extra_host_args} ${baseargs}"
671aa708
NN
3501
3502target_configargs=${baseargs}
3503
3504# Passing a --with-cross-host argument lets the target libraries know
3505# whether they are being built with a cross-compiler or being built
3506# native. However, it would be better to use other mechanisms to make the
3507# sorts of decisions they want to make on this basis. Please consider
3508# this option to be deprecated. FIXME.
3509if test x${is_cross_compiler} = xyes ; then
3510 target_configargs="--with-cross-host=${host_alias} ${target_configargs}"
3511fi
3512
3513# Default to --enable-multilib.
3514if test x${enable_multilib} = x ; then
3515 target_configargs="--enable-multilib ${target_configargs}"
3516fi
3517
3518# Pass --with-newlib if appropriate. Note that target_configdirs has
3519# changed from the earlier setting of with_newlib.
3520if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
3521 target_configargs="--with-newlib ${target_configargs}"
3522fi
3523
6b9eb62c
NN
3524# Different target subdirs use different values of certain variables
3525# (notably CXX). Worse, multilibs use *lots* of different values.
3526# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
3527# it doesn't automatically accept command-line overrides of them.
3528# This means it's not safe for target subdirs to share a cache file,
3529# which is disgusting, but there you have it. Hopefully this can be
3530# fixed in future. It's still worthwhile to use a cache file for each
3531# directory. I think.
3532
bebcd931
MS
3533# Pass the appropriate --build, --host, --target and --cache-file arguments.
3534# We need to pass --target, as newer autoconf's requires consistency
3535# for target_alias and gcc doesn't manage it consistently.
e69bf64b 3536target_configargs="--cache-file=./config.cache ${target_configargs}"
671aa708 3537
671aa708
NN
3538FLAGS_FOR_TARGET=
3539case " $target_configdirs " in
3540 *" newlib "*)
3541 case " $target_configargs " in
3542 *" --with-newlib "*)
3543 case "$target" in
3544 *-cygwin*)
aa8f1f57 3545 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include' ;;
671aa708
NN
3546 esac
3547
3548 # If we're not building GCC, don't discard standard headers.
3549 if test -d ${srcdir}/gcc; then
3550 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
3551
3552 if test "${build}" != "${host}"; then
3553 # On Canadian crosses, CC_FOR_TARGET will have already been set
3554 # by `configure', so we won't have an opportunity to add -Bgcc/
3555 # to it. This is right: we don't want to search that directory
3556 # for binaries, but we want the header files in there, so add
3557 # them explicitly.
215c351a 3558 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include'
671aa708
NN
3559
3560 # Someone might think of using the pre-installed headers on
3561 # Canadian crosses, in case the installed compiler is not fully
3562 # compatible with the compiler being built. In this case, it
3563 # would be better to flag an error than risking having
3564 # incompatible object files being constructed. We can't
3565 # guarantee that an error will be flagged, but let's hope the
3566 # compiler will do it, when presented with incompatible header
3567 # files.
3568 fi
3569 fi
3570
3571 case "${target}-${is_cross_compiler}" in
f2a0e225 3572 i[3456789]86-*-linux*-no)
671aa708
NN
3573 # Here host == target, so we don't need to build gcc,
3574 # so we don't want to discard standard headers.
3575 FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
3576 ;;
3577 *)
3578 # If we're building newlib, use its generic headers last, but search
3579 # for any libc-related directories first (so make it the last -B
3580 # switch).
3581 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
3582 ;;
3583 esac
3584 ;;
3585 esac
3586 ;;
3587esac
b91f0a41
CV
3588case "$target" in
3589*-mingw*)
3590 # Can't be handled as Cygwin above since Mingw does not use newlib.
3591 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' ;;
3592esac
671aa708 3593
6691a79e
ME
3594# Allow the user to override the flags for
3595# our build compiler if desired.
3596CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
3597
671aa708
NN
3598# On Canadian crosses, we'll be searching the right directories for
3599# the previously-installed cross compiler, so don't bother to add
3600# flags for directories within the install tree of the compiler
3601# being built; programs in there won't even run.
3602if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
3603 # Search for pre-installed headers if nothing else fits.
9124bc53 3604 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
3605fi
3606
3607if test "x${use_gnu_ld}" = x &&
3608 echo " ${configdirs} " | grep " ld " > /dev/null ; then
3609 # Arrange for us to find uninstalled linker scripts.
215c351a 3610 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
671aa708
NN
3611fi
3612
e88a2c09
DD
3613# Search for other target-specific linker scripts and such.
3614case "${target}" in
3615 m32c-*-* )
3616 if test -d ${srcdir}/libgloss/m32c; then
3617 # This is for crt0.o
3618 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/libgloss/m32c'
3619 # This is for r8c.ld
3620 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/m32c'
3621 # This is for libnosys.a
3622 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/libnosys'
3623 fi
3624 ;;
3625esac
3626
671aa708 3627# Makefile fragments.
7b61653a
PE
3628for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
3629do
3630 eval fragval=\$$frag
3631 if test $fragval != /dev/null; then
3632 eval $frag=${srcdir}/$fragval
3633 fi
3634done
671aa708
NN
3635
3636
3637
3638
3639
3640# Miscellanea: directories, flags, etc.
3641
3642
3643
3644
3645
3646
3647
23f6b2f9 3648# Build module lists & subconfigure args.
671aa708
NN
3649
3650
3651
2abefe3d
PB
3652# Host module lists & subconfigure args.
3653
3654
3655
3656# Target module lists & subconfigure args.
3657
3658
3659
3660# Build tools.
3661
3662
3663
3664# Generate default definitions for YACC, M4, LEX and other programs that run
3665# on the build machine. These are used if the Makefile can't locate these
3666# programs in objdir.
3667MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
3668
3669for ac_prog in 'bison -y' byacc yacc
3670do
af71363e 3671# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3672set dummy $ac_prog; ac_word=$2
af71363e 3673echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3674echo "configure:3675: checking for $ac_word" >&5
af71363e
AS
3675if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
3676 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3677else
3678 if test -n "$YACC"; then
3679 ac_cv_prog_YACC="$YACC" # Let the user override the test.
3680else
af71363e
AS
3681 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3682 ac_dummy="$PATH"
3683 for ac_dir in $ac_dummy; do
3684 test -z "$ac_dir" && ac_dir=.
3685 if test -f $ac_dir/$ac_word; then
3686 ac_cv_prog_YACC="$ac_prog"
3687 break
3688 fi
3689 done
3690 IFS="$ac_save_ifs"
2abefe3d
PB
3691fi
3692fi
af71363e 3693YACC="$ac_cv_prog_YACC"
2abefe3d 3694if test -n "$YACC"; then
af71363e 3695 echo "$ac_t""$YACC" 1>&6
2abefe3d 3696else
af71363e 3697 echo "$ac_t""no" 1>&6
2abefe3d
PB
3698fi
3699
af71363e 3700test -n "$YACC" && break
2abefe3d
PB
3701done
3702test -n "$YACC" || YACC="$MISSING bison -y"
3703
3704case " $build_configdirs " in
3705 *" bison "*) YACC='$$r/$(BUILD_SUBDIR)/bison/tests/bison -y' ;;
3706 *" byacc "*) YACC='$$r/$(BUILD_SUBDIR)/byacc/byacc' ;;
3707esac
3708
3709for ac_prog in bison
3710do
af71363e 3711# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3712set dummy $ac_prog; ac_word=$2
af71363e 3713echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3714echo "configure:3715: checking for $ac_word" >&5
af71363e
AS
3715if eval "test \"`echo '$''{'ac_cv_prog_BISON'+set}'`\" = set"; then
3716 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3717else
3718 if test -n "$BISON"; then
3719 ac_cv_prog_BISON="$BISON" # Let the user override the test.
3720else
af71363e
AS
3721 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3722 ac_dummy="$PATH"
3723 for ac_dir in $ac_dummy; do
3724 test -z "$ac_dir" && ac_dir=.
3725 if test -f $ac_dir/$ac_word; then
3726 ac_cv_prog_BISON="$ac_prog"
3727 break
3728 fi
3729 done
3730 IFS="$ac_save_ifs"
2abefe3d
PB
3731fi
3732fi
af71363e 3733BISON="$ac_cv_prog_BISON"
2abefe3d 3734if test -n "$BISON"; then
af71363e 3735 echo "$ac_t""$BISON" 1>&6
2abefe3d 3736else
af71363e 3737 echo "$ac_t""no" 1>&6
2abefe3d
PB
3738fi
3739
af71363e 3740test -n "$BISON" && break
2abefe3d
PB
3741done
3742test -n "$BISON" || BISON="$MISSING bison"
3743
3744case " $build_configdirs " in
3745 *" bison "*) BISON='$$r/$(BUILD_SUBDIR)/bison/tests/bison' ;;
3746esac
3747
3748for ac_prog in gm4 gnum4 m4
3749do
af71363e 3750# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3751set dummy $ac_prog; ac_word=$2
af71363e 3752echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3753echo "configure:3754: checking for $ac_word" >&5
af71363e
AS
3754if eval "test \"`echo '$''{'ac_cv_prog_M4'+set}'`\" = set"; then
3755 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3756else
3757 if test -n "$M4"; then
3758 ac_cv_prog_M4="$M4" # Let the user override the test.
3759else
af71363e
AS
3760 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3761 ac_dummy="$PATH"
3762 for ac_dir in $ac_dummy; do
3763 test -z "$ac_dir" && ac_dir=.
3764 if test -f $ac_dir/$ac_word; then
3765 ac_cv_prog_M4="$ac_prog"
3766 break
3767 fi
3768 done
3769 IFS="$ac_save_ifs"
2abefe3d
PB
3770fi
3771fi
af71363e 3772M4="$ac_cv_prog_M4"
2abefe3d 3773if test -n "$M4"; then
af71363e 3774 echo "$ac_t""$M4" 1>&6
2abefe3d 3775else
af71363e 3776 echo "$ac_t""no" 1>&6
2abefe3d
PB
3777fi
3778
af71363e 3779test -n "$M4" && break
2abefe3d
PB
3780done
3781test -n "$M4" || M4="$MISSING m4"
3782
3783case " $build_configdirs " in
3784 *" m4 "*) M4='$$r/$(BUILD_SUBDIR)/m4/m4' ;;
3785esac
3786
3787for ac_prog in flex lex
3788do
af71363e 3789# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3790set dummy $ac_prog; ac_word=$2
af71363e 3791echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3792echo "configure:3793: checking for $ac_word" >&5
af71363e
AS
3793if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
3794 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3795else
3796 if test -n "$LEX"; then
3797 ac_cv_prog_LEX="$LEX" # Let the user override the test.
3798else
af71363e
AS
3799 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3800 ac_dummy="$PATH"
3801 for ac_dir in $ac_dummy; do
3802 test -z "$ac_dir" && ac_dir=.
3803 if test -f $ac_dir/$ac_word; then
3804 ac_cv_prog_LEX="$ac_prog"
3805 break
3806 fi
3807 done
3808 IFS="$ac_save_ifs"
2abefe3d
PB
3809fi
3810fi
af71363e 3811LEX="$ac_cv_prog_LEX"
2abefe3d 3812if test -n "$LEX"; then
af71363e 3813 echo "$ac_t""$LEX" 1>&6
2abefe3d 3814else
af71363e 3815 echo "$ac_t""no" 1>&6
2abefe3d
PB
3816fi
3817
af71363e 3818test -n "$LEX" && break
2abefe3d
PB
3819done
3820test -n "$LEX" || LEX="$MISSING flex"
3821
3822case " $build_configdirs " in
3823 *" flex "*) LEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
3824 *" lex "*) LEX='$$r/$(BUILD_SUBDIR)/lex/lex' ;;
3825esac
3826
3827for ac_prog in flex
3828do
af71363e 3829# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3830set dummy $ac_prog; ac_word=$2
af71363e 3831echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3832echo "configure:3833: checking for $ac_word" >&5
af71363e
AS
3833if eval "test \"`echo '$''{'ac_cv_prog_FLEX'+set}'`\" = set"; then
3834 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3835else
3836 if test -n "$FLEX"; then
3837 ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
3838else
af71363e
AS
3839 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3840 ac_dummy="$PATH"
3841 for ac_dir in $ac_dummy; do
3842 test -z "$ac_dir" && ac_dir=.
3843 if test -f $ac_dir/$ac_word; then
3844 ac_cv_prog_FLEX="$ac_prog"
3845 break
3846 fi
3847 done
3848 IFS="$ac_save_ifs"
2abefe3d
PB
3849fi
3850fi
af71363e 3851FLEX="$ac_cv_prog_FLEX"
2abefe3d 3852if test -n "$FLEX"; then
af71363e 3853 echo "$ac_t""$FLEX" 1>&6
2abefe3d 3854else
af71363e 3855 echo "$ac_t""no" 1>&6
2abefe3d
PB
3856fi
3857
af71363e 3858test -n "$FLEX" && break
2abefe3d
PB
3859done
3860test -n "$FLEX" || FLEX="$MISSING flex"
3861
3862case " $build_configdirs " in
3863 *" flex "*) FLEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
3864esac
3865
3866for ac_prog in makeinfo
3867do
af71363e 3868# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3869set dummy $ac_prog; ac_word=$2
af71363e 3870echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3871echo "configure:3872: checking for $ac_word" >&5
af71363e
AS
3872if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then
3873 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3874else
3875 if test -n "$MAKEINFO"; then
3876 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
3877else
af71363e
AS
3878 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3879 ac_dummy="$PATH"
3880 for ac_dir in $ac_dummy; do
3881 test -z "$ac_dir" && ac_dir=.
3882 if test -f $ac_dir/$ac_word; then
3883 ac_cv_prog_MAKEINFO="$ac_prog"
3884 break
3885 fi
3886 done
3887 IFS="$ac_save_ifs"
2abefe3d
PB
3888fi
3889fi
af71363e 3890MAKEINFO="$ac_cv_prog_MAKEINFO"
2abefe3d 3891if test -n "$MAKEINFO"; then
af71363e 3892 echo "$ac_t""$MAKEINFO" 1>&6
2abefe3d 3893else
af71363e 3894 echo "$ac_t""no" 1>&6
2abefe3d
PB
3895fi
3896
af71363e 3897test -n "$MAKEINFO" && break
2abefe3d
PB
3898done
3899test -n "$MAKEINFO" || MAKEINFO="$MISSING makeinfo"
3900
3901case " $build_configdirs " in
3902 *" texinfo "*) MAKEINFO='$$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo' ;;
3903 *)
3904
27b6c940 3905 # For an installed makeinfo, we require it to be from texinfo 4.4 or
2abefe3d
PB
3906 # higher, else we use the "missing" dummy.
3907 if ${MAKEINFO} --version \
27b6c940 3908 | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[4-9]|[5-9])' >/dev/null 2>&1; then
2abefe3d
PB
3909 :
3910 else
3911 MAKEINFO="$MISSING makeinfo"
3912 fi
3913 ;;
3914
3915esac
671aa708 3916
2abefe3d 3917# FIXME: expect and dejagnu may become build tools?
671aa708 3918
2abefe3d
PB
3919for ac_prog in expect
3920do
af71363e 3921# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3922set dummy $ac_prog; ac_word=$2
af71363e 3923echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3924echo "configure:3925: checking for $ac_word" >&5
af71363e
AS
3925if eval "test \"`echo '$''{'ac_cv_prog_EXPECT'+set}'`\" = set"; then
3926 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3927else
3928 if test -n "$EXPECT"; then
3929 ac_cv_prog_EXPECT="$EXPECT" # Let the user override the test.
3930else
af71363e
AS
3931 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3932 ac_dummy="$PATH"
3933 for ac_dir in $ac_dummy; do
3934 test -z "$ac_dir" && ac_dir=.
3935 if test -f $ac_dir/$ac_word; then
3936 ac_cv_prog_EXPECT="$ac_prog"
3937 break
3938 fi
3939 done
3940 IFS="$ac_save_ifs"
2abefe3d
PB
3941fi
3942fi
af71363e 3943EXPECT="$ac_cv_prog_EXPECT"
2abefe3d 3944if test -n "$EXPECT"; then
af71363e 3945 echo "$ac_t""$EXPECT" 1>&6
2abefe3d 3946else
af71363e 3947 echo "$ac_t""no" 1>&6
2abefe3d 3948fi
671aa708 3949
af71363e 3950test -n "$EXPECT" && break
2abefe3d
PB
3951done
3952test -n "$EXPECT" || EXPECT="expect"
671aa708 3953
2abefe3d
PB
3954case " $configdirs " in
3955 *" expect "*)
3956 test $host = $build && EXPECT='$$r/$(HOST_SUBDIR)/expect/expect'
3957 ;;
3958esac
671aa708 3959
2abefe3d
PB
3960for ac_prog in runtest
3961do
af71363e 3962# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3963set dummy $ac_prog; ac_word=$2
af71363e 3964echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 3965echo "configure:3966: checking for $ac_word" >&5
af71363e
AS
3966if eval "test \"`echo '$''{'ac_cv_prog_RUNTEST'+set}'`\" = set"; then
3967 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3968else
3969 if test -n "$RUNTEST"; then
3970 ac_cv_prog_RUNTEST="$RUNTEST" # Let the user override the test.
fb0103e5 3971else
af71363e
AS
3972 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3973 ac_dummy="$PATH"
3974 for ac_dir in $ac_dummy; do
3975 test -z "$ac_dir" && ac_dir=.
3976 if test -f $ac_dir/$ac_word; then
3977 ac_cv_prog_RUNTEST="$ac_prog"
3978 break
3979 fi
3980 done
3981 IFS="$ac_save_ifs"
2abefe3d
PB
3982fi
3983fi
af71363e 3984RUNTEST="$ac_cv_prog_RUNTEST"
2abefe3d 3985if test -n "$RUNTEST"; then
af71363e 3986 echo "$ac_t""$RUNTEST" 1>&6
2abefe3d 3987else
af71363e 3988 echo "$ac_t""no" 1>&6
2abefe3d 3989fi
671aa708 3990
af71363e 3991test -n "$RUNTEST" && break
2abefe3d
PB
3992done
3993test -n "$RUNTEST" || RUNTEST="runtest"
671aa708 3994
2abefe3d
PB
3995case " $configdirs " in
3996 *" dejagnu "*)
c394e891 3997 test $host = $build && RUNTEST='$$s/$(HOST_SUBDIR)/dejagnu/runtest'
2abefe3d
PB
3998 ;;
3999esac
671aa708
NN
4000
4001
671aa708 4002# Host tools.
ca9f4b81
AO
4003ncn_tool_prefix=
4004test -n "$host_alias" && ncn_tool_prefix=$host_alias-
4005ncn_target_tool_prefix=
4006test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
4007
2693c0b0
PB
4008 for ncn_progname in ar; do
4009 if test -n "$ncn_tool_prefix"; then
4010 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4011set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4012echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4013echo "configure:4014: checking for $ac_word" >&5
af71363e
AS
4014if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
4015 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4016else
4017 if test -n "$AR"; then
4018 ac_cv_prog_AR="$AR" # Let the user override the test.
4019else
af71363e
AS
4020 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4021 ac_dummy="$PATH"
4022 for ac_dir in $ac_dummy; do
4023 test -z "$ac_dir" && ac_dir=.
4024 if test -f $ac_dir/$ac_word; then
4025 ac_cv_prog_AR="${ncn_tool_prefix}${ncn_progname}"
4026 break
4027 fi
4028 done
4029 IFS="$ac_save_ifs"
ca9f4b81
AO
4030fi
4031fi
af71363e 4032AR="$ac_cv_prog_AR"
ca9f4b81 4033if test -n "$AR"; then
af71363e 4034 echo "$ac_t""$AR" 1>&6
ca9f4b81 4035else
af71363e 4036 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4037fi
4038
2693c0b0
PB
4039 fi
4040 if test -z "$ac_cv_prog_AR" && test $build = $host ; then
4041 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4042set dummy ${ncn_progname}; ac_word=$2
af71363e 4043echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4044echo "configure:4045: checking for $ac_word" >&5
af71363e
AS
4045if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
4046 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4047else
2693c0b0 4048 if test -n "$AR"; then
af71363e
AS
4049 ac_cv_prog_AR="$AR" # Let the user override the test.
4050else
4051 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4052 ac_dummy="$PATH"
4053 for ac_dir in $ac_dummy; do
4054 test -z "$ac_dir" && ac_dir=.
4055 if test -f $ac_dir/$ac_word; then
4056 ac_cv_prog_AR="${ncn_progname}"
4057 break
4058 fi
4059 done
4060 IFS="$ac_save_ifs"
ca9f4b81
AO
4061fi
4062fi
af71363e 4063AR="$ac_cv_prog_AR"
2693c0b0 4064if test -n "$AR"; then
af71363e 4065 echo "$ac_t""$AR" 1>&6
ca9f4b81 4066else
af71363e 4067 echo "$ac_t""no" 1>&6
ca9f4b81 4068fi
af71363e 4069
2693c0b0
PB
4070 fi
4071 test -n "$ac_cv_prog_AR" && break
4072done
4073
4074if test -z "$ac_cv_prog_AR" ; then
4075 set dummy ar
4076 if test $build = $host ; then
4077 AR="$2"
ca9f4b81 4078 else
2693c0b0 4079 AR="${ncn_tool_prefix}$2"
ca9f4b81 4080 fi
ca9f4b81
AO
4081fi
4082
2693c0b0
PB
4083 for ncn_progname in as; do
4084 if test -n "$ncn_tool_prefix"; then
4085 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4086set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4087echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4088echo "configure:4089: checking for $ac_word" >&5
af71363e
AS
4089if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
4090 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4091else
4092 if test -n "$AS"; then
4093 ac_cv_prog_AS="$AS" # Let the user override the test.
0b0dc272 4094else
af71363e
AS
4095 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4096 ac_dummy="$PATH"
4097 for ac_dir in $ac_dummy; do
4098 test -z "$ac_dir" && ac_dir=.
4099 if test -f $ac_dir/$ac_word; then
4100 ac_cv_prog_AS="${ncn_tool_prefix}${ncn_progname}"
4101 break
4102 fi
4103 done
4104 IFS="$ac_save_ifs"
ca9f4b81
AO
4105fi
4106fi
af71363e 4107AS="$ac_cv_prog_AS"
ca9f4b81 4108if test -n "$AS"; then
af71363e 4109 echo "$ac_t""$AS" 1>&6
ca9f4b81 4110else
af71363e 4111 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4112fi
4113
2693c0b0
PB
4114 fi
4115 if test -z "$ac_cv_prog_AS" && test $build = $host ; then
4116 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4117set dummy ${ncn_progname}; ac_word=$2
af71363e 4118echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4119echo "configure:4120: checking for $ac_word" >&5
af71363e
AS
4120if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
4121 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4122else
2693c0b0
PB
4123 if test -n "$AS"; then
4124 ac_cv_prog_AS="$AS" # Let the user override the test.
ca9f4b81 4125else
af71363e
AS
4126 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4127 ac_dummy="$PATH"
4128 for ac_dir in $ac_dummy; do
4129 test -z "$ac_dir" && ac_dir=.
4130 if test -f $ac_dir/$ac_word; then
4131 ac_cv_prog_AS="${ncn_progname}"
4132 break
4133 fi
4134 done
4135 IFS="$ac_save_ifs"
ca9f4b81
AO
4136fi
4137fi
af71363e 4138AS="$ac_cv_prog_AS"
2693c0b0 4139if test -n "$AS"; then
af71363e 4140 echo "$ac_t""$AS" 1>&6
ca9f4b81 4141else
af71363e 4142 echo "$ac_t""no" 1>&6
ca9f4b81 4143fi
af71363e 4144
2693c0b0
PB
4145 fi
4146 test -n "$ac_cv_prog_AS" && break
4147done
4148
4149if test -z "$ac_cv_prog_AS" ; then
4150 set dummy as
4151 if test $build = $host ; then
4152 AS="$2"
ca9f4b81 4153 else
2693c0b0 4154 AS="${ncn_tool_prefix}$2"
ca9f4b81 4155 fi
ca9f4b81
AO
4156fi
4157
2693c0b0
PB
4158 for ncn_progname in dlltool; do
4159 if test -n "$ncn_tool_prefix"; then
4160 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4161set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4162echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4163echo "configure:4164: checking for $ac_word" >&5
af71363e
AS
4164if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
4165 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4166else
4167 if test -n "$DLLTOOL"; then
4168 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
4169else
af71363e
AS
4170 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4171 ac_dummy="$PATH"
4172 for ac_dir in $ac_dummy; do
4173 test -z "$ac_dir" && ac_dir=.
4174 if test -f $ac_dir/$ac_word; then
4175 ac_cv_prog_DLLTOOL="${ncn_tool_prefix}${ncn_progname}"
4176 break
4177 fi
4178 done
4179 IFS="$ac_save_ifs"
ca9f4b81
AO
4180fi
4181fi
af71363e 4182DLLTOOL="$ac_cv_prog_DLLTOOL"
ca9f4b81 4183if test -n "$DLLTOOL"; then
af71363e 4184 echo "$ac_t""$DLLTOOL" 1>&6
ca9f4b81 4185else
af71363e 4186 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4187fi
4188
2693c0b0
PB
4189 fi
4190 if test -z "$ac_cv_prog_DLLTOOL" && test $build = $host ; then
4191 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4192set dummy ${ncn_progname}; ac_word=$2
af71363e 4193echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4194echo "configure:4195: checking for $ac_word" >&5
af71363e
AS
4195if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
4196 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4197else
2693c0b0
PB
4198 if test -n "$DLLTOOL"; then
4199 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
ca9f4b81 4200else
af71363e
AS
4201 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4202 ac_dummy="$PATH"
4203 for ac_dir in $ac_dummy; do
4204 test -z "$ac_dir" && ac_dir=.
4205 if test -f $ac_dir/$ac_word; then
4206 ac_cv_prog_DLLTOOL="${ncn_progname}"
4207 break
4208 fi
4209 done
4210 IFS="$ac_save_ifs"
ca9f4b81
AO
4211fi
4212fi
af71363e 4213DLLTOOL="$ac_cv_prog_DLLTOOL"
2693c0b0 4214if test -n "$DLLTOOL"; then
af71363e 4215 echo "$ac_t""$DLLTOOL" 1>&6
ca9f4b81 4216else
af71363e 4217 echo "$ac_t""no" 1>&6
ca9f4b81 4218fi
af71363e 4219
2693c0b0
PB
4220 fi
4221 test -n "$ac_cv_prog_DLLTOOL" && break
4222done
4223
4224if test -z "$ac_cv_prog_DLLTOOL" ; then
4225 set dummy dlltool
4226 if test $build = $host ; then
4227 DLLTOOL="$2"
ca9f4b81 4228 else
2693c0b0 4229 DLLTOOL="${ncn_tool_prefix}$2"
ca9f4b81 4230 fi
ca9f4b81
AO
4231fi
4232
2693c0b0
PB
4233 for ncn_progname in ld; do
4234 if test -n "$ncn_tool_prefix"; then
4235 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4236set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4237echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4238echo "configure:4239: checking for $ac_word" >&5
af71363e
AS
4239if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
4240 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4241else
4242 if test -n "$LD"; then
4243 ac_cv_prog_LD="$LD" # Let the user override the test.
4244else
af71363e
AS
4245 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4246 ac_dummy="$PATH"
4247 for ac_dir in $ac_dummy; do
4248 test -z "$ac_dir" && ac_dir=.
4249 if test -f $ac_dir/$ac_word; then
4250 ac_cv_prog_LD="${ncn_tool_prefix}${ncn_progname}"
4251 break
4252 fi
4253 done
4254 IFS="$ac_save_ifs"
ca9f4b81
AO
4255fi
4256fi
af71363e 4257LD="$ac_cv_prog_LD"
ca9f4b81 4258if test -n "$LD"; then
af71363e 4259 echo "$ac_t""$LD" 1>&6
ca9f4b81 4260else
af71363e 4261 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4262fi
4263
2693c0b0
PB
4264 fi
4265 if test -z "$ac_cv_prog_LD" && test $build = $host ; then
4266 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4267set dummy ${ncn_progname}; ac_word=$2
af71363e 4268echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4269echo "configure:4270: checking for $ac_word" >&5
af71363e
AS
4270if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
4271 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4272else
2693c0b0
PB
4273 if test -n "$LD"; then
4274 ac_cv_prog_LD="$LD" # Let the user override the test.
6b65a26d 4275else
af71363e
AS
4276 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4277 ac_dummy="$PATH"
4278 for ac_dir in $ac_dummy; do
4279 test -z "$ac_dir" && ac_dir=.
4280 if test -f $ac_dir/$ac_word; then
4281 ac_cv_prog_LD="${ncn_progname}"
4282 break
4283 fi
4284 done
4285 IFS="$ac_save_ifs"
ca9f4b81
AO
4286fi
4287fi
af71363e 4288LD="$ac_cv_prog_LD"
2693c0b0 4289if test -n "$LD"; then
af71363e 4290 echo "$ac_t""$LD" 1>&6
ca9f4b81 4291else
af71363e 4292 echo "$ac_t""no" 1>&6
ca9f4b81 4293fi
af71363e 4294
2693c0b0
PB
4295 fi
4296 test -n "$ac_cv_prog_LD" && break
4297done
4298
4299if test -z "$ac_cv_prog_LD" ; then
4300 set dummy ld
4301 if test $build = $host ; then
4302 LD="$2"
ca9f4b81 4303 else
2693c0b0 4304 LD="${ncn_tool_prefix}$2"
ca9f4b81 4305 fi
ca9f4b81
AO
4306fi
4307
2abefe3d
PB
4308 for ncn_progname in lipo; do
4309 if test -n "$ncn_tool_prefix"; then
4310 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4311set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4312echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4313echo "configure:4314: checking for $ac_word" >&5
af71363e
AS
4314if eval "test \"`echo '$''{'ac_cv_prog_LIPO'+set}'`\" = set"; then
4315 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4316else
4317 if test -n "$LIPO"; then
4318 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
4319else
af71363e
AS
4320 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4321 ac_dummy="$PATH"
4322 for ac_dir in $ac_dummy; do
4323 test -z "$ac_dir" && ac_dir=.
4324 if test -f $ac_dir/$ac_word; then
4325 ac_cv_prog_LIPO="${ncn_tool_prefix}${ncn_progname}"
4326 break
4327 fi
4328 done
4329 IFS="$ac_save_ifs"
2abefe3d
PB
4330fi
4331fi
af71363e 4332LIPO="$ac_cv_prog_LIPO"
2abefe3d 4333if test -n "$LIPO"; then
af71363e 4334 echo "$ac_t""$LIPO" 1>&6
2abefe3d 4335else
af71363e 4336 echo "$ac_t""no" 1>&6
2abefe3d
PB
4337fi
4338
4339 fi
4340 if test -z "$ac_cv_prog_LIPO" && test $build = $host ; then
4341 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4342set dummy ${ncn_progname}; ac_word=$2
af71363e 4343echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4344echo "configure:4345: checking for $ac_word" >&5
af71363e
AS
4345if eval "test \"`echo '$''{'ac_cv_prog_LIPO'+set}'`\" = set"; then
4346 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4347else
4348 if test -n "$LIPO"; then
4349 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
4350else
af71363e
AS
4351 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4352 ac_dummy="$PATH"
4353 for ac_dir in $ac_dummy; do
4354 test -z "$ac_dir" && ac_dir=.
4355 if test -f $ac_dir/$ac_word; then
4356 ac_cv_prog_LIPO="${ncn_progname}"
4357 break
4358 fi
4359 done
4360 IFS="$ac_save_ifs"
2abefe3d
PB
4361fi
4362fi
af71363e 4363LIPO="$ac_cv_prog_LIPO"
2abefe3d 4364if test -n "$LIPO"; then
af71363e 4365 echo "$ac_t""$LIPO" 1>&6
2abefe3d 4366else
af71363e 4367 echo "$ac_t""no" 1>&6
2abefe3d 4368fi
af71363e 4369
2abefe3d
PB
4370 fi
4371 test -n "$ac_cv_prog_LIPO" && break
4372done
4373
4374if test -z "$ac_cv_prog_LIPO" ; then
4375 set dummy lipo
4376 if test $build = $host ; then
4377 LIPO="$2"
4378 else
4379 LIPO="${ncn_tool_prefix}$2"
4380 fi
4381fi
4382
2693c0b0
PB
4383 for ncn_progname in nm; do
4384 if test -n "$ncn_tool_prefix"; then
4385 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4386set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4387echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4388echo "configure:4389: checking for $ac_word" >&5
af71363e
AS
4389if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
4390 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4391else
4392 if test -n "$NM"; then
4393 ac_cv_prog_NM="$NM" # Let the user override the test.
4394else
af71363e
AS
4395 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4396 ac_dummy="$PATH"
4397 for ac_dir in $ac_dummy; do
4398 test -z "$ac_dir" && ac_dir=.
4399 if test -f $ac_dir/$ac_word; then
4400 ac_cv_prog_NM="${ncn_tool_prefix}${ncn_progname}"
4401 break
4402 fi
4403 done
4404 IFS="$ac_save_ifs"
ca9f4b81
AO
4405fi
4406fi
af71363e 4407NM="$ac_cv_prog_NM"
ca9f4b81 4408if test -n "$NM"; then
af71363e 4409 echo "$ac_t""$NM" 1>&6
ca9f4b81 4410else
af71363e 4411 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4412fi
4413
2693c0b0
PB
4414 fi
4415 if test -z "$ac_cv_prog_NM" && test $build = $host ; then
4416 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4417set dummy ${ncn_progname}; ac_word=$2
af71363e 4418echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4419echo "configure:4420: checking for $ac_word" >&5
af71363e
AS
4420if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
4421 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4422else
2693c0b0
PB
4423 if test -n "$NM"; then
4424 ac_cv_prog_NM="$NM" # Let the user override the test.
ca9f4b81 4425else
af71363e
AS
4426 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4427 ac_dummy="$PATH"
4428 for ac_dir in $ac_dummy; do
4429 test -z "$ac_dir" && ac_dir=.
4430 if test -f $ac_dir/$ac_word; then
4431 ac_cv_prog_NM="${ncn_progname}"
4432 break
4433 fi
4434 done
4435 IFS="$ac_save_ifs"
ca9f4b81
AO
4436fi
4437fi
af71363e 4438NM="$ac_cv_prog_NM"
2693c0b0 4439if test -n "$NM"; then
af71363e 4440 echo "$ac_t""$NM" 1>&6
ca9f4b81 4441else
af71363e 4442 echo "$ac_t""no" 1>&6
ca9f4b81 4443fi
af71363e 4444
2693c0b0
PB
4445 fi
4446 test -n "$ac_cv_prog_NM" && break
4447done
4448
4449if test -z "$ac_cv_prog_NM" ; then
4450 set dummy nm
4451 if test $build = $host ; then
4452 NM="$2"
ca9f4b81 4453 else
2693c0b0 4454 NM="${ncn_tool_prefix}$2"
ca9f4b81 4455 fi
ca9f4b81
AO
4456fi
4457
2693c0b0
PB
4458 for ncn_progname in ranlib; do
4459 if test -n "$ncn_tool_prefix"; then
4460 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4461set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4462echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4463echo "configure:4464: checking for $ac_word" >&5
af71363e
AS
4464if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
4465 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4466else
4467 if test -n "$RANLIB"; then
4468 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4469else
af71363e
AS
4470 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4471 ac_dummy="$PATH"
4472 for ac_dir in $ac_dummy; do
4473 test -z "$ac_dir" && ac_dir=.
4474 if test -f $ac_dir/$ac_word; then
4475 ac_cv_prog_RANLIB="${ncn_tool_prefix}${ncn_progname}"
4476 break
4477 fi
4478 done
4479 IFS="$ac_save_ifs"
ca9f4b81
AO
4480fi
4481fi
af71363e 4482RANLIB="$ac_cv_prog_RANLIB"
ca9f4b81 4483if test -n "$RANLIB"; then
af71363e 4484 echo "$ac_t""$RANLIB" 1>&6
ca9f4b81 4485else
af71363e 4486 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4487fi
4488
2693c0b0
PB
4489 fi
4490 if test -z "$ac_cv_prog_RANLIB" && test $build = $host ; then
4491 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4492set dummy ${ncn_progname}; ac_word=$2
af71363e 4493echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4494echo "configure:4495: checking for $ac_word" >&5
af71363e
AS
4495if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
4496 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4497else
2693c0b0
PB
4498 if test -n "$RANLIB"; then
4499 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
ca9f4b81 4500else
af71363e
AS
4501 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4502 ac_dummy="$PATH"
4503 for ac_dir in $ac_dummy; do
4504 test -z "$ac_dir" && ac_dir=.
4505 if test -f $ac_dir/$ac_word; then
4506 ac_cv_prog_RANLIB="${ncn_progname}"
4507 break
4508 fi
4509 done
4510 IFS="$ac_save_ifs"
ca9f4b81
AO
4511fi
4512fi
af71363e 4513RANLIB="$ac_cv_prog_RANLIB"
2693c0b0 4514if test -n "$RANLIB"; then
af71363e 4515 echo "$ac_t""$RANLIB" 1>&6
ca9f4b81 4516else
af71363e 4517 echo "$ac_t""no" 1>&6
ca9f4b81 4518fi
af71363e 4519
ca9f4b81 4520 fi
2693c0b0
PB
4521 test -n "$ac_cv_prog_RANLIB" && break
4522done
4523
4524if test -z "$ac_cv_prog_RANLIB" ; then
4525 RANLIB=":"
ca9f4b81
AO
4526fi
4527
2abefe3d
PB
4528 for ncn_progname in strip; do
4529 if test -n "$ncn_tool_prefix"; then
4530 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4531set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4532echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4533echo "configure:4534: checking for $ac_word" >&5
af71363e
AS
4534if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
4535 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4536else
4537 if test -n "$STRIP"; then
4538 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4539else
af71363e
AS
4540 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4541 ac_dummy="$PATH"
4542 for ac_dir in $ac_dummy; do
4543 test -z "$ac_dir" && ac_dir=.
4544 if test -f $ac_dir/$ac_word; then
4545 ac_cv_prog_STRIP="${ncn_tool_prefix}${ncn_progname}"
4546 break
4547 fi
4548 done
4549 IFS="$ac_save_ifs"
2abefe3d
PB
4550fi
4551fi
af71363e 4552STRIP="$ac_cv_prog_STRIP"
2abefe3d 4553if test -n "$STRIP"; then
af71363e 4554 echo "$ac_t""$STRIP" 1>&6
2abefe3d 4555else
af71363e 4556 echo "$ac_t""no" 1>&6
2abefe3d
PB
4557fi
4558
4559 fi
4560 if test -z "$ac_cv_prog_STRIP" && test $build = $host ; then
4561 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4562set dummy ${ncn_progname}; ac_word=$2
af71363e 4563echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4564echo "configure:4565: checking for $ac_word" >&5
af71363e
AS
4565if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
4566 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4567else
4568 if test -n "$STRIP"; then
4569 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4570else
af71363e
AS
4571 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4572 ac_dummy="$PATH"
4573 for ac_dir in $ac_dummy; do
4574 test -z "$ac_dir" && ac_dir=.
4575 if test -f $ac_dir/$ac_word; then
4576 ac_cv_prog_STRIP="${ncn_progname}"
4577 break
4578 fi
4579 done
4580 IFS="$ac_save_ifs"
2abefe3d
PB
4581fi
4582fi
af71363e 4583STRIP="$ac_cv_prog_STRIP"
2abefe3d 4584if test -n "$STRIP"; then
af71363e 4585 echo "$ac_t""$STRIP" 1>&6
2abefe3d 4586else
af71363e 4587 echo "$ac_t""no" 1>&6
2abefe3d 4588fi
af71363e 4589
2abefe3d
PB
4590 fi
4591 test -n "$ac_cv_prog_STRIP" && break
4592done
4593
4594if test -z "$ac_cv_prog_STRIP" ; then
4595 STRIP=":"
4596fi
4597
2693c0b0
PB
4598 for ncn_progname in windres; do
4599 if test -n "$ncn_tool_prefix"; then
4600 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4601set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4602echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4603echo "configure:4604: checking for $ac_word" >&5
af71363e
AS
4604if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
4605 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4606else
4607 if test -n "$WINDRES"; then
4608 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
4609else
af71363e
AS
4610 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4611 ac_dummy="$PATH"
4612 for ac_dir in $ac_dummy; do
4613 test -z "$ac_dir" && ac_dir=.
4614 if test -f $ac_dir/$ac_word; then
4615 ac_cv_prog_WINDRES="${ncn_tool_prefix}${ncn_progname}"
4616 break
4617 fi
4618 done
4619 IFS="$ac_save_ifs"
ca9f4b81
AO
4620fi
4621fi
af71363e 4622WINDRES="$ac_cv_prog_WINDRES"
ca9f4b81 4623if test -n "$WINDRES"; then
af71363e 4624 echo "$ac_t""$WINDRES" 1>&6
ca9f4b81 4625else
af71363e 4626 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4627fi
4628
2693c0b0
PB
4629 fi
4630 if test -z "$ac_cv_prog_WINDRES" && test $build = $host ; then
4631 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4632set dummy ${ncn_progname}; ac_word=$2
af71363e 4633echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4634echo "configure:4635: checking for $ac_word" >&5
af71363e
AS
4635if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
4636 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4637else
2693c0b0
PB
4638 if test -n "$WINDRES"; then
4639 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
ca9f4b81 4640else
af71363e
AS
4641 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4642 ac_dummy="$PATH"
4643 for ac_dir in $ac_dummy; do
4644 test -z "$ac_dir" && ac_dir=.
4645 if test -f $ac_dir/$ac_word; then
4646 ac_cv_prog_WINDRES="${ncn_progname}"
4647 break
4648 fi
4649 done
4650 IFS="$ac_save_ifs"
ca9f4b81
AO
4651fi
4652fi
af71363e 4653WINDRES="$ac_cv_prog_WINDRES"
2693c0b0 4654if test -n "$WINDRES"; then
af71363e 4655 echo "$ac_t""$WINDRES" 1>&6
ca9f4b81 4656else
af71363e 4657 echo "$ac_t""no" 1>&6
ca9f4b81 4658fi
af71363e 4659
2693c0b0
PB
4660 fi
4661 test -n "$ac_cv_prog_WINDRES" && break
4662done
4663
4664if test -z "$ac_cv_prog_WINDRES" ; then
4665 set dummy windres
4666 if test $build = $host ; then
4667 WINDRES="$2"
ca9f4b81 4668 else
2693c0b0 4669 WINDRES="${ncn_tool_prefix}$2"
ca9f4b81 4670 fi
ca9f4b81
AO
4671fi
4672
2693c0b0
PB
4673 for ncn_progname in objcopy; do
4674 if test -n "$ncn_tool_prefix"; then
4675 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4676set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4677echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4678echo "configure:4679: checking for $ac_word" >&5
af71363e
AS
4679if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
4680 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4681else
4682 if test -n "$OBJCOPY"; then
4683 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
4684else
af71363e
AS
4685 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4686 ac_dummy="$PATH"
4687 for ac_dir in $ac_dummy; do
4688 test -z "$ac_dir" && ac_dir=.
4689 if test -f $ac_dir/$ac_word; then
4690 ac_cv_prog_OBJCOPY="${ncn_tool_prefix}${ncn_progname}"
4691 break
4692 fi
4693 done
4694 IFS="$ac_save_ifs"
ca9f4b81
AO
4695fi
4696fi
af71363e 4697OBJCOPY="$ac_cv_prog_OBJCOPY"
ca9f4b81 4698if test -n "$OBJCOPY"; then
af71363e 4699 echo "$ac_t""$OBJCOPY" 1>&6
ca9f4b81 4700else
af71363e 4701 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4702fi
4703
2693c0b0
PB
4704 fi
4705 if test -z "$ac_cv_prog_OBJCOPY" && test $build = $host ; then
4706 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4707set dummy ${ncn_progname}; ac_word=$2
af71363e 4708echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4709echo "configure:4710: checking for $ac_word" >&5
af71363e
AS
4710if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
4711 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4712else
2693c0b0
PB
4713 if test -n "$OBJCOPY"; then
4714 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
ca9f4b81 4715else
af71363e
AS
4716 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4717 ac_dummy="$PATH"
4718 for ac_dir in $ac_dummy; do
4719 test -z "$ac_dir" && ac_dir=.
4720 if test -f $ac_dir/$ac_word; then
4721 ac_cv_prog_OBJCOPY="${ncn_progname}"
4722 break
4723 fi
4724 done
4725 IFS="$ac_save_ifs"
ca9f4b81
AO
4726fi
4727fi
af71363e 4728OBJCOPY="$ac_cv_prog_OBJCOPY"
2693c0b0 4729if test -n "$OBJCOPY"; then
af71363e 4730 echo "$ac_t""$OBJCOPY" 1>&6
ca9f4b81 4731else
af71363e 4732 echo "$ac_t""no" 1>&6
ca9f4b81 4733fi
af71363e 4734
2693c0b0
PB
4735 fi
4736 test -n "$ac_cv_prog_OBJCOPY" && break
4737done
4738
4739if test -z "$ac_cv_prog_OBJCOPY" ; then
4740 set dummy objcopy
4741 if test $build = $host ; then
4742 OBJCOPY="$2"
ca9f4b81 4743 else
2693c0b0 4744 OBJCOPY="${ncn_tool_prefix}$2"
ca9f4b81 4745 fi
ca9f4b81
AO
4746fi
4747
2693c0b0
PB
4748 for ncn_progname in objdump; do
4749 if test -n "$ncn_tool_prefix"; then
4750 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4751set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4752echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4753echo "configure:4754: checking for $ac_word" >&5
af71363e
AS
4754if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
4755 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4756else
4757 if test -n "$OBJDUMP"; then
4758 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
4759else
af71363e
AS
4760 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4761 ac_dummy="$PATH"
4762 for ac_dir in $ac_dummy; do
4763 test -z "$ac_dir" && ac_dir=.
4764 if test -f $ac_dir/$ac_word; then
4765 ac_cv_prog_OBJDUMP="${ncn_tool_prefix}${ncn_progname}"
4766 break
4767 fi
4768 done
4769 IFS="$ac_save_ifs"
ca9f4b81
AO
4770fi
4771fi
af71363e 4772OBJDUMP="$ac_cv_prog_OBJDUMP"
ca9f4b81 4773if test -n "$OBJDUMP"; then
af71363e 4774 echo "$ac_t""$OBJDUMP" 1>&6
ca9f4b81 4775else
af71363e 4776 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4777fi
4778
2693c0b0
PB
4779 fi
4780 if test -z "$ac_cv_prog_OBJDUMP" && test $build = $host ; then
4781 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4782set dummy ${ncn_progname}; ac_word=$2
af71363e 4783echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4784echo "configure:4785: checking for $ac_word" >&5
af71363e
AS
4785if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
4786 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4787else
2693c0b0
PB
4788 if test -n "$OBJDUMP"; then
4789 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
ca9f4b81 4790else
af71363e
AS
4791 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4792 ac_dummy="$PATH"
4793 for ac_dir in $ac_dummy; do
4794 test -z "$ac_dir" && ac_dir=.
4795 if test -f $ac_dir/$ac_word; then
4796 ac_cv_prog_OBJDUMP="${ncn_progname}"
4797 break
4798 fi
4799 done
4800 IFS="$ac_save_ifs"
ca9f4b81
AO
4801fi
4802fi
af71363e 4803OBJDUMP="$ac_cv_prog_OBJDUMP"
2693c0b0 4804if test -n "$OBJDUMP"; then
af71363e 4805 echo "$ac_t""$OBJDUMP" 1>&6
ca9f4b81 4806else
af71363e 4807 echo "$ac_t""no" 1>&6
ca9f4b81 4808fi
af71363e 4809
2693c0b0
PB
4810 fi
4811 test -n "$ac_cv_prog_OBJDUMP" && break
4812done
4813
4814if test -z "$ac_cv_prog_OBJDUMP" ; then
4815 set dummy objdump
4816 if test $build = $host ; then
4817 OBJDUMP="$2"
ca9f4b81 4818 else
2693c0b0 4819 OBJDUMP="${ncn_tool_prefix}$2"
ca9f4b81 4820 fi
ca9f4b81
AO
4821fi
4822
671aa708
NN
4823
4824
4825
4826
4827
4828
2abefe3d 4829# Target tools.
e8b05380
PB
4830# Check whether --with-build-time-tools or --without-build-time-tools was given.
4831if test "${with_build_time_tools+set}" = set; then
4832 withval="$with_build_time_tools"
4833 case x"$withval" in
4834 x/*) ;;
4835 *)
4836 with_build_time_tools=
af71363e 4837 echo "configure: warning: argument to --with-build-time-tools must be an absolute path" 1>&2
e8b05380
PB
4838 ;;
4839 esac
ca9f4b81 4840else
e8b05380 4841 with_build_time_tools=
af71363e
AS
4842fi
4843
ca9f4b81 4844
e8b05380
PB
4845 if test -n "$with_build_time_tools"; then
4846 for ncn_progname in cc gcc; do
af71363e 4847 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 4848echo "configure:4849: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
4849 if test -x $with_build_time_tools/${ncn_progname}; then
4850 ac_cv_prog_CC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 4851 echo "$ac_t""yes" 1>&6
72a7ab82 4852 break
e8b05380 4853 else
af71363e 4854 echo "$ac_t""no" 1>&6
72a7ab82
AP
4855 fi
4856 done
4de997d1
PB
4857fi
4858
e8b05380
PB
4859if test -z "$ac_cv_prog_CC_FOR_TARGET"; then
4860 for ncn_progname in cc gcc; do
4861 if test -n "$ncn_target_tool_prefix"; then
4862 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 4863set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4864echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4865echo "configure:4866: checking for $ac_word" >&5
af71363e
AS
4866if eval "test \"`echo '$''{'ac_cv_prog_CC_FOR_TARGET'+set}'`\" = set"; then
4867 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1
PB
4868else
4869 if test -n "$CC_FOR_TARGET"; then
4870 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4871else
af71363e
AS
4872 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4873 ac_dummy="$PATH"
4874 for ac_dir in $ac_dummy; do
4875 test -z "$ac_dir" && ac_dir=.
4876 if test -f $ac_dir/$ac_word; then
4877 ac_cv_prog_CC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4878 break
4879 fi
4880 done
4881 IFS="$ac_save_ifs"
4de997d1
PB
4882fi
4883fi
af71363e 4884CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
4de997d1 4885if test -n "$CC_FOR_TARGET"; then
af71363e 4886 echo "$ac_t""$CC_FOR_TARGET" 1>&6
4de997d1 4887else
af71363e 4888 echo "$ac_t""no" 1>&6
4de997d1
PB
4889fi
4890
e8b05380
PB
4891 fi
4892 if test -z "$ac_cv_prog_CC_FOR_TARGET" && test $build = $target ; then
4893 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 4894set dummy ${ncn_progname}; ac_word=$2
af71363e 4895echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4896echo "configure:4897: checking for $ac_word" >&5
af71363e
AS
4897if eval "test \"`echo '$''{'ac_cv_prog_CC_FOR_TARGET'+set}'`\" = set"; then
4898 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 4899else
2693c0b0
PB
4900 if test -n "$CC_FOR_TARGET"; then
4901 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4de997d1 4902else
af71363e
AS
4903 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4904 ac_dummy="$PATH"
4905 for ac_dir in $ac_dummy; do
4906 test -z "$ac_dir" && ac_dir=.
4907 if test -f $ac_dir/$ac_word; then
4908 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
4909 break
4910 fi
4911 done
4912 IFS="$ac_save_ifs"
4de997d1
PB
4913fi
4914fi
af71363e 4915CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
2693c0b0 4916if test -n "$CC_FOR_TARGET"; then
af71363e 4917 echo "$ac_t""$CC_FOR_TARGET" 1>&6
4de997d1 4918else
af71363e 4919 echo "$ac_t""no" 1>&6
4de997d1 4920fi
af71363e 4921
e8b05380
PB
4922 fi
4923 test -n "$ac_cv_prog_CC_FOR_TARGET" && break
4924 done
4925fi
af71363e 4926
2693c0b0
PB
4927if test -z "$ac_cv_prog_CC_FOR_TARGET" ; then
4928 set dummy cc gcc
4929 if test $build = $target ; then
4930 CC_FOR_TARGET="$2"
4de997d1 4931 else
2693c0b0 4932 CC_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 4933 fi
4de997d1
PB
4934fi
4935
e8b05380
PB
4936 if test -n "$with_build_time_tools"; then
4937 for ncn_progname in c++ g++ cxx gxx; do
af71363e 4938 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 4939echo "configure:4940: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
4940 if test -x $with_build_time_tools/${ncn_progname}; then
4941 ac_cv_prog_CXX_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 4942 echo "$ac_t""yes" 1>&6
e8b05380
PB
4943 break
4944 else
af71363e 4945 echo "$ac_t""no" 1>&6
e8b05380
PB
4946 fi
4947 done
4948fi
4949
4950if test -z "$ac_cv_prog_CXX_FOR_TARGET"; then
4951 for ncn_progname in c++ g++ cxx gxx; do
4952 if test -n "$ncn_target_tool_prefix"; then
4953 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 4954set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4955echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4956echo "configure:4957: checking for $ac_word" >&5
af71363e
AS
4957if eval "test \"`echo '$''{'ac_cv_prog_CXX_FOR_TARGET'+set}'`\" = set"; then
4958 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1
PB
4959else
4960 if test -n "$CXX_FOR_TARGET"; then
4961 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4962else
af71363e
AS
4963 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4964 ac_dummy="$PATH"
4965 for ac_dir in $ac_dummy; do
4966 test -z "$ac_dir" && ac_dir=.
4967 if test -f $ac_dir/$ac_word; then
4968 ac_cv_prog_CXX_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4969 break
4970 fi
4971 done
4972 IFS="$ac_save_ifs"
4de997d1
PB
4973fi
4974fi
af71363e 4975CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
4de997d1 4976if test -n "$CXX_FOR_TARGET"; then
af71363e 4977 echo "$ac_t""$CXX_FOR_TARGET" 1>&6
4de997d1 4978else
af71363e 4979 echo "$ac_t""no" 1>&6
4de997d1
PB
4980fi
4981
e8b05380
PB
4982 fi
4983 if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test $build = $target ; then
4984 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 4985set dummy ${ncn_progname}; ac_word=$2
af71363e 4986echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 4987echo "configure:4988: checking for $ac_word" >&5
af71363e
AS
4988if eval "test \"`echo '$''{'ac_cv_prog_CXX_FOR_TARGET'+set}'`\" = set"; then
4989 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 4990else
2693c0b0
PB
4991 if test -n "$CXX_FOR_TARGET"; then
4992 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4de997d1 4993else
af71363e
AS
4994 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4995 ac_dummy="$PATH"
4996 for ac_dir in $ac_dummy; do
4997 test -z "$ac_dir" && ac_dir=.
4998 if test -f $ac_dir/$ac_word; then
4999 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
5000 break
5001 fi
5002 done
5003 IFS="$ac_save_ifs"
4de997d1
PB
5004fi
5005fi
af71363e 5006CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
2693c0b0 5007if test -n "$CXX_FOR_TARGET"; then
af71363e 5008 echo "$ac_t""$CXX_FOR_TARGET" 1>&6
4de997d1 5009else
af71363e 5010 echo "$ac_t""no" 1>&6
4de997d1 5011fi
af71363e 5012
e8b05380
PB
5013 fi
5014 test -n "$ac_cv_prog_CXX_FOR_TARGET" && break
5015 done
5016fi
af71363e 5017
2693c0b0
PB
5018if test -z "$ac_cv_prog_CXX_FOR_TARGET" ; then
5019 set dummy c++ g++ cxx gxx
5020 if test $build = $target ; then
5021 CXX_FOR_TARGET="$2"
4de997d1 5022 else
2693c0b0 5023 CXX_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 5024 fi
ca9f4b81
AO
5025fi
5026
e8b05380
PB
5027 if test -n "$with_build_time_tools"; then
5028 for ncn_progname in gcc; do
af71363e 5029 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5030echo "configure:5031: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5031 if test -x $with_build_time_tools/${ncn_progname}; then
5032 ac_cv_prog_GCC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5033 echo "$ac_t""yes" 1>&6
e8b05380
PB
5034 break
5035 else
af71363e 5036 echo "$ac_t""no" 1>&6
e8b05380
PB
5037 fi
5038 done
5039fi
5040
5041if test -z "$ac_cv_prog_GCC_FOR_TARGET"; then
5042 for ncn_progname in gcc; do
5043 if test -n "$ncn_target_tool_prefix"; then
5044 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 5045set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5046echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5047echo "configure:5048: checking for $ac_word" >&5
af71363e
AS
5048if eval "test \"`echo '$''{'ac_cv_prog_GCC_FOR_TARGET'+set}'`\" = set"; then
5049 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5050else
e8b05380
PB
5051 if test -n "$GCC_FOR_TARGET"; then
5052 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 5053else
af71363e
AS
5054 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5055 ac_dummy="$PATH"
5056 for ac_dir in $ac_dummy; do
5057 test -z "$ac_dir" && ac_dir=.
5058 if test -f $ac_dir/$ac_word; then
5059 ac_cv_prog_GCC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5060 break
5061 fi
5062 done
5063 IFS="$ac_save_ifs"
ca9f4b81
AO
5064fi
5065fi
af71363e 5066GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
e8b05380 5067if test -n "$GCC_FOR_TARGET"; then
af71363e 5068 echo "$ac_t""$GCC_FOR_TARGET" 1>&6
ca9f4b81 5069else
af71363e 5070 echo "$ac_t""no" 1>&6
ca9f4b81
AO
5071fi
5072
e8b05380
PB
5073 fi
5074 if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test $build = $target ; then
5075 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 5076set dummy ${ncn_progname}; ac_word=$2
af71363e 5077echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5078echo "configure:5079: checking for $ac_word" >&5
af71363e
AS
5079if eval "test \"`echo '$''{'ac_cv_prog_GCC_FOR_TARGET'+set}'`\" = set"; then
5080 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5081else
e8b05380
PB
5082 if test -n "$GCC_FOR_TARGET"; then
5083 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 5084else
af71363e
AS
5085 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5086 ac_dummy="$PATH"
5087 for ac_dir in $ac_dummy; do
5088 test -z "$ac_dir" && ac_dir=.
5089 if test -f $ac_dir/$ac_word; then
5090 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
5091 break
5092 fi
5093 done
5094 IFS="$ac_save_ifs"
ca9f4b81
AO
5095fi
5096fi
af71363e 5097GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
e8b05380 5098if test -n "$GCC_FOR_TARGET"; then
af71363e 5099 echo "$ac_t""$GCC_FOR_TARGET" 1>&6
ca9f4b81 5100else
af71363e 5101 echo "$ac_t""no" 1>&6
ca9f4b81 5102fi
af71363e 5103
e8b05380
PB
5104 fi
5105 test -n "$ac_cv_prog_GCC_FOR_TARGET" && break
5106 done
5107fi
af71363e 5108
e8b05380
PB
5109if test -z "$ac_cv_prog_GCC_FOR_TARGET" ; then
5110 GCC_FOR_TARGET="${CC_FOR_TARGET}"
5111fi
5112
5113 if test -n "$with_build_time_tools"; then
5114 for ncn_progname in gcj; do
af71363e 5115 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5116echo "configure:5117: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5117 if test -x $with_build_time_tools/${ncn_progname}; then
5118 ac_cv_prog_GCJ_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5119 echo "$ac_t""yes" 1>&6
e8b05380
PB
5120 break
5121 else
af71363e 5122 echo "$ac_t""no" 1>&6
e8b05380
PB
5123 fi
5124 done
5125fi
5126
5127if test -z "$ac_cv_prog_GCJ_FOR_TARGET"; then
5128 for ncn_progname in gcj; do
5129 if test -n "$ncn_target_tool_prefix"; then
5130 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5131set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5132echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5133echo "configure:5134: checking for $ac_word" >&5
af71363e
AS
5134if eval "test \"`echo '$''{'ac_cv_prog_GCJ_FOR_TARGET'+set}'`\" = set"; then
5135 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5136else
fb0103e5
RG
5137 if test -n "$GCJ_FOR_TARGET"; then
5138 ac_cv_prog_GCJ_FOR_TARGET="$GCJ_FOR_TARGET" # Let the user override the test.
5139else
af71363e
AS
5140 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5141 ac_dummy="$PATH"
5142 for ac_dir in $ac_dummy; do
5143 test -z "$ac_dir" && ac_dir=.
5144 if test -f $ac_dir/$ac_word; then
5145 ac_cv_prog_GCJ_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5146 break
5147 fi
5148 done
5149 IFS="$ac_save_ifs"
e8b05380
PB
5150fi
5151fi
af71363e 5152GCJ_FOR_TARGET="$ac_cv_prog_GCJ_FOR_TARGET"
e8b05380 5153if test -n "$GCJ_FOR_TARGET"; then
af71363e 5154 echo "$ac_t""$GCJ_FOR_TARGET" 1>&6
e8b05380 5155else
af71363e 5156 echo "$ac_t""no" 1>&6
e8b05380
PB
5157fi
5158
5159 fi
5160 if test -z "$ac_cv_prog_GCJ_FOR_TARGET" && test $build = $target ; then
5161 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5162set dummy ${ncn_progname}; ac_word=$2
af71363e 5163echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5164echo "configure:5165: checking for $ac_word" >&5
af71363e
AS
5165if eval "test \"`echo '$''{'ac_cv_prog_GCJ_FOR_TARGET'+set}'`\" = set"; then
5166 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5167else
5168 if test -n "$GCJ_FOR_TARGET"; then
5169 ac_cv_prog_GCJ_FOR_TARGET="$GCJ_FOR_TARGET" # Let the user override the test.
5170else
af71363e
AS
5171 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5172 ac_dummy="$PATH"
5173 for ac_dir in $ac_dummy; do
5174 test -z "$ac_dir" && ac_dir=.
5175 if test -f $ac_dir/$ac_word; then
5176 ac_cv_prog_GCJ_FOR_TARGET="${ncn_progname}"
5177 break
5178 fi
5179 done
5180 IFS="$ac_save_ifs"
e8b05380
PB
5181fi
5182fi
af71363e 5183GCJ_FOR_TARGET="$ac_cv_prog_GCJ_FOR_TARGET"
e8b05380 5184if test -n "$GCJ_FOR_TARGET"; then
af71363e 5185 echo "$ac_t""$GCJ_FOR_TARGET" 1>&6
e8b05380 5186else
af71363e 5187 echo "$ac_t""no" 1>&6
e8b05380 5188fi
af71363e 5189
e8b05380
PB
5190 fi
5191 test -n "$ac_cv_prog_GCJ_FOR_TARGET" && break
5192 done
5193fi
af71363e 5194
e8b05380
PB
5195if test -z "$ac_cv_prog_GCJ_FOR_TARGET" ; then
5196 set dummy gcj
5197 if test $build = $target ; then
5198 GCJ_FOR_TARGET="$2"
5199 else
5200 GCJ_FOR_TARGET="${ncn_target_tool_prefix}$2"
2693c0b0 5201 fi
e8b05380 5202fi
2693c0b0 5203
e8b05380
PB
5204 if test -n "$with_build_time_tools"; then
5205 for ncn_progname in gfortran; do
af71363e 5206 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5207echo "configure:5208: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5208 if test -x $with_build_time_tools/${ncn_progname}; then
5209 ac_cv_prog_GFORTRAN_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5210 echo "$ac_t""yes" 1>&6
e8b05380
PB
5211 break
5212 else
af71363e 5213 echo "$ac_t""no" 1>&6
e8b05380
PB
5214 fi
5215 done
5216fi
5217
5218if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
5219 for ncn_progname in gfortran; do
5220 if test -n "$ncn_target_tool_prefix"; then
5221 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5222set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5223echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5224echo "configure:5225: checking for $ac_word" >&5
af71363e
AS
5225if eval "test \"`echo '$''{'ac_cv_prog_GFORTRAN_FOR_TARGET'+set}'`\" = set"; then
5226 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5227else
5228 if test -n "$GFORTRAN_FOR_TARGET"; then
5229 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
5230else
af71363e
AS
5231 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5232 ac_dummy="$PATH"
5233 for ac_dir in $ac_dummy; do
5234 test -z "$ac_dir" && ac_dir=.
5235 if test -f $ac_dir/$ac_word; then
5236 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5237 break
5238 fi
5239 done
5240 IFS="$ac_save_ifs"
e8b05380
PB
5241fi
5242fi
af71363e 5243GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
e8b05380 5244if test -n "$GFORTRAN_FOR_TARGET"; then
af71363e 5245 echo "$ac_t""$GFORTRAN_FOR_TARGET" 1>&6
e8b05380 5246else
af71363e 5247 echo "$ac_t""no" 1>&6
e8b05380
PB
5248fi
5249
5250 fi
5251 if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test $build = $target ; then
5252 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5253set dummy ${ncn_progname}; ac_word=$2
af71363e 5254echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5255echo "configure:5256: checking for $ac_word" >&5
af71363e
AS
5256if eval "test \"`echo '$''{'ac_cv_prog_GFORTRAN_FOR_TARGET'+set}'`\" = set"; then
5257 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5258else
5259 if test -n "$GFORTRAN_FOR_TARGET"; then
5260 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
5261else
af71363e
AS
5262 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5263 ac_dummy="$PATH"
5264 for ac_dir in $ac_dummy; do
5265 test -z "$ac_dir" && ac_dir=.
5266 if test -f $ac_dir/$ac_word; then
5267 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
5268 break
5269 fi
5270 done
5271 IFS="$ac_save_ifs"
e8b05380
PB
5272fi
5273fi
af71363e 5274GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
e8b05380 5275if test -n "$GFORTRAN_FOR_TARGET"; then
af71363e 5276 echo "$ac_t""$GFORTRAN_FOR_TARGET" 1>&6
e8b05380 5277else
af71363e 5278 echo "$ac_t""no" 1>&6
e8b05380 5279fi
af71363e 5280
e8b05380
PB
5281 fi
5282 test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET" && break
5283 done
5284fi
af71363e 5285
e8b05380
PB
5286if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" ; then
5287 set dummy gfortran
2693c0b0 5288 if test $build = $target ; then
e8b05380 5289 GFORTRAN_FOR_TARGET="$2"
ca9f4b81 5290 else
e8b05380
PB
5291 GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}$2"
5292 fi
5293fi
5294
5295
5296
5297# The user is always right.
5298if test "${PATH_SEPARATOR+set}" != set; then
5299 echo "#! /bin/sh" >conf$$.sh
5300 echo "exit 0" >>conf$$.sh
5301 chmod +x conf$$.sh
5302 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
5303 PATH_SEPARATOR=';'
5304 else
af71363e 5305 PATH_SEPARATOR=:
ca9f4b81 5306 fi
e8b05380
PB
5307 rm -f conf$$.sh
5308fi
5309
5310
5311
5312if test "x$exec_prefix" = xNONE; then
5313 if test "x$prefix" = xNONE; then
5314 gcc_cv_tool_prefix=$ac_default_prefix
5315 else
5316 gcc_cv_tool_prefix=$prefix
5317 fi
5318else
5319 gcc_cv_tool_prefix=$exec_prefix
5320fi
5321
5322# If there is no compiler in the tree, use the PATH only. In any
5323# case, if there is no compiler in the tree nobody should use
5324# AS_FOR_TARGET and LD_FOR_TARGET.
5325if test x$host = x$build && test -f $srcdir/gcc/BASE-VER; then
5326 gcc_version=`cat $srcdir/gcc/BASE-VER`
5327 gcc_cv_tool_dirs="$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
5328 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical$PATH_SEPARATOR"
5329 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
5330 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical$PATH_SEPARATOR"
5331 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
5332 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin$PATH_SEPARATOR"
5333else
5334 gcc_cv_tool_dirs=
5335fi
5336
5337if test x$build = x$target && test -n "$md_exec_prefix"; then
5338 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$md_exec_prefix$PATH_SEPARATOR"
5339fi
5340
5341
5342
5343cat > conftest.c << \EOF
5344#ifdef __GNUC__
5345 gcc_yay;
5346#endif
5347EOF
5348if ($GCC_FOR_TARGET -E conftest.c | grep gcc_yay) > /dev/null 2>&1; then
5349 have_gcc_for_target=yes
5350else
5351 GCC_FOR_TARGET=${ncn_target_tool_prefix}gcc
5352 have_gcc_for_target=no
5353fi
5354rm conftest.c
5355
5356
5357
5358
5359if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
5360 if test -n "$with_build_time_tools"; then
af71363e 5361 echo $ac_n "checking for ar in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5362echo "configure:5363: checking for ar in $with_build_time_tools" >&5
d1f8db0c
PB
5363 if test -x $with_build_time_tools/ar; then
5364 AR_FOR_TARGET=`cd $with_build_time_tools && pwd`/ar
5365 ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
af71363e 5366 echo "$ac_t""$ac_cv_path_AR_FOR_TARGET" 1>&6
d1f8db0c 5367 else
af71363e 5368 echo "$ac_t""no" 1>&6
d1f8db0c 5369 fi
e8b05380
PB
5370 elif test $build != $host && test $have_gcc_for_target = yes; then
5371 AR_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ar`
5372 test $AR_FOR_TARGET=ar && AR_FOR_TARGET=
5373 ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
5374 fi
5375fi
5376if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
5377 # Extract the first word of "ar", so it can be a program name with args.
5378set dummy ar; ac_word=$2
af71363e 5379echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5380echo "configure:5381: checking for $ac_word" >&5
af71363e
AS
5381if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
5382 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5383else
af71363e
AS
5384 case "$AR_FOR_TARGET" in
5385 /*)
e8b05380
PB
5386 ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
5387 ;;
af71363e
AS
5388 ?:/*)
5389 ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a dos path.
5390 ;;
e8b05380 5391 *)
af71363e
AS
5392 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5393 ac_dummy="$gcc_cv_tool_dirs"
5394 for ac_dir in $ac_dummy; do
5395 test -z "$ac_dir" && ac_dir=.
5396 if test -f $ac_dir/$ac_word; then
5397 ac_cv_path_AR_FOR_TARGET="$ac_dir/$ac_word"
5398 break
5399 fi
5400 done
5401 IFS="$ac_save_ifs"
e8b05380
PB
5402 ;;
5403esac
5404fi
af71363e 5405AR_FOR_TARGET="$ac_cv_path_AR_FOR_TARGET"
e8b05380 5406if test -n "$AR_FOR_TARGET"; then
af71363e 5407 echo "$ac_t""$AR_FOR_TARGET" 1>&6
e8b05380 5408else
af71363e 5409 echo "$ac_t""no" 1>&6
4de997d1
PB
5410fi
5411
e8b05380
PB
5412fi
5413if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
5414 if test -n "$with_build_time_tools"; then
5415 for ncn_progname in ar; do
af71363e 5416 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5417echo "configure:5418: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5418 if test -x $with_build_time_tools/${ncn_progname}; then
5419 ac_cv_prog_AR_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5420 echo "$ac_t""yes" 1>&6
e8b05380
PB
5421 break
5422 else
af71363e 5423 echo "$ac_t""no" 1>&6
e8b05380
PB
5424 fi
5425 done
5426fi
5427
5428if test -z "$ac_cv_prog_AR_FOR_TARGET"; then
5429 for ncn_progname in ar; do
5430 if test -n "$ncn_target_tool_prefix"; then
5431 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 5432set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5433echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5434echo "configure:5435: checking for $ac_word" >&5
af71363e
AS
5435if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
5436 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5437else
e8b05380
PB
5438 if test -n "$AR_FOR_TARGET"; then
5439 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
4de997d1 5440else
af71363e
AS
5441 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5442 ac_dummy="$PATH"
5443 for ac_dir in $ac_dummy; do
5444 test -z "$ac_dir" && ac_dir=.
5445 if test -f $ac_dir/$ac_word; then
5446 ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5447 break
5448 fi
5449 done
5450 IFS="$ac_save_ifs"
4de997d1
PB
5451fi
5452fi
af71363e 5453AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
e8b05380 5454if test -n "$AR_FOR_TARGET"; then
af71363e 5455 echo "$ac_t""$AR_FOR_TARGET" 1>&6
4de997d1 5456else
af71363e 5457 echo "$ac_t""no" 1>&6
4de997d1
PB
5458fi
5459
e8b05380
PB
5460 fi
5461 if test -z "$ac_cv_prog_AR_FOR_TARGET" && test $build = $target ; then
5462 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5463set dummy ${ncn_progname}; ac_word=$2
af71363e 5464echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5465echo "configure:5466: checking for $ac_word" >&5
af71363e
AS
5466if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
5467 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5468else
5469 if test -n "$AR_FOR_TARGET"; then
5470 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
5471else
af71363e
AS
5472 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5473 ac_dummy="$PATH"
5474 for ac_dir in $ac_dummy; do
5475 test -z "$ac_dir" && ac_dir=.
5476 if test -f $ac_dir/$ac_word; then
5477 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
5478 break
5479 fi
5480 done
5481 IFS="$ac_save_ifs"
e8b05380
PB
5482fi
5483fi
af71363e 5484AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
e8b05380 5485if test -n "$AR_FOR_TARGET"; then
af71363e 5486 echo "$ac_t""$AR_FOR_TARGET" 1>&6
e8b05380 5487else
af71363e 5488 echo "$ac_t""no" 1>&6
e8b05380 5489fi
af71363e 5490
e8b05380
PB
5491 fi
5492 test -n "$ac_cv_prog_AR_FOR_TARGET" && break
5493 done
5494fi
af71363e 5495
e8b05380
PB
5496if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
5497 set dummy ar
5498 if test $build = $target ; then
5499 AR_FOR_TARGET="$2"
5500 else
5501 AR_FOR_TARGET="${ncn_target_tool_prefix}$2"
2693c0b0 5502 fi
e8b05380
PB
5503fi
5504
d1f8db0c
PB
5505else
5506 AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
e8b05380
PB
5507fi
5508
5509
5510
5511
5512if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
5513 if test -n "$with_build_time_tools"; then
af71363e 5514 echo $ac_n "checking for as in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5515echo "configure:5516: checking for as in $with_build_time_tools" >&5
d1f8db0c
PB
5516 if test -x $with_build_time_tools/as; then
5517 AS_FOR_TARGET=`cd $with_build_time_tools && pwd`/as
5518 ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
af71363e 5519 echo "$ac_t""$ac_cv_path_AS_FOR_TARGET" 1>&6
d1f8db0c 5520 else
af71363e 5521 echo "$ac_t""no" 1>&6
d1f8db0c 5522 fi
e8b05380
PB
5523 elif test $build != $host && test $have_gcc_for_target = yes; then
5524 AS_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=as`
5525 test $AS_FOR_TARGET=as && AS_FOR_TARGET=
5526 ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
5527 fi
5528fi
5529if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
5530 # Extract the first word of "as", so it can be a program name with args.
5531set dummy as; ac_word=$2
af71363e 5532echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5533echo "configure:5534: checking for $ac_word" >&5
af71363e
AS
5534if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
5535 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5536else
af71363e
AS
5537 case "$AS_FOR_TARGET" in
5538 /*)
e8b05380
PB
5539 ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
5540 ;;
af71363e
AS
5541 ?:/*)
5542 ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a dos path.
5543 ;;
e8b05380 5544 *)
af71363e
AS
5545 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5546 ac_dummy="$gcc_cv_tool_dirs"
5547 for ac_dir in $ac_dummy; do
5548 test -z "$ac_dir" && ac_dir=.
5549 if test -f $ac_dir/$ac_word; then
5550 ac_cv_path_AS_FOR_TARGET="$ac_dir/$ac_word"
5551 break
5552 fi
5553 done
5554 IFS="$ac_save_ifs"
e8b05380
PB
5555 ;;
5556esac
5557fi
af71363e 5558AS_FOR_TARGET="$ac_cv_path_AS_FOR_TARGET"
e8b05380 5559if test -n "$AS_FOR_TARGET"; then
af71363e 5560 echo "$ac_t""$AS_FOR_TARGET" 1>&6
e8b05380 5561else
af71363e 5562 echo "$ac_t""no" 1>&6
e8b05380
PB
5563fi
5564
5565fi
5566if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
5567 if test -n "$with_build_time_tools"; then
5568 for ncn_progname in as; do
af71363e 5569 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5570echo "configure:5571: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5571 if test -x $with_build_time_tools/${ncn_progname}; then
5572 ac_cv_prog_AS_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5573 echo "$ac_t""yes" 1>&6
e8b05380
PB
5574 break
5575 else
af71363e 5576 echo "$ac_t""no" 1>&6
e8b05380
PB
5577 fi
5578 done
5579fi
5580
5581if test -z "$ac_cv_prog_AS_FOR_TARGET"; then
5582 for ncn_progname in as; do
5583 if test -n "$ncn_target_tool_prefix"; then
5584 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5585set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5586echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5587echo "configure:5588: checking for $ac_word" >&5
af71363e
AS
5588if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
5589 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5590else
5591 if test -n "$AS_FOR_TARGET"; then
5592 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
5593else
af71363e
AS
5594 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5595 ac_dummy="$PATH"
5596 for ac_dir in $ac_dummy; do
5597 test -z "$ac_dir" && ac_dir=.
5598 if test -f $ac_dir/$ac_word; then
5599 ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5600 break
5601 fi
5602 done
5603 IFS="$ac_save_ifs"
e8b05380
PB
5604fi
5605fi
af71363e 5606AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
e8b05380 5607if test -n "$AS_FOR_TARGET"; then
af71363e 5608 echo "$ac_t""$AS_FOR_TARGET" 1>&6
e8b05380 5609else
af71363e 5610 echo "$ac_t""no" 1>&6
e8b05380
PB
5611fi
5612
5613 fi
5614 if test -z "$ac_cv_prog_AS_FOR_TARGET" && test $build = $target ; then
5615 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 5616set dummy ${ncn_progname}; ac_word=$2
af71363e 5617echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5618echo "configure:5619: checking for $ac_word" >&5
af71363e
AS
5619if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
5620 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5621else
e8b05380
PB
5622 if test -n "$AS_FOR_TARGET"; then
5623 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
4de997d1 5624else
af71363e
AS
5625 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5626 ac_dummy="$PATH"
5627 for ac_dir in $ac_dummy; do
5628 test -z "$ac_dir" && ac_dir=.
5629 if test -f $ac_dir/$ac_word; then
5630 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
5631 break
5632 fi
5633 done
5634 IFS="$ac_save_ifs"
4de997d1
PB
5635fi
5636fi
af71363e 5637AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
e8b05380 5638if test -n "$AS_FOR_TARGET"; then
af71363e 5639 echo "$ac_t""$AS_FOR_TARGET" 1>&6
4de997d1 5640else
af71363e 5641 echo "$ac_t""no" 1>&6
4de997d1 5642fi
af71363e 5643
e8b05380
PB
5644 fi
5645 test -n "$ac_cv_prog_AS_FOR_TARGET" && break
5646 done
5647fi
af71363e 5648
e8b05380
PB
5649if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
5650 set dummy as
5651 if test $build = $target ; then
5652 AS_FOR_TARGET="$2"
5653 else
5654 AS_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 5655 fi
e8b05380 5656fi
2693c0b0 5657
d1f8db0c
PB
5658else
5659 AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
4de997d1
PB
5660fi
5661
e8b05380
PB
5662
5663
5664
5665if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
5666 if test -n "$with_build_time_tools"; then
af71363e 5667 echo $ac_n "checking for dlltool in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5668echo "configure:5669: checking for dlltool in $with_build_time_tools" >&5
d1f8db0c
PB
5669 if test -x $with_build_time_tools/dlltool; then
5670 DLLTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dlltool
5671 ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
af71363e 5672 echo "$ac_t""$ac_cv_path_DLLTOOL_FOR_TARGET" 1>&6
d1f8db0c 5673 else
af71363e 5674 echo "$ac_t""no" 1>&6
d1f8db0c 5675 fi
e8b05380
PB
5676 elif test $build != $host && test $have_gcc_for_target = yes; then
5677 DLLTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dlltool`
5678 test $DLLTOOL_FOR_TARGET=dlltool && DLLTOOL_FOR_TARGET=
5679 ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
5680 fi
5681fi
5682if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
5683 # Extract the first word of "dlltool", so it can be a program name with args.
5684set dummy dlltool; ac_word=$2
af71363e 5685echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5686echo "configure:5687: checking for $ac_word" >&5
af71363e
AS
5687if eval "test \"`echo '$''{'ac_cv_path_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
5688 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5689else
af71363e
AS
5690 case "$DLLTOOL_FOR_TARGET" in
5691 /*)
e8b05380
PB
5692 ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a path.
5693 ;;
af71363e
AS
5694 ?:/*)
5695 ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a dos path.
5696 ;;
e8b05380 5697 *)
af71363e
AS
5698 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5699 ac_dummy="$gcc_cv_tool_dirs"
5700 for ac_dir in $ac_dummy; do
5701 test -z "$ac_dir" && ac_dir=.
5702 if test -f $ac_dir/$ac_word; then
5703 ac_cv_path_DLLTOOL_FOR_TARGET="$ac_dir/$ac_word"
5704 break
5705 fi
5706 done
5707 IFS="$ac_save_ifs"
e8b05380
PB
5708 ;;
5709esac
4de997d1 5710fi
af71363e 5711DLLTOOL_FOR_TARGET="$ac_cv_path_DLLTOOL_FOR_TARGET"
e8b05380 5712if test -n "$DLLTOOL_FOR_TARGET"; then
af71363e 5713 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
4de997d1 5714else
af71363e 5715 echo "$ac_t""no" 1>&6
4de997d1
PB
5716fi
5717
e8b05380
PB
5718fi
5719if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
5720 if test -n "$with_build_time_tools"; then
5721 for ncn_progname in dlltool; do
af71363e 5722 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5723echo "configure:5724: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5724 if test -x $with_build_time_tools/${ncn_progname}; then
5725 ac_cv_prog_DLLTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5726 echo "$ac_t""yes" 1>&6
e8b05380
PB
5727 break
5728 else
af71363e 5729 echo "$ac_t""no" 1>&6
e8b05380
PB
5730 fi
5731 done
5732fi
5733
5734if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
5735 for ncn_progname in dlltool; do
5736 if test -n "$ncn_target_tool_prefix"; then
5737 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5738set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5739echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5740echo "configure:5741: checking for $ac_word" >&5
af71363e
AS
5741if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
5742 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5743else
e8b05380
PB
5744 if test -n "$DLLTOOL_FOR_TARGET"; then
5745 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 5746else
af71363e
AS
5747 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5748 ac_dummy="$PATH"
5749 for ac_dir in $ac_dummy; do
5750 test -z "$ac_dir" && ac_dir=.
5751 if test -f $ac_dir/$ac_word; then
5752 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5753 break
5754 fi
5755 done
5756 IFS="$ac_save_ifs"
4de997d1
PB
5757fi
5758fi
af71363e 5759DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
e8b05380 5760if test -n "$DLLTOOL_FOR_TARGET"; then
af71363e 5761 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
4de997d1 5762else
af71363e 5763 echo "$ac_t""no" 1>&6
4de997d1 5764fi
4de997d1 5765
e8b05380
PB
5766 fi
5767 if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test $build = $target ; then
5768 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5769set dummy ${ncn_progname}; ac_word=$2
af71363e 5770echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5771echo "configure:5772: checking for $ac_word" >&5
af71363e
AS
5772if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
5773 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5774else
e8b05380
PB
5775 if test -n "$DLLTOOL_FOR_TARGET"; then
5776 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 5777else
af71363e
AS
5778 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5779 ac_dummy="$PATH"
5780 for ac_dir in $ac_dummy; do
5781 test -z "$ac_dir" && ac_dir=.
5782 if test -f $ac_dir/$ac_word; then
5783 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
5784 break
5785 fi
5786 done
5787 IFS="$ac_save_ifs"
4de997d1
PB
5788fi
5789fi
af71363e 5790DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
e8b05380 5791if test -n "$DLLTOOL_FOR_TARGET"; then
af71363e 5792 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
4de997d1 5793else
af71363e 5794 echo "$ac_t""no" 1>&6
4de997d1 5795fi
af71363e 5796
e8b05380
PB
5797 fi
5798 test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET" && break
5799 done
5800fi
af71363e 5801
e8b05380
PB
5802if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
5803 set dummy dlltool
5804 if test $build = $target ; then
5805 DLLTOOL_FOR_TARGET="$2"
5806 else
5807 DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
5808 fi
5809fi
5810
d1f8db0c
PB
5811else
5812 DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
e8b05380
PB
5813fi
5814
4de997d1 5815
e8b05380
PB
5816
5817
5818if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
5819 if test -n "$with_build_time_tools"; then
af71363e 5820 echo $ac_n "checking for ld in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5821echo "configure:5822: checking for ld in $with_build_time_tools" >&5
d1f8db0c
PB
5822 if test -x $with_build_time_tools/ld; then
5823 LD_FOR_TARGET=`cd $with_build_time_tools && pwd`/ld
5824 ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
af71363e 5825 echo "$ac_t""$ac_cv_path_LD_FOR_TARGET" 1>&6
d1f8db0c 5826 else
af71363e 5827 echo "$ac_t""no" 1>&6
d1f8db0c 5828 fi
e8b05380
PB
5829 elif test $build != $host && test $have_gcc_for_target = yes; then
5830 LD_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ld`
5831 test $LD_FOR_TARGET=ld && LD_FOR_TARGET=
5832 ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
2693c0b0 5833 fi
e8b05380
PB
5834fi
5835if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
5836 # Extract the first word of "ld", so it can be a program name with args.
5837set dummy ld; ac_word=$2
af71363e 5838echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5839echo "configure:5840: checking for $ac_word" >&5
af71363e
AS
5840if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
5841 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5842else
af71363e
AS
5843 case "$LD_FOR_TARGET" in
5844 /*)
e8b05380
PB
5845 ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
5846 ;;
af71363e
AS
5847 ?:/*)
5848 ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a dos path.
5849 ;;
e8b05380 5850 *)
af71363e
AS
5851 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5852 ac_dummy="$gcc_cv_tool_dirs"
5853 for ac_dir in $ac_dummy; do
5854 test -z "$ac_dir" && ac_dir=.
5855 if test -f $ac_dir/$ac_word; then
5856 ac_cv_path_LD_FOR_TARGET="$ac_dir/$ac_word"
5857 break
5858 fi
5859 done
5860 IFS="$ac_save_ifs"
e8b05380
PB
5861 ;;
5862esac
4de997d1 5863fi
af71363e 5864LD_FOR_TARGET="$ac_cv_path_LD_FOR_TARGET"
e8b05380 5865if test -n "$LD_FOR_TARGET"; then
af71363e 5866 echo "$ac_t""$LD_FOR_TARGET" 1>&6
4de997d1 5867else
af71363e 5868 echo "$ac_t""no" 1>&6
4de997d1 5869fi
2693c0b0 5870
e8b05380
PB
5871fi
5872if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
5873 if test -n "$with_build_time_tools"; then
5874 for ncn_progname in ld; do
af71363e 5875 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5876echo "configure:5877: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5877 if test -x $with_build_time_tools/${ncn_progname}; then
5878 ac_cv_prog_LD_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5879 echo "$ac_t""yes" 1>&6
e8b05380
PB
5880 break
5881 else
af71363e 5882 echo "$ac_t""no" 1>&6
e8b05380
PB
5883 fi
5884 done
ca9f4b81
AO
5885fi
5886
e8b05380
PB
5887if test -z "$ac_cv_prog_LD_FOR_TARGET"; then
5888 for ncn_progname in ld; do
5889 if test -n "$ncn_target_tool_prefix"; then
5890 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 5891set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5892echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5893echo "configure:5894: checking for $ac_word" >&5
af71363e
AS
5894if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
5895 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5896else
4de997d1
PB
5897 if test -n "$LD_FOR_TARGET"; then
5898 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 5899else
af71363e
AS
5900 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5901 ac_dummy="$PATH"
5902 for ac_dir in $ac_dummy; do
5903 test -z "$ac_dir" && ac_dir=.
5904 if test -f $ac_dir/$ac_word; then
5905 ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5906 break
5907 fi
5908 done
5909 IFS="$ac_save_ifs"
ca9f4b81
AO
5910fi
5911fi
af71363e 5912LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
4de997d1 5913if test -n "$LD_FOR_TARGET"; then
af71363e 5914 echo "$ac_t""$LD_FOR_TARGET" 1>&6
ca9f4b81 5915else
af71363e 5916 echo "$ac_t""no" 1>&6
ca9f4b81
AO
5917fi
5918
e8b05380
PB
5919 fi
5920 if test -z "$ac_cv_prog_LD_FOR_TARGET" && test $build = $target ; then
5921 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 5922set dummy ${ncn_progname}; ac_word=$2
af71363e 5923echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5924echo "configure:5925: checking for $ac_word" >&5
af71363e
AS
5925if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
5926 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5927else
2693c0b0
PB
5928 if test -n "$LD_FOR_TARGET"; then
5929 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 5930else
af71363e
AS
5931 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5932 ac_dummy="$PATH"
5933 for ac_dir in $ac_dummy; do
5934 test -z "$ac_dir" && ac_dir=.
5935 if test -f $ac_dir/$ac_word; then
5936 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
5937 break
5938 fi
5939 done
5940 IFS="$ac_save_ifs"
ca9f4b81
AO
5941fi
5942fi
af71363e 5943LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
2693c0b0 5944if test -n "$LD_FOR_TARGET"; then
af71363e 5945 echo "$ac_t""$LD_FOR_TARGET" 1>&6
ca9f4b81 5946else
af71363e 5947 echo "$ac_t""no" 1>&6
ca9f4b81 5948fi
af71363e 5949
e8b05380
PB
5950 fi
5951 test -n "$ac_cv_prog_LD_FOR_TARGET" && break
5952 done
5953fi
af71363e 5954
2693c0b0
PB
5955if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
5956 set dummy ld
5957 if test $build = $target ; then
5958 LD_FOR_TARGET="$2"
ca9f4b81 5959 else
2693c0b0 5960 LD_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 5961 fi
ca9f4b81
AO
5962fi
5963
d1f8db0c
PB
5964else
5965 LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
e8b05380
PB
5966fi
5967
5968
5969
5970
5971if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
5972 if test -n "$with_build_time_tools"; then
af71363e 5973 echo $ac_n "checking for lipo in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 5974echo "configure:5975: checking for lipo in $with_build_time_tools" >&5
d1f8db0c
PB
5975 if test -x $with_build_time_tools/lipo; then
5976 LIPO_FOR_TARGET=`cd $with_build_time_tools && pwd`/lipo
5977 ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
af71363e 5978 echo "$ac_t""$ac_cv_path_LIPO_FOR_TARGET" 1>&6
d1f8db0c 5979 else
af71363e 5980 echo "$ac_t""no" 1>&6
d1f8db0c 5981 fi
e8b05380
PB
5982 elif test $build != $host && test $have_gcc_for_target = yes; then
5983 LIPO_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=lipo`
5984 test $LIPO_FOR_TARGET=lipo && LIPO_FOR_TARGET=
5985 ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
5986 fi
5987fi
5988if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
5989 # Extract the first word of "lipo", so it can be a program name with args.
5990set dummy lipo; ac_word=$2
af71363e 5991echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 5992echo "configure:5993: checking for $ac_word" >&5
af71363e
AS
5993if eval "test \"`echo '$''{'ac_cv_path_LIPO_FOR_TARGET'+set}'`\" = set"; then
5994 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5995else
af71363e
AS
5996 case "$LIPO_FOR_TARGET" in
5997 /*)
e8b05380
PB
5998 ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a path.
5999 ;;
af71363e
AS
6000 ?:/*)
6001 ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a dos path.
6002 ;;
e8b05380 6003 *)
af71363e
AS
6004 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6005 ac_dummy="$gcc_cv_tool_dirs"
6006 for ac_dir in $ac_dummy; do
6007 test -z "$ac_dir" && ac_dir=.
6008 if test -f $ac_dir/$ac_word; then
6009 ac_cv_path_LIPO_FOR_TARGET="$ac_dir/$ac_word"
6010 break
6011 fi
6012 done
6013 IFS="$ac_save_ifs"
e8b05380
PB
6014 ;;
6015esac
6016fi
af71363e 6017LIPO_FOR_TARGET="$ac_cv_path_LIPO_FOR_TARGET"
e8b05380 6018if test -n "$LIPO_FOR_TARGET"; then
af71363e 6019 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
e8b05380 6020else
af71363e 6021 echo "$ac_t""no" 1>&6
e8b05380
PB
6022fi
6023
6024fi
6025if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
6026 if test -n "$with_build_time_tools"; then
6027 for ncn_progname in lipo; do
af71363e 6028 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6029echo "configure:6030: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6030 if test -x $with_build_time_tools/${ncn_progname}; then
6031 ac_cv_prog_LIPO_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6032 echo "$ac_t""yes" 1>&6
e8b05380
PB
6033 break
6034 else
af71363e 6035 echo "$ac_t""no" 1>&6
e8b05380
PB
6036 fi
6037 done
6038fi
6039
6040if test -z "$ac_cv_prog_LIPO_FOR_TARGET"; then
6041 for ncn_progname in lipo; do
6042 if test -n "$ncn_target_tool_prefix"; then
6043 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 6044set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6045echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6046echo "configure:6047: checking for $ac_word" >&5
af71363e
AS
6047if eval "test \"`echo '$''{'ac_cv_prog_LIPO_FOR_TARGET'+set}'`\" = set"; then
6048 echo $ac_n "(cached) $ac_c" 1>&6
040b1c5a
GK
6049else
6050 if test -n "$LIPO_FOR_TARGET"; then
6051 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
6052else
af71363e
AS
6053 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6054 ac_dummy="$PATH"
6055 for ac_dir in $ac_dummy; do
6056 test -z "$ac_dir" && ac_dir=.
6057 if test -f $ac_dir/$ac_word; then
6058 ac_cv_prog_LIPO_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6059 break
6060 fi
6061 done
6062 IFS="$ac_save_ifs"
040b1c5a
GK
6063fi
6064fi
af71363e 6065LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
040b1c5a 6066if test -n "$LIPO_FOR_TARGET"; then
af71363e 6067 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
040b1c5a 6068else
af71363e 6069 echo "$ac_t""no" 1>&6
040b1c5a
GK
6070fi
6071
e8b05380
PB
6072 fi
6073 if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test $build = $target ; then
6074 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 6075set dummy ${ncn_progname}; ac_word=$2
af71363e 6076echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6077echo "configure:6078: checking for $ac_word" >&5
af71363e
AS
6078if eval "test \"`echo '$''{'ac_cv_prog_LIPO_FOR_TARGET'+set}'`\" = set"; then
6079 echo $ac_n "(cached) $ac_c" 1>&6
040b1c5a
GK
6080else
6081 if test -n "$LIPO_FOR_TARGET"; then
72a7ab82
AP
6082 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
6083else
af71363e
AS
6084 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6085 ac_dummy="$PATH"
6086 for ac_dir in $ac_dummy; do
6087 test -z "$ac_dir" && ac_dir=.
6088 if test -f $ac_dir/$ac_word; then
6089 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
6090 break
6091 fi
6092 done
6093 IFS="$ac_save_ifs"
040b1c5a
GK
6094fi
6095fi
af71363e 6096LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
040b1c5a 6097if test -n "$LIPO_FOR_TARGET"; then
af71363e 6098 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
040b1c5a 6099else
af71363e 6100 echo "$ac_t""no" 1>&6
040b1c5a 6101fi
af71363e 6102
e8b05380
PB
6103 fi
6104 test -n "$ac_cv_prog_LIPO_FOR_TARGET" && break
6105 done
6106fi
af71363e 6107
040b1c5a
GK
6108if test -z "$ac_cv_prog_LIPO_FOR_TARGET" ; then
6109 set dummy lipo
6110 if test $build = $target ; then
6111 LIPO_FOR_TARGET="$2"
6112 else
6113 LIPO_FOR_TARGET="${ncn_target_tool_prefix}$2"
6114 fi
6115fi
6116
d1f8db0c
PB
6117else
6118 LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
e8b05380
PB
6119fi
6120
6121
6122
6123
6124if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
6125 if test -n "$with_build_time_tools"; then
af71363e 6126 echo $ac_n "checking for nm in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6127echo "configure:6128: checking for nm in $with_build_time_tools" >&5
d1f8db0c
PB
6128 if test -x $with_build_time_tools/nm; then
6129 NM_FOR_TARGET=`cd $with_build_time_tools && pwd`/nm
6130 ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
af71363e 6131 echo "$ac_t""$ac_cv_path_NM_FOR_TARGET" 1>&6
d1f8db0c 6132 else
af71363e 6133 echo "$ac_t""no" 1>&6
d1f8db0c 6134 fi
e8b05380
PB
6135 elif test $build != $host && test $have_gcc_for_target = yes; then
6136 NM_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=nm`
6137 test $NM_FOR_TARGET=nm && NM_FOR_TARGET=
6138 ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
6139 fi
6140fi
6141if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
6142 # Extract the first word of "nm", so it can be a program name with args.
6143set dummy nm; ac_word=$2
af71363e 6144echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6145echo "configure:6146: checking for $ac_word" >&5
af71363e
AS
6146if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
6147 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6148else
af71363e
AS
6149 case "$NM_FOR_TARGET" in
6150 /*)
e8b05380
PB
6151 ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
6152 ;;
af71363e
AS
6153 ?:/*)
6154 ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a dos path.
6155 ;;
e8b05380 6156 *)
af71363e
AS
6157 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6158 ac_dummy="$gcc_cv_tool_dirs"
6159 for ac_dir in $ac_dummy; do
6160 test -z "$ac_dir" && ac_dir=.
6161 if test -f $ac_dir/$ac_word; then
6162 ac_cv_path_NM_FOR_TARGET="$ac_dir/$ac_word"
6163 break
6164 fi
6165 done
6166 IFS="$ac_save_ifs"
e8b05380
PB
6167 ;;
6168esac
6169fi
af71363e 6170NM_FOR_TARGET="$ac_cv_path_NM_FOR_TARGET"
e8b05380 6171if test -n "$NM_FOR_TARGET"; then
af71363e 6172 echo "$ac_t""$NM_FOR_TARGET" 1>&6
e8b05380 6173else
af71363e 6174 echo "$ac_t""no" 1>&6
e8b05380
PB
6175fi
6176
6177fi
6178if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
6179 if test -n "$with_build_time_tools"; then
6180 for ncn_progname in nm; do
af71363e 6181 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6182echo "configure:6183: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6183 if test -x $with_build_time_tools/${ncn_progname}; then
6184 ac_cv_prog_NM_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6185 echo "$ac_t""yes" 1>&6
e8b05380
PB
6186 break
6187 else
af71363e 6188 echo "$ac_t""no" 1>&6
e8b05380
PB
6189 fi
6190 done
6191fi
6192
6193if test -z "$ac_cv_prog_NM_FOR_TARGET"; then
6194 for ncn_progname in nm; do
6195 if test -n "$ncn_target_tool_prefix"; then
6196 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 6197set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6198echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6199echo "configure:6200: checking for $ac_word" >&5
af71363e
AS
6200if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
6201 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6202else
4de997d1
PB
6203 if test -n "$NM_FOR_TARGET"; then
6204 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 6205else
af71363e
AS
6206 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6207 ac_dummy="$PATH"
6208 for ac_dir in $ac_dummy; do
6209 test -z "$ac_dir" && ac_dir=.
6210 if test -f $ac_dir/$ac_word; then
6211 ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6212 break
6213 fi
6214 done
6215 IFS="$ac_save_ifs"
ca9f4b81
AO
6216fi
6217fi
af71363e 6218NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
4de997d1 6219if test -n "$NM_FOR_TARGET"; then
af71363e 6220 echo "$ac_t""$NM_FOR_TARGET" 1>&6
ca9f4b81 6221else
af71363e 6222 echo "$ac_t""no" 1>&6
ca9f4b81
AO
6223fi
6224
e8b05380
PB
6225 fi
6226 if test -z "$ac_cv_prog_NM_FOR_TARGET" && test $build = $target ; then
6227 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 6228set dummy ${ncn_progname}; ac_word=$2
af71363e 6229echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6230echo "configure:6231: checking for $ac_word" >&5
af71363e
AS
6231if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
6232 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6233else
2693c0b0
PB
6234 if test -n "$NM_FOR_TARGET"; then
6235 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 6236else
af71363e
AS
6237 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6238 ac_dummy="$PATH"
6239 for ac_dir in $ac_dummy; do
6240 test -z "$ac_dir" && ac_dir=.
6241 if test -f $ac_dir/$ac_word; then
6242 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
6243 break
6244 fi
6245 done
6246 IFS="$ac_save_ifs"
ca9f4b81
AO
6247fi
6248fi
af71363e 6249NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
2693c0b0 6250if test -n "$NM_FOR_TARGET"; then
af71363e 6251 echo "$ac_t""$NM_FOR_TARGET" 1>&6
ca9f4b81 6252else
af71363e 6253 echo "$ac_t""no" 1>&6
ca9f4b81 6254fi
af71363e 6255
e8b05380
PB
6256 fi
6257 test -n "$ac_cv_prog_NM_FOR_TARGET" && break
6258 done
6259fi
af71363e 6260
2693c0b0
PB
6261if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
6262 set dummy nm
6263 if test $build = $target ; then
6264 NM_FOR_TARGET="$2"
ca9f4b81 6265 else
2693c0b0 6266 NM_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 6267 fi
ca9f4b81
AO
6268fi
6269
d1f8db0c
PB
6270else
6271 NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
e8b05380
PB
6272fi
6273
6274
6275
6276
6277if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
6278 if test -n "$with_build_time_tools"; then
af71363e 6279 echo $ac_n "checking for objdump in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6280echo "configure:6281: checking for objdump in $with_build_time_tools" >&5
d1f8db0c
PB
6281 if test -x $with_build_time_tools/objdump; then
6282 OBJDUMP_FOR_TARGET=`cd $with_build_time_tools && pwd`/objdump
6283 ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
af71363e 6284 echo "$ac_t""$ac_cv_path_OBJDUMP_FOR_TARGET" 1>&6
d1f8db0c 6285 else
af71363e 6286 echo "$ac_t""no" 1>&6
d1f8db0c 6287 fi
e8b05380
PB
6288 elif test $build != $host && test $have_gcc_for_target = yes; then
6289 OBJDUMP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objdump`
6290 test $OBJDUMP_FOR_TARGET=objdump && OBJDUMP_FOR_TARGET=
6291 ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
6292 fi
6293fi
6294if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
6295 # Extract the first word of "objdump", so it can be a program name with args.
6296set dummy objdump; ac_word=$2
af71363e 6297echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6298echo "configure:6299: checking for $ac_word" >&5
af71363e
AS
6299if eval "test \"`echo '$''{'ac_cv_path_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
6300 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6301else
af71363e
AS
6302 case "$OBJDUMP_FOR_TARGET" in
6303 /*)
e8b05380
PB
6304 ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a path.
6305 ;;
af71363e
AS
6306 ?:/*)
6307 ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a dos path.
6308 ;;
e8b05380 6309 *)
af71363e
AS
6310 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6311 ac_dummy="$gcc_cv_tool_dirs"
6312 for ac_dir in $ac_dummy; do
6313 test -z "$ac_dir" && ac_dir=.
6314 if test -f $ac_dir/$ac_word; then
6315 ac_cv_path_OBJDUMP_FOR_TARGET="$ac_dir/$ac_word"
6316 break
6317 fi
6318 done
6319 IFS="$ac_save_ifs"
e8b05380
PB
6320 ;;
6321esac
6322fi
af71363e 6323OBJDUMP_FOR_TARGET="$ac_cv_path_OBJDUMP_FOR_TARGET"
e8b05380 6324if test -n "$OBJDUMP_FOR_TARGET"; then
af71363e 6325 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
e8b05380 6326else
af71363e 6327 echo "$ac_t""no" 1>&6
e8b05380
PB
6328fi
6329
6330fi
6331if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
6332 if test -n "$with_build_time_tools"; then
6333 for ncn_progname in objdump; do
af71363e 6334 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6335echo "configure:6336: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6336 if test -x $with_build_time_tools/${ncn_progname}; then
6337 ac_cv_prog_OBJDUMP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6338 echo "$ac_t""yes" 1>&6
e8b05380
PB
6339 break
6340 else
af71363e 6341 echo "$ac_t""no" 1>&6
e8b05380
PB
6342 fi
6343 done
6344fi
6345
6346if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
6347 for ncn_progname in objdump; do
6348 if test -n "$ncn_target_tool_prefix"; then
6349 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 6350set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6351echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6352echo "configure:6353: checking for $ac_word" >&5
af71363e
AS
6353if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
6354 echo $ac_n "(cached) $ac_c" 1>&6
d739199a
DJ
6355else
6356 if test -n "$OBJDUMP_FOR_TARGET"; then
6357 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
6358else
af71363e
AS
6359 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6360 ac_dummy="$PATH"
6361 for ac_dir in $ac_dummy; do
6362 test -z "$ac_dir" && ac_dir=.
6363 if test -f $ac_dir/$ac_word; then
6364 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6365 break
6366 fi
6367 done
6368 IFS="$ac_save_ifs"
d739199a
DJ
6369fi
6370fi
af71363e 6371OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
d739199a 6372if test -n "$OBJDUMP_FOR_TARGET"; then
af71363e 6373 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
d739199a 6374else
af71363e 6375 echo "$ac_t""no" 1>&6
d739199a
DJ
6376fi
6377
e8b05380
PB
6378 fi
6379 if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test $build = $target ; then
6380 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
d739199a 6381set dummy ${ncn_progname}; ac_word=$2
af71363e 6382echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6383echo "configure:6384: checking for $ac_word" >&5
af71363e
AS
6384if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
6385 echo $ac_n "(cached) $ac_c" 1>&6
d739199a
DJ
6386else
6387 if test -n "$OBJDUMP_FOR_TARGET"; then
6388 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
6389else
af71363e
AS
6390 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6391 ac_dummy="$PATH"
6392 for ac_dir in $ac_dummy; do
6393 test -z "$ac_dir" && ac_dir=.
6394 if test -f $ac_dir/$ac_word; then
6395 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
6396 break
6397 fi
6398 done
6399 IFS="$ac_save_ifs"
d739199a
DJ
6400fi
6401fi
af71363e 6402OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
d739199a 6403if test -n "$OBJDUMP_FOR_TARGET"; then
af71363e 6404 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
d739199a 6405else
af71363e 6406 echo "$ac_t""no" 1>&6
d739199a 6407fi
af71363e 6408
e8b05380
PB
6409 fi
6410 test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET" && break
6411 done
6412fi
af71363e 6413
d739199a
DJ
6414if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" ; then
6415 set dummy objdump
6416 if test $build = $target ; then
6417 OBJDUMP_FOR_TARGET="$2"
6418 else
6419 OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}$2"
6420 fi
6421fi
6422
d1f8db0c
PB
6423else
6424 OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
e8b05380
PB
6425fi
6426
6427
6428
6429
6430if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
6431 if test -n "$with_build_time_tools"; then
af71363e 6432 echo $ac_n "checking for ranlib in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6433echo "configure:6434: checking for ranlib in $with_build_time_tools" >&5
d1f8db0c
PB
6434 if test -x $with_build_time_tools/ranlib; then
6435 RANLIB_FOR_TARGET=`cd $with_build_time_tools && pwd`/ranlib
6436 ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
af71363e 6437 echo "$ac_t""$ac_cv_path_RANLIB_FOR_TARGET" 1>&6
d1f8db0c 6438 else
af71363e 6439 echo "$ac_t""no" 1>&6
d1f8db0c 6440 fi
e8b05380
PB
6441 elif test $build != $host && test $have_gcc_for_target = yes; then
6442 RANLIB_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ranlib`
6443 test $RANLIB_FOR_TARGET=ranlib && RANLIB_FOR_TARGET=
6444 ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
6445 fi
6446fi
6447if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
6448 # Extract the first word of "ranlib", so it can be a program name with args.
6449set dummy ranlib; ac_word=$2
af71363e 6450echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6451echo "configure:6452: checking for $ac_word" >&5
af71363e
AS
6452if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
6453 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6454else
af71363e
AS
6455 case "$RANLIB_FOR_TARGET" in
6456 /*)
e8b05380
PB
6457 ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
6458 ;;
af71363e
AS
6459 ?:/*)
6460 ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a dos path.
6461 ;;
e8b05380 6462 *)
af71363e
AS
6463 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6464 ac_dummy="$gcc_cv_tool_dirs"
6465 for ac_dir in $ac_dummy; do
6466 test -z "$ac_dir" && ac_dir=.
6467 if test -f $ac_dir/$ac_word; then
6468 ac_cv_path_RANLIB_FOR_TARGET="$ac_dir/$ac_word"
6469 break
6470 fi
6471 done
6472 IFS="$ac_save_ifs"
e8b05380
PB
6473 ;;
6474esac
6475fi
af71363e 6476RANLIB_FOR_TARGET="$ac_cv_path_RANLIB_FOR_TARGET"
e8b05380 6477if test -n "$RANLIB_FOR_TARGET"; then
af71363e 6478 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
e8b05380 6479else
af71363e 6480 echo "$ac_t""no" 1>&6
e8b05380
PB
6481fi
6482
6483fi
6484if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
6485 if test -n "$with_build_time_tools"; then
6486 for ncn_progname in ranlib; do
af71363e 6487 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6488echo "configure:6489: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6489 if test -x $with_build_time_tools/${ncn_progname}; then
6490 ac_cv_prog_RANLIB_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6491 echo "$ac_t""yes" 1>&6
e8b05380
PB
6492 break
6493 else
af71363e 6494 echo "$ac_t""no" 1>&6
e8b05380
PB
6495 fi
6496 done
6497fi
6498
6499if test -z "$ac_cv_prog_RANLIB_FOR_TARGET"; then
6500 for ncn_progname in ranlib; do
6501 if test -n "$ncn_target_tool_prefix"; then
6502 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
d739199a 6503set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6504echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6505echo "configure:6506: checking for $ac_word" >&5
af71363e
AS
6506if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
6507 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6508else
4de997d1
PB
6509 if test -n "$RANLIB_FOR_TARGET"; then
6510 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 6511else
af71363e
AS
6512 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6513 ac_dummy="$PATH"
6514 for ac_dir in $ac_dummy; do
6515 test -z "$ac_dir" && ac_dir=.
6516 if test -f $ac_dir/$ac_word; then
6517 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6518 break
6519 fi
6520 done
6521 IFS="$ac_save_ifs"
ca9f4b81
AO
6522fi
6523fi
af71363e 6524RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
4de997d1 6525if test -n "$RANLIB_FOR_TARGET"; then
af71363e 6526 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
ca9f4b81 6527else
af71363e 6528 echo "$ac_t""no" 1>&6
ca9f4b81
AO
6529fi
6530
e8b05380
PB
6531 fi
6532 if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test $build = $target ; then
6533 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 6534set dummy ${ncn_progname}; ac_word=$2
af71363e 6535echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6536echo "configure:6537: checking for $ac_word" >&5
af71363e
AS
6537if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
6538 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6539else
2693c0b0
PB
6540 if test -n "$RANLIB_FOR_TARGET"; then
6541 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 6542else
af71363e
AS
6543 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6544 ac_dummy="$PATH"
6545 for ac_dir in $ac_dummy; do
6546 test -z "$ac_dir" && ac_dir=.
6547 if test -f $ac_dir/$ac_word; then
6548 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
6549 break
6550 fi
6551 done
6552 IFS="$ac_save_ifs"
ca9f4b81
AO
6553fi
6554fi
af71363e 6555RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
2693c0b0 6556if test -n "$RANLIB_FOR_TARGET"; then
af71363e 6557 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
ca9f4b81 6558else
af71363e 6559 echo "$ac_t""no" 1>&6
ca9f4b81 6560fi
af71363e 6561
e8b05380
PB
6562 fi
6563 test -n "$ac_cv_prog_RANLIB_FOR_TARGET" && break
6564 done
6565fi
af71363e 6566
e8b05380
PB
6567if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
6568 set dummy ranlib
6569 if test $build = $target ; then
6570 RANLIB_FOR_TARGET="$2"
6571 else
6572 RANLIB_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 6573 fi
e8b05380 6574fi
2693c0b0 6575
d1f8db0c
PB
6576else
6577 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
ca9f4b81
AO
6578fi
6579
e8b05380
PB
6580
6581
6582
6583if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
6584 if test -n "$with_build_time_tools"; then
af71363e 6585 echo $ac_n "checking for strip in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6586echo "configure:6587: checking for strip in $with_build_time_tools" >&5
d1f8db0c
PB
6587 if test -x $with_build_time_tools/strip; then
6588 STRIP_FOR_TARGET=`cd $with_build_time_tools && pwd`/strip
6589 ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
af71363e 6590 echo "$ac_t""$ac_cv_path_STRIP_FOR_TARGET" 1>&6
d1f8db0c 6591 else
af71363e 6592 echo "$ac_t""no" 1>&6
d1f8db0c 6593 fi
e8b05380
PB
6594 elif test $build != $host && test $have_gcc_for_target = yes; then
6595 STRIP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=strip`
6596 test $STRIP_FOR_TARGET=strip && STRIP_FOR_TARGET=
6597 ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
6598 fi
6599fi
6600if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
6601 # Extract the first word of "strip", so it can be a program name with args.
6602set dummy strip; ac_word=$2
af71363e 6603echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6604echo "configure:6605: checking for $ac_word" >&5
af71363e
AS
6605if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
6606 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6607else
af71363e
AS
6608 case "$STRIP_FOR_TARGET" in
6609 /*)
e8b05380
PB
6610 ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a path.
6611 ;;
af71363e
AS
6612 ?:/*)
6613 ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a dos path.
6614 ;;
e8b05380 6615 *)
af71363e
AS
6616 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6617 ac_dummy="$gcc_cv_tool_dirs"
6618 for ac_dir in $ac_dummy; do
6619 test -z "$ac_dir" && ac_dir=.
6620 if test -f $ac_dir/$ac_word; then
6621 ac_cv_path_STRIP_FOR_TARGET="$ac_dir/$ac_word"
6622 break
6623 fi
6624 done
6625 IFS="$ac_save_ifs"
e8b05380
PB
6626 ;;
6627esac
6628fi
af71363e 6629STRIP_FOR_TARGET="$ac_cv_path_STRIP_FOR_TARGET"
e8b05380 6630if test -n "$STRIP_FOR_TARGET"; then
af71363e 6631 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
e8b05380 6632else
af71363e 6633 echo "$ac_t""no" 1>&6
e8b05380
PB
6634fi
6635
6636fi
6637if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
6638 if test -n "$with_build_time_tools"; then
6639 for ncn_progname in strip; do
af71363e 6640 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6641echo "configure:6642: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6642 if test -x $with_build_time_tools/${ncn_progname}; then
6643 ac_cv_prog_STRIP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6644 echo "$ac_t""yes" 1>&6
e8b05380
PB
6645 break
6646 else
af71363e 6647 echo "$ac_t""no" 1>&6
e8b05380
PB
6648 fi
6649 done
6650fi
6651
6652if test -z "$ac_cv_prog_STRIP_FOR_TARGET"; then
6653 for ncn_progname in strip; do
6654 if test -n "$ncn_target_tool_prefix"; then
6655 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 6656set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6657echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6658echo "configure:6659: checking for $ac_word" >&5
af71363e
AS
6659if eval "test \"`echo '$''{'ac_cv_prog_STRIP_FOR_TARGET'+set}'`\" = set"; then
6660 echo $ac_n "(cached) $ac_c" 1>&6
6661else
6662 if test -n "$STRIP_FOR_TARGET"; then
6663 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
6664else
6665 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6666 ac_dummy="$PATH"
6667 for ac_dir in $ac_dummy; do
6668 test -z "$ac_dir" && ac_dir=.
6669 if test -f $ac_dir/$ac_word; then
6670 ac_cv_prog_STRIP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6671 break
6672 fi
6673 done
6674 IFS="$ac_save_ifs"
040b1c5a
GK
6675fi
6676fi
af71363e 6677STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
040b1c5a 6678if test -n "$STRIP_FOR_TARGET"; then
af71363e 6679 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
040b1c5a 6680else
af71363e 6681 echo "$ac_t""no" 1>&6
040b1c5a
GK
6682fi
6683
e8b05380
PB
6684 fi
6685 if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test $build = $target ; then
6686 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 6687set dummy ${ncn_progname}; ac_word=$2
af71363e 6688echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6689echo "configure:6690: checking for $ac_word" >&5
af71363e
AS
6690if eval "test \"`echo '$''{'ac_cv_prog_STRIP_FOR_TARGET'+set}'`\" = set"; then
6691 echo $ac_n "(cached) $ac_c" 1>&6
040b1c5a
GK
6692else
6693 if test -n "$STRIP_FOR_TARGET"; then
6694 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
6695else
af71363e
AS
6696 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6697 ac_dummy="$PATH"
6698 for ac_dir in $ac_dummy; do
6699 test -z "$ac_dir" && ac_dir=.
6700 if test -f $ac_dir/$ac_word; then
6701 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
6702 break
6703 fi
6704 done
6705 IFS="$ac_save_ifs"
040b1c5a
GK
6706fi
6707fi
af71363e 6708STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
040b1c5a 6709if test -n "$STRIP_FOR_TARGET"; then
af71363e 6710 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
040b1c5a 6711else
af71363e 6712 echo "$ac_t""no" 1>&6
040b1c5a 6713fi
af71363e 6714
e8b05380
PB
6715 fi
6716 test -n "$ac_cv_prog_STRIP_FOR_TARGET" && break
6717 done
6718fi
af71363e 6719
040b1c5a
GK
6720if test -z "$ac_cv_prog_STRIP_FOR_TARGET" ; then
6721 set dummy strip
6722 if test $build = $target ; then
6723 STRIP_FOR_TARGET="$2"
6724 else
6725 STRIP_FOR_TARGET="${ncn_target_tool_prefix}$2"
6726 fi
6727fi
6728
d1f8db0c
PB
6729else
6730 STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
e8b05380
PB
6731fi
6732
6733
6734
6735
6736if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
6737 if test -n "$with_build_time_tools"; then
af71363e 6738 echo $ac_n "checking for windres in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6739echo "configure:6740: checking for windres in $with_build_time_tools" >&5
d1f8db0c
PB
6740 if test -x $with_build_time_tools/windres; then
6741 WINDRES_FOR_TARGET=`cd $with_build_time_tools && pwd`/windres
6742 ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
af71363e 6743 echo "$ac_t""$ac_cv_path_WINDRES_FOR_TARGET" 1>&6
d1f8db0c 6744 else
af71363e 6745 echo "$ac_t""no" 1>&6
d1f8db0c 6746 fi
e8b05380
PB
6747 elif test $build != $host && test $have_gcc_for_target = yes; then
6748 WINDRES_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windres`
6749 test $WINDRES_FOR_TARGET=windres && WINDRES_FOR_TARGET=
6750 ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
6751 fi
6752fi
6753if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
6754 # Extract the first word of "windres", so it can be a program name with args.
6755set dummy windres; ac_word=$2
af71363e 6756echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6757echo "configure:6758: checking for $ac_word" >&5
af71363e
AS
6758if eval "test \"`echo '$''{'ac_cv_path_WINDRES_FOR_TARGET'+set}'`\" = set"; then
6759 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6760else
af71363e
AS
6761 case "$WINDRES_FOR_TARGET" in
6762 /*)
e8b05380
PB
6763 ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a path.
6764 ;;
af71363e
AS
6765 ?:/*)
6766 ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a dos path.
6767 ;;
e8b05380 6768 *)
af71363e
AS
6769 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6770 ac_dummy="$gcc_cv_tool_dirs"
6771 for ac_dir in $ac_dummy; do
6772 test -z "$ac_dir" && ac_dir=.
6773 if test -f $ac_dir/$ac_word; then
6774 ac_cv_path_WINDRES_FOR_TARGET="$ac_dir/$ac_word"
6775 break
6776 fi
6777 done
6778 IFS="$ac_save_ifs"
e8b05380
PB
6779 ;;
6780esac
6781fi
af71363e 6782WINDRES_FOR_TARGET="$ac_cv_path_WINDRES_FOR_TARGET"
e8b05380 6783if test -n "$WINDRES_FOR_TARGET"; then
af71363e 6784 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
e8b05380 6785else
af71363e 6786 echo "$ac_t""no" 1>&6
e8b05380
PB
6787fi
6788
6789fi
6790if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
6791 if test -n "$with_build_time_tools"; then
6792 for ncn_progname in windres; do
af71363e 6793 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
5305be7e 6794echo "configure:6795: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6795 if test -x $with_build_time_tools/${ncn_progname}; then
6796 ac_cv_prog_WINDRES_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6797 echo "$ac_t""yes" 1>&6
e8b05380
PB
6798 break
6799 else
af71363e 6800 echo "$ac_t""no" 1>&6
e8b05380
PB
6801 fi
6802 done
6803fi
6804
6805if test -z "$ac_cv_prog_WINDRES_FOR_TARGET"; then
6806 for ncn_progname in windres; do
6807 if test -n "$ncn_target_tool_prefix"; then
6808 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 6809set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6810echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6811echo "configure:6812: checking for $ac_word" >&5
af71363e
AS
6812if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
6813 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6814else
4de997d1
PB
6815 if test -n "$WINDRES_FOR_TARGET"; then
6816 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 6817else
af71363e
AS
6818 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6819 ac_dummy="$PATH"
6820 for ac_dir in $ac_dummy; do
6821 test -z "$ac_dir" && ac_dir=.
6822 if test -f $ac_dir/$ac_word; then
6823 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6824 break
6825 fi
6826 done
6827 IFS="$ac_save_ifs"
ca9f4b81
AO
6828fi
6829fi
af71363e 6830WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
4de997d1 6831if test -n "$WINDRES_FOR_TARGET"; then
af71363e 6832 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
ca9f4b81 6833else
af71363e 6834 echo "$ac_t""no" 1>&6
ca9f4b81
AO
6835fi
6836
e8b05380
PB
6837 fi
6838 if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test $build = $target ; then
6839 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 6840set dummy ${ncn_progname}; ac_word=$2
af71363e 6841echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5305be7e 6842echo "configure:6843: checking for $ac_word" >&5
af71363e
AS
6843if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
6844 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6845else
2693c0b0
PB
6846 if test -n "$WINDRES_FOR_TARGET"; then
6847 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 6848else
af71363e
AS
6849 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6850 ac_dummy="$PATH"
6851 for ac_dir in $ac_dummy; do
6852 test -z "$ac_dir" && ac_dir=.
6853 if test -f $ac_dir/$ac_word; then
6854 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
6855 break
6856 fi
6857 done
6858 IFS="$ac_save_ifs"
ca9f4b81
AO
6859fi
6860fi
af71363e 6861WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
2693c0b0 6862if test -n "$WINDRES_FOR_TARGET"; then
af71363e 6863 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
ca9f4b81 6864else
af71363e 6865 echo "$ac_t""no" 1>&6
ca9f4b81 6866fi
af71363e 6867
e8b05380
PB
6868 fi
6869 test -n "$ac_cv_prog_WINDRES_FOR_TARGET" && break
6870 done
6871fi
af71363e 6872
2693c0b0
PB
6873if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
6874 set dummy windres
6875 if test $build = $target ; then
6876 WINDRES_FOR_TARGET="$2"
ca9f4b81 6877 else
2693c0b0 6878 WINDRES_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 6879 fi
ca9f4b81
AO
6880fi
6881
d1f8db0c
PB
6882else
6883 WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
e8b05380
PB
6884fi
6885
4977bab6 6886
2abefe3d
PB
6887RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET"
6888
af71363e 6889echo $ac_n "checking where to find the target ar""... $ac_c" 1>&6
5305be7e 6890echo "configure:6891: checking where to find the target ar" >&5
2abefe3d 6891if test "x${build}" != "x${host}" ; then
e8b05380
PB
6892 if expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
6893 # We already found the complete path
af71363e 6894 echo "$ac_t""pre-installed in `dirname $AR_FOR_TARGET`" 1>&6
e8b05380
PB
6895 else
6896 # Canadian cross, just use what we found
af71363e 6897 echo "$ac_t""pre-installed" 1>&6
e8b05380 6898 fi
2abefe3d
PB
6899else
6900 ok=yes
6901 case " ${configdirs} " in
6902 *" binutils "*) ;;
6903 *) ok=no ;;
6904 esac
af71363e 6905
2abefe3d
PB
6906 if test $ok = yes; then
6907 # An in-tree tool is available and we can use it
6908 AR_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ar'
af71363e 6909 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6910 elif expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
6911 # We already found the complete path
af71363e 6912 echo "$ac_t""pre-installed in `dirname $AR_FOR_TARGET`" 1>&6
2abefe3d
PB
6913 elif test "x$target" = "x$host"; then
6914 # We can use an host tool
6915 AR_FOR_TARGET='$(AR)'
af71363e 6916 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6917 else
6918 # We need a cross tool
af71363e 6919 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6920 fi
6921fi
0b0dc272 6922
af71363e 6923echo $ac_n "checking where to find the target as""... $ac_c" 1>&6
5305be7e 6924echo "configure:6925: checking where to find the target as" >&5
2abefe3d 6925if test "x${build}" != "x${host}" ; then
e8b05380
PB
6926 if expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
6927 # We already found the complete path
af71363e 6928 echo "$ac_t""pre-installed in `dirname $AS_FOR_TARGET`" 1>&6
e8b05380
PB
6929 else
6930 # Canadian cross, just use what we found
af71363e 6931 echo "$ac_t""pre-installed" 1>&6
e8b05380 6932 fi
2abefe3d
PB
6933else
6934 ok=yes
6935 case " ${configdirs} " in
6936 *" gas "*) ;;
6937 *) ok=no ;;
6938 esac
af71363e 6939
2abefe3d
PB
6940 if test $ok = yes; then
6941 # An in-tree tool is available and we can use it
6942 AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gas/as-new'
af71363e 6943 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6944 elif expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
6945 # We already found the complete path
af71363e 6946 echo "$ac_t""pre-installed in `dirname $AS_FOR_TARGET`" 1>&6
2abefe3d
PB
6947 elif test "x$target" = "x$host"; then
6948 # We can use an host tool
6949 AS_FOR_TARGET='$(AS)'
af71363e 6950 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6951 else
6952 # We need a cross tool
af71363e 6953 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6954 fi
6955fi
0b0dc272 6956
af71363e 6957echo $ac_n "checking where to find the target cc""... $ac_c" 1>&6
5305be7e 6958echo "configure:6959: checking where to find the target cc" >&5
2abefe3d 6959if test "x${build}" != "x${host}" ; then
e8b05380
PB
6960 if expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
6961 # We already found the complete path
af71363e 6962 echo "$ac_t""pre-installed in `dirname $CC_FOR_TARGET`" 1>&6
e8b05380
PB
6963 else
6964 # Canadian cross, just use what we found
af71363e 6965 echo "$ac_t""pre-installed" 1>&6
e8b05380 6966 fi
2abefe3d
PB
6967else
6968 ok=yes
6969 case " ${configdirs} " in
6970 *" gcc "*) ;;
6971 *) ok=no ;;
6972 esac
af71363e 6973
2abefe3d
PB
6974 if test $ok = yes; then
6975 # An in-tree tool is available and we can use it
6976 CC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 6977 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6978 elif expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
6979 # We already found the complete path
af71363e 6980 echo "$ac_t""pre-installed in `dirname $CC_FOR_TARGET`" 1>&6
2abefe3d
PB
6981 elif test "x$target" = "x$host"; then
6982 # We can use an host tool
6983 CC_FOR_TARGET='$(CC)'
af71363e 6984 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6985 else
6986 # We need a cross tool
af71363e 6987 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6988 fi
6989fi
0b0dc272 6990
af71363e 6991echo $ac_n "checking where to find the target c++""... $ac_c" 1>&6
5305be7e 6992echo "configure:6993: checking where to find the target c++" >&5
2abefe3d 6993if test "x${build}" != "x${host}" ; then
e8b05380
PB
6994 if expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
6995 # We already found the complete path
af71363e 6996 echo "$ac_t""pre-installed in `dirname $CXX_FOR_TARGET`" 1>&6
e8b05380
PB
6997 else
6998 # Canadian cross, just use what we found
af71363e 6999 echo "$ac_t""pre-installed" 1>&6
e8b05380 7000 fi
2abefe3d
PB
7001else
7002 ok=yes
7003 case " ${configdirs} " in
7004 *" gcc "*) ;;
7005 *) ok=no ;;
7006 esac
7007 case ,${enable_languages}, in
7008 *,c++,*) ;;
7009 *) ok=no ;;
7010 esac
7011 if test $ok = yes; then
7012 # An in-tree tool is available and we can use it
7013 CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/g++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
af71363e 7014 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7015 elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
7016 # We already found the complete path
af71363e 7017 echo "$ac_t""pre-installed in `dirname $CXX_FOR_TARGET`" 1>&6
2abefe3d
PB
7018 elif test "x$target" = "x$host"; then
7019 # We can use an host tool
7020 CXX_FOR_TARGET='$(CXX)'
af71363e 7021 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7022 else
7023 # We need a cross tool
af71363e 7024 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7025 fi
7026fi
0b0dc272 7027
af71363e 7028echo $ac_n "checking where to find the target c++ for libstdc++""... $ac_c" 1>&6
5305be7e 7029echo "configure:7030: checking where to find the target c++ for libstdc++" >&5
2abefe3d 7030if test "x${build}" != "x${host}" ; then
e8b05380
PB
7031 if expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
7032 # We already found the complete path
af71363e 7033 echo "$ac_t""pre-installed in `dirname $RAW_CXX_FOR_TARGET`" 1>&6
e8b05380
PB
7034 else
7035 # Canadian cross, just use what we found
af71363e 7036 echo "$ac_t""pre-installed" 1>&6
e8b05380 7037 fi
2abefe3d
PB
7038else
7039 ok=yes
7040 case " ${configdirs} " in
7041 *" gcc "*) ;;
7042 *) ok=no ;;
7043 esac
7044 case ,${enable_languages}, in
7045 *,c++,*) ;;
7046 *) ok=no ;;
7047 esac
7048 if test $ok = yes; then
7049 # An in-tree tool is available and we can use it
7050 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'
af71363e 7051 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7052 elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
7053 # We already found the complete path
af71363e 7054 echo "$ac_t""pre-installed in `dirname $RAW_CXX_FOR_TARGET`" 1>&6
2abefe3d
PB
7055 elif test "x$target" = "x$host"; then
7056 # We can use an host tool
7057 RAW_CXX_FOR_TARGET='$(CXX)'
af71363e 7058 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7059 else
7060 # We need a cross tool
af71363e 7061 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7062 fi
7063fi
0b0dc272 7064
af71363e 7065echo $ac_n "checking where to find the target dlltool""... $ac_c" 1>&6
5305be7e 7066echo "configure:7067: checking where to find the target dlltool" >&5
2abefe3d 7067if test "x${build}" != "x${host}" ; then
e8b05380
PB
7068 if expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
7069 # We already found the complete path
af71363e 7070 echo "$ac_t""pre-installed in `dirname $DLLTOOL_FOR_TARGET`" 1>&6
e8b05380
PB
7071 else
7072 # Canadian cross, just use what we found
af71363e 7073 echo "$ac_t""pre-installed" 1>&6
e8b05380 7074 fi
2abefe3d
PB
7075else
7076 ok=yes
7077 case " ${configdirs} " in
7078 *" binutils "*) ;;
7079 *) ok=no ;;
7080 esac
af71363e 7081
2abefe3d
PB
7082 if test $ok = yes; then
7083 # An in-tree tool is available and we can use it
7084 DLLTOOL_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/dlltool'
af71363e 7085 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7086 elif expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
7087 # We already found the complete path
af71363e 7088 echo "$ac_t""pre-installed in `dirname $DLLTOOL_FOR_TARGET`" 1>&6
2abefe3d
PB
7089 elif test "x$target" = "x$host"; then
7090 # We can use an host tool
7091 DLLTOOL_FOR_TARGET='$(DLLTOOL)'
af71363e 7092 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7093 else
7094 # We need a cross tool
af71363e 7095 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7096 fi
7097fi
0b0dc272 7098
af71363e 7099echo $ac_n "checking where to find the target gcc""... $ac_c" 1>&6
5305be7e 7100echo "configure:7101: checking where to find the target gcc" >&5
2abefe3d 7101if test "x${build}" != "x${host}" ; then
e8b05380
PB
7102 if expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
7103 # We already found the complete path
af71363e 7104 echo "$ac_t""pre-installed in `dirname $GCC_FOR_TARGET`" 1>&6
e8b05380
PB
7105 else
7106 # Canadian cross, just use what we found
af71363e 7107 echo "$ac_t""pre-installed" 1>&6
e8b05380 7108 fi
2abefe3d
PB
7109else
7110 ok=yes
7111 case " ${configdirs} " in
7112 *" gcc "*) ;;
7113 *) ok=no ;;
7114 esac
af71363e 7115
2abefe3d
PB
7116 if test $ok = yes; then
7117 # An in-tree tool is available and we can use it
7118 GCC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 7119 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7120 elif expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
7121 # We already found the complete path
af71363e 7122 echo "$ac_t""pre-installed in `dirname $GCC_FOR_TARGET`" 1>&6
2abefe3d
PB
7123 elif test "x$target" = "x$host"; then
7124 # We can use an host tool
7125 GCC_FOR_TARGET='$()'
af71363e 7126 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7127 else
7128 # We need a cross tool
af71363e 7129 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7130 fi
7131fi
0b0dc272 7132
af71363e 7133echo $ac_n "checking where to find the target gcj""... $ac_c" 1>&6
5305be7e 7134echo "configure:7135: checking where to find the target gcj" >&5
2abefe3d 7135if test "x${build}" != "x${host}" ; then
e8b05380
PB
7136 if expr "x$GCJ_FOR_TARGET" : "x/" > /dev/null; then
7137 # We already found the complete path
af71363e 7138 echo "$ac_t""pre-installed in `dirname $GCJ_FOR_TARGET`" 1>&6
e8b05380
PB
7139 else
7140 # Canadian cross, just use what we found
af71363e 7141 echo "$ac_t""pre-installed" 1>&6
e8b05380 7142 fi
2abefe3d
PB
7143else
7144 ok=yes
7145 case " ${configdirs} " in
7146 *" gcc "*) ;;
7147 *) ok=no ;;
7148 esac
7149 case ,${enable_languages}, in
7150 *,java,*) ;;
7151 *) ok=no ;;
7152 esac
7153 if test $ok = yes; then
7154 # An in-tree tool is available and we can use it
7155 GCJ_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gcj -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 7156 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7157 elif expr "x$GCJ_FOR_TARGET" : "x/" > /dev/null; then
7158 # We already found the complete path
af71363e 7159 echo "$ac_t""pre-installed in `dirname $GCJ_FOR_TARGET`" 1>&6
2abefe3d
PB
7160 elif test "x$target" = "x$host"; then
7161 # We can use an host tool
7162 GCJ_FOR_TARGET='$(GCJ)'
af71363e 7163 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7164 else
7165 # We need a cross tool
af71363e 7166 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7167 fi
7168fi
0b0dc272 7169
af71363e 7170echo $ac_n "checking where to find the target gfortran""... $ac_c" 1>&6
5305be7e 7171echo "configure:7172: checking where to find the target gfortran" >&5
2abefe3d 7172if test "x${build}" != "x${host}" ; then
e8b05380
PB
7173 if expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
7174 # We already found the complete path
af71363e 7175 echo "$ac_t""pre-installed in `dirname $GFORTRAN_FOR_TARGET`" 1>&6
e8b05380
PB
7176 else
7177 # Canadian cross, just use what we found
af71363e 7178 echo "$ac_t""pre-installed" 1>&6
e8b05380 7179 fi
2abefe3d
PB
7180else
7181 ok=yes
7182 case " ${configdirs} " in
7183 *" gcc "*) ;;
7184 *) ok=no ;;
7185 esac
7186 case ,${enable_languages}, in
7187 *,fortran,*) ;;
7188 *) ok=no ;;
7189 esac
7190 if test $ok = yes; then
7191 # An in-tree tool is available and we can use it
7192 GFORTRAN_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 7193 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7194 elif expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
7195 # We already found the complete path
af71363e 7196 echo "$ac_t""pre-installed in `dirname $GFORTRAN_FOR_TARGET`" 1>&6
2abefe3d
PB
7197 elif test "x$target" = "x$host"; then
7198 # We can use an host tool
7199 GFORTRAN_FOR_TARGET='$(GFORTRAN)'
af71363e 7200 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7201 else
7202 # We need a cross tool
af71363e 7203 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7204 fi
7205fi
0b0dc272 7206
af71363e 7207echo $ac_n "checking where to find the target ld""... $ac_c" 1>&6
5305be7e 7208echo "configure:7209: checking where to find the target ld" >&5
2abefe3d 7209if test "x${build}" != "x${host}" ; then
e8b05380
PB
7210 if expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
7211 # We already found the complete path
af71363e 7212 echo "$ac_t""pre-installed in `dirname $LD_FOR_TARGET`" 1>&6
e8b05380
PB
7213 else
7214 # Canadian cross, just use what we found
af71363e 7215 echo "$ac_t""pre-installed" 1>&6
e8b05380 7216 fi
2abefe3d
PB
7217else
7218 ok=yes
7219 case " ${configdirs} " in
7220 *" ld "*) ;;
7221 *) ok=no ;;
7222 esac
af71363e 7223
2abefe3d
PB
7224 if test $ok = yes; then
7225 # An in-tree tool is available and we can use it
7226 LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/ld/ld-new'
af71363e 7227 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7228 elif expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
7229 # We already found the complete path
af71363e 7230 echo "$ac_t""pre-installed in `dirname $LD_FOR_TARGET`" 1>&6
2abefe3d
PB
7231 elif test "x$target" = "x$host"; then
7232 # We can use an host tool
7233 LD_FOR_TARGET='$(LD)'
af71363e 7234 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7235 else
7236 # We need a cross tool
af71363e 7237 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7238 fi
7239fi
0b0dc272 7240
af71363e 7241echo $ac_n "checking where to find the target lipo""... $ac_c" 1>&6
5305be7e 7242echo "configure:7243: checking where to find the target lipo" >&5
2abefe3d 7243if test "x${build}" != "x${host}" ; then
e8b05380
PB
7244 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
7245 # We already found the complete path
af71363e 7246 echo "$ac_t""pre-installed in `dirname $LIPO_FOR_TARGET`" 1>&6
e8b05380
PB
7247 else
7248 # Canadian cross, just use what we found
af71363e 7249 echo "$ac_t""pre-installed" 1>&6
e8b05380 7250 fi
2abefe3d 7251else
e8b05380
PB
7252 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
7253 # We already found the complete path
af71363e 7254 echo "$ac_t""pre-installed in `dirname $LIPO_FOR_TARGET`" 1>&6
e8b05380 7255 elif test "x$target" = "x$host"; then
2abefe3d
PB
7256 # We can use an host tool
7257 LIPO_FOR_TARGET='$(LIPO)'
af71363e 7258 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7259 else
7260 # We need a cross tool
af71363e 7261 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7262 fi
7263fi
0b0dc272 7264
af71363e 7265echo $ac_n "checking where to find the target nm""... $ac_c" 1>&6
5305be7e 7266echo "configure:7267: checking where to find the target nm" >&5
2abefe3d 7267if test "x${build}" != "x${host}" ; then
e8b05380
PB
7268 if expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
7269 # We already found the complete path
af71363e 7270 echo "$ac_t""pre-installed in `dirname $NM_FOR_TARGET`" 1>&6
e8b05380
PB
7271 else
7272 # Canadian cross, just use what we found
af71363e 7273 echo "$ac_t""pre-installed" 1>&6
e8b05380 7274 fi
2abefe3d
PB
7275else
7276 ok=yes
7277 case " ${configdirs} " in
7278 *" binutils "*) ;;
7279 *) ok=no ;;
7280 esac
af71363e 7281
2abefe3d
PB
7282 if test $ok = yes; then
7283 # An in-tree tool is available and we can use it
7284 NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/nm-new'
af71363e 7285 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7286 elif expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
7287 # We already found the complete path
af71363e 7288 echo "$ac_t""pre-installed in `dirname $NM_FOR_TARGET`" 1>&6
2abefe3d
PB
7289 elif test "x$target" = "x$host"; then
7290 # We can use an host tool
7291 NM_FOR_TARGET='$(NM)'
af71363e 7292 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7293 else
7294 # We need a cross tool
af71363e 7295 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7296 fi
7297fi
0b0dc272 7298
af71363e 7299echo $ac_n "checking where to find the target objdump""... $ac_c" 1>&6
5305be7e 7300echo "configure:7301: checking where to find the target objdump" >&5
2abefe3d 7301if test "x${build}" != "x${host}" ; then
e8b05380
PB
7302 if expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
7303 # We already found the complete path
af71363e 7304 echo "$ac_t""pre-installed in `dirname $OBJDUMP_FOR_TARGET`" 1>&6
e8b05380
PB
7305 else
7306 # Canadian cross, just use what we found
af71363e 7307 echo "$ac_t""pre-installed" 1>&6
e8b05380 7308 fi
2abefe3d
PB
7309else
7310 ok=yes
7311 case " ${configdirs} " in
7312 *" binutils "*) ;;
7313 *) ok=no ;;
7314 esac
af71363e 7315
2abefe3d
PB
7316 if test $ok = yes; then
7317 # An in-tree tool is available and we can use it
7318 OBJDUMP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objdump'
af71363e 7319 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7320 elif expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
7321 # We already found the complete path
af71363e 7322 echo "$ac_t""pre-installed in `dirname $OBJDUMP_FOR_TARGET`" 1>&6
2abefe3d
PB
7323 elif test "x$target" = "x$host"; then
7324 # We can use an host tool
7325 OBJDUMP_FOR_TARGET='$(OBJDUMP)'
af71363e 7326 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7327 else
7328 # We need a cross tool
af71363e 7329 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7330 fi
7331fi
0b0dc272 7332
af71363e 7333echo $ac_n "checking where to find the target ranlib""... $ac_c" 1>&6
5305be7e 7334echo "configure:7335: checking where to find the target ranlib" >&5
2abefe3d 7335if test "x${build}" != "x${host}" ; then
e8b05380
PB
7336 if expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
7337 # We already found the complete path
af71363e 7338 echo "$ac_t""pre-installed in `dirname $RANLIB_FOR_TARGET`" 1>&6
e8b05380
PB
7339 else
7340 # Canadian cross, just use what we found
af71363e 7341 echo "$ac_t""pre-installed" 1>&6
e8b05380 7342 fi
2abefe3d
PB
7343else
7344 ok=yes
7345 case " ${configdirs} " in
7346 *" binutils "*) ;;
7347 *) ok=no ;;
7348 esac
af71363e 7349
2abefe3d
PB
7350 if test $ok = yes; then
7351 # An in-tree tool is available and we can use it
7352 RANLIB_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ranlib'
af71363e 7353 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7354 elif expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
7355 # We already found the complete path
af71363e 7356 echo "$ac_t""pre-installed in `dirname $RANLIB_FOR_TARGET`" 1>&6
2abefe3d
PB
7357 elif test "x$target" = "x$host"; then
7358 # We can use an host tool
7359 RANLIB_FOR_TARGET='$(RANLIB)'
af71363e 7360 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7361 else
7362 # We need a cross tool
af71363e 7363 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7364 fi
7365fi
0b0dc272 7366
af71363e 7367echo $ac_n "checking where to find the target strip""... $ac_c" 1>&6
5305be7e 7368echo "configure:7369: checking where to find the target strip" >&5
2abefe3d 7369if test "x${build}" != "x${host}" ; then
e8b05380
PB
7370 if expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
7371 # We already found the complete path
af71363e 7372 echo "$ac_t""pre-installed in `dirname $STRIP_FOR_TARGET`" 1>&6
e8b05380
PB
7373 else
7374 # Canadian cross, just use what we found
af71363e 7375 echo "$ac_t""pre-installed" 1>&6
e8b05380 7376 fi
2abefe3d
PB
7377else
7378 ok=yes
7379 case " ${configdirs} " in
7380 *" binutils "*) ;;
7381 *) ok=no ;;
7382 esac
af71363e 7383
2abefe3d
PB
7384 if test $ok = yes; then
7385 # An in-tree tool is available and we can use it
7386 STRIP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/strip'
af71363e 7387 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7388 elif expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
7389 # We already found the complete path
af71363e 7390 echo "$ac_t""pre-installed in `dirname $STRIP_FOR_TARGET`" 1>&6
2abefe3d
PB
7391 elif test "x$target" = "x$host"; then
7392 # We can use an host tool
7393 STRIP_FOR_TARGET='$(STRIP)'
af71363e 7394 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7395 else
7396 # We need a cross tool
af71363e 7397 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7398 fi
7399fi
0b0dc272 7400
af71363e 7401echo $ac_n "checking where to find the target windres""... $ac_c" 1>&6
5305be7e 7402echo "configure:7403: checking where to find the target windres" >&5
2abefe3d 7403if test "x${build}" != "x${host}" ; then
e8b05380
PB
7404 if expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
7405 # We already found the complete path
af71363e 7406 echo "$ac_t""pre-installed in `dirname $WINDRES_FOR_TARGET`" 1>&6
e8b05380
PB
7407 else
7408 # Canadian cross, just use what we found
af71363e 7409 echo "$ac_t""pre-installed" 1>&6
e8b05380 7410 fi
2abefe3d
PB
7411else
7412 ok=yes
7413 case " ${configdirs} " in
7414 *" binutils "*) ;;
7415 *) ok=no ;;
7416 esac
af71363e 7417
2abefe3d
PB
7418 if test $ok = yes; then
7419 # An in-tree tool is available and we can use it
7420 WINDRES_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windres'
af71363e 7421 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7422 elif expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
7423 # We already found the complete path
af71363e 7424 echo "$ac_t""pre-installed in `dirname $WINDRES_FOR_TARGET`" 1>&6
2abefe3d
PB
7425 elif test "x$target" = "x$host"; then
7426 # We can use an host tool
7427 WINDRES_FOR_TARGET='$(WINDRES)'
af71363e 7428 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7429 else
7430 # We need a cross tool
af71363e 7431 echo "$ac_t""pre-installed" 1>&6
2abefe3d 7432 fi
671aa708 7433fi
be912515
NN
7434
7435
7436
2abefe3d 7437
0b0dc272 7438
671aa708
NN
7439# Certain tools may need extra flags.
7440AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
7441RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
7442NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
7443
2abefe3d
PB
7444# When building target libraries, except in a Canadian cross, we use
7445# the same toolchain as the compiler we just built.
7446COMPILER_AS_FOR_TARGET='$(AS_FOR_TARGET)'
7447COMPILER_LD_FOR_TARGET='$(LD_FOR_TARGET)'
7448COMPILER_NM_FOR_TARGET='$(NM_FOR_TARGET)'
7449if test $host = $build; then
7450 case " $configdirs " in
7451 *" gcc "*)
7452 COMPILER_AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/as'
7453 COMPILER_LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/collect-ld'
7454 COMPILER_NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/nm'${extra_nmflags_for_target}
7455 ;;
7456 esac
7457fi
7458
7459
7460
7461
7462
af71363e 7463echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
5305be7e 7464echo "configure:7465: checking whether to enable maintainer-specific portions of Makefiles" >&5
ee03dc5e
AO
7465# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
7466if test "${enable_maintainer_mode+set}" = set; then
7467 enableval="$enable_maintainer_mode"
7468 USE_MAINTAINER_MODE=$enableval
7469else
7470 USE_MAINTAINER_MODE=no
af71363e
AS
7471fi
7472
7473echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
ee03dc5e
AO
7474
7475
7476if test "$USE_MAINTAINER_MODE" = yes; then
7477 MAINTAINER_MODE_TRUE=
7478 MAINTAINER_MODE_FALSE='#'
7479else
7480 MAINTAINER_MODE_TRUE='#'
7481 MAINTAINER_MODE_FALSE=
af71363e 7482fi
ee03dc5e
AO
7483MAINT=$MAINTAINER_MODE_TRUE
7484
2805b53a
NN
7485# ---------------------
7486# GCC bootstrap support
7487# ---------------------
7488
7489# Stage specific cflags for build.
7490stage1_cflags="-g"
7491case $build in
7492 vax-*-*)
7493 case ${GCC} in
7494 yes) stage1_cflags="-g -Wa,-J" ;;
7495 *) stage1_cflags="-g -J" ;;
7496 esac ;;
2805b53a
NN
7497esac
7498
0b50988a
EB
7499# This is aimed to mimic bootstrap with a non-GCC compiler to catch problems.
7500if test "$GCC" = yes; then
7501 saved_CFLAGS="$CFLAGS"
7502
7503 # Pass -fkeep-inline-functions for stage 1 if the GCC version supports it.
7504 CFLAGS="$CFLAGS -fkeep-inline-functions"
af71363e 7505 echo $ac_n "checking whether -fkeep-inline-functions is supported""... $ac_c" 1>&6
5305be7e 7506echo "configure:7507: checking whether -fkeep-inline-functions is supported" >&5
af71363e 7507 cat > conftest.$ac_ext <<EOF
5305be7e 7508#line 7509 "configure"
af71363e
AS
7509#include "confdefs.h"
7510
7511int main() {
7512
7513; return 0; }
7514EOF
5305be7e 7515if { (eval echo configure:7516: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
af71363e
AS
7516 rm -rf conftest*
7517 echo "$ac_t""yes" 1>&6; stage1_cflags="$stage1_cflags -fkeep-inline-functions"
7518else
7519 echo "configure: failed program was:" >&5
7520 cat conftest.$ac_ext >&5
7521 rm -rf conftest*
7522 echo "$ac_t""no" 1>&6
7523fi
7524rm -f conftest*
0b50988a
EB
7525
7526 CFLAGS="$saved_CFLAGS"
7527fi
7528
7529
2805b53a 7530
8efea775
PB
7531# Enable --enable-checking in stage1 of the compiler.
7532# Check whether --enable-stage1-checking or --disable-stage1-checking was given.
7533if test "${enable_stage1_checking+set}" = set; then
7534 enableval="$enable_stage1_checking"
7535 stage1_checking=--enable-checking=${enable_stage1_checking}
7536else
7537 if test "x$enable_checking" = xno; then
7538 stage1_checking=--enable-checking
7539else
7540 stage1_checking=--enable-checking${enable_checking+=}$enable_checking
7541fi
af71363e
AS
7542fi
7543
8efea775
PB
7544
7545
2805b53a 7546# Enable -Werror in bootstrap stage2 and later.
2805b53a
NN
7547# Check whether --enable-werror or --disable-werror was given.
7548if test "${enable_werror+set}" = set; then
7549 enableval="$enable_werror"
af71363e 7550 :
2805b53a 7551else
416cfb5e 7552 if test -d ${srcdir}/gcc && test x"`cat $srcdir/gcc/DEV-PHASE`" = xexperimental; then
2805b53a 7553 enable_werror=yes
88fceb68
PB
7554else
7555 enable_werror=no
7556fi
af71363e
AS
7557fi
7558
09a9c095
NN
7559case ${enable_werror} in
7560 yes) stage2_werror_flag="--enable-werror-always" ;;
7561 *) stage2_werror_flag="" ;;
2805b53a
NN
7562esac
7563
7564
32845532
CD
7565# Flags needed to enable html installing and building
7566# Check whether --with-datarootdir or --without-datarootdir was given.
7567if test "${with_datarootdir+set}" = set; then
7568 withval="$with_datarootdir"
7569 datarootdir="\${prefix}/${withval}"
7570else
7571 datarootdir="\${prefix}/share"
af71363e 7572fi
32845532
CD
7573
7574
7575# Check whether --with-docdir or --without-docdir was given.
7576if test "${with_docdir+set}" = set; then
7577 withval="$with_docdir"
7578 docdir="\${prefix}/${withval}"
7579else
7580 docdir="\${datarootdir}/doc"
af71363e 7581fi
32845532
CD
7582
7583
7584# Check whether --with-htmldir or --without-htmldir was given.
7585if test "${with_htmldir+set}" = set; then
7586 withval="$with_htmldir"
7587 htmldir="\${prefix}/${withval}"
7588else
7589 htmldir="\${docdir}"
af71363e
AS
7590fi
7591
32845532
CD
7592
7593
7594
7595
7596
af71363e
AS
7597trap '' 1 2 15
7598cat > confcache <<\EOF
671aa708
NN
7599# This file is a shell script that caches the results of configure
7600# tests run on this system so they can be shared between configure
af71363e
AS
7601# scripts and configure runs. It is not useful on other systems.
7602# If it contains results you don't want to keep, you may remove or edit it.
671aa708 7603#
af71363e
AS
7604# By default, configure uses ./config.cache as the cache file,
7605# creating it if it does not exist already. You can give configure
7606# the --cache-file=FILE option to use a different cache file; that is
7607# what configure does when it calls configure scripts in
7608# subdirectories, so they share the cache.
7609# Giving --cache-file=/dev/null disables caching, for debugging configure.
7610# config.status only pays attention to the cache file if you give it the
7611# --recheck option to rerun configure.
671aa708 7612#
af71363e 7613EOF
671aa708
NN
7614# The following way of writing the cache mishandles newlines in values,
7615# but we know of no workaround that is simple, portable, and efficient.
7616# So, don't put newlines in cache variables' values.
7617# Ultrix sh set writes to stderr and can't be redirected directly,
7618# and sets the high bit in the cache file unless we assign to the vars.
af71363e
AS
7619(set) 2>&1 |
7620 case `(ac_space=' '; set | grep ac_space) 2>&1` in
7621 *ac_space=\ *)
7622 # `set' does not quote correctly, so add quotes (double-quote substitution
7623 # turns \\\\ into \\, and sed turns \\ into \).
7624 sed -n \
7625 -e "s/'/'\\\\''/g" \
7626 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
7627 ;;
7628 *)
7629 # `set' quotes correctly as required by POSIX, so do not add quotes.
7630 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
7631 ;;
7632 esac >> confcache
7633if cmp -s $cache_file confcache; then
7634 :
7635else
671aa708 7636 if test -w $cache_file; then
af71363e
AS
7637 echo "updating cache $cache_file"
7638 cat confcache > $cache_file
671aa708
NN
7639 else
7640 echo "not updating unwritable cache $cache_file"
7641 fi
4977bab6 7642fi
671aa708 7643rm -f confcache
79c06341 7644
af71363e
AS
7645trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
7646
671aa708
NN
7647test "x$prefix" = xNONE && prefix=$ac_default_prefix
7648# Let make expand exec_prefix.
7649test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4e77e8f1 7650
af71363e
AS
7651# Any assignment to VPATH causes Sun make to only execute
7652# the first set of double-colon rules, so remove it if not needed.
7653# If there is a colon in the path, we need to keep it.
671aa708 7654if test "x$srcdir" = x.; then
af71363e 7655 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
671aa708 7656fi
79c06341 7657
af71363e
AS
7658trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
7659
671aa708
NN
7660# Transform confdefs.h into DEFS.
7661# Protect against shell expansion while executing Makefile rules.
7662# Protect against Makefile macro expansion.
a3993f33
KG
7663cat > conftest.defs <<\EOF
7664s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
7665s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
7666s%\[%\\&%g
7667s%\]%\\&%g
7668s%\$%$$%g
7669EOF
7670DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
7671rm -f conftest.defs
fb0103e5 7672
0b0dc272 7673
af71363e 7674# Without the "./", some shells look in PATH for config.status.
0b0dc272 7675: ${CONFIG_STATUS=./config.status}
af71363e
AS
7676
7677echo creating $CONFIG_STATUS
7678rm -f $CONFIG_STATUS
7679cat > $CONFIG_STATUS <<EOF
7680#! /bin/sh
7681# Generated automatically by configure.
671aa708 7682# Run this file to recreate the current configuration.
af71363e
AS
7683# This directory was configured as follows,
7684# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
7685#
7686# $0 $ac_configure_args
7687#
671aa708 7688# Compiler output produced by configure, useful for debugging
af71363e 7689# configure, is in ./config.log if it exists.
0b0dc272 7690
af71363e
AS
7691ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
7692for ac_option
a4b9e93e 7693do
af71363e 7694 case "\$ac_option" in
671aa708 7695 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
af71363e
AS
7696 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
7697 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
7698 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
7699 echo "$CONFIG_STATUS generated by autoconf version 2.13"
7700 exit 0 ;;
7701 -help | --help | --hel | --he | --h)
7702 echo "\$ac_cs_usage"; exit 0 ;;
7703 *) echo "\$ac_cs_usage"; exit 1 ;;
0b0dc272
AM
7704 esac
7705done
7706
af71363e
AS
7707ac_given_srcdir=$srcdir
7708ac_given_INSTALL="$INSTALL"
0b0dc272 7709
af71363e
AS
7710trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
7711EOF
7712cat >> $CONFIG_STATUS <<EOF
0b0dc272 7713
af71363e
AS
7714# Protect against being on the right side of a sed subst in config.status.
7715sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
7716 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
7717$ac_vpsub
7718$extrasub
7719s%@SHELL@%$SHELL%g
7720s%@CFLAGS@%$CFLAGS%g
7721s%@CPPFLAGS@%$CPPFLAGS%g
7722s%@CXXFLAGS@%$CXXFLAGS%g
7723s%@FFLAGS@%$FFLAGS%g
7724s%@DEFS@%$DEFS%g
7725s%@LDFLAGS@%$LDFLAGS%g
7726s%@LIBS@%$LIBS%g
7727s%@exec_prefix@%$exec_prefix%g
7728s%@prefix@%$prefix%g
7729s%@program_transform_name@%$program_transform_name%g
7730s%@bindir@%$bindir%g
7731s%@sbindir@%$sbindir%g
7732s%@libexecdir@%$libexecdir%g
7733s%@datadir@%$datadir%g
7734s%@sysconfdir@%$sysconfdir%g
7735s%@sharedstatedir@%$sharedstatedir%g
7736s%@localstatedir@%$localstatedir%g
7737s%@libdir@%$libdir%g
7738s%@includedir@%$includedir%g
7739s%@oldincludedir@%$oldincludedir%g
7740s%@infodir@%$infodir%g
7741s%@mandir@%$mandir%g
7742s%@host@%$host%g
7743s%@host_alias@%$host_alias%g
7744s%@host_cpu@%$host_cpu%g
7745s%@host_vendor@%$host_vendor%g
7746s%@host_os@%$host_os%g
7747s%@target@%$target%g
7748s%@target_alias@%$target_alias%g
7749s%@target_cpu@%$target_cpu%g
7750s%@target_vendor@%$target_vendor%g
7751s%@target_os@%$target_os%g
7752s%@build@%$build%g
7753s%@build_alias@%$build_alias%g
7754s%@build_cpu@%$build_cpu%g
7755s%@build_vendor@%$build_vendor%g
7756s%@build_os@%$build_os%g
7757s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
7758s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
7759s%@INSTALL_DATA@%$INSTALL_DATA%g
7760s%@LN@%$LN%g
7761s%@LN_S@%$LN_S%g
7762s%@TOPLEVEL_CONFIGURE_ARGUMENTS@%$TOPLEVEL_CONFIGURE_ARGUMENTS%g
7763s%@build_libsubdir@%$build_libsubdir%g
7764s%@build_subdir@%$build_subdir%g
7765s%@host_subdir@%$host_subdir%g
7766s%@target_subdir@%$target_subdir%g
7767s%@CC@%$CC%g
7768s%@GNATBIND@%$GNATBIND%g
5305be7e 7769s%@GNATMAKE@%$GNATMAKE%g
af71363e
AS
7770s%@do_compare@%$do_compare%g
7771s%@gmplibs@%$gmplibs%g
7772s%@gmpinc@%$gmpinc%g
7773s%@stage1_languages@%$stage1_languages%g
7774s%@SYSROOT_CFLAGS_FOR_TARGET@%$SYSROOT_CFLAGS_FOR_TARGET%g
671aa708 7775/@serialization_dependencies@/r $serialization_dependencies
af71363e 7776s%@serialization_dependencies@%%g
671aa708 7777/@host_makefile_frag@/r $host_makefile_frag
af71363e 7778s%@host_makefile_frag@%%g
671aa708 7779/@target_makefile_frag@/r $target_makefile_frag
af71363e 7780s%@target_makefile_frag@%%g
671aa708 7781/@alphaieee_frag@/r $alphaieee_frag
af71363e 7782s%@alphaieee_frag@%%g
671aa708 7783/@ospace_frag@/r $ospace_frag
af71363e
AS
7784s%@ospace_frag@%%g
7785s%@RPATH_ENVVAR@%$RPATH_ENVVAR%g
7786s%@tooldir@%$tooldir%g
7787s%@build_tooldir@%$build_tooldir%g
7788s%@CONFIGURE_GDB_TK@%$CONFIGURE_GDB_TK%g
7789s%@GDB_TK@%$GDB_TK%g
7790s%@INSTALL_GDB_TK@%$INSTALL_GDB_TK%g
7791s%@build_configargs@%$build_configargs%g
7792s%@build_configdirs@%$build_configdirs%g
7793s%@host_configargs@%$host_configargs%g
7794s%@configdirs@%$configdirs%g
7795s%@target_configargs@%$target_configargs%g
7796s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
7797s%@config_shell@%$config_shell%g
7798s%@YACC@%$YACC%g
7799s%@BISON@%$BISON%g
7800s%@M4@%$M4%g
7801s%@LEX@%$LEX%g
7802s%@FLEX@%$FLEX%g
7803s%@MAKEINFO@%$MAKEINFO%g
7804s%@EXPECT@%$EXPECT%g
7805s%@RUNTEST@%$RUNTEST%g
7806s%@AR@%$AR%g
7807s%@AS@%$AS%g
7808s%@DLLTOOL@%$DLLTOOL%g
7809s%@LD@%$LD%g
7810s%@LIPO@%$LIPO%g
7811s%@NM@%$NM%g
7812s%@RANLIB@%$RANLIB%g
7813s%@STRIP@%$STRIP%g
7814s%@WINDRES@%$WINDRES%g
7815s%@OBJCOPY@%$OBJCOPY%g
7816s%@OBJDUMP@%$OBJDUMP%g
7817s%@CXX@%$CXX%g
7818s%@CFLAGS_FOR_BUILD@%$CFLAGS_FOR_BUILD%g
7819s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
7820s%@CXX_FOR_TARGET@%$CXX_FOR_TARGET%g
7821s%@GCC_FOR_TARGET@%$GCC_FOR_TARGET%g
7822s%@GCJ_FOR_TARGET@%$GCJ_FOR_TARGET%g
7823s%@GFORTRAN_FOR_TARGET@%$GFORTRAN_FOR_TARGET%g
7824s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
7825s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
7826s%@DLLTOOL_FOR_TARGET@%$DLLTOOL_FOR_TARGET%g
7827s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
7828s%@LIPO_FOR_TARGET@%$LIPO_FOR_TARGET%g
7829s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
7830s%@OBJDUMP_FOR_TARGET@%$OBJDUMP_FOR_TARGET%g
7831s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
7832s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
7833s%@WINDRES_FOR_TARGET@%$WINDRES_FOR_TARGET%g
7834s%@RAW_CXX_FOR_TARGET@%$RAW_CXX_FOR_TARGET%g
7835s%@FLAGS_FOR_TARGET@%$FLAGS_FOR_TARGET%g
7836s%@COMPILER_AS_FOR_TARGET@%$COMPILER_AS_FOR_TARGET%g
7837s%@COMPILER_LD_FOR_TARGET@%$COMPILER_LD_FOR_TARGET%g
7838s%@COMPILER_NM_FOR_TARGET@%$COMPILER_NM_FOR_TARGET%g
7839s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
7840s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
7841s%@MAINT@%$MAINT%g
7842s%@stage1_cflags@%$stage1_cflags%g
7843s%@stage1_checking@%$stage1_checking%g
7844s%@stage2_werror_flag@%$stage2_werror_flag%g
7845s%@datarootdir@%$datarootdir%g
7846s%@docdir@%$docdir%g
7847s%@htmldir@%$htmldir%g
7848
671aa708 7849CEOF
af71363e 7850EOF
79c06341 7851
af71363e
AS
7852cat >> $CONFIG_STATUS <<\EOF
7853
7854# Split the substitutions into bite-sized pieces for seds with
7855# small command number limits, like on Digital OSF/1 and HP-UX.
7856ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
7857ac_file=1 # Number of current file.
7858ac_beg=1 # First line for current file.
7859ac_end=$ac_max_sed_cmds # Line after last line for current file.
7860ac_more_lines=:
7861ac_sed_cmds=""
7862while $ac_more_lines; do
7863 if test $ac_beg -gt 1; then
7864 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
7865 else
7866 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
7867 fi
7868 if test ! -s conftest.s$ac_file; then
7869 ac_more_lines=false
7870 rm -f conftest.s$ac_file
7871 else
7872 if test -z "$ac_sed_cmds"; then
7873 ac_sed_cmds="sed -f conftest.s$ac_file"
671aa708 7874 else
af71363e 7875 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
671aa708 7876 fi
af71363e
AS
7877 ac_file=`expr $ac_file + 1`
7878 ac_beg=$ac_end
7879 ac_end=`expr $ac_end + $ac_max_sed_cmds`
4977bab6 7880 fi
af71363e
AS
7881done
7882if test -z "$ac_sed_cmds"; then
7883 ac_sed_cmds=cat
7884fi
7885EOF
79c06341 7886
af71363e
AS
7887cat >> $CONFIG_STATUS <<EOF
7888
7889CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
7890EOF
7891cat >> $CONFIG_STATUS <<\EOF
7892for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
671aa708 7893 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
af71363e
AS
7894 case "$ac_file" in
7895 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
7896 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
7897 *) ac_file_in="${ac_file}.in" ;;
671aa708 7898 esac
79c06341 7899
af71363e 7900 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
0b0dc272 7901
af71363e
AS
7902 # Remove last slash and all that follows it. Not all systems have dirname.
7903 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
7904 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7905 # The file is in a subdirectory.
7906 test ! -d "$ac_dir" && mkdir "$ac_dir"
7907 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
7908 # A "../" for each directory in $ac_dir_suffix.
7909 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
7910 else
7911 ac_dir_suffix= ac_dots=
7912 fi
0b0dc272 7913
af71363e
AS
7914 case "$ac_given_srcdir" in
7915 .) srcdir=.
7916 if test -z "$ac_dots"; then top_srcdir=.
7917 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
7918 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
671aa708 7919 *) # Relative path.
af71363e
AS
7920 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
7921 top_srcdir="$ac_dots$ac_given_srcdir" ;;
7922 esac
a4b9e93e 7923
af71363e
AS
7924 case "$ac_given_INSTALL" in
7925 [/$]*) INSTALL="$ac_given_INSTALL" ;;
7926 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
7927 esac
0b0dc272 7928
af71363e
AS
7929 echo creating "$ac_file"
7930 rm -f "$ac_file"
7931 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
7932 case "$ac_file" in
7933 *Makefile*) ac_comsub="1i\\
7934# $configure_input" ;;
7935 *) ac_comsub= ;;
671aa708 7936 esac
79c06341 7937
af71363e
AS
7938 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
7939 sed -e "$ac_comsub
7940s%@configure_input@%$configure_input%g
7941s%@srcdir@%$srcdir%g
7942s%@top_srcdir@%$top_srcdir%g
7943s%@INSTALL@%$INSTALL%g
7944" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
7945fi; done
7946rm -f conftest.s*
79c06341 7947
af71363e
AS
7948EOF
7949cat >> $CONFIG_STATUS <<EOF
79c06341 7950
af71363e
AS
7951EOF
7952cat >> $CONFIG_STATUS <<\EOF
79c06341 7953
af71363e
AS
7954exit 0
7955EOF
671aa708 7956chmod +x $CONFIG_STATUS
af71363e
AS
7957rm -fr confdefs* $ac_clean_files
7958test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
79c06341 7959