]> git.ipfire.org Git - thirdparty/gcc.git/blame - configure
[multiple changes]
[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
af71363e 2200echo $ac_n "checking whether compiler driver understands Ada""... $ac_c" 1>&6
95af8923 2201echo "configure:2202: checking whether compiler driver understands Ada" >&5
af71363e
AS
2202if eval "test \"`echo '$''{'acx_cv_cc_gcc_supports_ada'+set}'`\" = set"; then
2203 echo $ac_n "(cached) $ac_c" 1>&6
55ffb5ed
NN
2204else
2205 cat >conftest.adb <<EOF
2206procedure conftest is begin null; end conftest;
2207EOF
2208acx_cv_cc_gcc_supports_ada=no
2209# There is a bug in old released versions of GCC which causes the
2210# driver to exit successfully when the appropriate language module
2211# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
2212# Therefore we must check for the error message as well as an
2213# unsuccessful exit.
1db673ca
RO
2214# Other compilers, like HP Tru64 UNIX cc, exit successfully when
2215# given a .adb file, but produce no object file. So we must check
2216# if an object file was really produced to guard against this.
55ffb5ed 2217errors=`(${CC} -c conftest.adb) 2>&1 || echo failure`
1db673ca 2218if test x"$errors" = x && test -f conftest.$ac_objext; then
55ffb5ed 2219 acx_cv_cc_gcc_supports_ada=yes
55ffb5ed
NN
2220fi
2221rm -f conftest.*
2222fi
af71363e
AS
2223
2224echo "$ac_t""$acx_cv_cc_gcc_supports_ada" 1>&6
55ffb5ed 2225
1db673ca 2226if test x$GNATBIND != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
55ffb5ed
NN
2227 have_gnat=yes
2228else
2229 have_gnat=no
2230fi
2231
af71363e 2232echo $ac_n "checking how to compare bootstrapped objects""... $ac_c" 1>&6
95af8923 2233echo "configure:2234: checking how to compare bootstrapped objects" >&5
af71363e
AS
2234if eval "test \"`echo '$''{'gcc_cv_prog_cmp_skip'+set}'`\" = set"; then
2235 echo $ac_n "(cached) $ac_c" 1>&6
a76494aa
PB
2236else
2237 echo abfoo >t1
2238 echo cdfoo >t2
2239 gcc_cv_prog_cmp_skip='tail +16c $$f1 > tmp-foo1; tail +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
6cf1ac42
PB
2240 if cmp t1 t2 2 2 > /dev/null 2>&1; then
2241 if cmp t1 t2 1 1 > /dev/null 2>&1; then
2242 :
2243 else
2244 gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
2245 fi
2246 fi
a76494aa
PB
2247 if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
2248 if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
6cf1ac42 2249 :
a76494aa
PB
2250 else
2251 gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
2252 fi
2253 fi
2254 rm t1 t2
2255
2256fi
af71363e
AS
2257
2258echo "$ac_t""$gcc_cv_prog_cmp_skip" 1>&6
a76494aa
PB
2259do_compare="$gcc_cv_prog_cmp_skip"
2260
2261
55ffb5ed 2262
bebf829d 2263# Check for GMP and MPFR
e69bf64b 2264gmplibs="-lmpfr -lgmp"
6de9cd9a 2265gmpinc=
e69bf64b
PB
2266have_gmp=no
2267
bebf829d
PB
2268# Specify a location for mpfr
2269# check for this first so it ends up on the link line before gmp.
2270# Check whether --with-mpfr-dir or --without-mpfr-dir was given.
2271if test "${with_mpfr_dir+set}" = set; then
2272 withval="$with_mpfr_dir"
af71363e
AS
2273 { echo "configure: error: The --with-mpfr-dir=PATH option has been removed.
2274Use --with-mpfr=PATH or --with-mpfr-include=PATH plus --with-mpfr-lib=PATH" 1>&2; exit 1; }
2275fi
bebf829d
PB
2276
2277
bebf829d
PB
2278# Check whether --with-mpfr or --without-mpfr was given.
2279if test "${with_mpfr+set}" = set; then
2280 withval="$with_mpfr"
af71363e
AS
2281 :
2282fi
bebf829d 2283
8a877c9c
KG
2284# Check whether --with-mpfr_include or --without-mpfr_include was given.
2285if test "${with_mpfr_include+set}" = set; then
2286 withval="$with_mpfr_include"
af71363e
AS
2287 :
2288fi
8a877c9c
KG
2289
2290# Check whether --with-mpfr_lib or --without-mpfr_lib was given.
2291if test "${with_mpfr_lib+set}" = set; then
2292 withval="$with_mpfr_lib"
af71363e
AS
2293 :
2294fi
8a877c9c 2295
bebf829d
PB
2296
2297if test "x$with_mpfr" != x; then
2298 gmplibs="-L$with_mpfr/lib $gmplibs"
2299 gmpinc="-I$with_mpfr/include"
2300fi
8a877c9c
KG
2301if test "x$with_mpfr_include" != x; then
2302 gmpinc="-I$with_mpfr_include"
2303fi
2304if test "x$with_mpfr_lib" != x; then
2305 gmplibs="-L$with_mpfr_lib $gmplibs"
2306fi
e69bf64b
PB
2307if test "x$with_mpfr$with_mpfr_include$with_mpfr_lib" = x && test -d ${srcdir}/mpfr; then
2308 gmplibs='-L$$r/$(HOST_SUBDIR)/mpfr/.libs -L$$r/$(HOST_SUBDIR)/mpfr/_libs '"$gmplibs"
2309 gmpinc='-I$$r/$(HOST_SUBDIR)/mpfr -I$$s/mpfr '"$gmpinc"
2310 # Do not test the mpfr version. Assume that it is sufficient, since
2311 # it is in the source tree, and the library has not been built yet
2312 # but it would be included on the link line in the version check below
2313 # hence making the test fail.
2314 have_gmp=yes
2315fi
bebf829d 2316
6de9cd9a
DN
2317# Specify a location for gmp
2318# Check whether --with-gmp-dir or --without-gmp-dir was given.
2319if test "${with_gmp_dir+set}" = set; then
2320 withval="$with_gmp_dir"
af71363e
AS
2321 { echo "configure: error: The --with-gmp-dir=PATH option has been removed.
2322Use --with-gmp=PATH or --with-gmp-include=PATH plus --with-gmp-lib=PATH" 1>&2; exit 1; }
2323fi
6de9cd9a 2324
6de9cd9a
DN
2325
2326# Check whether --with-gmp or --without-gmp was given.
2327if test "${with_gmp+set}" = set; then
2328 withval="$with_gmp"
af71363e
AS
2329 :
2330fi
6de9cd9a 2331
8a877c9c
KG
2332# Check whether --with-gmp_include or --without-gmp_include was given.
2333if test "${with_gmp_include+set}" = set; then
2334 withval="$with_gmp_include"
af71363e
AS
2335 :
2336fi
8a877c9c
KG
2337
2338# Check whether --with-gmp_lib or --without-gmp_lib was given.
2339if test "${with_gmp_lib+set}" = set; then
2340 withval="$with_gmp_lib"
af71363e
AS
2341 :
2342fi
8a877c9c
KG
2343
2344
6de9cd9a 2345
bebf829d
PB
2346if test "x$with_gmp" != x; then
2347 gmplibs="-L$with_gmp/lib $gmplibs"
2348 gmpinc="-I$with_gmp/include $gmpinc"
6de9cd9a 2349fi
8a877c9c
KG
2350if test "x$with_gmp_include" != x; then
2351 gmpinc="-I$with_gmp_include $gmpinc"
2352fi
2353if test "x$with_gmp_lib" != x; then
2354 gmplibs="-L$with_gmp_lib $gmplibs"
2355fi
e69bf64b
PB
2356if test "x$with_gmp$with_gmp_include$with_gmp_lib" = x && test -d ${srcdir}/gmp; then
2357 gmplibs='-L$$r/$(HOST_SUBDIR)/gmp/.libs -L$$r/$(HOST_SUBDIR)/gmp/_libs '"$gmplibs"
2358 gmpinc='-I$$r/$(HOST_SUBDIR)/gmp -I$$s/gmp '"$gmpinc"
2359 # Do not test the gmp version. Assume that it is sufficient, since
2360 # it is in the source tree, and the library has not been built yet
2361 # but it would be included on the link line in the version check below
2362 # hence making the test fail.
2363 have_gmp=yes
2364fi
6de9cd9a 2365
e69bf64b
PB
2366if test -d ${srcdir}/gcc && test "x$have_gmp" == xno; then
2367 have_gmp=yes
2368 saved_CFLAGS="$CFLAGS"
2369 CFLAGS="$CFLAGS $gmpinc"
2370 # Check GMP actually works
2371 echo $ac_n "checking for correct version of gmp.h""... $ac_c" 1>&6
2372echo "configure:2373: checking for correct version of gmp.h" >&5
2373 cat > conftest.$ac_ext <<EOF
2374#line 2375 "configure"
af71363e 2375#include "confdefs.h"
6de9cd9a 2376#include "gmp.h"
af71363e 2377int main() {
6de9cd9a 2378
e69bf64b
PB
2379 #if __GNU_MP_VERSION < 4 || (__GNU_MP_VERSION == 4 && __GNU_MP_VERSION_MINOR < 1)
2380 choke me
2381 #endif
2382
af71363e
AS
2383; return 0; }
2384EOF
e69bf64b 2385if { (eval echo configure:2386: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
af71363e
AS
2386 rm -rf conftest*
2387 echo "$ac_t""yes" 1>&6
2388else
2389 echo "configure: failed program was:" >&5
2390 cat conftest.$ac_ext >&5
2391 rm -rf conftest*
2392 echo "$ac_t""no" 1>&6; have_gmp=no
2393fi
2394rm -f conftest*
6de9cd9a 2395
e69bf64b
PB
2396 if test x"$have_gmp" = xyes; then
2397 saved_LIBS="$LIBS"
2398 LIBS="$LIBS $gmplibs"
2399 echo $ac_n "checking for correct version of mpfr.h""... $ac_c" 1>&6
2400echo "configure:2401: checking for correct version of mpfr.h" >&5
2401 cat > conftest.$ac_ext <<EOF
2402#line 2403 "configure"
af71363e 2403#include "confdefs.h"
70ec446f 2404#include <gmp.h>
e69bf64b 2405 #include <mpfr.h>
af71363e 2406int main() {
e48d66a9 2407
e69bf64b
PB
2408 #if MPFR_VERSION < MPFR_VERSION_NUM(2,2,0)
2409 choke me
2410 #endif
2411 mpfr_t n; mpfr_init(n);
2412 mpfr_t x; mpfr_init(x);
2413 int t;
2414 mpfr_atan2 (n, n, x, GMP_RNDN);
2415 mpfr_erfc (n, x, GMP_RNDN);
2416 mpfr_subnormalize (x, t, GMP_RNDN);
2417
af71363e
AS
2418; return 0; }
2419EOF
e69bf64b 2420if { (eval echo configure:2421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
a3993f33
KG
2421 rm -rf conftest*
2422 cat > conftest.$ac_ext <<EOF
e69bf64b 2423#line 2424 "configure"
a3993f33
KG
2424#include "confdefs.h"
2425#include <gmp.h>
e69bf64b 2426 #include <mpfr.h>
a3993f33
KG
2427int main() {
2428
e69bf64b
PB
2429 #if MPFR_VERSION < MPFR_VERSION_NUM(2,2,1)
2430 choke me
2431 #endif
2432 mpfr_t n; mpfr_init(n);
2433
a3993f33
KG
2434; return 0; }
2435EOF
e69bf64b 2436if { (eval echo configure:2437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
af71363e
AS
2437 rm -rf conftest*
2438 echo "$ac_t""yes" 1>&6
a3993f33
KG
2439else
2440 echo "configure: failed program was:" >&5
2441 cat conftest.$ac_ext >&5
2442 rm -rf conftest*
2443 echo "$ac_t""buggy but acceptable" 1>&6
2444fi
2445rm -f conftest*
af71363e
AS
2446else
2447 echo "configure: failed program was:" >&5
2448 cat conftest.$ac_ext >&5
2449 rm -rf conftest*
2450 echo "$ac_t""no" 1>&6; have_gmp=no
2451fi
2452rm -f conftest*
e69bf64b
PB
2453 LIBS="$saved_LIBS"
2454 fi
2455 CFLAGS="$saved_CFLAGS"
6de9cd9a 2456
e69bf64b
PB
2457 if test x$have_gmp != xyes; then
2458 { echo "configure: error: Building GCC requires GMP 4.1+ and MPFR 2.2.1+.
ca558912
KG
2459Try the --with-gmp and/or --with-mpfr options to specify their locations.
2460Copies of these libraries' source code can be found at their respective
2461hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
dbee1fb3
KG
2462See also http://gcc.gnu.org/install/prerequisites.html for additional info.
2463If you obtained GMP and/or MPFR from a vendor distribution package, make
2464sure that you have installed both the libraries and the header files.
af71363e 2465They may be located in separate packages." 1>&2; exit 1; }
e69bf64b 2466 fi
70ec446f
KG
2467fi
2468
bebf829d 2469# Flags needed for both GMP and/or MPFR
6de9cd9a
DN
2470
2471
2472
1e0f07d3 2473# By default, C is the only stage 1 language.
e1888513 2474stage1_languages=,c,
2805b53a 2475
55ffb5ed
NN
2476# Figure out what language subdirectories are present.
2477# Look if the user specified --enable-languages="..."; if not, use
2478# the environment variable $LANGUAGES if defined. $LANGUAGES might
2479# go away some day.
2480# NB: embedded tabs in this IF block -- do not untabify
2481if test -d ${srcdir}/gcc; then
2482 if test x"${enable_languages+set}" != xset; then
2483 if test x"${LANGUAGES+set}" = xset; then
2484 enable_languages="${LANGUAGES}"
2485 echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
2486 else
2487 enable_languages=all
2488 fi
2489 else
2490 if test x"${enable_languages}" = x ||
2491 test x"${enable_languages}" = xyes;
2492 then
2493 echo configure.in: --enable-languages needs at least one language argument 1>&2
2494 exit 1
2495 fi
2496 fi
2497 enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
2498
7f26dfa3
FXC
2499 # 'f95' is the old name for the 'fortran' language. We issue a warning
2500 # and make the substitution.
2501 case ,${enable_languages}, in
2502 *,f95,*)
2503 echo configure.in: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
2504 enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
2505 ;;
2506 esac
2507
55ffb5ed
NN
2508 # First scan to see if an enabled language requires some other language.
2509 # We assume that a given config-lang.in will list all the language
2510 # front ends it requires, even if some are required indirectly.
2511 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
2512 case ${lang_frag} in
2513 ..) ;;
2514 # The odd quoting in the next line works around
2515 # an apparent bug in bash 1.12 on linux.
2516 ${srcdir}/gcc/[*]/config-lang.in) ;;
2517 *)
2518 # From the config-lang.in, get $language, $lang_requires
2519 language=
2520 lang_requires=
2521 . ${lang_frag}
2522 for other in ${lang_requires} ; do
2523 case ,${enable_languages}, in
2524 *,$other,*) ;;
2525 *,all,*) ;;
2526 *,$language,*)
2527 echo " \`$other' language required by \`$language'; enabling" 1>&2
2528 enable_languages="${enable_languages},${other}"
2529 ;;
2530 esac
2531 done
2532 ;;
2533 esac
2534 done
2535
e1888513 2536 new_enable_languages=,c,
55ffb5ed 2537 missing_languages=`echo ",$enable_languages," | sed -e s/,all,/,/ -e s/,c,/,/ `
e1888513 2538 potential_languages=,c,
55ffb5ed
NN
2539
2540 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
2541 case ${lang_frag} in
2542 ..) ;;
2543 # The odd quoting in the next line works around
2544 # an apparent bug in bash 1.12 on linux.
2545 ${srcdir}/gcc/[*]/config-lang.in) ;;
2546 *)
af71363e 2547 # From the config-lang.in, get $language, $target_libs,
2805b53a 2548 # $lang_dirs, $boot_language, and $build_by_default
55ffb5ed
NN
2549 language=
2550 target_libs=
2551 lang_dirs=
1546bb64 2552 subdir_requires=
e1888513
PB
2553 boot_language=no
2554 build_by_default=yes
55ffb5ed 2555 . ${lang_frag}
e1888513
PB
2556 if test x${language} = x; then
2557 echo "${lang_frag} doesn't set \$language." 1>&2
2558 exit 1
2559 fi
2560
2561 case ,${enable_languages}, in
2562 *,${language},*)
55ffb5ed
NN
2563 # Language was explicitly selected; include it.
2564 add_this_lang=yes
2565 ;;
e1888513
PB
2566 *,all,*)
2567 # 'all' was selected, select it if it is a default language
2568 add_this_lang=${build_by_default}
55ffb5ed
NN
2569 ;;
2570 *)
2571 add_this_lang=no
2572 ;;
2573 esac
6de9cd9a 2574
1546bb64 2575 # Disable languages that need other directories if these aren't available.
95695ad3 2576 for i in $subdir_requires; do
b6348cb3 2577 test -f "$srcdir/gcc/$i/config-lang.in" && continue
1546bb64
PB
2578 case ,${enable_languages}, in
2579 *,${language},*)
2580 # Specifically requested language; tell them.
af71363e 2581 { echo "configure: error: The gcc/$i directory contains parts of $language but is missing" 1>&2; exit 1; }
1546bb64
PB
2582 ;;
2583 *)
2584 # Silently disable.
e1888513 2585 add_this_lang=unsupported
1546bb64
PB
2586 ;;
2587 esac
2588 done
2589
e1888513
PB
2590 # Disable Ada if no preexisting GNAT is available.
2591 case ,${enable_languages},:${language}:${have_gnat} in
2592 *,${language},*:ada:no)
2593 # Specifically requested language; tell them.
2594 { echo "configure: error: GNAT is required to build $language" 1>&2; exit 1; }
2595 ;;
2596 *:ada:no)
2597 # Silently disable.
2598 add_this_lang=unsupported
2599 ;;
2600 esac
2601
4fab7234
HPN
2602 # Disable a language that is unsupported by the target.
2603 case " $unsupported_languages " in
2604 *" $language "*)
e1888513 2605 add_this_lang=unsupported
4fab7234
HPN
2606 ;;
2607 esac
2608
6de9cd9a 2609 case $add_this_lang in
e1888513 2610 unsupported)
55ffb5ed 2611 # Remove language-dependent dirs.
2805b53a
NN
2612 eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
2613 ;;
e1888513
PB
2614 no)
2615 # Remove language-dependent dirs; still show language as supported.
2616 eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
2617 potential_languages="${potential_languages}${language},"
2618 ;;
2619 yes)
2620 new_enable_languages="${new_enable_languages}${language},"
2621 potential_languages="${potential_languages}${language},"
2805b53a
NN
2622 missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
2623 case ${boot_language} in
2624 yes)
340de83f 2625 # Add to (comma-separated) list of stage 1 languages.
e1888513 2626 stage1_languages="${stage1_languages}${language},"
2805b53a
NN
2627 ;;
2628 esac
2629 ;;
55ffb5ed
NN
2630 esac
2631 ;;
2632 esac
2633 done
2634
e1888513
PB
2635 # Check whether --enable-stage1-languages or --disable-stage1-languages was given.
2636if test "${enable_stage1_languages+set}" = set; then
2637 enableval="$enable_stage1_languages"
2638 case ,${enable_stage1_languages}, in
2639 ,no,|,,)
2640 # Set it to something that will have no effect in the loop below
2641 enable_stage1_languages=c ;;
2642 ,yes,)
2643 enable_stage1_languages=`echo $new_enable_languages | \
2644 sed -e "s/^,//" -e "s/,$//" ` ;;
2645 *,all,*)
2646 enable_stage1_languages=`echo ,$enable_stage1_languages, | \
2647 sed -e "s/,all,/$new_enable_languages/" -e "s/^,//" -e "s/,$//" ` ;;
2648 esac
2649
2650 # Add "good" languages from enable_stage1_languages to stage1_languages,
2651 # while "bad" languages go in missing_languages. Leave no duplicates.
2652 for i in `echo $enable_stage1_languages | sed 's/,/ /g' `; do
2653 case $potential_languages in
2654 *,$i,*)
2655 case $stage1_languages in
2656 *,$i,*) ;;
2657 *) stage1_languages="$stage1_languages$i," ;;
2658 esac ;;
2659 *)
2660 case $missing_languages in
2661 *,$i,*) ;;
2662 *) missing_languages="$missing_languages$i," ;;
2663 esac ;;
2664 esac
2665 done
2666fi
2667
2668
2669 # Remove leading/trailing commas that were added for simplicity
2670 potential_languages=`echo "$potential_languages" | sed -e "s/^,//" -e "s/,$//"`
79b4b7d2 2671 missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
e1888513
PB
2672 stage1_languages=`echo "$stage1_languages" | sed -e "s/^,//" -e "s/,$//"`
2673 new_enable_languages=`echo "$new_enable_languages" | sed -e "s/^,//" -e "s/,$//"`
2674
55ffb5ed 2675 if test "x$missing_languages" != x; then
af71363e 2676 { echo "configure: error:
0cf085e4 2677The following requested languages could not be built: ${missing_languages}
e1888513 2678Supported languages are: ${potential_languages}" 1>&2; exit 1; }
55ffb5ed 2679 fi
55ffb5ed
NN
2680 if test "x$new_enable_languages" != "x$enable_languages"; then
2681 echo The following languages will be built: ${new_enable_languages}
e1888513 2682 enable_languages="$new_enable_languages"
55ffb5ed 2683 fi
e1888513
PB
2684
2685
6bbec498 2686 ac_configure_args=`echo " $ac_configure_args" | sed -e 's/ --enable-languages=[^ ]*//' -e 's/$/ --enable-languages='"$enable_languages"/ `
55ffb5ed
NN
2687fi
2688
27079765
AH
2689# Handle --disable-<component> generically.
2690for dir in $configdirs $build_configdirs $target_configdirs ; do
2691 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g -e s/-/_/g`
2692 if eval test x\${enable_${dirname}} "=" xno ; then
2693 noconfigdirs="$noconfigdirs $dir"
2694 fi
2695done
2696
7cd0cf9c
DA
2697# Check for Boehm's garbage collector
2698# Check whether --enable-objc-gc or --disable-objc-gc was given.
2699if test "${enable_objc_gc+set}" = set; then
2700 enableval="$enable_objc_gc"
2701 case ,${enable_languages},:${enable_objc_gc}:${noconfigdirs} in
2702 *,objc,*:*:yes:*target-boehm-gc*)
af71363e 2703 { echo "configure: error: Boehm's garbage collector was requested yet not supported in this configuration" 1>&2; exit 1; }
7cd0cf9c
DA
2704 ;;
2705esac
af71363e
AS
2706fi
2707
7cd0cf9c
DA
2708
2709# Make sure we only build Boehm's garbage collector if required.
2a79fd67
DA
2710case ,${enable_languages},:${enable_objc_gc} in
2711 *,objc,*:yes)
7cd0cf9c
DA
2712 # Keep target-boehm-gc if requested for Objective-C.
2713 ;;
7cd0cf9c 2714 *)
2a79fd67
DA
2715 # Otherwise remove target-boehm-gc depending on target-libjava.
2716 if echo " ${noconfigdirs} " | grep "target-libjava" >/dev/null 2>&1; then
2717 noconfigdirs="$noconfigdirs target-boehm-gc"
2718 fi
7cd0cf9c
DA
2719 ;;
2720esac
2721
ee6a22df
L
2722# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
2723# $build_configdirs and $target_configdirs.
55ffb5ed
NN
2724# If we have the source for $noconfigdirs entries, add them to $notsupp.
2725
2726notsupp=""
2727for dir in . $skipdirs $noconfigdirs ; do
ee6a22df 2728 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
55ffb5ed
NN
2729 if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2730 configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
2731 if test -r $srcdir/$dirname/configure ; then
2732 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2733 true
2734 else
2735 notsupp="$notsupp $dir"
2736 fi
2737 fi
2738 fi
ee6a22df
L
2739 if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2740 build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
2741 if test -r $srcdir/$dirname/configure ; then
2742 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2743 true
2744 else
2745 notsupp="$notsupp $dir"
2746 fi
2747 fi
2748 fi
55ffb5ed
NN
2749 if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2750 target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
2751 if test -r $srcdir/$dirname/configure ; then
2752 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2753 true
2754 else
2755 notsupp="$notsupp $dir"
2756 fi
2757 fi
2758 fi
2759done
2760
2761# Sometimes the tools are distributed with libiberty but with no other
2762# libraries. In that case, we don't want to build target-libiberty.
54fdc474 2763# Don't let libgcc imply libiberty either.
55ffb5ed 2764if test -n "${target_configdirs}" ; then
54fdc474 2765 libgcc=
55ffb5ed
NN
2766 others=
2767 for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
54fdc474
DJ
2768 if test "$i" = "libgcc"; then
2769 libgcc=target-libgcc
2770 elif test "$i" != "libiberty" ; then
55ffb5ed
NN
2771 if test -r $srcdir/$i/configure ; then
2772 others=yes;
2773 break;
2774 fi
2775 fi
2776 done
2777 if test -z "${others}" ; then
54fdc474 2778 target_configdirs=$libgcc
55ffb5ed
NN
2779 fi
2780fi
2781
2782# Quietly strip out all directories which aren't configurable in this tree.
2783# This relies on all configurable subdirectories being autoconfiscated, which
2784# is now the case.
23f6b2f9
PB
2785build_configdirs_all="$build_configdirs"
2786build_configdirs=
2787for i in ${build_configdirs_all} ; do
af71363e 2788 j=`echo $i | sed -e s/build-//g`
23f6b2f9
PB
2789 if test -f ${srcdir}/$j/configure ; then
2790 build_configdirs="${build_configdirs} $i"
2791 fi
2792done
2793
55ffb5ed
NN
2794configdirs_all="$configdirs"
2795configdirs=
2796for i in ${configdirs_all} ; do
2797 if test -f ${srcdir}/$i/configure ; then
2798 configdirs="${configdirs} $i"
2799 fi
2800done
23f6b2f9 2801
55ffb5ed
NN
2802target_configdirs_all="$target_configdirs"
2803target_configdirs=
2804for i in ${target_configdirs_all} ; do
af71363e 2805 j=`echo $i | sed -e s/target-//g`
55ffb5ed
NN
2806 if test -f ${srcdir}/$j/configure ; then
2807 target_configdirs="${target_configdirs} $i"
2808 fi
2809done
2810
2811# Produce a warning message for the subdirs we can't configure.
2812# This isn't especially interesting in the Cygnus tree, but in the individual
2813# FSF releases, it's important to let people know when their machine isn't
2814# supported by the one or two programs in a package.
2815
2816if test -n "${notsupp}" && test -z "${norecursion}" ; then
2817 # If $appdirs is non-empty, at least one of those directories must still
2818 # be configured, or we error out. (E.g., if the gas release supports a
2819 # specified target in some subdirs but not the gas subdir, we shouldn't
2820 # pretend that all is well.)
2821 if test -n "$appdirs" ; then
2822 for dir in $appdirs ; do
2823 if test -r $dir/Makefile.in ; then
2824 if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2825 appdirs=""
2826 break
2827 fi
23f6b2f9 2828 if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
55ffb5ed
NN
2829 appdirs=""
2830 break
2831 fi
2832 fi
2833 done
2834 if test -n "$appdirs" ; then
2835 echo "*** This configuration is not supported by this package." 1>&2
2836 exit 1
2837 fi
2838 fi
2839 # Okay, some application will build, or we don't care to check. Still
2840 # notify of subdirs not getting built.
2841 echo "*** This configuration is not supported in the following subdirectories:" 1>&2
2842 echo " ${notsupp}" 1>&2
2843 echo " (Any other directories should still work fine.)" 1>&2
2844fi
2845
2846case "$host" in
2847 *msdosdjgpp*)
2848 enable_gdbtk=no ;;
2849esac
2850
2851copy_dirs=
2852
526635cb
MM
2853# Check whether --with-build-sysroot or --without-build-sysroot was given.
2854if test "${with_build_sysroot+set}" = set; then
2855 withval="$with_build_sysroot"
2856 if test x"$withval" != x ; then
2857 SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
2858 fi
2859else
2860 SYSROOT_CFLAGS_FOR_TARGET=
af71363e
AS
2861fi
2862
526635cb
MM
2863
2864
55ffb5ed
NN
2865# Handle --with-headers=XXX. If the value is not "yes", the contents of
2866# the named directory are copied to $(tooldir)/sys-include.
2867if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
2868 if test x${is_cross_compiler} = xno ; then
2869 echo 1>&2 '***' --with-headers is only supported when cross compiling
2870 exit 1
2871 fi
2872 if test x"${with_headers}" != xyes ; then
2873 case "${exec_prefixoption}" in
2874 "") x=${prefix} ;;
2875 *) x=${exec_prefix} ;;
2876 esac
2877 copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
2878 fi
2879fi
2880
2881# Handle --with-libs=XXX. If the value is not "yes", the contents of
2882# the name directories are copied to $(tooldir)/lib. Multiple directories
2883# are permitted.
2884if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
2885 if test x${is_cross_compiler} = xno ; then
2886 echo 1>&2 '***' --with-libs is only supported when cross compiling
2887 exit 1
2888 fi
2889 if test x"${with_libs}" != xyes ; then
2890 # Copy the libraries in reverse order, so that files in the first named
2891 # library override files in subsequent libraries.
2892 case "${exec_prefixoption}" in
2893 "") x=${prefix} ;;
2894 *) x=${exec_prefix} ;;
2895 esac
2896 for l in ${with_libs}; do
2897 copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
2898 done
2899 fi
2900fi
2901
e8b05380
PB
2902# Set with_gnu_as and with_gnu_ld as appropriate.
2903#
2904# This is done by determining whether or not the appropriate directory
2905# is available, and by checking whether or not specific configurations
2906# have requested that this magic not happen.
af71363e
AS
2907#
2908# The command line options always override the explicit settings in
e8b05380
PB
2909# configure.in, and the settings in configure.in override this magic.
2910#
af71363e 2911# If the default for a toolchain is to use GNU as and ld, and you don't
e8b05380
PB
2912# want to do that, then you should use the --without-gnu-as and
2913# --without-gnu-ld options for the configure script.
2914
2915if test x${use_gnu_as} = x &&
2916 echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
2917 with_gnu_as=yes
2918 extra_host_args="$extra_host_args --with-gnu-as"
2919fi
2920
2921if test x${use_gnu_ld} = x &&
2922 echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
2923 with_gnu_ld=yes
2924 extra_host_args="$extra_host_args --with-gnu-ld"
2925fi
2926
2927# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
2928# can detect this case.
2929
2930if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
2931 with_newlib=yes
2932 extra_host_args="$extra_host_args --with-newlib"
2933fi
2934
55ffb5ed
NN
2935# Handle ${copy_dirs}
2936set fnord ${copy_dirs}
2937shift
2938while test $# != 0 ; do
2939 if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
2940 :
2941 else
2942 echo Copying $1 to $2
2943
2944 # Use the install script to create the directory and all required
2945 # parent directories.
2946 if test -d $2 ; then
2947 :
2948 else
2949 echo >config.temp
2950 ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
2951 fi
2952
2953 # Copy the directory, assuming we have tar.
2954 # FIXME: Should we use B in the second tar? Not all systems support it.
2955 (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
2956
2957 # It is the responsibility of the user to correctly adjust all
2958 # symlinks. If somebody can figure out how to handle them correctly
2959 # here, feel free to add the code.
2960
2961 echo $1 > $2/COPIED
2962 fi
2963 shift; shift
2964done
2965
e8b05380
PB
2966# Determine a target-dependent exec_prefix that the installed
2967# gcc will search in. Keep this list sorted by triplet, with
2968# the *-*-osname triplets last.
2969md_exec_prefix=
2970case "${target}" in
2971 alpha*-*-*vms*)
2972 md_exec_prefix=/gnu/lib/gcc-lib
2973 ;;
2974 i3456786-pc-msdosdjgpp*)
2975 md_exec_prefix=/dev/env/DJDIR/bin
2976 ;;
2977 i3456786-*-sco3.2v5*)
2978 if test $with_gnu_as = yes; then
2979 md_exec_prefix=/usr/gnu/bin
2980 else
2981 md_exec_prefix=/usr/ccs/bin/elf
2982 fi
2983 ;;
2984
2985 mn10300-*-* | \
2986 powerpc-*-chorusos* | \
2987 powerpc*-*-eabi* | \
2988 powerpc*-*-sysv* | \
2989 powerpc*-*-kaos* | \
2990 s390x-ibm-tpf*)
2991 md_exec_prefix=/usr/ccs/bin
2992 ;;
2993 sparc64-*-elf*)
2994 ;;
2995 v850*-*-*)
2996 md_exec_prefix=/usr/ccs/bin
2997 ;;
2998 xtensa-*-elf*)
2999 ;;
3000
3001 *-*-beos* | \
3002 *-*-elf* | \
3003 *-*-hpux* | \
3004 *-*-netware* | \
3005 *-*-nto-qnx* | \
3006 *-*-rtems* | \
3007 *-*-solaris2* | \
3008 *-*-sysv45* | \
3009 *-*-vxworks* | \
3010 *-wrs-windiss)
3011 md_exec_prefix=/usr/ccs/bin
3012 ;;
3013esac
3014
671aa708
NN
3015extra_arflags_for_target=
3016extra_nmflags_for_target=
3017extra_ranlibflags_for_target=
3018target_makefile_frag=/dev/null
3019case "${target}" in
58e24147
AM
3020 spu-*-*)
3021 target_makefile_frag="config/mt-spu"
3022 ;;
61fec9ff 3023 *-*-netware*)
671aa708
NN
3024 target_makefile_frag="config/mt-netware"
3025 ;;
98a5bb3b
RM
3026 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
3027 target_makefile_frag="config/mt-gnu"
671aa708
NN
3028 ;;
3029 *-*-aix4.[3456789]* | *-*-aix[56789].*)
af71363e 3030 # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
671aa708
NN
3031 # commands to handle both 32-bit and 64-bit objects. These flags are
3032 # harmless if we're using GNU nm or ar.
3033 extra_arflags_for_target=" -X32_64"
3034 extra_nmflags_for_target=" -B -X32_64"
3035 ;;
3036 *-*-darwin*)
3037 # ranlib from Darwin requires the -c flag to look at common symbols.
3038 extra_ranlibflags_for_target=" -c"
3039 ;;
3040 mips*-*-pe | sh*-*-pe | *arm-wince-pe)
3041 target_makefile_frag="config/mt-wince"
3042 ;;
3043esac
3044
3045alphaieee_frag=/dev/null
3046case $target in
3047 alpha*-*-*)
3048 # This just makes sure to use the -mieee option to build target libs.
3049 # This should probably be set individually by each library.
3050 alphaieee_frag="config/mt-alphaieee"
3051 ;;
3052esac
3053
3054# If --enable-target-optspace always use -Os instead of -O2 to build
3055# the target libraries, similarly if it is not specified, use -Os
3056# on selected platforms.
3057ospace_frag=/dev/null
3058case "${enable_target_optspace}:${target}" in
3059 yes:*)
3060 ospace_frag="config/mt-ospace"
3061 ;;
3062 :d30v-*)
3063 ospace_frag="config/mt-d30v"
3064 ;;
3065 :m32r-* | :d10v-* | :fr30-*)
3066 ospace_frag="config/mt-ospace"
3067 ;;
3068 no:* | :*)
3069 ;;
3070 *)
3071 echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
3072 ;;
3073esac
3074
671aa708
NN
3075# Default to using --with-stabs for certain targets.
3076if test x${with_stabs} = x ; then
3077 case "${target}" in
89a95129 3078 mips*-*-irix[56]*)
671aa708
NN
3079 ;;
3080 mips*-*-* | alpha*-*-osf*)
3081 with_stabs=yes;
3082 extra_host_args="${extra_host_args} --with-stabs"
3083 ;;
3084 esac
3085fi
3086
3087# hpux11 in 64bit mode has libraries in a weird place. Arrange to find
3088# them automatically.
3089case "${host}" in
af71363e 3090 hppa*64*-*-hpux11*)
671aa708
NN
3091 extra_host_args="$extra_host_args -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
3092 ;;
3093esac
3094
671aa708
NN
3095# Some systems (e.g., one of the i386-aix systems the gas testers are
3096# using) don't handle "\$" correctly, so don't use it here.
df445104 3097tooldir='${exec_prefix}'/${target_alias}
671aa708
NN
3098build_tooldir=${tooldir}
3099
671aa708
NN
3100# Create a .gdbinit file which runs the one in srcdir
3101# and tells GDB to look there for source files.
3102
3103if test -r ${srcdir}/.gdbinit ; then
3104 case ${srcdir} in
3105 .) ;;
3106 *) cat > ./.gdbinit <<EOF
3107# ${NO_EDIT}
3108dir ${srcdir}
3109dir .
3110source ${srcdir}/.gdbinit
3111EOF
3112 ;;
3113 esac
3114fi
3115
671aa708
NN
3116# Make sure that the compiler is able to generate an executable. If it
3117# can't, we are probably in trouble. We don't care whether we can run the
3118# executable--we might be using a cross compiler--we only care whether it
3119# can be created. At this point the main configure script has set CC.
3120we_are_ok=no
3121echo "int main () { return 0; }" > conftest.c
3122${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
3123if test $? = 0 ; then
3124 if test -s conftest || test -s conftest.exe ; then
3125 we_are_ok=yes
3126 fi
af71363e 3127fi
671aa708
NN
3128case $we_are_ok in
3129 no)
3130 echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
3131 echo 1>&2 "*** You must set the environment variable CC to a working compiler."
3132 rm -f conftest*
3133 exit 1
3134 ;;
3135esac
3136rm -f conftest*
3137
3138# The Solaris /usr/ucb/cc compiler does not appear to work.
3139case "${host}" in
3140 sparc-sun-solaris2*)
3141 CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
3142 if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
3143 could_use=
3144 test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
3145 if test -d /opt/cygnus/bin ; then
3146 if test "$could_use" = "" ; then
3147 could_use="/opt/cygnus/bin"
3148 else
3149 could_use="$could_use or /opt/cygnus/bin"
3150 fi
3151 fi
3152 if test "$could_use" = "" ; then
3153 echo "Warning: compilation may fail because you're using"
3154 echo "/usr/ucb/cc. You should change your PATH or CC "
3155 echo "variable and rerun configure."
3156 else
3157 echo "Warning: compilation may fail because you're using"
3158 echo "/usr/ucb/cc, when you should use the C compiler from"
3159 echo "$could_use. You should change your"
3160 echo "PATH or CC variable and rerun configure."
3161 fi
3162 fi
3163 ;;
3164esac
3165
671aa708
NN
3166case "${host}" in
3167 *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
256f7136 3168 *-*-darwin* | *-*-rhapsody* ) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
671aa708
NN
3169 *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
3170esac
3171
3172# Record target_configdirs and the configure arguments for target and
3173# build configuration in Makefile.
3174target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
23f6b2f9 3175build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
671aa708 3176
671aa708
NN
3177# Determine whether gdb needs tk/tcl or not.
3178# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
3179# and in that case we want gdb to be built without tk. Ugh!
3180# In fact I believe gdb is the *only* package directly dependent on tk,
3181# so we should be able to put the 'maybe's in unconditionally and
3182# leave out the maybe dependencies when enable_gdbtk is false. I'm not
3183# 100% sure that that's safe though.
e914a571 3184
b4f96efe 3185gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
671aa708
NN
3186case "$enable_gdbtk" in
3187 no)
3188 GDB_TK="" ;;
e914a571
AC
3189 yes)
3190 GDB_TK="${gdb_tk}" ;;
671aa708 3191 *)
e914a571
AC
3192 # Only add the dependency on gdbtk when GDBtk is part of the gdb
3193 # distro. Eventually someone will fix this and move Insight, nee
3194 # gdbtk to a separate directory.
3195 if test -d ${srcdir}/gdb/gdbtk ; then
3196 GDB_TK="${gdb_tk}"
3197 else
3198 GDB_TK=""
3199 fi
3200 ;;
671aa708 3201esac
ef9db8d5
DJ
3202CONFIGURE_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-configure-/g`
3203INSTALL_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-install-/g`
671aa708 3204
60975492 3205# Strip out unwanted targets.
8b87bb96
NN
3206
3207# While at that, we remove Makefiles if we were started for recursive
3208# configuration, so that the top-level Makefile reconfigures them,
3209# like we used to do when configure itself was recursive.
8b87bb96 3210
60975492
PB
3211# Loop over modules. $extrasub must be used with care, limiting as
3212# much as possible the usage of range addresses. That's because autoconf
3213# splits the sed script to overcome limits in the number of commands,
3214# and relying on carefully-timed sed passes may turn out to be very hard
3215# to maintain later. In this particular case, you just have to be careful
3216# not to nest @if/@endif pairs, because configure will not warn you at all.
8b87bb96 3217
f516a7da
PB
3218# Check whether --enable-bootstrap or --disable-bootstrap was given.
3219if test "${enable_bootstrap+set}" = set; then
3220 enableval="$enable_bootstrap"
af71363e 3221 :
f516a7da 3222else
ce521a9c 3223 enable_bootstrap=default
af71363e
AS
3224fi
3225
f516a7da 3226
ce521a9c
PB
3227# Issue errors and warnings for invalid/strange bootstrap combinations.
3228case "$configdirs" in
3229 *gcc*) have_compiler=yes ;;
3230 *) have_compiler=no ;;
3231esac
3232
3233case "$have_compiler:$host:$target:$enable_bootstrap" in
3234 *:*:*:no) ;;
3235
1ca26cd2 3236 # Default behavior. Enable bootstrap if we have a compiler
ce521a9c
PB
3237 # and we are in a native configuration.
3238 yes:$build:$build:default)
1ca26cd2 3239 enable_bootstrap=yes ;;
ce521a9c
PB
3240
3241 *:*:*:default)
3242 enable_bootstrap=no ;;
3243
3244 # We have a compiler and we are in a native configuration, bootstrap is ok
2d309510 3245 yes:$build:$build:yes)
ce521a9c
PB
3246 ;;
3247
3248 # Other configurations, but we have a compiler. Assume the user knows
3249 # what he's doing.
2d309510 3250 yes:*:*:yes)
af71363e 3251 echo "configure: warning: trying to bootstrap a cross compiler" 1>&2
ce521a9c
PB
3252 ;;
3253
3254 # No compiler: if they passed --enable-bootstrap explicitly, fail
2d309510 3255 no:*:*:yes)
af71363e 3256 { echo "configure: error: cannot bootstrap without a compiler" 1>&2; exit 1; } ;;
ce521a9c
PB
3257
3258 # Fail if wrong command line
3259 *)
af71363e 3260 { echo "configure: error: invalid option for --enable-bootstrap" 1>&2; exit 1; }
ce521a9c
PB
3261 ;;
3262esac
3263
3264# Adjust the toplevel makefile according to whether bootstrap was selected.
f516a7da
PB
3265case "$enable_bootstrap" in
3266 yes)
5607edfd 3267 bootstrap_suffix=bootstrap ;;
f516a7da 3268 no)
5607edfd 3269 bootstrap_suffix=no-bootstrap ;;
f516a7da
PB
3270esac
3271
23f6b2f9 3272for module in ${build_configdirs} ; do
5607edfd
PB
3273 if test -z "${no_recursion}" \
3274 && test -f ${build_subdir}/${module}/Makefile; then
3275 echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
3276 rm -f ${build_subdir}/${module}/Makefile
3277 fi
3278 extrasub="$extrasub
3279/^@if build-$module\$/d
3280/^@endif build-$module\$/d
3281/^@if build-$module-$bootstrap_suffix\$/d
3282/^@endif build-$module-$bootstrap_suffix\$/d"
3283done
3284for module in ${configdirs} ; do
a6fbc1e2 3285 if test -z "${no_recursion}"; then
f063a9ed 3286 for file in stage*-${module}/Makefile prev-${module}/Makefile ${module}/Makefile; do
a6fbc1e2
AS
3287 if test -f ${file}; then
3288 echo 1>&2 "*** removing ${file} to force reconfigure"
3289 rm -f ${file}
3290 fi
3291 done
5607edfd
PB
3292 fi
3293 extrasub="$extrasub
3294/^@if $module\$/d
3295/^@endif $module\$/d
3296/^@if $module-$bootstrap_suffix\$/d
3297/^@endif $module-$bootstrap_suffix\$/d"
3298done
3299for module in ${target_configdirs} ; do
3300 if test -z "${no_recursion}" \
3301 && test -f ${target_subdir}/${module}/Makefile; then
3302 echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
3303 rm -f ${target_subdir}/${module}/Makefile
3304 fi
3305 extrasub="$extrasub
3306/^@if target-$module\$/d
3307/^@endif target-$module\$/d
3308/^@if target-$module-$bootstrap_suffix\$/d
3309/^@endif target-$module-$bootstrap_suffix\$/d"
3310done
3311
60975492
PB
3312extrasub="$extrasub
3313/^@if /,/^@endif /d"
671aa708
NN
3314
3315# Create the serialization dependencies. This uses a temporary file.
3316
ade82b16
AO
3317# Check whether --enable-serial-configure or --disable-serial-configure was given.
3318if test "${enable_serial_configure+set}" = set; then
3319 enableval="$enable_serial_configure"
af71363e
AS
3320 :
3321fi
ade82b16
AO
3322
3323
bf1d3e81
NN
3324case ${enable_serial_configure} in
3325 yes)
3326 enable_serial_build_configure=yes
3327 enable_serial_host_configure=yes
3328 enable_serial_target_configure=yes
3329 ;;
3330esac
3331
671aa708
NN
3332# These force 'configure's to be done one at a time, to avoid problems
3333# with contention over a shared config.cache.
3334rm -f serdep.tmp
ade82b16 3335echo '# serdep.tmp' > serdep.tmp
671aa708 3336olditem=
bf1d3e81 3337test "x${enable_serial_build_configure}" = xyes &&
671aa708
NN
3338for item in ${build_configdirs} ; do
3339 case ${olditem} in
3340 "") ;;
ade82b16 3341 *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
671aa708
NN
3342 esac
3343 olditem=${item}
3344done
3345olditem=
bf1d3e81 3346test "x${enable_serial_host_configure}" = xyes &&
671aa708
NN
3347for item in ${configdirs} ; do
3348 case ${olditem} in
3349 "") ;;
ade82b16 3350 *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
671aa708
NN
3351 esac
3352 olditem=${item}
3353done
3354olditem=
bf1d3e81 3355test "x${enable_serial_target_configure}" = xyes &&
671aa708
NN
3356for item in ${target_configdirs} ; do
3357 case ${olditem} in
3358 "") ;;
ade82b16 3359 *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
671aa708
NN
3360 esac
3361 olditem=${item}
3362done
3363serialization_dependencies=serdep.tmp
3364
3365
ade82b16
AO
3366# Base args. Strip norecursion, cache-file, srcdir, host, build,
3367# target and nonopt. These are the ones we might not want to pass
43bb47c2
DJ
3368# down to subconfigures. Also strip program-prefix, program-suffix,
3369# and program-transform-name, so that we can pass down a consistent
3370# program-transform-name. If autoconf has put single quotes around
3371# any of these arguments (because they contain shell metacharacters)
3372# then this will fail; in practice this only happens for
3373# --program-transform-name, so be sure to override --program-transform-name
3374# at the end of the argument list.
3375# These will be expanded by make, so quote '$'.
b348267b 3376cat <<\EOF_SED > conftestsed
9104315a
NN
3377s/ --no[^ ]*/ /g
3378s/ --c[a-z-]*[= ][^ ]*//g
3379s/ --sr[a-z-]*[= ][^ ]*//g
3380s/ --ho[a-z-]*[= ][^ ]*//g
3381s/ --bu[a-z-]*[= ][^ ]*//g
3382s/ --t[a-z-]*[= ][^ ]*//g
3383s/ --program-[pst][a-z-]*[= ][^ ]*//g
3384s/ -cache-file[= ][^ ]*//g
3385s/ -srcdir[= ][^ ]*//g
3386s/ -host[= ][^ ]*//g
3387s/ -build[= ][^ ]*//g
3388s/ -target[= ][^ ]*//g
3389s/ -program-prefix[= ][^ ]*//g
3390s/ -program-suffix[= ][^ ]*//g
3391s/ -program-transform-name[= ][^ ]*//g
b348267b
GK
3392s/ [^' -][^ ]* / /
3393s/^ *//;s/ *$//
eeae7b41
DJ
3394s,\$,$$,g
3395EOF_SED
3396sed -f conftestsed <<EOF_SED > conftestsed.out
af71363e 3397 ${ac_configure_args}
b348267b 3398EOF_SED
eeae7b41
DJ
3399baseargs=`cat conftestsed.out`
3400rm -f conftestsed conftestsed.out
671aa708 3401
43bb47c2
DJ
3402# Add in --program-transform-name, after --program-prefix and
3403# --program-suffix have been applied to it. Autoconf has already
3404# doubled dollar signs and backslashes in program_transform_name; we want
3405# the backslashes un-doubled, and then the entire thing wrapped in single
af71363e 3406# quotes, because this will be expanded first by make and then by the shell.
43bb47c2
DJ
3407# Also, because we want to override the logic in subdir configure scripts to
3408# choose program_transform_name, replace any s,x,x, with s,y,y,.
3409sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
3410${program_transform_name}
3411EOF_SED
3412gcc_transform_name=`cat conftestsed.out`
3413rm -f conftestsed.out
3414baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
3415
671aa708
NN
3416# For the build-side libraries, we just need to pretend we're native,
3417# and not use the same cache file. Multilibs are neither needed nor
3418# desired.
e69bf64b 3419build_configargs="--cache-file=../config.cache ${baseargs}"
671aa708
NN
3420
3421# For host modules, accept cache file option, or specification as blank.
3422case "${cache_file}" in
3423"") # empty
3424 cache_file_option="" ;;
3425/* | [A-Za-z]:[\\/]* ) # absolute path
3426 cache_file_option="--cache-file=${cache_file}" ;;
3427*) # relative path
3428 cache_file_option="--cache-file=../${cache_file}" ;;
3429esac
3430
09438bde
NN
3431# Host dirs don't like to share a cache file either, horribly enough.
3432# This seems to be due to autoconf 2.5x stupidity.
e69bf64b 3433host_configargs="--cache-file=./config.cache ${extra_host_args} ${baseargs}"
671aa708
NN
3434
3435target_configargs=${baseargs}
3436
3437# Passing a --with-cross-host argument lets the target libraries know
3438# whether they are being built with a cross-compiler or being built
3439# native. However, it would be better to use other mechanisms to make the
3440# sorts of decisions they want to make on this basis. Please consider
3441# this option to be deprecated. FIXME.
3442if test x${is_cross_compiler} = xyes ; then
3443 target_configargs="--with-cross-host=${host_alias} ${target_configargs}"
3444fi
3445
3446# Default to --enable-multilib.
3447if test x${enable_multilib} = x ; then
3448 target_configargs="--enable-multilib ${target_configargs}"
3449fi
3450
3451# Pass --with-newlib if appropriate. Note that target_configdirs has
3452# changed from the earlier setting of with_newlib.
3453if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
3454 target_configargs="--with-newlib ${target_configargs}"
3455fi
3456
6b9eb62c
NN
3457# Different target subdirs use different values of certain variables
3458# (notably CXX). Worse, multilibs use *lots* of different values.
3459# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
3460# it doesn't automatically accept command-line overrides of them.
3461# This means it's not safe for target subdirs to share a cache file,
3462# which is disgusting, but there you have it. Hopefully this can be
3463# fixed in future. It's still worthwhile to use a cache file for each
3464# directory. I think.
3465
bebcd931
MS
3466# Pass the appropriate --build, --host, --target and --cache-file arguments.
3467# We need to pass --target, as newer autoconf's requires consistency
3468# for target_alias and gcc doesn't manage it consistently.
e69bf64b 3469target_configargs="--cache-file=./config.cache ${target_configargs}"
671aa708 3470
671aa708
NN
3471FLAGS_FOR_TARGET=
3472case " $target_configdirs " in
3473 *" newlib "*)
3474 case " $target_configargs " in
3475 *" --with-newlib "*)
3476 case "$target" in
3477 *-cygwin*)
aa8f1f57 3478 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
3479 esac
3480
3481 # If we're not building GCC, don't discard standard headers.
3482 if test -d ${srcdir}/gcc; then
3483 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
3484
3485 if test "${build}" != "${host}"; then
3486 # On Canadian crosses, CC_FOR_TARGET will have already been set
3487 # by `configure', so we won't have an opportunity to add -Bgcc/
3488 # to it. This is right: we don't want to search that directory
3489 # for binaries, but we want the header files in there, so add
3490 # them explicitly.
215c351a 3491 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include'
671aa708
NN
3492
3493 # Someone might think of using the pre-installed headers on
3494 # Canadian crosses, in case the installed compiler is not fully
3495 # compatible with the compiler being built. In this case, it
3496 # would be better to flag an error than risking having
3497 # incompatible object files being constructed. We can't
3498 # guarantee that an error will be flagged, but let's hope the
3499 # compiler will do it, when presented with incompatible header
3500 # files.
3501 fi
3502 fi
3503
3504 case "${target}-${is_cross_compiler}" in
f2a0e225 3505 i[3456789]86-*-linux*-no)
671aa708
NN
3506 # Here host == target, so we don't need to build gcc,
3507 # so we don't want to discard standard headers.
3508 FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
3509 ;;
3510 *)
3511 # If we're building newlib, use its generic headers last, but search
3512 # for any libc-related directories first (so make it the last -B
3513 # switch).
3514 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
3515 ;;
3516 esac
3517 ;;
3518 esac
3519 ;;
3520esac
b91f0a41
CV
3521case "$target" in
3522*-mingw*)
3523 # Can't be handled as Cygwin above since Mingw does not use newlib.
3524 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' ;;
3525esac
671aa708 3526
6691a79e
ME
3527# Allow the user to override the flags for
3528# our build compiler if desired.
3529CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
3530
671aa708
NN
3531# On Canadian crosses, we'll be searching the right directories for
3532# the previously-installed cross compiler, so don't bother to add
3533# flags for directories within the install tree of the compiler
3534# being built; programs in there won't even run.
3535if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
3536 # Search for pre-installed headers if nothing else fits.
9124bc53 3537 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
3538fi
3539
3540if test "x${use_gnu_ld}" = x &&
3541 echo " ${configdirs} " | grep " ld " > /dev/null ; then
3542 # Arrange for us to find uninstalled linker scripts.
215c351a 3543 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
671aa708
NN
3544fi
3545
e88a2c09
DD
3546# Search for other target-specific linker scripts and such.
3547case "${target}" in
3548 m32c-*-* )
3549 if test -d ${srcdir}/libgloss/m32c; then
3550 # This is for crt0.o
3551 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/libgloss/m32c'
3552 # This is for r8c.ld
3553 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/m32c'
3554 # This is for libnosys.a
3555 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/libnosys'
3556 fi
3557 ;;
3558esac
3559
671aa708 3560# Makefile fragments.
7b61653a
PE
3561for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
3562do
3563 eval fragval=\$$frag
3564 if test $fragval != /dev/null; then
3565 eval $frag=${srcdir}/$fragval
3566 fi
3567done
671aa708
NN
3568
3569
3570
3571
3572
3573# Miscellanea: directories, flags, etc.
3574
3575
3576
3577
3578
3579
3580
23f6b2f9 3581# Build module lists & subconfigure args.
671aa708
NN
3582
3583
3584
2abefe3d
PB
3585# Host module lists & subconfigure args.
3586
3587
3588
3589# Target module lists & subconfigure args.
3590
3591
3592
3593# Build tools.
3594
3595
3596
3597# Generate default definitions for YACC, M4, LEX and other programs that run
3598# on the build machine. These are used if the Makefile can't locate these
3599# programs in objdir.
3600MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
3601
3602for ac_prog in 'bison -y' byacc yacc
3603do
af71363e 3604# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3605set dummy $ac_prog; ac_word=$2
af71363e 3606echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3607echo "configure:3608: checking for $ac_word" >&5
af71363e
AS
3608if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
3609 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3610else
3611 if test -n "$YACC"; then
3612 ac_cv_prog_YACC="$YACC" # Let the user override the test.
3613else
af71363e
AS
3614 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3615 ac_dummy="$PATH"
3616 for ac_dir in $ac_dummy; do
3617 test -z "$ac_dir" && ac_dir=.
3618 if test -f $ac_dir/$ac_word; then
3619 ac_cv_prog_YACC="$ac_prog"
3620 break
3621 fi
3622 done
3623 IFS="$ac_save_ifs"
2abefe3d
PB
3624fi
3625fi
af71363e 3626YACC="$ac_cv_prog_YACC"
2abefe3d 3627if test -n "$YACC"; then
af71363e 3628 echo "$ac_t""$YACC" 1>&6
2abefe3d 3629else
af71363e 3630 echo "$ac_t""no" 1>&6
2abefe3d
PB
3631fi
3632
af71363e 3633test -n "$YACC" && break
2abefe3d
PB
3634done
3635test -n "$YACC" || YACC="$MISSING bison -y"
3636
3637case " $build_configdirs " in
3638 *" bison "*) YACC='$$r/$(BUILD_SUBDIR)/bison/tests/bison -y' ;;
3639 *" byacc "*) YACC='$$r/$(BUILD_SUBDIR)/byacc/byacc' ;;
3640esac
3641
3642for ac_prog in bison
3643do
af71363e 3644# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3645set dummy $ac_prog; ac_word=$2
af71363e 3646echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3647echo "configure:3648: checking for $ac_word" >&5
af71363e
AS
3648if eval "test \"`echo '$''{'ac_cv_prog_BISON'+set}'`\" = set"; then
3649 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3650else
3651 if test -n "$BISON"; then
3652 ac_cv_prog_BISON="$BISON" # Let the user override the test.
3653else
af71363e
AS
3654 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3655 ac_dummy="$PATH"
3656 for ac_dir in $ac_dummy; do
3657 test -z "$ac_dir" && ac_dir=.
3658 if test -f $ac_dir/$ac_word; then
3659 ac_cv_prog_BISON="$ac_prog"
3660 break
3661 fi
3662 done
3663 IFS="$ac_save_ifs"
2abefe3d
PB
3664fi
3665fi
af71363e 3666BISON="$ac_cv_prog_BISON"
2abefe3d 3667if test -n "$BISON"; then
af71363e 3668 echo "$ac_t""$BISON" 1>&6
2abefe3d 3669else
af71363e 3670 echo "$ac_t""no" 1>&6
2abefe3d
PB
3671fi
3672
af71363e 3673test -n "$BISON" && break
2abefe3d
PB
3674done
3675test -n "$BISON" || BISON="$MISSING bison"
3676
3677case " $build_configdirs " in
3678 *" bison "*) BISON='$$r/$(BUILD_SUBDIR)/bison/tests/bison' ;;
3679esac
3680
3681for ac_prog in gm4 gnum4 m4
3682do
af71363e 3683# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3684set dummy $ac_prog; ac_word=$2
af71363e 3685echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3686echo "configure:3687: checking for $ac_word" >&5
af71363e
AS
3687if eval "test \"`echo '$''{'ac_cv_prog_M4'+set}'`\" = set"; then
3688 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3689else
3690 if test -n "$M4"; then
3691 ac_cv_prog_M4="$M4" # Let the user override the test.
3692else
af71363e
AS
3693 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3694 ac_dummy="$PATH"
3695 for ac_dir in $ac_dummy; do
3696 test -z "$ac_dir" && ac_dir=.
3697 if test -f $ac_dir/$ac_word; then
3698 ac_cv_prog_M4="$ac_prog"
3699 break
3700 fi
3701 done
3702 IFS="$ac_save_ifs"
2abefe3d
PB
3703fi
3704fi
af71363e 3705M4="$ac_cv_prog_M4"
2abefe3d 3706if test -n "$M4"; then
af71363e 3707 echo "$ac_t""$M4" 1>&6
2abefe3d 3708else
af71363e 3709 echo "$ac_t""no" 1>&6
2abefe3d
PB
3710fi
3711
af71363e 3712test -n "$M4" && break
2abefe3d
PB
3713done
3714test -n "$M4" || M4="$MISSING m4"
3715
3716case " $build_configdirs " in
3717 *" m4 "*) M4='$$r/$(BUILD_SUBDIR)/m4/m4' ;;
3718esac
3719
3720for ac_prog in flex lex
3721do
af71363e 3722# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3723set dummy $ac_prog; ac_word=$2
af71363e 3724echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3725echo "configure:3726: checking for $ac_word" >&5
af71363e
AS
3726if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
3727 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3728else
3729 if test -n "$LEX"; then
3730 ac_cv_prog_LEX="$LEX" # Let the user override the test.
3731else
af71363e
AS
3732 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3733 ac_dummy="$PATH"
3734 for ac_dir in $ac_dummy; do
3735 test -z "$ac_dir" && ac_dir=.
3736 if test -f $ac_dir/$ac_word; then
3737 ac_cv_prog_LEX="$ac_prog"
3738 break
3739 fi
3740 done
3741 IFS="$ac_save_ifs"
2abefe3d
PB
3742fi
3743fi
af71363e 3744LEX="$ac_cv_prog_LEX"
2abefe3d 3745if test -n "$LEX"; then
af71363e 3746 echo "$ac_t""$LEX" 1>&6
2abefe3d 3747else
af71363e 3748 echo "$ac_t""no" 1>&6
2abefe3d
PB
3749fi
3750
af71363e 3751test -n "$LEX" && break
2abefe3d
PB
3752done
3753test -n "$LEX" || LEX="$MISSING flex"
3754
3755case " $build_configdirs " in
3756 *" flex "*) LEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
3757 *" lex "*) LEX='$$r/$(BUILD_SUBDIR)/lex/lex' ;;
3758esac
3759
3760for ac_prog in flex
3761do
af71363e 3762# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3763set dummy $ac_prog; ac_word=$2
af71363e 3764echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3765echo "configure:3766: checking for $ac_word" >&5
af71363e
AS
3766if eval "test \"`echo '$''{'ac_cv_prog_FLEX'+set}'`\" = set"; then
3767 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3768else
3769 if test -n "$FLEX"; then
3770 ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
3771else
af71363e
AS
3772 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3773 ac_dummy="$PATH"
3774 for ac_dir in $ac_dummy; do
3775 test -z "$ac_dir" && ac_dir=.
3776 if test -f $ac_dir/$ac_word; then
3777 ac_cv_prog_FLEX="$ac_prog"
3778 break
3779 fi
3780 done
3781 IFS="$ac_save_ifs"
2abefe3d
PB
3782fi
3783fi
af71363e 3784FLEX="$ac_cv_prog_FLEX"
2abefe3d 3785if test -n "$FLEX"; then
af71363e 3786 echo "$ac_t""$FLEX" 1>&6
2abefe3d 3787else
af71363e 3788 echo "$ac_t""no" 1>&6
2abefe3d
PB
3789fi
3790
af71363e 3791test -n "$FLEX" && break
2abefe3d
PB
3792done
3793test -n "$FLEX" || FLEX="$MISSING flex"
3794
3795case " $build_configdirs " in
3796 *" flex "*) FLEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
3797esac
3798
3799for ac_prog in makeinfo
3800do
af71363e 3801# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3802set dummy $ac_prog; ac_word=$2
af71363e 3803echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3804echo "configure:3805: checking for $ac_word" >&5
af71363e
AS
3805if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then
3806 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3807else
3808 if test -n "$MAKEINFO"; then
3809 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
3810else
af71363e
AS
3811 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3812 ac_dummy="$PATH"
3813 for ac_dir in $ac_dummy; do
3814 test -z "$ac_dir" && ac_dir=.
3815 if test -f $ac_dir/$ac_word; then
3816 ac_cv_prog_MAKEINFO="$ac_prog"
3817 break
3818 fi
3819 done
3820 IFS="$ac_save_ifs"
2abefe3d
PB
3821fi
3822fi
af71363e 3823MAKEINFO="$ac_cv_prog_MAKEINFO"
2abefe3d 3824if test -n "$MAKEINFO"; then
af71363e 3825 echo "$ac_t""$MAKEINFO" 1>&6
2abefe3d 3826else
af71363e 3827 echo "$ac_t""no" 1>&6
2abefe3d
PB
3828fi
3829
af71363e 3830test -n "$MAKEINFO" && break
2abefe3d
PB
3831done
3832test -n "$MAKEINFO" || MAKEINFO="$MISSING makeinfo"
3833
3834case " $build_configdirs " in
3835 *" texinfo "*) MAKEINFO='$$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo' ;;
3836 *)
3837
27b6c940 3838 # For an installed makeinfo, we require it to be from texinfo 4.4 or
2abefe3d
PB
3839 # higher, else we use the "missing" dummy.
3840 if ${MAKEINFO} --version \
27b6c940 3841 | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[4-9]|[5-9])' >/dev/null 2>&1; then
2abefe3d
PB
3842 :
3843 else
3844 MAKEINFO="$MISSING makeinfo"
3845 fi
3846 ;;
3847
3848esac
671aa708 3849
2abefe3d 3850# FIXME: expect and dejagnu may become build tools?
671aa708 3851
2abefe3d
PB
3852for ac_prog in expect
3853do
af71363e 3854# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3855set dummy $ac_prog; ac_word=$2
af71363e 3856echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3857echo "configure:3858: checking for $ac_word" >&5
af71363e
AS
3858if eval "test \"`echo '$''{'ac_cv_prog_EXPECT'+set}'`\" = set"; then
3859 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3860else
3861 if test -n "$EXPECT"; then
3862 ac_cv_prog_EXPECT="$EXPECT" # Let the user override the test.
3863else
af71363e
AS
3864 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3865 ac_dummy="$PATH"
3866 for ac_dir in $ac_dummy; do
3867 test -z "$ac_dir" && ac_dir=.
3868 if test -f $ac_dir/$ac_word; then
3869 ac_cv_prog_EXPECT="$ac_prog"
3870 break
3871 fi
3872 done
3873 IFS="$ac_save_ifs"
2abefe3d
PB
3874fi
3875fi
af71363e 3876EXPECT="$ac_cv_prog_EXPECT"
2abefe3d 3877if test -n "$EXPECT"; then
af71363e 3878 echo "$ac_t""$EXPECT" 1>&6
2abefe3d 3879else
af71363e 3880 echo "$ac_t""no" 1>&6
2abefe3d 3881fi
671aa708 3882
af71363e 3883test -n "$EXPECT" && break
2abefe3d
PB
3884done
3885test -n "$EXPECT" || EXPECT="expect"
671aa708 3886
2abefe3d
PB
3887case " $configdirs " in
3888 *" expect "*)
3889 test $host = $build && EXPECT='$$r/$(HOST_SUBDIR)/expect/expect'
3890 ;;
3891esac
671aa708 3892
2abefe3d
PB
3893for ac_prog in runtest
3894do
af71363e 3895# Extract the first word of "$ac_prog", so it can be a program name with args.
2abefe3d 3896set dummy $ac_prog; ac_word=$2
af71363e 3897echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3898echo "configure:3899: checking for $ac_word" >&5
af71363e
AS
3899if eval "test \"`echo '$''{'ac_cv_prog_RUNTEST'+set}'`\" = set"; then
3900 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
3901else
3902 if test -n "$RUNTEST"; then
3903 ac_cv_prog_RUNTEST="$RUNTEST" # Let the user override the test.
fb0103e5 3904else
af71363e
AS
3905 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3906 ac_dummy="$PATH"
3907 for ac_dir in $ac_dummy; do
3908 test -z "$ac_dir" && ac_dir=.
3909 if test -f $ac_dir/$ac_word; then
3910 ac_cv_prog_RUNTEST="$ac_prog"
3911 break
3912 fi
3913 done
3914 IFS="$ac_save_ifs"
2abefe3d
PB
3915fi
3916fi
af71363e 3917RUNTEST="$ac_cv_prog_RUNTEST"
2abefe3d 3918if test -n "$RUNTEST"; then
af71363e 3919 echo "$ac_t""$RUNTEST" 1>&6
2abefe3d 3920else
af71363e 3921 echo "$ac_t""no" 1>&6
2abefe3d 3922fi
671aa708 3923
af71363e 3924test -n "$RUNTEST" && break
2abefe3d
PB
3925done
3926test -n "$RUNTEST" || RUNTEST="runtest"
671aa708 3927
2abefe3d
PB
3928case " $configdirs " in
3929 *" dejagnu "*)
c394e891 3930 test $host = $build && RUNTEST='$$s/$(HOST_SUBDIR)/dejagnu/runtest'
2abefe3d
PB
3931 ;;
3932esac
671aa708
NN
3933
3934
671aa708 3935# Host tools.
ca9f4b81
AO
3936ncn_tool_prefix=
3937test -n "$host_alias" && ncn_tool_prefix=$host_alias-
3938ncn_target_tool_prefix=
3939test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
3940
2693c0b0
PB
3941 for ncn_progname in ar; do
3942 if test -n "$ncn_tool_prefix"; then
3943 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3944set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 3945echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3946echo "configure:3947: checking for $ac_word" >&5
af71363e
AS
3947if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
3948 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
3949else
3950 if test -n "$AR"; then
3951 ac_cv_prog_AR="$AR" # Let the user override the test.
3952else
af71363e
AS
3953 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3954 ac_dummy="$PATH"
3955 for ac_dir in $ac_dummy; do
3956 test -z "$ac_dir" && ac_dir=.
3957 if test -f $ac_dir/$ac_word; then
3958 ac_cv_prog_AR="${ncn_tool_prefix}${ncn_progname}"
3959 break
3960 fi
3961 done
3962 IFS="$ac_save_ifs"
ca9f4b81
AO
3963fi
3964fi
af71363e 3965AR="$ac_cv_prog_AR"
ca9f4b81 3966if test -n "$AR"; then
af71363e 3967 echo "$ac_t""$AR" 1>&6
ca9f4b81 3968else
af71363e 3969 echo "$ac_t""no" 1>&6
ca9f4b81
AO
3970fi
3971
2693c0b0
PB
3972 fi
3973 if test -z "$ac_cv_prog_AR" && test $build = $host ; then
3974 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3975set dummy ${ncn_progname}; ac_word=$2
af71363e 3976echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 3977echo "configure:3978: checking for $ac_word" >&5
af71363e
AS
3978if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
3979 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 3980else
2693c0b0 3981 if test -n "$AR"; then
af71363e
AS
3982 ac_cv_prog_AR="$AR" # Let the user override the test.
3983else
3984 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3985 ac_dummy="$PATH"
3986 for ac_dir in $ac_dummy; do
3987 test -z "$ac_dir" && ac_dir=.
3988 if test -f $ac_dir/$ac_word; then
3989 ac_cv_prog_AR="${ncn_progname}"
3990 break
3991 fi
3992 done
3993 IFS="$ac_save_ifs"
ca9f4b81
AO
3994fi
3995fi
af71363e 3996AR="$ac_cv_prog_AR"
2693c0b0 3997if test -n "$AR"; then
af71363e 3998 echo "$ac_t""$AR" 1>&6
ca9f4b81 3999else
af71363e 4000 echo "$ac_t""no" 1>&6
ca9f4b81 4001fi
af71363e 4002
2693c0b0
PB
4003 fi
4004 test -n "$ac_cv_prog_AR" && break
4005done
4006
4007if test -z "$ac_cv_prog_AR" ; then
4008 set dummy ar
4009 if test $build = $host ; then
4010 AR="$2"
ca9f4b81 4011 else
2693c0b0 4012 AR="${ncn_tool_prefix}$2"
ca9f4b81 4013 fi
ca9f4b81
AO
4014fi
4015
2693c0b0
PB
4016 for ncn_progname in as; do
4017 if test -n "$ncn_tool_prefix"; then
4018 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4019set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4020echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4021echo "configure:4022: checking for $ac_word" >&5
af71363e
AS
4022if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
4023 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4024else
4025 if test -n "$AS"; then
4026 ac_cv_prog_AS="$AS" # Let the user override the test.
0b0dc272 4027else
af71363e
AS
4028 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4029 ac_dummy="$PATH"
4030 for ac_dir in $ac_dummy; do
4031 test -z "$ac_dir" && ac_dir=.
4032 if test -f $ac_dir/$ac_word; then
4033 ac_cv_prog_AS="${ncn_tool_prefix}${ncn_progname}"
4034 break
4035 fi
4036 done
4037 IFS="$ac_save_ifs"
ca9f4b81
AO
4038fi
4039fi
af71363e 4040AS="$ac_cv_prog_AS"
ca9f4b81 4041if test -n "$AS"; then
af71363e 4042 echo "$ac_t""$AS" 1>&6
ca9f4b81 4043else
af71363e 4044 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4045fi
4046
2693c0b0
PB
4047 fi
4048 if test -z "$ac_cv_prog_AS" && test $build = $host ; then
4049 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4050set dummy ${ncn_progname}; ac_word=$2
af71363e 4051echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4052echo "configure:4053: checking for $ac_word" >&5
af71363e
AS
4053if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
4054 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4055else
2693c0b0
PB
4056 if test -n "$AS"; then
4057 ac_cv_prog_AS="$AS" # Let the user override the test.
ca9f4b81 4058else
af71363e
AS
4059 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4060 ac_dummy="$PATH"
4061 for ac_dir in $ac_dummy; do
4062 test -z "$ac_dir" && ac_dir=.
4063 if test -f $ac_dir/$ac_word; then
4064 ac_cv_prog_AS="${ncn_progname}"
4065 break
4066 fi
4067 done
4068 IFS="$ac_save_ifs"
ca9f4b81
AO
4069fi
4070fi
af71363e 4071AS="$ac_cv_prog_AS"
2693c0b0 4072if test -n "$AS"; then
af71363e 4073 echo "$ac_t""$AS" 1>&6
ca9f4b81 4074else
af71363e 4075 echo "$ac_t""no" 1>&6
ca9f4b81 4076fi
af71363e 4077
2693c0b0
PB
4078 fi
4079 test -n "$ac_cv_prog_AS" && break
4080done
4081
4082if test -z "$ac_cv_prog_AS" ; then
4083 set dummy as
4084 if test $build = $host ; then
4085 AS="$2"
ca9f4b81 4086 else
2693c0b0 4087 AS="${ncn_tool_prefix}$2"
ca9f4b81 4088 fi
ca9f4b81
AO
4089fi
4090
2693c0b0
PB
4091 for ncn_progname in dlltool; do
4092 if test -n "$ncn_tool_prefix"; then
4093 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4094set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4095echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4096echo "configure:4097: checking for $ac_word" >&5
af71363e
AS
4097if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
4098 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4099else
4100 if test -n "$DLLTOOL"; then
4101 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
4102else
af71363e
AS
4103 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4104 ac_dummy="$PATH"
4105 for ac_dir in $ac_dummy; do
4106 test -z "$ac_dir" && ac_dir=.
4107 if test -f $ac_dir/$ac_word; then
4108 ac_cv_prog_DLLTOOL="${ncn_tool_prefix}${ncn_progname}"
4109 break
4110 fi
4111 done
4112 IFS="$ac_save_ifs"
ca9f4b81
AO
4113fi
4114fi
af71363e 4115DLLTOOL="$ac_cv_prog_DLLTOOL"
ca9f4b81 4116if test -n "$DLLTOOL"; then
af71363e 4117 echo "$ac_t""$DLLTOOL" 1>&6
ca9f4b81 4118else
af71363e 4119 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4120fi
4121
2693c0b0
PB
4122 fi
4123 if test -z "$ac_cv_prog_DLLTOOL" && test $build = $host ; then
4124 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4125set dummy ${ncn_progname}; ac_word=$2
af71363e 4126echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4127echo "configure:4128: checking for $ac_word" >&5
af71363e
AS
4128if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
4129 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4130else
2693c0b0
PB
4131 if test -n "$DLLTOOL"; then
4132 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
ca9f4b81 4133else
af71363e
AS
4134 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4135 ac_dummy="$PATH"
4136 for ac_dir in $ac_dummy; do
4137 test -z "$ac_dir" && ac_dir=.
4138 if test -f $ac_dir/$ac_word; then
4139 ac_cv_prog_DLLTOOL="${ncn_progname}"
4140 break
4141 fi
4142 done
4143 IFS="$ac_save_ifs"
ca9f4b81
AO
4144fi
4145fi
af71363e 4146DLLTOOL="$ac_cv_prog_DLLTOOL"
2693c0b0 4147if test -n "$DLLTOOL"; then
af71363e 4148 echo "$ac_t""$DLLTOOL" 1>&6
ca9f4b81 4149else
af71363e 4150 echo "$ac_t""no" 1>&6
ca9f4b81 4151fi
af71363e 4152
2693c0b0
PB
4153 fi
4154 test -n "$ac_cv_prog_DLLTOOL" && break
4155done
4156
4157if test -z "$ac_cv_prog_DLLTOOL" ; then
4158 set dummy dlltool
4159 if test $build = $host ; then
4160 DLLTOOL="$2"
ca9f4b81 4161 else
2693c0b0 4162 DLLTOOL="${ncn_tool_prefix}$2"
ca9f4b81 4163 fi
ca9f4b81
AO
4164fi
4165
2693c0b0
PB
4166 for ncn_progname in ld; do
4167 if test -n "$ncn_tool_prefix"; then
4168 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4169set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4170echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4171echo "configure:4172: checking for $ac_word" >&5
af71363e
AS
4172if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
4173 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4174else
4175 if test -n "$LD"; then
4176 ac_cv_prog_LD="$LD" # Let the user override the test.
4177else
af71363e
AS
4178 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4179 ac_dummy="$PATH"
4180 for ac_dir in $ac_dummy; do
4181 test -z "$ac_dir" && ac_dir=.
4182 if test -f $ac_dir/$ac_word; then
4183 ac_cv_prog_LD="${ncn_tool_prefix}${ncn_progname}"
4184 break
4185 fi
4186 done
4187 IFS="$ac_save_ifs"
ca9f4b81
AO
4188fi
4189fi
af71363e 4190LD="$ac_cv_prog_LD"
ca9f4b81 4191if test -n "$LD"; then
af71363e 4192 echo "$ac_t""$LD" 1>&6
ca9f4b81 4193else
af71363e 4194 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4195fi
4196
2693c0b0
PB
4197 fi
4198 if test -z "$ac_cv_prog_LD" && test $build = $host ; then
4199 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4200set dummy ${ncn_progname}; ac_word=$2
af71363e 4201echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4202echo "configure:4203: checking for $ac_word" >&5
af71363e
AS
4203if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
4204 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4205else
2693c0b0
PB
4206 if test -n "$LD"; then
4207 ac_cv_prog_LD="$LD" # Let the user override the test.
6b65a26d 4208else
af71363e
AS
4209 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4210 ac_dummy="$PATH"
4211 for ac_dir in $ac_dummy; do
4212 test -z "$ac_dir" && ac_dir=.
4213 if test -f $ac_dir/$ac_word; then
4214 ac_cv_prog_LD="${ncn_progname}"
4215 break
4216 fi
4217 done
4218 IFS="$ac_save_ifs"
ca9f4b81
AO
4219fi
4220fi
af71363e 4221LD="$ac_cv_prog_LD"
2693c0b0 4222if test -n "$LD"; then
af71363e 4223 echo "$ac_t""$LD" 1>&6
ca9f4b81 4224else
af71363e 4225 echo "$ac_t""no" 1>&6
ca9f4b81 4226fi
af71363e 4227
2693c0b0
PB
4228 fi
4229 test -n "$ac_cv_prog_LD" && break
4230done
4231
4232if test -z "$ac_cv_prog_LD" ; then
4233 set dummy ld
4234 if test $build = $host ; then
4235 LD="$2"
ca9f4b81 4236 else
2693c0b0 4237 LD="${ncn_tool_prefix}$2"
ca9f4b81 4238 fi
ca9f4b81
AO
4239fi
4240
2abefe3d
PB
4241 for ncn_progname in lipo; do
4242 if test -n "$ncn_tool_prefix"; then
4243 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4244set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4245echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4246echo "configure:4247: checking for $ac_word" >&5
af71363e
AS
4247if eval "test \"`echo '$''{'ac_cv_prog_LIPO'+set}'`\" = set"; then
4248 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4249else
4250 if test -n "$LIPO"; then
4251 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
4252else
af71363e
AS
4253 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4254 ac_dummy="$PATH"
4255 for ac_dir in $ac_dummy; do
4256 test -z "$ac_dir" && ac_dir=.
4257 if test -f $ac_dir/$ac_word; then
4258 ac_cv_prog_LIPO="${ncn_tool_prefix}${ncn_progname}"
4259 break
4260 fi
4261 done
4262 IFS="$ac_save_ifs"
2abefe3d
PB
4263fi
4264fi
af71363e 4265LIPO="$ac_cv_prog_LIPO"
2abefe3d 4266if test -n "$LIPO"; then
af71363e 4267 echo "$ac_t""$LIPO" 1>&6
2abefe3d 4268else
af71363e 4269 echo "$ac_t""no" 1>&6
2abefe3d
PB
4270fi
4271
4272 fi
4273 if test -z "$ac_cv_prog_LIPO" && test $build = $host ; then
4274 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4275set dummy ${ncn_progname}; ac_word=$2
af71363e 4276echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4277echo "configure:4278: checking for $ac_word" >&5
af71363e
AS
4278if eval "test \"`echo '$''{'ac_cv_prog_LIPO'+set}'`\" = set"; then
4279 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4280else
4281 if test -n "$LIPO"; then
4282 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
4283else
af71363e
AS
4284 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4285 ac_dummy="$PATH"
4286 for ac_dir in $ac_dummy; do
4287 test -z "$ac_dir" && ac_dir=.
4288 if test -f $ac_dir/$ac_word; then
4289 ac_cv_prog_LIPO="${ncn_progname}"
4290 break
4291 fi
4292 done
4293 IFS="$ac_save_ifs"
2abefe3d
PB
4294fi
4295fi
af71363e 4296LIPO="$ac_cv_prog_LIPO"
2abefe3d 4297if test -n "$LIPO"; then
af71363e 4298 echo "$ac_t""$LIPO" 1>&6
2abefe3d 4299else
af71363e 4300 echo "$ac_t""no" 1>&6
2abefe3d 4301fi
af71363e 4302
2abefe3d
PB
4303 fi
4304 test -n "$ac_cv_prog_LIPO" && break
4305done
4306
4307if test -z "$ac_cv_prog_LIPO" ; then
4308 set dummy lipo
4309 if test $build = $host ; then
4310 LIPO="$2"
4311 else
4312 LIPO="${ncn_tool_prefix}$2"
4313 fi
4314fi
4315
2693c0b0
PB
4316 for ncn_progname in nm; do
4317 if test -n "$ncn_tool_prefix"; then
4318 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4319set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4320echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4321echo "configure:4322: checking for $ac_word" >&5
af71363e
AS
4322if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
4323 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4324else
4325 if test -n "$NM"; then
4326 ac_cv_prog_NM="$NM" # Let the user override the test.
4327else
af71363e
AS
4328 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4329 ac_dummy="$PATH"
4330 for ac_dir in $ac_dummy; do
4331 test -z "$ac_dir" && ac_dir=.
4332 if test -f $ac_dir/$ac_word; then
4333 ac_cv_prog_NM="${ncn_tool_prefix}${ncn_progname}"
4334 break
4335 fi
4336 done
4337 IFS="$ac_save_ifs"
ca9f4b81
AO
4338fi
4339fi
af71363e 4340NM="$ac_cv_prog_NM"
ca9f4b81 4341if test -n "$NM"; then
af71363e 4342 echo "$ac_t""$NM" 1>&6
ca9f4b81 4343else
af71363e 4344 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4345fi
4346
2693c0b0
PB
4347 fi
4348 if test -z "$ac_cv_prog_NM" && test $build = $host ; then
4349 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4350set dummy ${ncn_progname}; ac_word=$2
af71363e 4351echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4352echo "configure:4353: checking for $ac_word" >&5
af71363e
AS
4353if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
4354 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4355else
2693c0b0
PB
4356 if test -n "$NM"; then
4357 ac_cv_prog_NM="$NM" # Let the user override the test.
ca9f4b81 4358else
af71363e
AS
4359 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4360 ac_dummy="$PATH"
4361 for ac_dir in $ac_dummy; do
4362 test -z "$ac_dir" && ac_dir=.
4363 if test -f $ac_dir/$ac_word; then
4364 ac_cv_prog_NM="${ncn_progname}"
4365 break
4366 fi
4367 done
4368 IFS="$ac_save_ifs"
ca9f4b81
AO
4369fi
4370fi
af71363e 4371NM="$ac_cv_prog_NM"
2693c0b0 4372if test -n "$NM"; then
af71363e 4373 echo "$ac_t""$NM" 1>&6
ca9f4b81 4374else
af71363e 4375 echo "$ac_t""no" 1>&6
ca9f4b81 4376fi
af71363e 4377
2693c0b0
PB
4378 fi
4379 test -n "$ac_cv_prog_NM" && break
4380done
4381
4382if test -z "$ac_cv_prog_NM" ; then
4383 set dummy nm
4384 if test $build = $host ; then
4385 NM="$2"
ca9f4b81 4386 else
2693c0b0 4387 NM="${ncn_tool_prefix}$2"
ca9f4b81 4388 fi
ca9f4b81
AO
4389fi
4390
2693c0b0
PB
4391 for ncn_progname in ranlib; do
4392 if test -n "$ncn_tool_prefix"; then
4393 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4394set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4395echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4396echo "configure:4397: checking for $ac_word" >&5
af71363e
AS
4397if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
4398 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4399else
4400 if test -n "$RANLIB"; then
4401 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4402else
af71363e
AS
4403 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4404 ac_dummy="$PATH"
4405 for ac_dir in $ac_dummy; do
4406 test -z "$ac_dir" && ac_dir=.
4407 if test -f $ac_dir/$ac_word; then
4408 ac_cv_prog_RANLIB="${ncn_tool_prefix}${ncn_progname}"
4409 break
4410 fi
4411 done
4412 IFS="$ac_save_ifs"
ca9f4b81
AO
4413fi
4414fi
af71363e 4415RANLIB="$ac_cv_prog_RANLIB"
ca9f4b81 4416if test -n "$RANLIB"; then
af71363e 4417 echo "$ac_t""$RANLIB" 1>&6
ca9f4b81 4418else
af71363e 4419 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4420fi
4421
2693c0b0
PB
4422 fi
4423 if test -z "$ac_cv_prog_RANLIB" && test $build = $host ; then
4424 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4425set dummy ${ncn_progname}; ac_word=$2
af71363e 4426echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4427echo "configure:4428: checking for $ac_word" >&5
af71363e
AS
4428if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
4429 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4430else
2693c0b0
PB
4431 if test -n "$RANLIB"; then
4432 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
ca9f4b81 4433else
af71363e
AS
4434 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4435 ac_dummy="$PATH"
4436 for ac_dir in $ac_dummy; do
4437 test -z "$ac_dir" && ac_dir=.
4438 if test -f $ac_dir/$ac_word; then
4439 ac_cv_prog_RANLIB="${ncn_progname}"
4440 break
4441 fi
4442 done
4443 IFS="$ac_save_ifs"
ca9f4b81
AO
4444fi
4445fi
af71363e 4446RANLIB="$ac_cv_prog_RANLIB"
2693c0b0 4447if test -n "$RANLIB"; then
af71363e 4448 echo "$ac_t""$RANLIB" 1>&6
ca9f4b81 4449else
af71363e 4450 echo "$ac_t""no" 1>&6
ca9f4b81 4451fi
af71363e 4452
ca9f4b81 4453 fi
2693c0b0
PB
4454 test -n "$ac_cv_prog_RANLIB" && break
4455done
4456
4457if test -z "$ac_cv_prog_RANLIB" ; then
4458 RANLIB=":"
ca9f4b81
AO
4459fi
4460
2abefe3d
PB
4461 for ncn_progname in strip; do
4462 if test -n "$ncn_tool_prefix"; then
4463 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4464set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4465echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4466echo "configure:4467: checking for $ac_word" >&5
af71363e
AS
4467if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
4468 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4469else
4470 if test -n "$STRIP"; then
4471 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4472else
af71363e
AS
4473 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4474 ac_dummy="$PATH"
4475 for ac_dir in $ac_dummy; do
4476 test -z "$ac_dir" && ac_dir=.
4477 if test -f $ac_dir/$ac_word; then
4478 ac_cv_prog_STRIP="${ncn_tool_prefix}${ncn_progname}"
4479 break
4480 fi
4481 done
4482 IFS="$ac_save_ifs"
2abefe3d
PB
4483fi
4484fi
af71363e 4485STRIP="$ac_cv_prog_STRIP"
2abefe3d 4486if test -n "$STRIP"; then
af71363e 4487 echo "$ac_t""$STRIP" 1>&6
2abefe3d 4488else
af71363e 4489 echo "$ac_t""no" 1>&6
2abefe3d
PB
4490fi
4491
4492 fi
4493 if test -z "$ac_cv_prog_STRIP" && test $build = $host ; then
4494 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4495set dummy ${ncn_progname}; ac_word=$2
af71363e 4496echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4497echo "configure:4498: checking for $ac_word" >&5
af71363e
AS
4498if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
4499 echo $ac_n "(cached) $ac_c" 1>&6
2abefe3d
PB
4500else
4501 if test -n "$STRIP"; then
4502 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4503else
af71363e
AS
4504 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4505 ac_dummy="$PATH"
4506 for ac_dir in $ac_dummy; do
4507 test -z "$ac_dir" && ac_dir=.
4508 if test -f $ac_dir/$ac_word; then
4509 ac_cv_prog_STRIP="${ncn_progname}"
4510 break
4511 fi
4512 done
4513 IFS="$ac_save_ifs"
2abefe3d
PB
4514fi
4515fi
af71363e 4516STRIP="$ac_cv_prog_STRIP"
2abefe3d 4517if test -n "$STRIP"; then
af71363e 4518 echo "$ac_t""$STRIP" 1>&6
2abefe3d 4519else
af71363e 4520 echo "$ac_t""no" 1>&6
2abefe3d 4521fi
af71363e 4522
2abefe3d
PB
4523 fi
4524 test -n "$ac_cv_prog_STRIP" && break
4525done
4526
4527if test -z "$ac_cv_prog_STRIP" ; then
4528 STRIP=":"
4529fi
4530
2693c0b0
PB
4531 for ncn_progname in windres; do
4532 if test -n "$ncn_tool_prefix"; then
4533 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4534set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4535echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4536echo "configure:4537: checking for $ac_word" >&5
af71363e
AS
4537if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
4538 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4539else
4540 if test -n "$WINDRES"; then
4541 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
4542else
af71363e
AS
4543 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4544 ac_dummy="$PATH"
4545 for ac_dir in $ac_dummy; do
4546 test -z "$ac_dir" && ac_dir=.
4547 if test -f $ac_dir/$ac_word; then
4548 ac_cv_prog_WINDRES="${ncn_tool_prefix}${ncn_progname}"
4549 break
4550 fi
4551 done
4552 IFS="$ac_save_ifs"
ca9f4b81
AO
4553fi
4554fi
af71363e 4555WINDRES="$ac_cv_prog_WINDRES"
ca9f4b81 4556if test -n "$WINDRES"; then
af71363e 4557 echo "$ac_t""$WINDRES" 1>&6
ca9f4b81 4558else
af71363e 4559 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4560fi
4561
2693c0b0
PB
4562 fi
4563 if test -z "$ac_cv_prog_WINDRES" && test $build = $host ; then
4564 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4565set dummy ${ncn_progname}; ac_word=$2
af71363e 4566echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4567echo "configure:4568: checking for $ac_word" >&5
af71363e
AS
4568if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
4569 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4570else
2693c0b0
PB
4571 if test -n "$WINDRES"; then
4572 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
ca9f4b81 4573else
af71363e
AS
4574 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4575 ac_dummy="$PATH"
4576 for ac_dir in $ac_dummy; do
4577 test -z "$ac_dir" && ac_dir=.
4578 if test -f $ac_dir/$ac_word; then
4579 ac_cv_prog_WINDRES="${ncn_progname}"
4580 break
4581 fi
4582 done
4583 IFS="$ac_save_ifs"
ca9f4b81
AO
4584fi
4585fi
af71363e 4586WINDRES="$ac_cv_prog_WINDRES"
2693c0b0 4587if test -n "$WINDRES"; then
af71363e 4588 echo "$ac_t""$WINDRES" 1>&6
ca9f4b81 4589else
af71363e 4590 echo "$ac_t""no" 1>&6
ca9f4b81 4591fi
af71363e 4592
2693c0b0
PB
4593 fi
4594 test -n "$ac_cv_prog_WINDRES" && break
4595done
4596
4597if test -z "$ac_cv_prog_WINDRES" ; then
4598 set dummy windres
4599 if test $build = $host ; then
4600 WINDRES="$2"
ca9f4b81 4601 else
2693c0b0 4602 WINDRES="${ncn_tool_prefix}$2"
ca9f4b81 4603 fi
ca9f4b81
AO
4604fi
4605
2693c0b0
PB
4606 for ncn_progname in objcopy; do
4607 if test -n "$ncn_tool_prefix"; then
4608 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4609set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4610echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4611echo "configure:4612: checking for $ac_word" >&5
af71363e
AS
4612if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
4613 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4614else
4615 if test -n "$OBJCOPY"; then
4616 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
4617else
af71363e
AS
4618 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4619 ac_dummy="$PATH"
4620 for ac_dir in $ac_dummy; do
4621 test -z "$ac_dir" && ac_dir=.
4622 if test -f $ac_dir/$ac_word; then
4623 ac_cv_prog_OBJCOPY="${ncn_tool_prefix}${ncn_progname}"
4624 break
4625 fi
4626 done
4627 IFS="$ac_save_ifs"
ca9f4b81
AO
4628fi
4629fi
af71363e 4630OBJCOPY="$ac_cv_prog_OBJCOPY"
ca9f4b81 4631if test -n "$OBJCOPY"; then
af71363e 4632 echo "$ac_t""$OBJCOPY" 1>&6
ca9f4b81 4633else
af71363e 4634 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4635fi
4636
2693c0b0
PB
4637 fi
4638 if test -z "$ac_cv_prog_OBJCOPY" && test $build = $host ; then
4639 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4640set dummy ${ncn_progname}; ac_word=$2
af71363e 4641echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4642echo "configure:4643: checking for $ac_word" >&5
af71363e
AS
4643if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
4644 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4645else
2693c0b0
PB
4646 if test -n "$OBJCOPY"; then
4647 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
ca9f4b81 4648else
af71363e
AS
4649 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4650 ac_dummy="$PATH"
4651 for ac_dir in $ac_dummy; do
4652 test -z "$ac_dir" && ac_dir=.
4653 if test -f $ac_dir/$ac_word; then
4654 ac_cv_prog_OBJCOPY="${ncn_progname}"
4655 break
4656 fi
4657 done
4658 IFS="$ac_save_ifs"
ca9f4b81
AO
4659fi
4660fi
af71363e 4661OBJCOPY="$ac_cv_prog_OBJCOPY"
2693c0b0 4662if test -n "$OBJCOPY"; then
af71363e 4663 echo "$ac_t""$OBJCOPY" 1>&6
ca9f4b81 4664else
af71363e 4665 echo "$ac_t""no" 1>&6
ca9f4b81 4666fi
af71363e 4667
2693c0b0
PB
4668 fi
4669 test -n "$ac_cv_prog_OBJCOPY" && break
4670done
4671
4672if test -z "$ac_cv_prog_OBJCOPY" ; then
4673 set dummy objcopy
4674 if test $build = $host ; then
4675 OBJCOPY="$2"
ca9f4b81 4676 else
2693c0b0 4677 OBJCOPY="${ncn_tool_prefix}$2"
ca9f4b81 4678 fi
ca9f4b81
AO
4679fi
4680
2693c0b0
PB
4681 for ncn_progname in objdump; do
4682 if test -n "$ncn_tool_prefix"; then
4683 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4684set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4685echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4686echo "configure:4687: checking for $ac_word" >&5
af71363e
AS
4687if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
4688 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81
AO
4689else
4690 if test -n "$OBJDUMP"; then
4691 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
4692else
af71363e
AS
4693 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4694 ac_dummy="$PATH"
4695 for ac_dir in $ac_dummy; do
4696 test -z "$ac_dir" && ac_dir=.
4697 if test -f $ac_dir/$ac_word; then
4698 ac_cv_prog_OBJDUMP="${ncn_tool_prefix}${ncn_progname}"
4699 break
4700 fi
4701 done
4702 IFS="$ac_save_ifs"
ca9f4b81
AO
4703fi
4704fi
af71363e 4705OBJDUMP="$ac_cv_prog_OBJDUMP"
ca9f4b81 4706if test -n "$OBJDUMP"; then
af71363e 4707 echo "$ac_t""$OBJDUMP" 1>&6
ca9f4b81 4708else
af71363e 4709 echo "$ac_t""no" 1>&6
ca9f4b81
AO
4710fi
4711
2693c0b0
PB
4712 fi
4713 if test -z "$ac_cv_prog_OBJDUMP" && test $build = $host ; then
4714 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4715set dummy ${ncn_progname}; ac_word=$2
af71363e 4716echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4717echo "configure:4718: checking for $ac_word" >&5
af71363e
AS
4718if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
4719 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4720else
2693c0b0
PB
4721 if test -n "$OBJDUMP"; then
4722 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
ca9f4b81 4723else
af71363e
AS
4724 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4725 ac_dummy="$PATH"
4726 for ac_dir in $ac_dummy; do
4727 test -z "$ac_dir" && ac_dir=.
4728 if test -f $ac_dir/$ac_word; then
4729 ac_cv_prog_OBJDUMP="${ncn_progname}"
4730 break
4731 fi
4732 done
4733 IFS="$ac_save_ifs"
ca9f4b81
AO
4734fi
4735fi
af71363e 4736OBJDUMP="$ac_cv_prog_OBJDUMP"
2693c0b0 4737if test -n "$OBJDUMP"; then
af71363e 4738 echo "$ac_t""$OBJDUMP" 1>&6
ca9f4b81 4739else
af71363e 4740 echo "$ac_t""no" 1>&6
ca9f4b81 4741fi
af71363e 4742
2693c0b0
PB
4743 fi
4744 test -n "$ac_cv_prog_OBJDUMP" && break
4745done
4746
4747if test -z "$ac_cv_prog_OBJDUMP" ; then
4748 set dummy objdump
4749 if test $build = $host ; then
4750 OBJDUMP="$2"
ca9f4b81 4751 else
2693c0b0 4752 OBJDUMP="${ncn_tool_prefix}$2"
ca9f4b81 4753 fi
ca9f4b81
AO
4754fi
4755
671aa708
NN
4756
4757
4758
4759
4760
4761
2abefe3d 4762# Target tools.
e8b05380
PB
4763# Check whether --with-build-time-tools or --without-build-time-tools was given.
4764if test "${with_build_time_tools+set}" = set; then
4765 withval="$with_build_time_tools"
4766 case x"$withval" in
4767 x/*) ;;
4768 *)
4769 with_build_time_tools=
af71363e 4770 echo "configure: warning: argument to --with-build-time-tools must be an absolute path" 1>&2
e8b05380
PB
4771 ;;
4772 esac
ca9f4b81 4773else
e8b05380 4774 with_build_time_tools=
af71363e
AS
4775fi
4776
ca9f4b81 4777
e8b05380
PB
4778 if test -n "$with_build_time_tools"; then
4779 for ncn_progname in cc gcc; do
af71363e 4780 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 4781echo "configure:4782: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
4782 if test -x $with_build_time_tools/${ncn_progname}; then
4783 ac_cv_prog_CC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 4784 echo "$ac_t""yes" 1>&6
72a7ab82 4785 break
e8b05380 4786 else
af71363e 4787 echo "$ac_t""no" 1>&6
72a7ab82
AP
4788 fi
4789 done
4de997d1
PB
4790fi
4791
e8b05380
PB
4792if test -z "$ac_cv_prog_CC_FOR_TARGET"; then
4793 for ncn_progname in cc gcc; do
4794 if test -n "$ncn_target_tool_prefix"; then
4795 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 4796set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4797echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4798echo "configure:4799: checking for $ac_word" >&5
af71363e
AS
4799if eval "test \"`echo '$''{'ac_cv_prog_CC_FOR_TARGET'+set}'`\" = set"; then
4800 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1
PB
4801else
4802 if test -n "$CC_FOR_TARGET"; then
4803 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4804else
af71363e
AS
4805 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4806 ac_dummy="$PATH"
4807 for ac_dir in $ac_dummy; do
4808 test -z "$ac_dir" && ac_dir=.
4809 if test -f $ac_dir/$ac_word; then
4810 ac_cv_prog_CC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4811 break
4812 fi
4813 done
4814 IFS="$ac_save_ifs"
4de997d1
PB
4815fi
4816fi
af71363e 4817CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
4de997d1 4818if test -n "$CC_FOR_TARGET"; then
af71363e 4819 echo "$ac_t""$CC_FOR_TARGET" 1>&6
4de997d1 4820else
af71363e 4821 echo "$ac_t""no" 1>&6
4de997d1
PB
4822fi
4823
e8b05380
PB
4824 fi
4825 if test -z "$ac_cv_prog_CC_FOR_TARGET" && test $build = $target ; then
4826 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 4827set dummy ${ncn_progname}; ac_word=$2
af71363e 4828echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4829echo "configure:4830: checking for $ac_word" >&5
af71363e
AS
4830if eval "test \"`echo '$''{'ac_cv_prog_CC_FOR_TARGET'+set}'`\" = set"; then
4831 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 4832else
2693c0b0
PB
4833 if test -n "$CC_FOR_TARGET"; then
4834 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4de997d1 4835else
af71363e
AS
4836 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4837 ac_dummy="$PATH"
4838 for ac_dir in $ac_dummy; do
4839 test -z "$ac_dir" && ac_dir=.
4840 if test -f $ac_dir/$ac_word; then
4841 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
4842 break
4843 fi
4844 done
4845 IFS="$ac_save_ifs"
4de997d1
PB
4846fi
4847fi
af71363e 4848CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
2693c0b0 4849if test -n "$CC_FOR_TARGET"; then
af71363e 4850 echo "$ac_t""$CC_FOR_TARGET" 1>&6
4de997d1 4851else
af71363e 4852 echo "$ac_t""no" 1>&6
4de997d1 4853fi
af71363e 4854
e8b05380
PB
4855 fi
4856 test -n "$ac_cv_prog_CC_FOR_TARGET" && break
4857 done
4858fi
af71363e 4859
2693c0b0
PB
4860if test -z "$ac_cv_prog_CC_FOR_TARGET" ; then
4861 set dummy cc gcc
4862 if test $build = $target ; then
4863 CC_FOR_TARGET="$2"
4de997d1 4864 else
2693c0b0 4865 CC_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 4866 fi
4de997d1
PB
4867fi
4868
e8b05380
PB
4869 if test -n "$with_build_time_tools"; then
4870 for ncn_progname in c++ g++ cxx gxx; do
af71363e 4871 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 4872echo "configure:4873: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
4873 if test -x $with_build_time_tools/${ncn_progname}; then
4874 ac_cv_prog_CXX_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 4875 echo "$ac_t""yes" 1>&6
e8b05380
PB
4876 break
4877 else
af71363e 4878 echo "$ac_t""no" 1>&6
e8b05380
PB
4879 fi
4880 done
4881fi
4882
4883if test -z "$ac_cv_prog_CXX_FOR_TARGET"; then
4884 for ncn_progname in c++ g++ cxx gxx; do
4885 if test -n "$ncn_target_tool_prefix"; then
4886 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 4887set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4888echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4889echo "configure:4890: checking for $ac_word" >&5
af71363e
AS
4890if eval "test \"`echo '$''{'ac_cv_prog_CXX_FOR_TARGET'+set}'`\" = set"; then
4891 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1
PB
4892else
4893 if test -n "$CXX_FOR_TARGET"; then
4894 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4895else
af71363e
AS
4896 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4897 ac_dummy="$PATH"
4898 for ac_dir in $ac_dummy; do
4899 test -z "$ac_dir" && ac_dir=.
4900 if test -f $ac_dir/$ac_word; then
4901 ac_cv_prog_CXX_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4902 break
4903 fi
4904 done
4905 IFS="$ac_save_ifs"
4de997d1
PB
4906fi
4907fi
af71363e 4908CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
4de997d1 4909if test -n "$CXX_FOR_TARGET"; then
af71363e 4910 echo "$ac_t""$CXX_FOR_TARGET" 1>&6
4de997d1 4911else
af71363e 4912 echo "$ac_t""no" 1>&6
4de997d1
PB
4913fi
4914
e8b05380
PB
4915 fi
4916 if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test $build = $target ; then
4917 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 4918set dummy ${ncn_progname}; ac_word=$2
af71363e 4919echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4920echo "configure:4921: checking for $ac_word" >&5
af71363e
AS
4921if eval "test \"`echo '$''{'ac_cv_prog_CXX_FOR_TARGET'+set}'`\" = set"; then
4922 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 4923else
2693c0b0
PB
4924 if test -n "$CXX_FOR_TARGET"; then
4925 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4de997d1 4926else
af71363e
AS
4927 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4928 ac_dummy="$PATH"
4929 for ac_dir in $ac_dummy; do
4930 test -z "$ac_dir" && ac_dir=.
4931 if test -f $ac_dir/$ac_word; then
4932 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
4933 break
4934 fi
4935 done
4936 IFS="$ac_save_ifs"
4de997d1
PB
4937fi
4938fi
af71363e 4939CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
2693c0b0 4940if test -n "$CXX_FOR_TARGET"; then
af71363e 4941 echo "$ac_t""$CXX_FOR_TARGET" 1>&6
4de997d1 4942else
af71363e 4943 echo "$ac_t""no" 1>&6
4de997d1 4944fi
af71363e 4945
e8b05380
PB
4946 fi
4947 test -n "$ac_cv_prog_CXX_FOR_TARGET" && break
4948 done
4949fi
af71363e 4950
2693c0b0
PB
4951if test -z "$ac_cv_prog_CXX_FOR_TARGET" ; then
4952 set dummy c++ g++ cxx gxx
4953 if test $build = $target ; then
4954 CXX_FOR_TARGET="$2"
4de997d1 4955 else
2693c0b0 4956 CXX_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 4957 fi
ca9f4b81
AO
4958fi
4959
e8b05380
PB
4960 if test -n "$with_build_time_tools"; then
4961 for ncn_progname in gcc; do
af71363e 4962 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 4963echo "configure:4964: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
4964 if test -x $with_build_time_tools/${ncn_progname}; then
4965 ac_cv_prog_GCC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 4966 echo "$ac_t""yes" 1>&6
e8b05380
PB
4967 break
4968 else
af71363e 4969 echo "$ac_t""no" 1>&6
e8b05380
PB
4970 fi
4971 done
4972fi
4973
4974if test -z "$ac_cv_prog_GCC_FOR_TARGET"; then
4975 for ncn_progname in gcc; do
4976 if test -n "$ncn_target_tool_prefix"; then
4977 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 4978set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 4979echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 4980echo "configure:4981: checking for $ac_word" >&5
af71363e
AS
4981if eval "test \"`echo '$''{'ac_cv_prog_GCC_FOR_TARGET'+set}'`\" = set"; then
4982 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 4983else
e8b05380
PB
4984 if test -n "$GCC_FOR_TARGET"; then
4985 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 4986else
af71363e
AS
4987 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4988 ac_dummy="$PATH"
4989 for ac_dir in $ac_dummy; do
4990 test -z "$ac_dir" && ac_dir=.
4991 if test -f $ac_dir/$ac_word; then
4992 ac_cv_prog_GCC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4993 break
4994 fi
4995 done
4996 IFS="$ac_save_ifs"
ca9f4b81
AO
4997fi
4998fi
af71363e 4999GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
e8b05380 5000if test -n "$GCC_FOR_TARGET"; then
af71363e 5001 echo "$ac_t""$GCC_FOR_TARGET" 1>&6
ca9f4b81 5002else
af71363e 5003 echo "$ac_t""no" 1>&6
ca9f4b81
AO
5004fi
5005
e8b05380
PB
5006 fi
5007 if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test $build = $target ; then
5008 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 5009set dummy ${ncn_progname}; ac_word=$2
af71363e 5010echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5011echo "configure:5012: checking for $ac_word" >&5
af71363e
AS
5012if eval "test \"`echo '$''{'ac_cv_prog_GCC_FOR_TARGET'+set}'`\" = set"; then
5013 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5014else
e8b05380
PB
5015 if test -n "$GCC_FOR_TARGET"; then
5016 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
ca9f4b81 5017else
af71363e
AS
5018 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5019 ac_dummy="$PATH"
5020 for ac_dir in $ac_dummy; do
5021 test -z "$ac_dir" && ac_dir=.
5022 if test -f $ac_dir/$ac_word; then
5023 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
5024 break
5025 fi
5026 done
5027 IFS="$ac_save_ifs"
ca9f4b81
AO
5028fi
5029fi
af71363e 5030GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
e8b05380 5031if test -n "$GCC_FOR_TARGET"; then
af71363e 5032 echo "$ac_t""$GCC_FOR_TARGET" 1>&6
ca9f4b81 5033else
af71363e 5034 echo "$ac_t""no" 1>&6
ca9f4b81 5035fi
af71363e 5036
e8b05380
PB
5037 fi
5038 test -n "$ac_cv_prog_GCC_FOR_TARGET" && break
5039 done
5040fi
af71363e 5041
e8b05380
PB
5042if test -z "$ac_cv_prog_GCC_FOR_TARGET" ; then
5043 GCC_FOR_TARGET="${CC_FOR_TARGET}"
5044fi
5045
5046 if test -n "$with_build_time_tools"; then
5047 for ncn_progname in gcj; do
af71363e 5048 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5049echo "configure:5050: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5050 if test -x $with_build_time_tools/${ncn_progname}; then
5051 ac_cv_prog_GCJ_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5052 echo "$ac_t""yes" 1>&6
e8b05380
PB
5053 break
5054 else
af71363e 5055 echo "$ac_t""no" 1>&6
e8b05380
PB
5056 fi
5057 done
5058fi
5059
5060if test -z "$ac_cv_prog_GCJ_FOR_TARGET"; then
5061 for ncn_progname in gcj; do
5062 if test -n "$ncn_target_tool_prefix"; then
5063 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5064set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5065echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5066echo "configure:5067: checking for $ac_word" >&5
af71363e
AS
5067if eval "test \"`echo '$''{'ac_cv_prog_GCJ_FOR_TARGET'+set}'`\" = set"; then
5068 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5069else
fb0103e5
RG
5070 if test -n "$GCJ_FOR_TARGET"; then
5071 ac_cv_prog_GCJ_FOR_TARGET="$GCJ_FOR_TARGET" # Let the user override the test.
5072else
af71363e
AS
5073 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5074 ac_dummy="$PATH"
5075 for ac_dir in $ac_dummy; do
5076 test -z "$ac_dir" && ac_dir=.
5077 if test -f $ac_dir/$ac_word; then
5078 ac_cv_prog_GCJ_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5079 break
5080 fi
5081 done
5082 IFS="$ac_save_ifs"
e8b05380
PB
5083fi
5084fi
af71363e 5085GCJ_FOR_TARGET="$ac_cv_prog_GCJ_FOR_TARGET"
e8b05380 5086if test -n "$GCJ_FOR_TARGET"; then
af71363e 5087 echo "$ac_t""$GCJ_FOR_TARGET" 1>&6
e8b05380 5088else
af71363e 5089 echo "$ac_t""no" 1>&6
e8b05380
PB
5090fi
5091
5092 fi
5093 if test -z "$ac_cv_prog_GCJ_FOR_TARGET" && test $build = $target ; then
5094 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5095set dummy ${ncn_progname}; ac_word=$2
af71363e 5096echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5097echo "configure:5098: checking for $ac_word" >&5
af71363e
AS
5098if eval "test \"`echo '$''{'ac_cv_prog_GCJ_FOR_TARGET'+set}'`\" = set"; then
5099 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5100else
5101 if test -n "$GCJ_FOR_TARGET"; then
5102 ac_cv_prog_GCJ_FOR_TARGET="$GCJ_FOR_TARGET" # Let the user override the test.
5103else
af71363e
AS
5104 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5105 ac_dummy="$PATH"
5106 for ac_dir in $ac_dummy; do
5107 test -z "$ac_dir" && ac_dir=.
5108 if test -f $ac_dir/$ac_word; then
5109 ac_cv_prog_GCJ_FOR_TARGET="${ncn_progname}"
5110 break
5111 fi
5112 done
5113 IFS="$ac_save_ifs"
e8b05380
PB
5114fi
5115fi
af71363e 5116GCJ_FOR_TARGET="$ac_cv_prog_GCJ_FOR_TARGET"
e8b05380 5117if test -n "$GCJ_FOR_TARGET"; then
af71363e 5118 echo "$ac_t""$GCJ_FOR_TARGET" 1>&6
e8b05380 5119else
af71363e 5120 echo "$ac_t""no" 1>&6
e8b05380 5121fi
af71363e 5122
e8b05380
PB
5123 fi
5124 test -n "$ac_cv_prog_GCJ_FOR_TARGET" && break
5125 done
5126fi
af71363e 5127
e8b05380
PB
5128if test -z "$ac_cv_prog_GCJ_FOR_TARGET" ; then
5129 set dummy gcj
5130 if test $build = $target ; then
5131 GCJ_FOR_TARGET="$2"
5132 else
5133 GCJ_FOR_TARGET="${ncn_target_tool_prefix}$2"
2693c0b0 5134 fi
e8b05380 5135fi
2693c0b0 5136
e8b05380
PB
5137 if test -n "$with_build_time_tools"; then
5138 for ncn_progname in gfortran; do
af71363e 5139 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5140echo "configure:5141: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5141 if test -x $with_build_time_tools/${ncn_progname}; then
5142 ac_cv_prog_GFORTRAN_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5143 echo "$ac_t""yes" 1>&6
e8b05380
PB
5144 break
5145 else
af71363e 5146 echo "$ac_t""no" 1>&6
e8b05380
PB
5147 fi
5148 done
5149fi
5150
5151if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
5152 for ncn_progname in gfortran; do
5153 if test -n "$ncn_target_tool_prefix"; then
5154 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5155set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5156echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5157echo "configure:5158: checking for $ac_word" >&5
af71363e
AS
5158if eval "test \"`echo '$''{'ac_cv_prog_GFORTRAN_FOR_TARGET'+set}'`\" = set"; then
5159 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5160else
5161 if test -n "$GFORTRAN_FOR_TARGET"; then
5162 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
5163else
af71363e
AS
5164 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5165 ac_dummy="$PATH"
5166 for ac_dir in $ac_dummy; do
5167 test -z "$ac_dir" && ac_dir=.
5168 if test -f $ac_dir/$ac_word; then
5169 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5170 break
5171 fi
5172 done
5173 IFS="$ac_save_ifs"
e8b05380
PB
5174fi
5175fi
af71363e 5176GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
e8b05380 5177if test -n "$GFORTRAN_FOR_TARGET"; then
af71363e 5178 echo "$ac_t""$GFORTRAN_FOR_TARGET" 1>&6
e8b05380 5179else
af71363e 5180 echo "$ac_t""no" 1>&6
e8b05380
PB
5181fi
5182
5183 fi
5184 if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test $build = $target ; then
5185 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5186set dummy ${ncn_progname}; ac_word=$2
af71363e 5187echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5188echo "configure:5189: checking for $ac_word" >&5
af71363e
AS
5189if eval "test \"`echo '$''{'ac_cv_prog_GFORTRAN_FOR_TARGET'+set}'`\" = set"; then
5190 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5191else
5192 if test -n "$GFORTRAN_FOR_TARGET"; then
5193 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
5194else
af71363e
AS
5195 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5196 ac_dummy="$PATH"
5197 for ac_dir in $ac_dummy; do
5198 test -z "$ac_dir" && ac_dir=.
5199 if test -f $ac_dir/$ac_word; then
5200 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
5201 break
5202 fi
5203 done
5204 IFS="$ac_save_ifs"
e8b05380
PB
5205fi
5206fi
af71363e 5207GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
e8b05380 5208if test -n "$GFORTRAN_FOR_TARGET"; then
af71363e 5209 echo "$ac_t""$GFORTRAN_FOR_TARGET" 1>&6
e8b05380 5210else
af71363e 5211 echo "$ac_t""no" 1>&6
e8b05380 5212fi
af71363e 5213
e8b05380
PB
5214 fi
5215 test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET" && break
5216 done
5217fi
af71363e 5218
e8b05380
PB
5219if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" ; then
5220 set dummy gfortran
2693c0b0 5221 if test $build = $target ; then
e8b05380 5222 GFORTRAN_FOR_TARGET="$2"
ca9f4b81 5223 else
e8b05380
PB
5224 GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}$2"
5225 fi
5226fi
5227
5228
5229
5230# The user is always right.
5231if test "${PATH_SEPARATOR+set}" != set; then
5232 echo "#! /bin/sh" >conf$$.sh
5233 echo "exit 0" >>conf$$.sh
5234 chmod +x conf$$.sh
5235 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
5236 PATH_SEPARATOR=';'
5237 else
af71363e 5238 PATH_SEPARATOR=:
ca9f4b81 5239 fi
e8b05380
PB
5240 rm -f conf$$.sh
5241fi
5242
5243
5244
5245if test "x$exec_prefix" = xNONE; then
5246 if test "x$prefix" = xNONE; then
5247 gcc_cv_tool_prefix=$ac_default_prefix
5248 else
5249 gcc_cv_tool_prefix=$prefix
5250 fi
5251else
5252 gcc_cv_tool_prefix=$exec_prefix
5253fi
5254
5255# If there is no compiler in the tree, use the PATH only. In any
5256# case, if there is no compiler in the tree nobody should use
5257# AS_FOR_TARGET and LD_FOR_TARGET.
5258if test x$host = x$build && test -f $srcdir/gcc/BASE-VER; then
5259 gcc_version=`cat $srcdir/gcc/BASE-VER`
5260 gcc_cv_tool_dirs="$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
5261 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical$PATH_SEPARATOR"
5262 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
5263 gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical$PATH_SEPARATOR"
5264 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
5265 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin$PATH_SEPARATOR"
5266else
5267 gcc_cv_tool_dirs=
5268fi
5269
5270if test x$build = x$target && test -n "$md_exec_prefix"; then
5271 gcc_cv_tool_dirs="$gcc_cv_tool_dirs$md_exec_prefix$PATH_SEPARATOR"
5272fi
5273
5274
5275
5276cat > conftest.c << \EOF
5277#ifdef __GNUC__
5278 gcc_yay;
5279#endif
5280EOF
5281if ($GCC_FOR_TARGET -E conftest.c | grep gcc_yay) > /dev/null 2>&1; then
5282 have_gcc_for_target=yes
5283else
5284 GCC_FOR_TARGET=${ncn_target_tool_prefix}gcc
5285 have_gcc_for_target=no
5286fi
5287rm conftest.c
5288
5289
5290
5291
5292if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
5293 if test -n "$with_build_time_tools"; then
af71363e 5294 echo $ac_n "checking for ar in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5295echo "configure:5296: checking for ar in $with_build_time_tools" >&5
d1f8db0c
PB
5296 if test -x $with_build_time_tools/ar; then
5297 AR_FOR_TARGET=`cd $with_build_time_tools && pwd`/ar
5298 ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
af71363e 5299 echo "$ac_t""$ac_cv_path_AR_FOR_TARGET" 1>&6
d1f8db0c 5300 else
af71363e 5301 echo "$ac_t""no" 1>&6
d1f8db0c 5302 fi
e8b05380
PB
5303 elif test $build != $host && test $have_gcc_for_target = yes; then
5304 AR_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ar`
5305 test $AR_FOR_TARGET=ar && AR_FOR_TARGET=
5306 ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
5307 fi
5308fi
5309if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
5310 # Extract the first word of "ar", so it can be a program name with args.
5311set dummy ar; ac_word=$2
af71363e 5312echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5313echo "configure:5314: checking for $ac_word" >&5
af71363e
AS
5314if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
5315 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5316else
af71363e
AS
5317 case "$AR_FOR_TARGET" in
5318 /*)
e8b05380
PB
5319 ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
5320 ;;
af71363e
AS
5321 ?:/*)
5322 ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a dos path.
5323 ;;
e8b05380 5324 *)
af71363e
AS
5325 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5326 ac_dummy="$gcc_cv_tool_dirs"
5327 for ac_dir in $ac_dummy; do
5328 test -z "$ac_dir" && ac_dir=.
5329 if test -f $ac_dir/$ac_word; then
5330 ac_cv_path_AR_FOR_TARGET="$ac_dir/$ac_word"
5331 break
5332 fi
5333 done
5334 IFS="$ac_save_ifs"
e8b05380
PB
5335 ;;
5336esac
5337fi
af71363e 5338AR_FOR_TARGET="$ac_cv_path_AR_FOR_TARGET"
e8b05380 5339if test -n "$AR_FOR_TARGET"; then
af71363e 5340 echo "$ac_t""$AR_FOR_TARGET" 1>&6
e8b05380 5341else
af71363e 5342 echo "$ac_t""no" 1>&6
4de997d1
PB
5343fi
5344
e8b05380
PB
5345fi
5346if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
5347 if test -n "$with_build_time_tools"; then
5348 for ncn_progname in ar; do
af71363e 5349 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5350echo "configure:5351: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5351 if test -x $with_build_time_tools/${ncn_progname}; then
5352 ac_cv_prog_AR_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5353 echo "$ac_t""yes" 1>&6
e8b05380
PB
5354 break
5355 else
af71363e 5356 echo "$ac_t""no" 1>&6
e8b05380
PB
5357 fi
5358 done
5359fi
5360
5361if test -z "$ac_cv_prog_AR_FOR_TARGET"; then
5362 for ncn_progname in ar; do
5363 if test -n "$ncn_target_tool_prefix"; then
5364 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 5365set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5366echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5367echo "configure:5368: checking for $ac_word" >&5
af71363e
AS
5368if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
5369 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5370else
e8b05380
PB
5371 if test -n "$AR_FOR_TARGET"; then
5372 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
4de997d1 5373else
af71363e
AS
5374 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5375 ac_dummy="$PATH"
5376 for ac_dir in $ac_dummy; do
5377 test -z "$ac_dir" && ac_dir=.
5378 if test -f $ac_dir/$ac_word; then
5379 ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5380 break
5381 fi
5382 done
5383 IFS="$ac_save_ifs"
4de997d1
PB
5384fi
5385fi
af71363e 5386AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
e8b05380 5387if test -n "$AR_FOR_TARGET"; then
af71363e 5388 echo "$ac_t""$AR_FOR_TARGET" 1>&6
4de997d1 5389else
af71363e 5390 echo "$ac_t""no" 1>&6
4de997d1
PB
5391fi
5392
e8b05380
PB
5393 fi
5394 if test -z "$ac_cv_prog_AR_FOR_TARGET" && test $build = $target ; then
5395 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5396set dummy ${ncn_progname}; ac_word=$2
af71363e 5397echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5398echo "configure:5399: checking for $ac_word" >&5
af71363e
AS
5399if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
5400 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5401else
5402 if test -n "$AR_FOR_TARGET"; then
5403 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
5404else
af71363e
AS
5405 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5406 ac_dummy="$PATH"
5407 for ac_dir in $ac_dummy; do
5408 test -z "$ac_dir" && ac_dir=.
5409 if test -f $ac_dir/$ac_word; then
5410 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
5411 break
5412 fi
5413 done
5414 IFS="$ac_save_ifs"
e8b05380
PB
5415fi
5416fi
af71363e 5417AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
e8b05380 5418if test -n "$AR_FOR_TARGET"; then
af71363e 5419 echo "$ac_t""$AR_FOR_TARGET" 1>&6
e8b05380 5420else
af71363e 5421 echo "$ac_t""no" 1>&6
e8b05380 5422fi
af71363e 5423
e8b05380
PB
5424 fi
5425 test -n "$ac_cv_prog_AR_FOR_TARGET" && break
5426 done
5427fi
af71363e 5428
e8b05380
PB
5429if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
5430 set dummy ar
5431 if test $build = $target ; then
5432 AR_FOR_TARGET="$2"
5433 else
5434 AR_FOR_TARGET="${ncn_target_tool_prefix}$2"
2693c0b0 5435 fi
e8b05380
PB
5436fi
5437
d1f8db0c
PB
5438else
5439 AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
e8b05380
PB
5440fi
5441
5442
5443
5444
5445if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
5446 if test -n "$with_build_time_tools"; then
af71363e 5447 echo $ac_n "checking for as in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5448echo "configure:5449: checking for as in $with_build_time_tools" >&5
d1f8db0c
PB
5449 if test -x $with_build_time_tools/as; then
5450 AS_FOR_TARGET=`cd $with_build_time_tools && pwd`/as
5451 ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
af71363e 5452 echo "$ac_t""$ac_cv_path_AS_FOR_TARGET" 1>&6
d1f8db0c 5453 else
af71363e 5454 echo "$ac_t""no" 1>&6
d1f8db0c 5455 fi
e8b05380
PB
5456 elif test $build != $host && test $have_gcc_for_target = yes; then
5457 AS_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=as`
5458 test $AS_FOR_TARGET=as && AS_FOR_TARGET=
5459 ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
5460 fi
5461fi
5462if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
5463 # Extract the first word of "as", so it can be a program name with args.
5464set dummy as; ac_word=$2
af71363e 5465echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5466echo "configure:5467: checking for $ac_word" >&5
af71363e
AS
5467if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
5468 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5469else
af71363e
AS
5470 case "$AS_FOR_TARGET" in
5471 /*)
e8b05380
PB
5472 ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
5473 ;;
af71363e
AS
5474 ?:/*)
5475 ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a dos path.
5476 ;;
e8b05380 5477 *)
af71363e
AS
5478 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5479 ac_dummy="$gcc_cv_tool_dirs"
5480 for ac_dir in $ac_dummy; do
5481 test -z "$ac_dir" && ac_dir=.
5482 if test -f $ac_dir/$ac_word; then
5483 ac_cv_path_AS_FOR_TARGET="$ac_dir/$ac_word"
5484 break
5485 fi
5486 done
5487 IFS="$ac_save_ifs"
e8b05380
PB
5488 ;;
5489esac
5490fi
af71363e 5491AS_FOR_TARGET="$ac_cv_path_AS_FOR_TARGET"
e8b05380 5492if test -n "$AS_FOR_TARGET"; then
af71363e 5493 echo "$ac_t""$AS_FOR_TARGET" 1>&6
e8b05380 5494else
af71363e 5495 echo "$ac_t""no" 1>&6
e8b05380
PB
5496fi
5497
5498fi
5499if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
5500 if test -n "$with_build_time_tools"; then
5501 for ncn_progname in as; do
af71363e 5502 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5503echo "configure:5504: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5504 if test -x $with_build_time_tools/${ncn_progname}; then
5505 ac_cv_prog_AS_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5506 echo "$ac_t""yes" 1>&6
e8b05380
PB
5507 break
5508 else
af71363e 5509 echo "$ac_t""no" 1>&6
e8b05380
PB
5510 fi
5511 done
5512fi
5513
5514if test -z "$ac_cv_prog_AS_FOR_TARGET"; then
5515 for ncn_progname in as; do
5516 if test -n "$ncn_target_tool_prefix"; then
5517 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5518set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5519echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5520echo "configure:5521: checking for $ac_word" >&5
af71363e
AS
5521if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
5522 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380
PB
5523else
5524 if test -n "$AS_FOR_TARGET"; then
5525 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
5526else
af71363e
AS
5527 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5528 ac_dummy="$PATH"
5529 for ac_dir in $ac_dummy; do
5530 test -z "$ac_dir" && ac_dir=.
5531 if test -f $ac_dir/$ac_word; then
5532 ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5533 break
5534 fi
5535 done
5536 IFS="$ac_save_ifs"
e8b05380
PB
5537fi
5538fi
af71363e 5539AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
e8b05380 5540if test -n "$AS_FOR_TARGET"; then
af71363e 5541 echo "$ac_t""$AS_FOR_TARGET" 1>&6
e8b05380 5542else
af71363e 5543 echo "$ac_t""no" 1>&6
e8b05380
PB
5544fi
5545
5546 fi
5547 if test -z "$ac_cv_prog_AS_FOR_TARGET" && test $build = $target ; then
5548 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 5549set dummy ${ncn_progname}; ac_word=$2
af71363e 5550echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5551echo "configure:5552: checking for $ac_word" >&5
af71363e
AS
5552if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
5553 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5554else
e8b05380
PB
5555 if test -n "$AS_FOR_TARGET"; then
5556 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
4de997d1 5557else
af71363e
AS
5558 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5559 ac_dummy="$PATH"
5560 for ac_dir in $ac_dummy; do
5561 test -z "$ac_dir" && ac_dir=.
5562 if test -f $ac_dir/$ac_word; then
5563 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
5564 break
5565 fi
5566 done
5567 IFS="$ac_save_ifs"
4de997d1
PB
5568fi
5569fi
af71363e 5570AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
e8b05380 5571if test -n "$AS_FOR_TARGET"; then
af71363e 5572 echo "$ac_t""$AS_FOR_TARGET" 1>&6
4de997d1 5573else
af71363e 5574 echo "$ac_t""no" 1>&6
4de997d1 5575fi
af71363e 5576
e8b05380
PB
5577 fi
5578 test -n "$ac_cv_prog_AS_FOR_TARGET" && break
5579 done
5580fi
af71363e 5581
e8b05380
PB
5582if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
5583 set dummy as
5584 if test $build = $target ; then
5585 AS_FOR_TARGET="$2"
5586 else
5587 AS_FOR_TARGET="${ncn_target_tool_prefix}$2"
4de997d1 5588 fi
e8b05380 5589fi
2693c0b0 5590
d1f8db0c
PB
5591else
5592 AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
4de997d1
PB
5593fi
5594
e8b05380
PB
5595
5596
5597
5598if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
5599 if test -n "$with_build_time_tools"; then
af71363e 5600 echo $ac_n "checking for dlltool in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5601echo "configure:5602: checking for dlltool in $with_build_time_tools" >&5
d1f8db0c
PB
5602 if test -x $with_build_time_tools/dlltool; then
5603 DLLTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dlltool
5604 ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
af71363e 5605 echo "$ac_t""$ac_cv_path_DLLTOOL_FOR_TARGET" 1>&6
d1f8db0c 5606 else
af71363e 5607 echo "$ac_t""no" 1>&6
d1f8db0c 5608 fi
e8b05380
PB
5609 elif test $build != $host && test $have_gcc_for_target = yes; then
5610 DLLTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dlltool`
5611 test $DLLTOOL_FOR_TARGET=dlltool && DLLTOOL_FOR_TARGET=
5612 ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
5613 fi
5614fi
5615if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
5616 # Extract the first word of "dlltool", so it can be a program name with args.
5617set dummy dlltool; ac_word=$2
af71363e 5618echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5619echo "configure:5620: checking for $ac_word" >&5
af71363e
AS
5620if eval "test \"`echo '$''{'ac_cv_path_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
5621 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5622else
af71363e
AS
5623 case "$DLLTOOL_FOR_TARGET" in
5624 /*)
e8b05380
PB
5625 ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a path.
5626 ;;
af71363e
AS
5627 ?:/*)
5628 ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a dos path.
5629 ;;
e8b05380 5630 *)
af71363e
AS
5631 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5632 ac_dummy="$gcc_cv_tool_dirs"
5633 for ac_dir in $ac_dummy; do
5634 test -z "$ac_dir" && ac_dir=.
5635 if test -f $ac_dir/$ac_word; then
5636 ac_cv_path_DLLTOOL_FOR_TARGET="$ac_dir/$ac_word"
5637 break
5638 fi
5639 done
5640 IFS="$ac_save_ifs"
e8b05380
PB
5641 ;;
5642esac
4de997d1 5643fi
af71363e 5644DLLTOOL_FOR_TARGET="$ac_cv_path_DLLTOOL_FOR_TARGET"
e8b05380 5645if test -n "$DLLTOOL_FOR_TARGET"; then
af71363e 5646 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
4de997d1 5647else
af71363e 5648 echo "$ac_t""no" 1>&6
4de997d1
PB
5649fi
5650
e8b05380
PB
5651fi
5652if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
5653 if test -n "$with_build_time_tools"; then
5654 for ncn_progname in dlltool; do
af71363e 5655 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5656echo "configure:5657: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5657 if test -x $with_build_time_tools/${ncn_progname}; then
5658 ac_cv_prog_DLLTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5659 echo "$ac_t""yes" 1>&6
e8b05380
PB
5660 break
5661 else
af71363e 5662 echo "$ac_t""no" 1>&6
e8b05380
PB
5663 fi
5664 done
5665fi
5666
5667if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
5668 for ncn_progname in dlltool; do
5669 if test -n "$ncn_target_tool_prefix"; then
5670 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5671set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5672echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5673echo "configure:5674: checking for $ac_word" >&5
af71363e
AS
5674if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
5675 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5676else
e8b05380
PB
5677 if test -n "$DLLTOOL_FOR_TARGET"; then
5678 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 5679else
af71363e
AS
5680 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5681 ac_dummy="$PATH"
5682 for ac_dir in $ac_dummy; do
5683 test -z "$ac_dir" && ac_dir=.
5684 if test -f $ac_dir/$ac_word; then
5685 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5686 break
5687 fi
5688 done
5689 IFS="$ac_save_ifs"
4de997d1
PB
5690fi
5691fi
af71363e 5692DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
e8b05380 5693if test -n "$DLLTOOL_FOR_TARGET"; then
af71363e 5694 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
4de997d1 5695else
af71363e 5696 echo "$ac_t""no" 1>&6
4de997d1 5697fi
4de997d1 5698
e8b05380
PB
5699 fi
5700 if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test $build = $target ; then
5701 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5702set dummy ${ncn_progname}; ac_word=$2
af71363e 5703echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5704echo "configure:5705: checking for $ac_word" >&5
af71363e
AS
5705if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
5706 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5707else
e8b05380
PB
5708 if test -n "$DLLTOOL_FOR_TARGET"; then
5709 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
4de997d1 5710else
af71363e
AS
5711 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5712 ac_dummy="$PATH"
5713 for ac_dir in $ac_dummy; do
5714 test -z "$ac_dir" && ac_dir=.
5715 if test -f $ac_dir/$ac_word; then
5716 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
5717 break
5718 fi
5719 done
5720 IFS="$ac_save_ifs"
4de997d1
PB
5721fi
5722fi
af71363e 5723DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
e8b05380 5724if test -n "$DLLTOOL_FOR_TARGET"; then
af71363e 5725 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
4de997d1 5726else
af71363e 5727 echo "$ac_t""no" 1>&6
4de997d1 5728fi
af71363e 5729
e8b05380
PB
5730 fi
5731 test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET" && break
5732 done
5733fi
af71363e 5734
e8b05380
PB
5735if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
5736 set dummy dlltool
5737 if test $build = $target ; then
5738 DLLTOOL_FOR_TARGET="$2"
5739 else
5740 DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
5741 fi
5742fi
5743
d1f8db0c
PB
5744else
5745 DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
e8b05380
PB
5746fi
5747
4de997d1 5748
e8b05380
PB
5749
5750
5751if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
5752 if test -n "$with_build_time_tools"; then
af71363e 5753 echo $ac_n "checking for ld in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5754echo "configure:5755: checking for ld in $with_build_time_tools" >&5
d1f8db0c
PB
5755 if test -x $with_build_time_tools/ld; then
5756 LD_FOR_TARGET=`cd $with_build_time_tools && pwd`/ld
5757 ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
af71363e 5758 echo "$ac_t""$ac_cv_path_LD_FOR_TARGET" 1>&6
d1f8db0c 5759 else
af71363e 5760 echo "$ac_t""no" 1>&6
d1f8db0c 5761 fi
e8b05380
PB
5762 elif test $build != $host && test $have_gcc_for_target = yes; then
5763 LD_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ld`
5764 test $LD_FOR_TARGET=ld && LD_FOR_TARGET=
5765 ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
2693c0b0 5766 fi
e8b05380
PB
5767fi
5768if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
5769 # Extract the first word of "ld", so it can be a program name with args.
5770set dummy ld; ac_word=$2
af71363e 5771echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5772echo "configure:5773: checking for $ac_word" >&5
af71363e
AS
5773if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
5774 echo $ac_n "(cached) $ac_c" 1>&6
4de997d1 5775else
af71363e
AS
5776 case "$LD_FOR_TARGET" in
5777 /*)
e8b05380
PB
5778 ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
5779 ;;
af71363e
AS
5780 ?:/*)
5781 ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a dos path.
5782 ;;
e8b05380 5783 *)
af71363e
AS
5784 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5785 ac_dummy="$gcc_cv_tool_dirs"
5786 for ac_dir in $ac_dummy; do
5787 test -z "$ac_dir" && ac_dir=.
5788 if test -f $ac_dir/$ac_word; then
5789 ac_cv_path_LD_FOR_TARGET="$ac_dir/$ac_word"
5790 break
5791 fi
5792 done
5793 IFS="$ac_save_ifs"
e8b05380
PB
5794 ;;
5795esac
4de997d1 5796fi
af71363e 5797LD_FOR_TARGET="$ac_cv_path_LD_FOR_TARGET"
e8b05380 5798if test -n "$LD_FOR_TARGET"; then
af71363e 5799 echo "$ac_t""$LD_FOR_TARGET" 1>&6
4de997d1 5800else
af71363e 5801 echo "$ac_t""no" 1>&6
4de997d1 5802fi
2693c0b0 5803
e8b05380
PB
5804fi
5805if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
5806 if test -n "$with_build_time_tools"; then
5807 for ncn_progname in ld; do
af71363e 5808 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5809echo "configure:5810: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5810 if test -x $with_build_time_tools/${ncn_progname}; then
5811 ac_cv_prog_LD_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5812 echo "$ac_t""yes" 1>&6
e8b05380
PB
5813 break
5814 else
af71363e 5815 echo "$ac_t""no" 1>&6
e8b05380
PB
5816 fi
5817 done
ca9f4b81
AO
5818fi
5819
e8b05380
PB
5820if test -z "$ac_cv_prog_LD_FOR_TARGET"; then
5821 for ncn_progname in ld; do
5822 if test -n "$ncn_target_tool_prefix"; then
5823 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 5824set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5825echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5826echo "configure:5827: checking for $ac_word" >&5
af71363e
AS
5827if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
5828 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5829else
4de997d1
PB
5830 if test -n "$LD_FOR_TARGET"; then
5831 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 5832else
af71363e
AS
5833 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5834 ac_dummy="$PATH"
5835 for ac_dir in $ac_dummy; do
5836 test -z "$ac_dir" && ac_dir=.
5837 if test -f $ac_dir/$ac_word; then
5838 ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5839 break
5840 fi
5841 done
5842 IFS="$ac_save_ifs"
ca9f4b81
AO
5843fi
5844fi
af71363e 5845LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
4de997d1 5846if test -n "$LD_FOR_TARGET"; then
af71363e 5847 echo "$ac_t""$LD_FOR_TARGET" 1>&6
ca9f4b81 5848else
af71363e 5849 echo "$ac_t""no" 1>&6
ca9f4b81
AO
5850fi
5851
e8b05380
PB
5852 fi
5853 if test -z "$ac_cv_prog_LD_FOR_TARGET" && test $build = $target ; then
5854 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 5855set dummy ${ncn_progname}; ac_word=$2
af71363e 5856echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5857echo "configure:5858: checking for $ac_word" >&5
af71363e
AS
5858if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
5859 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 5860else
2693c0b0
PB
5861 if test -n "$LD_FOR_TARGET"; then
5862 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
ca9f4b81 5863else
af71363e
AS
5864 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5865 ac_dummy="$PATH"
5866 for ac_dir in $ac_dummy; do
5867 test -z "$ac_dir" && ac_dir=.
5868 if test -f $ac_dir/$ac_word; then
5869 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
5870 break
5871 fi
5872 done
5873 IFS="$ac_save_ifs"
ca9f4b81
AO
5874fi
5875fi
af71363e 5876LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
2693c0b0 5877if test -n "$LD_FOR_TARGET"; then
af71363e 5878 echo "$ac_t""$LD_FOR_TARGET" 1>&6
ca9f4b81 5879else
af71363e 5880 echo "$ac_t""no" 1>&6
ca9f4b81 5881fi
af71363e 5882
e8b05380
PB
5883 fi
5884 test -n "$ac_cv_prog_LD_FOR_TARGET" && break
5885 done
5886fi
af71363e 5887
2693c0b0
PB
5888if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
5889 set dummy ld
5890 if test $build = $target ; then
5891 LD_FOR_TARGET="$2"
ca9f4b81 5892 else
2693c0b0 5893 LD_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 5894 fi
ca9f4b81
AO
5895fi
5896
d1f8db0c
PB
5897else
5898 LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
e8b05380
PB
5899fi
5900
5901
5902
5903
5904if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
5905 if test -n "$with_build_time_tools"; then
af71363e 5906 echo $ac_n "checking for lipo in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5907echo "configure:5908: checking for lipo in $with_build_time_tools" >&5
d1f8db0c
PB
5908 if test -x $with_build_time_tools/lipo; then
5909 LIPO_FOR_TARGET=`cd $with_build_time_tools && pwd`/lipo
5910 ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
af71363e 5911 echo "$ac_t""$ac_cv_path_LIPO_FOR_TARGET" 1>&6
d1f8db0c 5912 else
af71363e 5913 echo "$ac_t""no" 1>&6
d1f8db0c 5914 fi
e8b05380
PB
5915 elif test $build != $host && test $have_gcc_for_target = yes; then
5916 LIPO_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=lipo`
5917 test $LIPO_FOR_TARGET=lipo && LIPO_FOR_TARGET=
5918 ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
5919 fi
5920fi
5921if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
5922 # Extract the first word of "lipo", so it can be a program name with args.
5923set dummy lipo; ac_word=$2
af71363e 5924echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5925echo "configure:5926: checking for $ac_word" >&5
af71363e
AS
5926if eval "test \"`echo '$''{'ac_cv_path_LIPO_FOR_TARGET'+set}'`\" = set"; then
5927 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 5928else
af71363e
AS
5929 case "$LIPO_FOR_TARGET" in
5930 /*)
e8b05380
PB
5931 ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a path.
5932 ;;
af71363e
AS
5933 ?:/*)
5934 ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a dos path.
5935 ;;
e8b05380 5936 *)
af71363e
AS
5937 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5938 ac_dummy="$gcc_cv_tool_dirs"
5939 for ac_dir in $ac_dummy; do
5940 test -z "$ac_dir" && ac_dir=.
5941 if test -f $ac_dir/$ac_word; then
5942 ac_cv_path_LIPO_FOR_TARGET="$ac_dir/$ac_word"
5943 break
5944 fi
5945 done
5946 IFS="$ac_save_ifs"
e8b05380
PB
5947 ;;
5948esac
5949fi
af71363e 5950LIPO_FOR_TARGET="$ac_cv_path_LIPO_FOR_TARGET"
e8b05380 5951if test -n "$LIPO_FOR_TARGET"; then
af71363e 5952 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
e8b05380 5953else
af71363e 5954 echo "$ac_t""no" 1>&6
e8b05380
PB
5955fi
5956
5957fi
5958if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
5959 if test -n "$with_build_time_tools"; then
5960 for ncn_progname in lipo; do
af71363e 5961 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 5962echo "configure:5963: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
5963 if test -x $with_build_time_tools/${ncn_progname}; then
5964 ac_cv_prog_LIPO_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 5965 echo "$ac_t""yes" 1>&6
e8b05380
PB
5966 break
5967 else
af71363e 5968 echo "$ac_t""no" 1>&6
e8b05380
PB
5969 fi
5970 done
5971fi
5972
5973if test -z "$ac_cv_prog_LIPO_FOR_TARGET"; then
5974 for ncn_progname in lipo; do
5975 if test -n "$ncn_target_tool_prefix"; then
5976 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 5977set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 5978echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 5979echo "configure:5980: checking for $ac_word" >&5
af71363e
AS
5980if eval "test \"`echo '$''{'ac_cv_prog_LIPO_FOR_TARGET'+set}'`\" = set"; then
5981 echo $ac_n "(cached) $ac_c" 1>&6
040b1c5a
GK
5982else
5983 if test -n "$LIPO_FOR_TARGET"; then
5984 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
5985else
af71363e
AS
5986 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5987 ac_dummy="$PATH"
5988 for ac_dir in $ac_dummy; do
5989 test -z "$ac_dir" && ac_dir=.
5990 if test -f $ac_dir/$ac_word; then
5991 ac_cv_prog_LIPO_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5992 break
5993 fi
5994 done
5995 IFS="$ac_save_ifs"
040b1c5a
GK
5996fi
5997fi
af71363e 5998LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
040b1c5a 5999if test -n "$LIPO_FOR_TARGET"; then
af71363e 6000 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
040b1c5a 6001else
af71363e 6002 echo "$ac_t""no" 1>&6
040b1c5a
GK
6003fi
6004
e8b05380
PB
6005 fi
6006 if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test $build = $target ; then
6007 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 6008set dummy ${ncn_progname}; ac_word=$2
af71363e 6009echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6010echo "configure:6011: checking for $ac_word" >&5
af71363e
AS
6011if eval "test \"`echo '$''{'ac_cv_prog_LIPO_FOR_TARGET'+set}'`\" = set"; then
6012 echo $ac_n "(cached) $ac_c" 1>&6
040b1c5a
GK
6013else
6014 if test -n "$LIPO_FOR_TARGET"; then
72a7ab82
AP
6015 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
6016else
af71363e
AS
6017 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6018 ac_dummy="$PATH"
6019 for ac_dir in $ac_dummy; do
6020 test -z "$ac_dir" && ac_dir=.
6021 if test -f $ac_dir/$ac_word; then
6022 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
6023 break
6024 fi
6025 done
6026 IFS="$ac_save_ifs"
040b1c5a
GK
6027fi
6028fi
af71363e 6029LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
040b1c5a 6030if test -n "$LIPO_FOR_TARGET"; then
af71363e 6031 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
040b1c5a 6032else
af71363e 6033 echo "$ac_t""no" 1>&6
040b1c5a 6034fi
af71363e 6035
e8b05380
PB
6036 fi
6037 test -n "$ac_cv_prog_LIPO_FOR_TARGET" && break
6038 done
6039fi
af71363e 6040
040b1c5a
GK
6041if test -z "$ac_cv_prog_LIPO_FOR_TARGET" ; then
6042 set dummy lipo
6043 if test $build = $target ; then
6044 LIPO_FOR_TARGET="$2"
6045 else
6046 LIPO_FOR_TARGET="${ncn_target_tool_prefix}$2"
6047 fi
6048fi
6049
d1f8db0c
PB
6050else
6051 LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
e8b05380
PB
6052fi
6053
6054
6055
6056
6057if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
6058 if test -n "$with_build_time_tools"; then
af71363e 6059 echo $ac_n "checking for nm in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6060echo "configure:6061: checking for nm in $with_build_time_tools" >&5
d1f8db0c
PB
6061 if test -x $with_build_time_tools/nm; then
6062 NM_FOR_TARGET=`cd $with_build_time_tools && pwd`/nm
6063 ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
af71363e 6064 echo "$ac_t""$ac_cv_path_NM_FOR_TARGET" 1>&6
d1f8db0c 6065 else
af71363e 6066 echo "$ac_t""no" 1>&6
d1f8db0c 6067 fi
e8b05380
PB
6068 elif test $build != $host && test $have_gcc_for_target = yes; then
6069 NM_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=nm`
6070 test $NM_FOR_TARGET=nm && NM_FOR_TARGET=
6071 ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
6072 fi
6073fi
6074if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
6075 # Extract the first word of "nm", so it can be a program name with args.
6076set dummy nm; ac_word=$2
af71363e 6077echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6078echo "configure:6079: checking for $ac_word" >&5
af71363e
AS
6079if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
6080 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6081else
af71363e
AS
6082 case "$NM_FOR_TARGET" in
6083 /*)
e8b05380
PB
6084 ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
6085 ;;
af71363e
AS
6086 ?:/*)
6087 ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a dos path.
6088 ;;
e8b05380 6089 *)
af71363e
AS
6090 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6091 ac_dummy="$gcc_cv_tool_dirs"
6092 for ac_dir in $ac_dummy; do
6093 test -z "$ac_dir" && ac_dir=.
6094 if test -f $ac_dir/$ac_word; then
6095 ac_cv_path_NM_FOR_TARGET="$ac_dir/$ac_word"
6096 break
6097 fi
6098 done
6099 IFS="$ac_save_ifs"
e8b05380
PB
6100 ;;
6101esac
6102fi
af71363e 6103NM_FOR_TARGET="$ac_cv_path_NM_FOR_TARGET"
e8b05380 6104if test -n "$NM_FOR_TARGET"; then
af71363e 6105 echo "$ac_t""$NM_FOR_TARGET" 1>&6
e8b05380 6106else
af71363e 6107 echo "$ac_t""no" 1>&6
e8b05380
PB
6108fi
6109
6110fi
6111if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
6112 if test -n "$with_build_time_tools"; then
6113 for ncn_progname in nm; do
af71363e 6114 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6115echo "configure:6116: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6116 if test -x $with_build_time_tools/${ncn_progname}; then
6117 ac_cv_prog_NM_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6118 echo "$ac_t""yes" 1>&6
e8b05380
PB
6119 break
6120 else
af71363e 6121 echo "$ac_t""no" 1>&6
e8b05380
PB
6122 fi
6123 done
6124fi
6125
6126if test -z "$ac_cv_prog_NM_FOR_TARGET"; then
6127 for ncn_progname in nm; do
6128 if test -n "$ncn_target_tool_prefix"; then
6129 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 6130set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6131echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6132echo "configure:6133: checking for $ac_word" >&5
af71363e
AS
6133if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
6134 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6135else
4de997d1
PB
6136 if test -n "$NM_FOR_TARGET"; then
6137 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 6138else
af71363e
AS
6139 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6140 ac_dummy="$PATH"
6141 for ac_dir in $ac_dummy; do
6142 test -z "$ac_dir" && ac_dir=.
6143 if test -f $ac_dir/$ac_word; then
6144 ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6145 break
6146 fi
6147 done
6148 IFS="$ac_save_ifs"
ca9f4b81
AO
6149fi
6150fi
af71363e 6151NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
4de997d1 6152if test -n "$NM_FOR_TARGET"; then
af71363e 6153 echo "$ac_t""$NM_FOR_TARGET" 1>&6
ca9f4b81 6154else
af71363e 6155 echo "$ac_t""no" 1>&6
ca9f4b81
AO
6156fi
6157
e8b05380
PB
6158 fi
6159 if test -z "$ac_cv_prog_NM_FOR_TARGET" && test $build = $target ; then
6160 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 6161set dummy ${ncn_progname}; ac_word=$2
af71363e 6162echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6163echo "configure:6164: checking for $ac_word" >&5
af71363e
AS
6164if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
6165 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6166else
2693c0b0
PB
6167 if test -n "$NM_FOR_TARGET"; then
6168 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
ca9f4b81 6169else
af71363e
AS
6170 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6171 ac_dummy="$PATH"
6172 for ac_dir in $ac_dummy; do
6173 test -z "$ac_dir" && ac_dir=.
6174 if test -f $ac_dir/$ac_word; then
6175 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
6176 break
6177 fi
6178 done
6179 IFS="$ac_save_ifs"
ca9f4b81
AO
6180fi
6181fi
af71363e 6182NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
2693c0b0 6183if test -n "$NM_FOR_TARGET"; then
af71363e 6184 echo "$ac_t""$NM_FOR_TARGET" 1>&6
ca9f4b81 6185else
af71363e 6186 echo "$ac_t""no" 1>&6
ca9f4b81 6187fi
af71363e 6188
e8b05380
PB
6189 fi
6190 test -n "$ac_cv_prog_NM_FOR_TARGET" && break
6191 done
6192fi
af71363e 6193
2693c0b0
PB
6194if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
6195 set dummy nm
6196 if test $build = $target ; then
6197 NM_FOR_TARGET="$2"
ca9f4b81 6198 else
2693c0b0 6199 NM_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 6200 fi
ca9f4b81
AO
6201fi
6202
d1f8db0c
PB
6203else
6204 NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
e8b05380
PB
6205fi
6206
6207
6208
6209
6210if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
6211 if test -n "$with_build_time_tools"; then
af71363e 6212 echo $ac_n "checking for objdump in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6213echo "configure:6214: checking for objdump in $with_build_time_tools" >&5
d1f8db0c
PB
6214 if test -x $with_build_time_tools/objdump; then
6215 OBJDUMP_FOR_TARGET=`cd $with_build_time_tools && pwd`/objdump
6216 ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
af71363e 6217 echo "$ac_t""$ac_cv_path_OBJDUMP_FOR_TARGET" 1>&6
d1f8db0c 6218 else
af71363e 6219 echo "$ac_t""no" 1>&6
d1f8db0c 6220 fi
e8b05380
PB
6221 elif test $build != $host && test $have_gcc_for_target = yes; then
6222 OBJDUMP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objdump`
6223 test $OBJDUMP_FOR_TARGET=objdump && OBJDUMP_FOR_TARGET=
6224 ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
6225 fi
6226fi
6227if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
6228 # Extract the first word of "objdump", so it can be a program name with args.
6229set dummy objdump; ac_word=$2
af71363e 6230echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6231echo "configure:6232: checking for $ac_word" >&5
af71363e
AS
6232if eval "test \"`echo '$''{'ac_cv_path_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
6233 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6234else
af71363e
AS
6235 case "$OBJDUMP_FOR_TARGET" in
6236 /*)
e8b05380
PB
6237 ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a path.
6238 ;;
af71363e
AS
6239 ?:/*)
6240 ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a dos path.
6241 ;;
e8b05380 6242 *)
af71363e
AS
6243 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6244 ac_dummy="$gcc_cv_tool_dirs"
6245 for ac_dir in $ac_dummy; do
6246 test -z "$ac_dir" && ac_dir=.
6247 if test -f $ac_dir/$ac_word; then
6248 ac_cv_path_OBJDUMP_FOR_TARGET="$ac_dir/$ac_word"
6249 break
6250 fi
6251 done
6252 IFS="$ac_save_ifs"
e8b05380
PB
6253 ;;
6254esac
6255fi
af71363e 6256OBJDUMP_FOR_TARGET="$ac_cv_path_OBJDUMP_FOR_TARGET"
e8b05380 6257if test -n "$OBJDUMP_FOR_TARGET"; then
af71363e 6258 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
e8b05380 6259else
af71363e 6260 echo "$ac_t""no" 1>&6
e8b05380
PB
6261fi
6262
6263fi
6264if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
6265 if test -n "$with_build_time_tools"; then
6266 for ncn_progname in objdump; do
af71363e 6267 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6268echo "configure:6269: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6269 if test -x $with_build_time_tools/${ncn_progname}; then
6270 ac_cv_prog_OBJDUMP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6271 echo "$ac_t""yes" 1>&6
e8b05380
PB
6272 break
6273 else
af71363e 6274 echo "$ac_t""no" 1>&6
e8b05380
PB
6275 fi
6276 done
6277fi
6278
6279if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
6280 for ncn_progname in objdump; do
6281 if test -n "$ncn_target_tool_prefix"; then
6282 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 6283set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6284echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6285echo "configure:6286: checking for $ac_word" >&5
af71363e
AS
6286if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
6287 echo $ac_n "(cached) $ac_c" 1>&6
d739199a
DJ
6288else
6289 if test -n "$OBJDUMP_FOR_TARGET"; then
6290 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
6291else
af71363e
AS
6292 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6293 ac_dummy="$PATH"
6294 for ac_dir in $ac_dummy; do
6295 test -z "$ac_dir" && ac_dir=.
6296 if test -f $ac_dir/$ac_word; then
6297 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6298 break
6299 fi
6300 done
6301 IFS="$ac_save_ifs"
d739199a
DJ
6302fi
6303fi
af71363e 6304OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
d739199a 6305if test -n "$OBJDUMP_FOR_TARGET"; then
af71363e 6306 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
d739199a 6307else
af71363e 6308 echo "$ac_t""no" 1>&6
d739199a
DJ
6309fi
6310
e8b05380
PB
6311 fi
6312 if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test $build = $target ; then
6313 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
d739199a 6314set dummy ${ncn_progname}; ac_word=$2
af71363e 6315echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6316echo "configure:6317: checking for $ac_word" >&5
af71363e
AS
6317if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
6318 echo $ac_n "(cached) $ac_c" 1>&6
d739199a
DJ
6319else
6320 if test -n "$OBJDUMP_FOR_TARGET"; then
6321 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
6322else
af71363e
AS
6323 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6324 ac_dummy="$PATH"
6325 for ac_dir in $ac_dummy; do
6326 test -z "$ac_dir" && ac_dir=.
6327 if test -f $ac_dir/$ac_word; then
6328 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
6329 break
6330 fi
6331 done
6332 IFS="$ac_save_ifs"
d739199a
DJ
6333fi
6334fi
af71363e 6335OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
d739199a 6336if test -n "$OBJDUMP_FOR_TARGET"; then
af71363e 6337 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
d739199a 6338else
af71363e 6339 echo "$ac_t""no" 1>&6
d739199a 6340fi
af71363e 6341
e8b05380
PB
6342 fi
6343 test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET" && break
6344 done
6345fi
af71363e 6346
d739199a
DJ
6347if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" ; then
6348 set dummy objdump
6349 if test $build = $target ; then
6350 OBJDUMP_FOR_TARGET="$2"
6351 else
6352 OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}$2"
6353 fi
6354fi
6355
d1f8db0c
PB
6356else
6357 OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
e8b05380
PB
6358fi
6359
6360
6361
6362
6363if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
6364 if test -n "$with_build_time_tools"; then
af71363e 6365 echo $ac_n "checking for ranlib in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6366echo "configure:6367: checking for ranlib in $with_build_time_tools" >&5
d1f8db0c
PB
6367 if test -x $with_build_time_tools/ranlib; then
6368 RANLIB_FOR_TARGET=`cd $with_build_time_tools && pwd`/ranlib
6369 ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
af71363e 6370 echo "$ac_t""$ac_cv_path_RANLIB_FOR_TARGET" 1>&6
d1f8db0c 6371 else
af71363e 6372 echo "$ac_t""no" 1>&6
d1f8db0c 6373 fi
e8b05380
PB
6374 elif test $build != $host && test $have_gcc_for_target = yes; then
6375 RANLIB_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ranlib`
6376 test $RANLIB_FOR_TARGET=ranlib && RANLIB_FOR_TARGET=
6377 ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
6378 fi
6379fi
6380if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
6381 # Extract the first word of "ranlib", so it can be a program name with args.
6382set dummy ranlib; ac_word=$2
af71363e 6383echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6384echo "configure:6385: checking for $ac_word" >&5
af71363e
AS
6385if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
6386 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6387else
af71363e
AS
6388 case "$RANLIB_FOR_TARGET" in
6389 /*)
e8b05380
PB
6390 ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
6391 ;;
af71363e
AS
6392 ?:/*)
6393 ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a dos path.
6394 ;;
e8b05380 6395 *)
af71363e
AS
6396 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6397 ac_dummy="$gcc_cv_tool_dirs"
6398 for ac_dir in $ac_dummy; do
6399 test -z "$ac_dir" && ac_dir=.
6400 if test -f $ac_dir/$ac_word; then
6401 ac_cv_path_RANLIB_FOR_TARGET="$ac_dir/$ac_word"
6402 break
6403 fi
6404 done
6405 IFS="$ac_save_ifs"
e8b05380
PB
6406 ;;
6407esac
6408fi
af71363e 6409RANLIB_FOR_TARGET="$ac_cv_path_RANLIB_FOR_TARGET"
e8b05380 6410if test -n "$RANLIB_FOR_TARGET"; then
af71363e 6411 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
e8b05380 6412else
af71363e 6413 echo "$ac_t""no" 1>&6
e8b05380
PB
6414fi
6415
6416fi
6417if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
6418 if test -n "$with_build_time_tools"; then
6419 for ncn_progname in ranlib; do
af71363e 6420 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6421echo "configure:6422: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6422 if test -x $with_build_time_tools/${ncn_progname}; then
6423 ac_cv_prog_RANLIB_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6424 echo "$ac_t""yes" 1>&6
e8b05380
PB
6425 break
6426 else
af71363e 6427 echo "$ac_t""no" 1>&6
e8b05380
PB
6428 fi
6429 done
6430fi
6431
6432if test -z "$ac_cv_prog_RANLIB_FOR_TARGET"; then
6433 for ncn_progname in ranlib; do
6434 if test -n "$ncn_target_tool_prefix"; then
6435 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
d739199a 6436set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6437echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6438echo "configure:6439: checking for $ac_word" >&5
af71363e
AS
6439if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
6440 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6441else
4de997d1
PB
6442 if test -n "$RANLIB_FOR_TARGET"; then
6443 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 6444else
af71363e
AS
6445 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6446 ac_dummy="$PATH"
6447 for ac_dir in $ac_dummy; do
6448 test -z "$ac_dir" && ac_dir=.
6449 if test -f $ac_dir/$ac_word; then
6450 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6451 break
6452 fi
6453 done
6454 IFS="$ac_save_ifs"
ca9f4b81
AO
6455fi
6456fi
af71363e 6457RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
4de997d1 6458if test -n "$RANLIB_FOR_TARGET"; then
af71363e 6459 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
ca9f4b81 6460else
af71363e 6461 echo "$ac_t""no" 1>&6
ca9f4b81
AO
6462fi
6463
e8b05380
PB
6464 fi
6465 if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test $build = $target ; then
6466 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 6467set dummy ${ncn_progname}; ac_word=$2
af71363e 6468echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6469echo "configure:6470: checking for $ac_word" >&5
af71363e
AS
6470if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
6471 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6472else
2693c0b0
PB
6473 if test -n "$RANLIB_FOR_TARGET"; then
6474 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
ca9f4b81 6475else
af71363e
AS
6476 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6477 ac_dummy="$PATH"
6478 for ac_dir in $ac_dummy; do
6479 test -z "$ac_dir" && ac_dir=.
6480 if test -f $ac_dir/$ac_word; then
6481 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
6482 break
6483 fi
6484 done
6485 IFS="$ac_save_ifs"
ca9f4b81
AO
6486fi
6487fi
af71363e 6488RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
2693c0b0 6489if test -n "$RANLIB_FOR_TARGET"; then
af71363e 6490 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
ca9f4b81 6491else
af71363e 6492 echo "$ac_t""no" 1>&6
ca9f4b81 6493fi
af71363e 6494
e8b05380
PB
6495 fi
6496 test -n "$ac_cv_prog_RANLIB_FOR_TARGET" && break
6497 done
6498fi
af71363e 6499
e8b05380
PB
6500if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
6501 set dummy ranlib
6502 if test $build = $target ; then
6503 RANLIB_FOR_TARGET="$2"
6504 else
6505 RANLIB_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 6506 fi
e8b05380 6507fi
2693c0b0 6508
d1f8db0c
PB
6509else
6510 RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
ca9f4b81
AO
6511fi
6512
e8b05380
PB
6513
6514
6515
6516if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
6517 if test -n "$with_build_time_tools"; then
af71363e 6518 echo $ac_n "checking for strip in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6519echo "configure:6520: checking for strip in $with_build_time_tools" >&5
d1f8db0c
PB
6520 if test -x $with_build_time_tools/strip; then
6521 STRIP_FOR_TARGET=`cd $with_build_time_tools && pwd`/strip
6522 ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
af71363e 6523 echo "$ac_t""$ac_cv_path_STRIP_FOR_TARGET" 1>&6
d1f8db0c 6524 else
af71363e 6525 echo "$ac_t""no" 1>&6
d1f8db0c 6526 fi
e8b05380
PB
6527 elif test $build != $host && test $have_gcc_for_target = yes; then
6528 STRIP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=strip`
6529 test $STRIP_FOR_TARGET=strip && STRIP_FOR_TARGET=
6530 ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
6531 fi
6532fi
6533if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
6534 # Extract the first word of "strip", so it can be a program name with args.
6535set dummy strip; ac_word=$2
af71363e 6536echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6537echo "configure:6538: checking for $ac_word" >&5
af71363e
AS
6538if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
6539 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6540else
af71363e
AS
6541 case "$STRIP_FOR_TARGET" in
6542 /*)
e8b05380
PB
6543 ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a path.
6544 ;;
af71363e
AS
6545 ?:/*)
6546 ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a dos path.
6547 ;;
e8b05380 6548 *)
af71363e
AS
6549 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6550 ac_dummy="$gcc_cv_tool_dirs"
6551 for ac_dir in $ac_dummy; do
6552 test -z "$ac_dir" && ac_dir=.
6553 if test -f $ac_dir/$ac_word; then
6554 ac_cv_path_STRIP_FOR_TARGET="$ac_dir/$ac_word"
6555 break
6556 fi
6557 done
6558 IFS="$ac_save_ifs"
e8b05380
PB
6559 ;;
6560esac
6561fi
af71363e 6562STRIP_FOR_TARGET="$ac_cv_path_STRIP_FOR_TARGET"
e8b05380 6563if test -n "$STRIP_FOR_TARGET"; then
af71363e 6564 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
e8b05380 6565else
af71363e 6566 echo "$ac_t""no" 1>&6
e8b05380
PB
6567fi
6568
6569fi
6570if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
6571 if test -n "$with_build_time_tools"; then
6572 for ncn_progname in strip; do
af71363e 6573 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6574echo "configure:6575: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6575 if test -x $with_build_time_tools/${ncn_progname}; then
6576 ac_cv_prog_STRIP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6577 echo "$ac_t""yes" 1>&6
e8b05380
PB
6578 break
6579 else
af71363e 6580 echo "$ac_t""no" 1>&6
e8b05380
PB
6581 fi
6582 done
6583fi
6584
6585if test -z "$ac_cv_prog_STRIP_FOR_TARGET"; then
6586 for ncn_progname in strip; do
6587 if test -n "$ncn_target_tool_prefix"; then
6588 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
040b1c5a 6589set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6590echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6591echo "configure:6592: checking for $ac_word" >&5
af71363e
AS
6592if eval "test \"`echo '$''{'ac_cv_prog_STRIP_FOR_TARGET'+set}'`\" = set"; then
6593 echo $ac_n "(cached) $ac_c" 1>&6
6594else
6595 if test -n "$STRIP_FOR_TARGET"; then
6596 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
6597else
6598 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6599 ac_dummy="$PATH"
6600 for ac_dir in $ac_dummy; do
6601 test -z "$ac_dir" && ac_dir=.
6602 if test -f $ac_dir/$ac_word; then
6603 ac_cv_prog_STRIP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6604 break
6605 fi
6606 done
6607 IFS="$ac_save_ifs"
040b1c5a
GK
6608fi
6609fi
af71363e 6610STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
040b1c5a 6611if test -n "$STRIP_FOR_TARGET"; then
af71363e 6612 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
040b1c5a 6613else
af71363e 6614 echo "$ac_t""no" 1>&6
040b1c5a
GK
6615fi
6616
e8b05380
PB
6617 fi
6618 if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test $build = $target ; then
6619 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
040b1c5a 6620set dummy ${ncn_progname}; ac_word=$2
af71363e 6621echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6622echo "configure:6623: checking for $ac_word" >&5
af71363e
AS
6623if eval "test \"`echo '$''{'ac_cv_prog_STRIP_FOR_TARGET'+set}'`\" = set"; then
6624 echo $ac_n "(cached) $ac_c" 1>&6
040b1c5a
GK
6625else
6626 if test -n "$STRIP_FOR_TARGET"; then
6627 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
6628else
af71363e
AS
6629 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6630 ac_dummy="$PATH"
6631 for ac_dir in $ac_dummy; do
6632 test -z "$ac_dir" && ac_dir=.
6633 if test -f $ac_dir/$ac_word; then
6634 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
6635 break
6636 fi
6637 done
6638 IFS="$ac_save_ifs"
040b1c5a
GK
6639fi
6640fi
af71363e 6641STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
040b1c5a 6642if test -n "$STRIP_FOR_TARGET"; then
af71363e 6643 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
040b1c5a 6644else
af71363e 6645 echo "$ac_t""no" 1>&6
040b1c5a 6646fi
af71363e 6647
e8b05380
PB
6648 fi
6649 test -n "$ac_cv_prog_STRIP_FOR_TARGET" && break
6650 done
6651fi
af71363e 6652
040b1c5a
GK
6653if test -z "$ac_cv_prog_STRIP_FOR_TARGET" ; then
6654 set dummy strip
6655 if test $build = $target ; then
6656 STRIP_FOR_TARGET="$2"
6657 else
6658 STRIP_FOR_TARGET="${ncn_target_tool_prefix}$2"
6659 fi
6660fi
6661
d1f8db0c
PB
6662else
6663 STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
e8b05380
PB
6664fi
6665
6666
6667
6668
6669if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
6670 if test -n "$with_build_time_tools"; then
af71363e 6671 echo $ac_n "checking for windres in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6672echo "configure:6673: checking for windres in $with_build_time_tools" >&5
d1f8db0c
PB
6673 if test -x $with_build_time_tools/windres; then
6674 WINDRES_FOR_TARGET=`cd $with_build_time_tools && pwd`/windres
6675 ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
af71363e 6676 echo "$ac_t""$ac_cv_path_WINDRES_FOR_TARGET" 1>&6
d1f8db0c 6677 else
af71363e 6678 echo "$ac_t""no" 1>&6
d1f8db0c 6679 fi
e8b05380
PB
6680 elif test $build != $host && test $have_gcc_for_target = yes; then
6681 WINDRES_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windres`
6682 test $WINDRES_FOR_TARGET=windres && WINDRES_FOR_TARGET=
6683 ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
6684 fi
6685fi
6686if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
6687 # Extract the first word of "windres", so it can be a program name with args.
6688set dummy windres; ac_word=$2
af71363e 6689echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6690echo "configure:6691: checking for $ac_word" >&5
af71363e
AS
6691if eval "test \"`echo '$''{'ac_cv_path_WINDRES_FOR_TARGET'+set}'`\" = set"; then
6692 echo $ac_n "(cached) $ac_c" 1>&6
e8b05380 6693else
af71363e
AS
6694 case "$WINDRES_FOR_TARGET" in
6695 /*)
e8b05380
PB
6696 ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a path.
6697 ;;
af71363e
AS
6698 ?:/*)
6699 ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a dos path.
6700 ;;
e8b05380 6701 *)
af71363e
AS
6702 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6703 ac_dummy="$gcc_cv_tool_dirs"
6704 for ac_dir in $ac_dummy; do
6705 test -z "$ac_dir" && ac_dir=.
6706 if test -f $ac_dir/$ac_word; then
6707 ac_cv_path_WINDRES_FOR_TARGET="$ac_dir/$ac_word"
6708 break
6709 fi
6710 done
6711 IFS="$ac_save_ifs"
e8b05380
PB
6712 ;;
6713esac
6714fi
af71363e 6715WINDRES_FOR_TARGET="$ac_cv_path_WINDRES_FOR_TARGET"
e8b05380 6716if test -n "$WINDRES_FOR_TARGET"; then
af71363e 6717 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
e8b05380 6718else
af71363e 6719 echo "$ac_t""no" 1>&6
e8b05380
PB
6720fi
6721
6722fi
6723if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
6724 if test -n "$with_build_time_tools"; then
6725 for ncn_progname in windres; do
af71363e 6726 echo $ac_n "checking for ${ncn_progname} in $with_build_time_tools""... $ac_c" 1>&6
e69bf64b 6727echo "configure:6728: checking for ${ncn_progname} in $with_build_time_tools" >&5
d1f8db0c
PB
6728 if test -x $with_build_time_tools/${ncn_progname}; then
6729 ac_cv_prog_WINDRES_FOR_TARGET=$with_build_time_tools/${ncn_progname}
af71363e 6730 echo "$ac_t""yes" 1>&6
e8b05380
PB
6731 break
6732 else
af71363e 6733 echo "$ac_t""no" 1>&6
e8b05380
PB
6734 fi
6735 done
6736fi
6737
6738if test -z "$ac_cv_prog_WINDRES_FOR_TARGET"; then
6739 for ncn_progname in windres; do
6740 if test -n "$ncn_target_tool_prefix"; then
6741 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
2693c0b0 6742set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
af71363e 6743echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6744echo "configure:6745: checking for $ac_word" >&5
af71363e
AS
6745if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
6746 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6747else
4de997d1
PB
6748 if test -n "$WINDRES_FOR_TARGET"; then
6749 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 6750else
af71363e
AS
6751 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6752 ac_dummy="$PATH"
6753 for ac_dir in $ac_dummy; do
6754 test -z "$ac_dir" && ac_dir=.
6755 if test -f $ac_dir/$ac_word; then
6756 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
6757 break
6758 fi
6759 done
6760 IFS="$ac_save_ifs"
ca9f4b81
AO
6761fi
6762fi
af71363e 6763WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
4de997d1 6764if test -n "$WINDRES_FOR_TARGET"; then
af71363e 6765 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
ca9f4b81 6766else
af71363e 6767 echo "$ac_t""no" 1>&6
ca9f4b81
AO
6768fi
6769
e8b05380
PB
6770 fi
6771 if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test $build = $target ; then
6772 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
2693c0b0 6773set dummy ${ncn_progname}; ac_word=$2
af71363e 6774echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
e69bf64b 6775echo "configure:6776: checking for $ac_word" >&5
af71363e
AS
6776if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
6777 echo $ac_n "(cached) $ac_c" 1>&6
ca9f4b81 6778else
2693c0b0
PB
6779 if test -n "$WINDRES_FOR_TARGET"; then
6780 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
ca9f4b81 6781else
af71363e
AS
6782 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
6783 ac_dummy="$PATH"
6784 for ac_dir in $ac_dummy; do
6785 test -z "$ac_dir" && ac_dir=.
6786 if test -f $ac_dir/$ac_word; then
6787 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
6788 break
6789 fi
6790 done
6791 IFS="$ac_save_ifs"
ca9f4b81
AO
6792fi
6793fi
af71363e 6794WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
2693c0b0 6795if test -n "$WINDRES_FOR_TARGET"; then
af71363e 6796 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
ca9f4b81 6797else
af71363e 6798 echo "$ac_t""no" 1>&6
ca9f4b81 6799fi
af71363e 6800
e8b05380
PB
6801 fi
6802 test -n "$ac_cv_prog_WINDRES_FOR_TARGET" && break
6803 done
6804fi
af71363e 6805
2693c0b0
PB
6806if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
6807 set dummy windres
6808 if test $build = $target ; then
6809 WINDRES_FOR_TARGET="$2"
ca9f4b81 6810 else
2693c0b0 6811 WINDRES_FOR_TARGET="${ncn_target_tool_prefix}$2"
ca9f4b81 6812 fi
ca9f4b81
AO
6813fi
6814
d1f8db0c
PB
6815else
6816 WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
e8b05380
PB
6817fi
6818
4977bab6 6819
2abefe3d
PB
6820RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET"
6821
af71363e 6822echo $ac_n "checking where to find the target ar""... $ac_c" 1>&6
e69bf64b 6823echo "configure:6824: checking where to find the target ar" >&5
2abefe3d 6824if test "x${build}" != "x${host}" ; then
e8b05380
PB
6825 if expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
6826 # We already found the complete path
af71363e 6827 echo "$ac_t""pre-installed in `dirname $AR_FOR_TARGET`" 1>&6
e8b05380
PB
6828 else
6829 # Canadian cross, just use what we found
af71363e 6830 echo "$ac_t""pre-installed" 1>&6
e8b05380 6831 fi
2abefe3d
PB
6832else
6833 ok=yes
6834 case " ${configdirs} " in
6835 *" binutils "*) ;;
6836 *) ok=no ;;
6837 esac
af71363e 6838
2abefe3d
PB
6839 if test $ok = yes; then
6840 # An in-tree tool is available and we can use it
6841 AR_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ar'
af71363e 6842 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6843 elif expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
6844 # We already found the complete path
af71363e 6845 echo "$ac_t""pre-installed in `dirname $AR_FOR_TARGET`" 1>&6
2abefe3d
PB
6846 elif test "x$target" = "x$host"; then
6847 # We can use an host tool
6848 AR_FOR_TARGET='$(AR)'
af71363e 6849 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6850 else
6851 # We need a cross tool
af71363e 6852 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6853 fi
6854fi
0b0dc272 6855
af71363e 6856echo $ac_n "checking where to find the target as""... $ac_c" 1>&6
e69bf64b 6857echo "configure:6858: checking where to find the target as" >&5
2abefe3d 6858if test "x${build}" != "x${host}" ; then
e8b05380
PB
6859 if expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
6860 # We already found the complete path
af71363e 6861 echo "$ac_t""pre-installed in `dirname $AS_FOR_TARGET`" 1>&6
e8b05380
PB
6862 else
6863 # Canadian cross, just use what we found
af71363e 6864 echo "$ac_t""pre-installed" 1>&6
e8b05380 6865 fi
2abefe3d
PB
6866else
6867 ok=yes
6868 case " ${configdirs} " in
6869 *" gas "*) ;;
6870 *) ok=no ;;
6871 esac
af71363e 6872
2abefe3d
PB
6873 if test $ok = yes; then
6874 # An in-tree tool is available and we can use it
6875 AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gas/as-new'
af71363e 6876 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6877 elif expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
6878 # We already found the complete path
af71363e 6879 echo "$ac_t""pre-installed in `dirname $AS_FOR_TARGET`" 1>&6
2abefe3d
PB
6880 elif test "x$target" = "x$host"; then
6881 # We can use an host tool
6882 AS_FOR_TARGET='$(AS)'
af71363e 6883 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6884 else
6885 # We need a cross tool
af71363e 6886 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6887 fi
6888fi
0b0dc272 6889
af71363e 6890echo $ac_n "checking where to find the target cc""... $ac_c" 1>&6
e69bf64b 6891echo "configure:6892: checking where to find the target cc" >&5
2abefe3d 6892if test "x${build}" != "x${host}" ; then
e8b05380
PB
6893 if expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
6894 # We already found the complete path
af71363e 6895 echo "$ac_t""pre-installed in `dirname $CC_FOR_TARGET`" 1>&6
e8b05380
PB
6896 else
6897 # Canadian cross, just use what we found
af71363e 6898 echo "$ac_t""pre-installed" 1>&6
e8b05380 6899 fi
2abefe3d
PB
6900else
6901 ok=yes
6902 case " ${configdirs} " in
6903 *" gcc "*) ;;
6904 *) ok=no ;;
6905 esac
af71363e 6906
2abefe3d
PB
6907 if test $ok = yes; then
6908 # An in-tree tool is available and we can use it
6909 CC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 6910 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6911 elif expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
6912 # We already found the complete path
af71363e 6913 echo "$ac_t""pre-installed in `dirname $CC_FOR_TARGET`" 1>&6
2abefe3d
PB
6914 elif test "x$target" = "x$host"; then
6915 # We can use an host tool
6916 CC_FOR_TARGET='$(CC)'
af71363e 6917 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6918 else
6919 # We need a cross tool
af71363e 6920 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6921 fi
6922fi
0b0dc272 6923
af71363e 6924echo $ac_n "checking where to find the target c++""... $ac_c" 1>&6
e69bf64b 6925echo "configure:6926: checking where to find the target c++" >&5
2abefe3d 6926if test "x${build}" != "x${host}" ; then
e8b05380
PB
6927 if expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
6928 # We already found the complete path
af71363e 6929 echo "$ac_t""pre-installed in `dirname $CXX_FOR_TARGET`" 1>&6
e8b05380
PB
6930 else
6931 # Canadian cross, just use what we found
af71363e 6932 echo "$ac_t""pre-installed" 1>&6
e8b05380 6933 fi
2abefe3d
PB
6934else
6935 ok=yes
6936 case " ${configdirs} " in
6937 *" gcc "*) ;;
6938 *) ok=no ;;
6939 esac
6940 case ,${enable_languages}, in
6941 *,c++,*) ;;
6942 *) ok=no ;;
6943 esac
6944 if test $ok = yes; then
6945 # An in-tree tool is available and we can use it
6946 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 6947 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6948 elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
6949 # We already found the complete path
af71363e 6950 echo "$ac_t""pre-installed in `dirname $CXX_FOR_TARGET`" 1>&6
2abefe3d
PB
6951 elif test "x$target" = "x$host"; then
6952 # We can use an host tool
6953 CXX_FOR_TARGET='$(CXX)'
af71363e 6954 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6955 else
6956 # We need a cross tool
af71363e 6957 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6958 fi
6959fi
0b0dc272 6960
af71363e 6961echo $ac_n "checking where to find the target c++ for libstdc++""... $ac_c" 1>&6
e69bf64b 6962echo "configure:6963: checking where to find the target c++ for libstdc++" >&5
2abefe3d 6963if test "x${build}" != "x${host}" ; then
e8b05380
PB
6964 if expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
6965 # We already found the complete path
af71363e 6966 echo "$ac_t""pre-installed in `dirname $RAW_CXX_FOR_TARGET`" 1>&6
e8b05380
PB
6967 else
6968 # Canadian cross, just use what we found
af71363e 6969 echo "$ac_t""pre-installed" 1>&6
e8b05380 6970 fi
2abefe3d
PB
6971else
6972 ok=yes
6973 case " ${configdirs} " in
6974 *" gcc "*) ;;
6975 *) ok=no ;;
6976 esac
6977 case ,${enable_languages}, in
6978 *,c++,*) ;;
6979 *) ok=no ;;
6980 esac
6981 if test $ok = yes; then
6982 # An in-tree tool is available and we can use it
6983 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 6984 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
6985 elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
6986 # We already found the complete path
af71363e 6987 echo "$ac_t""pre-installed in `dirname $RAW_CXX_FOR_TARGET`" 1>&6
2abefe3d
PB
6988 elif test "x$target" = "x$host"; then
6989 # We can use an host tool
6990 RAW_CXX_FOR_TARGET='$(CXX)'
af71363e 6991 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
6992 else
6993 # We need a cross tool
af71363e 6994 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
6995 fi
6996fi
0b0dc272 6997
af71363e 6998echo $ac_n "checking where to find the target dlltool""... $ac_c" 1>&6
e69bf64b 6999echo "configure:7000: checking where to find the target dlltool" >&5
2abefe3d 7000if test "x${build}" != "x${host}" ; then
e8b05380
PB
7001 if expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
7002 # We already found the complete path
af71363e 7003 echo "$ac_t""pre-installed in `dirname $DLLTOOL_FOR_TARGET`" 1>&6
e8b05380
PB
7004 else
7005 # Canadian cross, just use what we found
af71363e 7006 echo "$ac_t""pre-installed" 1>&6
e8b05380 7007 fi
2abefe3d
PB
7008else
7009 ok=yes
7010 case " ${configdirs} " in
7011 *" binutils "*) ;;
7012 *) ok=no ;;
7013 esac
af71363e 7014
2abefe3d
PB
7015 if test $ok = yes; then
7016 # An in-tree tool is available and we can use it
7017 DLLTOOL_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/dlltool'
af71363e 7018 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7019 elif expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
7020 # We already found the complete path
af71363e 7021 echo "$ac_t""pre-installed in `dirname $DLLTOOL_FOR_TARGET`" 1>&6
2abefe3d
PB
7022 elif test "x$target" = "x$host"; then
7023 # We can use an host tool
7024 DLLTOOL_FOR_TARGET='$(DLLTOOL)'
af71363e 7025 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7026 else
7027 # We need a cross tool
af71363e 7028 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7029 fi
7030fi
0b0dc272 7031
af71363e 7032echo $ac_n "checking where to find the target gcc""... $ac_c" 1>&6
e69bf64b 7033echo "configure:7034: checking where to find the target gcc" >&5
2abefe3d 7034if test "x${build}" != "x${host}" ; then
e8b05380
PB
7035 if expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
7036 # We already found the complete path
af71363e 7037 echo "$ac_t""pre-installed in `dirname $GCC_FOR_TARGET`" 1>&6
e8b05380
PB
7038 else
7039 # Canadian cross, just use what we found
af71363e 7040 echo "$ac_t""pre-installed" 1>&6
e8b05380 7041 fi
2abefe3d
PB
7042else
7043 ok=yes
7044 case " ${configdirs} " in
7045 *" gcc "*) ;;
7046 *) ok=no ;;
7047 esac
af71363e 7048
2abefe3d
PB
7049 if test $ok = yes; then
7050 # An in-tree tool is available and we can use it
7051 GCC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 7052 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7053 elif expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
7054 # We already found the complete path
af71363e 7055 echo "$ac_t""pre-installed in `dirname $GCC_FOR_TARGET`" 1>&6
2abefe3d
PB
7056 elif test "x$target" = "x$host"; then
7057 # We can use an host tool
7058 GCC_FOR_TARGET='$()'
af71363e 7059 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7060 else
7061 # We need a cross tool
af71363e 7062 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7063 fi
7064fi
0b0dc272 7065
af71363e 7066echo $ac_n "checking where to find the target gcj""... $ac_c" 1>&6
e69bf64b 7067echo "configure:7068: checking where to find the target gcj" >&5
2abefe3d 7068if test "x${build}" != "x${host}" ; then
e8b05380
PB
7069 if expr "x$GCJ_FOR_TARGET" : "x/" > /dev/null; then
7070 # We already found the complete path
af71363e 7071 echo "$ac_t""pre-installed in `dirname $GCJ_FOR_TARGET`" 1>&6
e8b05380
PB
7072 else
7073 # Canadian cross, just use what we found
af71363e 7074 echo "$ac_t""pre-installed" 1>&6
e8b05380 7075 fi
2abefe3d
PB
7076else
7077 ok=yes
7078 case " ${configdirs} " in
7079 *" gcc "*) ;;
7080 *) ok=no ;;
7081 esac
7082 case ,${enable_languages}, in
7083 *,java,*) ;;
7084 *) ok=no ;;
7085 esac
7086 if test $ok = yes; then
7087 # An in-tree tool is available and we can use it
7088 GCJ_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gcj -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 7089 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7090 elif expr "x$GCJ_FOR_TARGET" : "x/" > /dev/null; then
7091 # We already found the complete path
af71363e 7092 echo "$ac_t""pre-installed in `dirname $GCJ_FOR_TARGET`" 1>&6
2abefe3d
PB
7093 elif test "x$target" = "x$host"; then
7094 # We can use an host tool
7095 GCJ_FOR_TARGET='$(GCJ)'
af71363e 7096 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7097 else
7098 # We need a cross tool
af71363e 7099 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7100 fi
7101fi
0b0dc272 7102
af71363e 7103echo $ac_n "checking where to find the target gfortran""... $ac_c" 1>&6
e69bf64b 7104echo "configure:7105: checking where to find the target gfortran" >&5
2abefe3d 7105if test "x${build}" != "x${host}" ; then
e8b05380
PB
7106 if expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
7107 # We already found the complete path
af71363e 7108 echo "$ac_t""pre-installed in `dirname $GFORTRAN_FOR_TARGET`" 1>&6
e8b05380
PB
7109 else
7110 # Canadian cross, just use what we found
af71363e 7111 echo "$ac_t""pre-installed" 1>&6
e8b05380 7112 fi
2abefe3d
PB
7113else
7114 ok=yes
7115 case " ${configdirs} " in
7116 *" gcc "*) ;;
7117 *) ok=no ;;
7118 esac
7119 case ,${enable_languages}, in
7120 *,fortran,*) ;;
7121 *) ok=no ;;
7122 esac
7123 if test $ok = yes; then
7124 # An in-tree tool is available and we can use it
7125 GFORTRAN_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/'
af71363e 7126 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7127 elif expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
7128 # We already found the complete path
af71363e 7129 echo "$ac_t""pre-installed in `dirname $GFORTRAN_FOR_TARGET`" 1>&6
2abefe3d
PB
7130 elif test "x$target" = "x$host"; then
7131 # We can use an host tool
7132 GFORTRAN_FOR_TARGET='$(GFORTRAN)'
af71363e 7133 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7134 else
7135 # We need a cross tool
af71363e 7136 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7137 fi
7138fi
0b0dc272 7139
af71363e 7140echo $ac_n "checking where to find the target ld""... $ac_c" 1>&6
e69bf64b 7141echo "configure:7142: checking where to find the target ld" >&5
2abefe3d 7142if test "x${build}" != "x${host}" ; then
e8b05380
PB
7143 if expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
7144 # We already found the complete path
af71363e 7145 echo "$ac_t""pre-installed in `dirname $LD_FOR_TARGET`" 1>&6
e8b05380
PB
7146 else
7147 # Canadian cross, just use what we found
af71363e 7148 echo "$ac_t""pre-installed" 1>&6
e8b05380 7149 fi
2abefe3d
PB
7150else
7151 ok=yes
7152 case " ${configdirs} " in
7153 *" ld "*) ;;
7154 *) ok=no ;;
7155 esac
af71363e 7156
2abefe3d
PB
7157 if test $ok = yes; then
7158 # An in-tree tool is available and we can use it
7159 LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/ld/ld-new'
af71363e 7160 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7161 elif expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
7162 # We already found the complete path
af71363e 7163 echo "$ac_t""pre-installed in `dirname $LD_FOR_TARGET`" 1>&6
2abefe3d
PB
7164 elif test "x$target" = "x$host"; then
7165 # We can use an host tool
7166 LD_FOR_TARGET='$(LD)'
af71363e 7167 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7168 else
7169 # We need a cross tool
af71363e 7170 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7171 fi
7172fi
0b0dc272 7173
af71363e 7174echo $ac_n "checking where to find the target lipo""... $ac_c" 1>&6
e69bf64b 7175echo "configure:7176: checking where to find the target lipo" >&5
2abefe3d 7176if test "x${build}" != "x${host}" ; then
e8b05380
PB
7177 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
7178 # We already found the complete path
af71363e 7179 echo "$ac_t""pre-installed in `dirname $LIPO_FOR_TARGET`" 1>&6
e8b05380
PB
7180 else
7181 # Canadian cross, just use what we found
af71363e 7182 echo "$ac_t""pre-installed" 1>&6
e8b05380 7183 fi
2abefe3d 7184else
e8b05380
PB
7185 if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
7186 # We already found the complete path
af71363e 7187 echo "$ac_t""pre-installed in `dirname $LIPO_FOR_TARGET`" 1>&6
e8b05380 7188 elif test "x$target" = "x$host"; then
2abefe3d
PB
7189 # We can use an host tool
7190 LIPO_FOR_TARGET='$(LIPO)'
af71363e 7191 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7192 else
7193 # We need a cross tool
af71363e 7194 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7195 fi
7196fi
0b0dc272 7197
af71363e 7198echo $ac_n "checking where to find the target nm""... $ac_c" 1>&6
e69bf64b 7199echo "configure:7200: checking where to find the target nm" >&5
2abefe3d 7200if test "x${build}" != "x${host}" ; then
e8b05380
PB
7201 if expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
7202 # We already found the complete path
af71363e 7203 echo "$ac_t""pre-installed in `dirname $NM_FOR_TARGET`" 1>&6
e8b05380
PB
7204 else
7205 # Canadian cross, just use what we found
af71363e 7206 echo "$ac_t""pre-installed" 1>&6
e8b05380 7207 fi
2abefe3d
PB
7208else
7209 ok=yes
7210 case " ${configdirs} " in
7211 *" binutils "*) ;;
7212 *) ok=no ;;
7213 esac
af71363e 7214
2abefe3d
PB
7215 if test $ok = yes; then
7216 # An in-tree tool is available and we can use it
7217 NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/nm-new'
af71363e 7218 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7219 elif expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
7220 # We already found the complete path
af71363e 7221 echo "$ac_t""pre-installed in `dirname $NM_FOR_TARGET`" 1>&6
2abefe3d
PB
7222 elif test "x$target" = "x$host"; then
7223 # We can use an host tool
7224 NM_FOR_TARGET='$(NM)'
af71363e 7225 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7226 else
7227 # We need a cross tool
af71363e 7228 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7229 fi
7230fi
0b0dc272 7231
af71363e 7232echo $ac_n "checking where to find the target objdump""... $ac_c" 1>&6
e69bf64b 7233echo "configure:7234: checking where to find the target objdump" >&5
2abefe3d 7234if test "x${build}" != "x${host}" ; then
e8b05380
PB
7235 if expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
7236 # We already found the complete path
af71363e 7237 echo "$ac_t""pre-installed in `dirname $OBJDUMP_FOR_TARGET`" 1>&6
e8b05380
PB
7238 else
7239 # Canadian cross, just use what we found
af71363e 7240 echo "$ac_t""pre-installed" 1>&6
e8b05380 7241 fi
2abefe3d
PB
7242else
7243 ok=yes
7244 case " ${configdirs} " in
7245 *" binutils "*) ;;
7246 *) ok=no ;;
7247 esac
af71363e 7248
2abefe3d
PB
7249 if test $ok = yes; then
7250 # An in-tree tool is available and we can use it
7251 OBJDUMP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objdump'
af71363e 7252 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7253 elif expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
7254 # We already found the complete path
af71363e 7255 echo "$ac_t""pre-installed in `dirname $OBJDUMP_FOR_TARGET`" 1>&6
2abefe3d
PB
7256 elif test "x$target" = "x$host"; then
7257 # We can use an host tool
7258 OBJDUMP_FOR_TARGET='$(OBJDUMP)'
af71363e 7259 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7260 else
7261 # We need a cross tool
af71363e 7262 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7263 fi
7264fi
0b0dc272 7265
af71363e 7266echo $ac_n "checking where to find the target ranlib""... $ac_c" 1>&6
e69bf64b 7267echo "configure:7268: checking where to find the target ranlib" >&5
2abefe3d 7268if test "x${build}" != "x${host}" ; then
e8b05380
PB
7269 if expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
7270 # We already found the complete path
af71363e 7271 echo "$ac_t""pre-installed in `dirname $RANLIB_FOR_TARGET`" 1>&6
e8b05380
PB
7272 else
7273 # Canadian cross, just use what we found
af71363e 7274 echo "$ac_t""pre-installed" 1>&6
e8b05380 7275 fi
2abefe3d
PB
7276else
7277 ok=yes
7278 case " ${configdirs} " in
7279 *" binutils "*) ;;
7280 *) ok=no ;;
7281 esac
af71363e 7282
2abefe3d
PB
7283 if test $ok = yes; then
7284 # An in-tree tool is available and we can use it
7285 RANLIB_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ranlib'
af71363e 7286 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7287 elif expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
7288 # We already found the complete path
af71363e 7289 echo "$ac_t""pre-installed in `dirname $RANLIB_FOR_TARGET`" 1>&6
2abefe3d
PB
7290 elif test "x$target" = "x$host"; then
7291 # We can use an host tool
7292 RANLIB_FOR_TARGET='$(RANLIB)'
af71363e 7293 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7294 else
7295 # We need a cross tool
af71363e 7296 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7297 fi
7298fi
0b0dc272 7299
af71363e 7300echo $ac_n "checking where to find the target strip""... $ac_c" 1>&6
e69bf64b 7301echo "configure:7302: checking where to find the target strip" >&5
2abefe3d 7302if test "x${build}" != "x${host}" ; then
e8b05380
PB
7303 if expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
7304 # We already found the complete path
af71363e 7305 echo "$ac_t""pre-installed in `dirname $STRIP_FOR_TARGET`" 1>&6
e8b05380
PB
7306 else
7307 # Canadian cross, just use what we found
af71363e 7308 echo "$ac_t""pre-installed" 1>&6
e8b05380 7309 fi
2abefe3d
PB
7310else
7311 ok=yes
7312 case " ${configdirs} " in
7313 *" binutils "*) ;;
7314 *) ok=no ;;
7315 esac
af71363e 7316
2abefe3d
PB
7317 if test $ok = yes; then
7318 # An in-tree tool is available and we can use it
7319 STRIP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/strip'
af71363e 7320 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7321 elif expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
7322 # We already found the complete path
af71363e 7323 echo "$ac_t""pre-installed in `dirname $STRIP_FOR_TARGET`" 1>&6
2abefe3d
PB
7324 elif test "x$target" = "x$host"; then
7325 # We can use an host tool
7326 STRIP_FOR_TARGET='$(STRIP)'
af71363e 7327 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7328 else
7329 # We need a cross tool
af71363e 7330 echo "$ac_t""pre-installed" 1>&6
2abefe3d
PB
7331 fi
7332fi
0b0dc272 7333
af71363e 7334echo $ac_n "checking where to find the target windres""... $ac_c" 1>&6
e69bf64b 7335echo "configure:7336: checking where to find the target windres" >&5
2abefe3d 7336if test "x${build}" != "x${host}" ; then
e8b05380
PB
7337 if expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
7338 # We already found the complete path
af71363e 7339 echo "$ac_t""pre-installed in `dirname $WINDRES_FOR_TARGET`" 1>&6
e8b05380
PB
7340 else
7341 # Canadian cross, just use what we found
af71363e 7342 echo "$ac_t""pre-installed" 1>&6
e8b05380 7343 fi
2abefe3d
PB
7344else
7345 ok=yes
7346 case " ${configdirs} " in
7347 *" binutils "*) ;;
7348 *) ok=no ;;
7349 esac
af71363e 7350
2abefe3d
PB
7351 if test $ok = yes; then
7352 # An in-tree tool is available and we can use it
7353 WINDRES_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windres'
af71363e 7354 echo "$ac_t""just compiled" 1>&6
e8b05380
PB
7355 elif expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
7356 # We already found the complete path
af71363e 7357 echo "$ac_t""pre-installed in `dirname $WINDRES_FOR_TARGET`" 1>&6
2abefe3d
PB
7358 elif test "x$target" = "x$host"; then
7359 # We can use an host tool
7360 WINDRES_FOR_TARGET='$(WINDRES)'
af71363e 7361 echo "$ac_t""host tool" 1>&6
2abefe3d
PB
7362 else
7363 # We need a cross tool
af71363e 7364 echo "$ac_t""pre-installed" 1>&6
2abefe3d 7365 fi
671aa708 7366fi
be912515
NN
7367
7368
7369
2abefe3d 7370
0b0dc272 7371
671aa708
NN
7372# Certain tools may need extra flags.
7373AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
7374RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
7375NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
7376
2abefe3d
PB
7377# When building target libraries, except in a Canadian cross, we use
7378# the same toolchain as the compiler we just built.
7379COMPILER_AS_FOR_TARGET='$(AS_FOR_TARGET)'
7380COMPILER_LD_FOR_TARGET='$(LD_FOR_TARGET)'
7381COMPILER_NM_FOR_TARGET='$(NM_FOR_TARGET)'
7382if test $host = $build; then
7383 case " $configdirs " in
7384 *" gcc "*)
7385 COMPILER_AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/as'
7386 COMPILER_LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/collect-ld'
7387 COMPILER_NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/nm'${extra_nmflags_for_target}
7388 ;;
7389 esac
7390fi
7391
7392
7393
7394
7395
af71363e 7396echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
e69bf64b 7397echo "configure:7398: checking whether to enable maintainer-specific portions of Makefiles" >&5
ee03dc5e
AO
7398# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
7399if test "${enable_maintainer_mode+set}" = set; then
7400 enableval="$enable_maintainer_mode"
7401 USE_MAINTAINER_MODE=$enableval
7402else
7403 USE_MAINTAINER_MODE=no
af71363e
AS
7404fi
7405
7406echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
ee03dc5e
AO
7407
7408
7409if test "$USE_MAINTAINER_MODE" = yes; then
7410 MAINTAINER_MODE_TRUE=
7411 MAINTAINER_MODE_FALSE='#'
7412else
7413 MAINTAINER_MODE_TRUE='#'
7414 MAINTAINER_MODE_FALSE=
af71363e 7415fi
ee03dc5e
AO
7416MAINT=$MAINTAINER_MODE_TRUE
7417
2805b53a
NN
7418# ---------------------
7419# GCC bootstrap support
7420# ---------------------
7421
7422# Stage specific cflags for build.
7423stage1_cflags="-g"
7424case $build in
7425 vax-*-*)
7426 case ${GCC} in
7427 yes) stage1_cflags="-g -Wa,-J" ;;
7428 *) stage1_cflags="-g -J" ;;
7429 esac ;;
2805b53a
NN
7430esac
7431
0b50988a
EB
7432# This is aimed to mimic bootstrap with a non-GCC compiler to catch problems.
7433if test "$GCC" = yes; then
7434 saved_CFLAGS="$CFLAGS"
7435
7436 # Pass -fkeep-inline-functions for stage 1 if the GCC version supports it.
7437 CFLAGS="$CFLAGS -fkeep-inline-functions"
af71363e 7438 echo $ac_n "checking whether -fkeep-inline-functions is supported""... $ac_c" 1>&6
e69bf64b 7439echo "configure:7440: checking whether -fkeep-inline-functions is supported" >&5
af71363e 7440 cat > conftest.$ac_ext <<EOF
e69bf64b 7441#line 7442 "configure"
af71363e
AS
7442#include "confdefs.h"
7443
7444int main() {
7445
7446; return 0; }
7447EOF
e69bf64b 7448if { (eval echo configure:7449: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
af71363e
AS
7449 rm -rf conftest*
7450 echo "$ac_t""yes" 1>&6; stage1_cflags="$stage1_cflags -fkeep-inline-functions"
7451else
7452 echo "configure: failed program was:" >&5
7453 cat conftest.$ac_ext >&5
7454 rm -rf conftest*
7455 echo "$ac_t""no" 1>&6
7456fi
7457rm -f conftest*
0b50988a
EB
7458
7459 CFLAGS="$saved_CFLAGS"
7460fi
7461
7462
2805b53a 7463
8efea775
PB
7464# Enable --enable-checking in stage1 of the compiler.
7465# Check whether --enable-stage1-checking or --disable-stage1-checking was given.
7466if test "${enable_stage1_checking+set}" = set; then
7467 enableval="$enable_stage1_checking"
7468 stage1_checking=--enable-checking=${enable_stage1_checking}
7469else
7470 if test "x$enable_checking" = xno; then
7471 stage1_checking=--enable-checking
7472else
7473 stage1_checking=--enable-checking${enable_checking+=}$enable_checking
7474fi
af71363e
AS
7475fi
7476
8efea775
PB
7477
7478
2805b53a 7479# Enable -Werror in bootstrap stage2 and later.
2805b53a
NN
7480# Check whether --enable-werror or --disable-werror was given.
7481if test "${enable_werror+set}" = set; then
7482 enableval="$enable_werror"
af71363e 7483 :
2805b53a 7484else
88fceb68 7485 if test -d gcc && test x"`cat $srcdir/gcc/DEV-PHASE`" = xexperimental; then
2805b53a 7486 enable_werror=yes
88fceb68
PB
7487else
7488 enable_werror=no
7489fi
af71363e
AS
7490fi
7491
09a9c095
NN
7492case ${enable_werror} in
7493 yes) stage2_werror_flag="--enable-werror-always" ;;
7494 *) stage2_werror_flag="" ;;
2805b53a
NN
7495esac
7496
7497
32845532
CD
7498# Flags needed to enable html installing and building
7499# Check whether --with-datarootdir or --without-datarootdir was given.
7500if test "${with_datarootdir+set}" = set; then
7501 withval="$with_datarootdir"
7502 datarootdir="\${prefix}/${withval}"
7503else
7504 datarootdir="\${prefix}/share"
af71363e 7505fi
32845532
CD
7506
7507
7508# Check whether --with-docdir or --without-docdir was given.
7509if test "${with_docdir+set}" = set; then
7510 withval="$with_docdir"
7511 docdir="\${prefix}/${withval}"
7512else
7513 docdir="\${datarootdir}/doc"
af71363e 7514fi
32845532
CD
7515
7516
7517# Check whether --with-htmldir or --without-htmldir was given.
7518if test "${with_htmldir+set}" = set; then
7519 withval="$with_htmldir"
7520 htmldir="\${prefix}/${withval}"
7521else
7522 htmldir="\${docdir}"
af71363e
AS
7523fi
7524
32845532
CD
7525
7526
7527
7528
7529
af71363e
AS
7530trap '' 1 2 15
7531cat > confcache <<\EOF
671aa708
NN
7532# This file is a shell script that caches the results of configure
7533# tests run on this system so they can be shared between configure
af71363e
AS
7534# scripts and configure runs. It is not useful on other systems.
7535# If it contains results you don't want to keep, you may remove or edit it.
671aa708 7536#
af71363e
AS
7537# By default, configure uses ./config.cache as the cache file,
7538# creating it if it does not exist already. You can give configure
7539# the --cache-file=FILE option to use a different cache file; that is
7540# what configure does when it calls configure scripts in
7541# subdirectories, so they share the cache.
7542# Giving --cache-file=/dev/null disables caching, for debugging configure.
7543# config.status only pays attention to the cache file if you give it the
7544# --recheck option to rerun configure.
671aa708 7545#
af71363e 7546EOF
671aa708
NN
7547# The following way of writing the cache mishandles newlines in values,
7548# but we know of no workaround that is simple, portable, and efficient.
7549# So, don't put newlines in cache variables' values.
7550# Ultrix sh set writes to stderr and can't be redirected directly,
7551# and sets the high bit in the cache file unless we assign to the vars.
af71363e
AS
7552(set) 2>&1 |
7553 case `(ac_space=' '; set | grep ac_space) 2>&1` in
7554 *ac_space=\ *)
7555 # `set' does not quote correctly, so add quotes (double-quote substitution
7556 # turns \\\\ into \\, and sed turns \\ into \).
7557 sed -n \
7558 -e "s/'/'\\\\''/g" \
7559 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
7560 ;;
7561 *)
7562 # `set' quotes correctly as required by POSIX, so do not add quotes.
7563 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
7564 ;;
7565 esac >> confcache
7566if cmp -s $cache_file confcache; then
7567 :
7568else
671aa708 7569 if test -w $cache_file; then
af71363e
AS
7570 echo "updating cache $cache_file"
7571 cat confcache > $cache_file
671aa708
NN
7572 else
7573 echo "not updating unwritable cache $cache_file"
7574 fi
4977bab6 7575fi
671aa708 7576rm -f confcache
79c06341 7577
af71363e
AS
7578trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
7579
671aa708
NN
7580test "x$prefix" = xNONE && prefix=$ac_default_prefix
7581# Let make expand exec_prefix.
7582test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4e77e8f1 7583
af71363e
AS
7584# Any assignment to VPATH causes Sun make to only execute
7585# the first set of double-colon rules, so remove it if not needed.
7586# If there is a colon in the path, we need to keep it.
671aa708 7587if test "x$srcdir" = x.; then
af71363e 7588 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
671aa708 7589fi
79c06341 7590
af71363e
AS
7591trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
7592
671aa708
NN
7593# Transform confdefs.h into DEFS.
7594# Protect against shell expansion while executing Makefile rules.
7595# Protect against Makefile macro expansion.
a3993f33
KG
7596cat > conftest.defs <<\EOF
7597s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
7598s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
7599s%\[%\\&%g
7600s%\]%\\&%g
7601s%\$%$$%g
7602EOF
7603DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
7604rm -f conftest.defs
fb0103e5 7605
0b0dc272 7606
af71363e 7607# Without the "./", some shells look in PATH for config.status.
0b0dc272 7608: ${CONFIG_STATUS=./config.status}
af71363e
AS
7609
7610echo creating $CONFIG_STATUS
7611rm -f $CONFIG_STATUS
7612cat > $CONFIG_STATUS <<EOF
7613#! /bin/sh
7614# Generated automatically by configure.
671aa708 7615# Run this file to recreate the current configuration.
af71363e
AS
7616# This directory was configured as follows,
7617# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
7618#
7619# $0 $ac_configure_args
7620#
671aa708 7621# Compiler output produced by configure, useful for debugging
af71363e 7622# configure, is in ./config.log if it exists.
0b0dc272 7623
af71363e
AS
7624ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
7625for ac_option
a4b9e93e 7626do
af71363e 7627 case "\$ac_option" in
671aa708 7628 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
af71363e
AS
7629 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
7630 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
7631 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
7632 echo "$CONFIG_STATUS generated by autoconf version 2.13"
7633 exit 0 ;;
7634 -help | --help | --hel | --he | --h)
7635 echo "\$ac_cs_usage"; exit 0 ;;
7636 *) echo "\$ac_cs_usage"; exit 1 ;;
0b0dc272
AM
7637 esac
7638done
7639
af71363e
AS
7640ac_given_srcdir=$srcdir
7641ac_given_INSTALL="$INSTALL"
0b0dc272 7642
af71363e
AS
7643trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
7644EOF
7645cat >> $CONFIG_STATUS <<EOF
0b0dc272 7646
af71363e
AS
7647# Protect against being on the right side of a sed subst in config.status.
7648sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
7649 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
7650$ac_vpsub
7651$extrasub
7652s%@SHELL@%$SHELL%g
7653s%@CFLAGS@%$CFLAGS%g
7654s%@CPPFLAGS@%$CPPFLAGS%g
7655s%@CXXFLAGS@%$CXXFLAGS%g
7656s%@FFLAGS@%$FFLAGS%g
7657s%@DEFS@%$DEFS%g
7658s%@LDFLAGS@%$LDFLAGS%g
7659s%@LIBS@%$LIBS%g
7660s%@exec_prefix@%$exec_prefix%g
7661s%@prefix@%$prefix%g
7662s%@program_transform_name@%$program_transform_name%g
7663s%@bindir@%$bindir%g
7664s%@sbindir@%$sbindir%g
7665s%@libexecdir@%$libexecdir%g
7666s%@datadir@%$datadir%g
7667s%@sysconfdir@%$sysconfdir%g
7668s%@sharedstatedir@%$sharedstatedir%g
7669s%@localstatedir@%$localstatedir%g
7670s%@libdir@%$libdir%g
7671s%@includedir@%$includedir%g
7672s%@oldincludedir@%$oldincludedir%g
7673s%@infodir@%$infodir%g
7674s%@mandir@%$mandir%g
7675s%@host@%$host%g
7676s%@host_alias@%$host_alias%g
7677s%@host_cpu@%$host_cpu%g
7678s%@host_vendor@%$host_vendor%g
7679s%@host_os@%$host_os%g
7680s%@target@%$target%g
7681s%@target_alias@%$target_alias%g
7682s%@target_cpu@%$target_cpu%g
7683s%@target_vendor@%$target_vendor%g
7684s%@target_os@%$target_os%g
7685s%@build@%$build%g
7686s%@build_alias@%$build_alias%g
7687s%@build_cpu@%$build_cpu%g
7688s%@build_vendor@%$build_vendor%g
7689s%@build_os@%$build_os%g
7690s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
7691s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
7692s%@INSTALL_DATA@%$INSTALL_DATA%g
7693s%@LN@%$LN%g
7694s%@LN_S@%$LN_S%g
7695s%@TOPLEVEL_CONFIGURE_ARGUMENTS@%$TOPLEVEL_CONFIGURE_ARGUMENTS%g
7696s%@build_libsubdir@%$build_libsubdir%g
7697s%@build_subdir@%$build_subdir%g
7698s%@host_subdir@%$host_subdir%g
7699s%@target_subdir@%$target_subdir%g
7700s%@CC@%$CC%g
7701s%@GNATBIND@%$GNATBIND%g
7702s%@do_compare@%$do_compare%g
7703s%@gmplibs@%$gmplibs%g
7704s%@gmpinc@%$gmpinc%g
7705s%@stage1_languages@%$stage1_languages%g
7706s%@SYSROOT_CFLAGS_FOR_TARGET@%$SYSROOT_CFLAGS_FOR_TARGET%g
671aa708 7707/@serialization_dependencies@/r $serialization_dependencies
af71363e 7708s%@serialization_dependencies@%%g
671aa708 7709/@host_makefile_frag@/r $host_makefile_frag
af71363e 7710s%@host_makefile_frag@%%g
671aa708 7711/@target_makefile_frag@/r $target_makefile_frag
af71363e 7712s%@target_makefile_frag@%%g
671aa708 7713/@alphaieee_frag@/r $alphaieee_frag
af71363e 7714s%@alphaieee_frag@%%g
671aa708 7715/@ospace_frag@/r $ospace_frag
af71363e
AS
7716s%@ospace_frag@%%g
7717s%@RPATH_ENVVAR@%$RPATH_ENVVAR%g
7718s%@tooldir@%$tooldir%g
7719s%@build_tooldir@%$build_tooldir%g
7720s%@CONFIGURE_GDB_TK@%$CONFIGURE_GDB_TK%g
7721s%@GDB_TK@%$GDB_TK%g
7722s%@INSTALL_GDB_TK@%$INSTALL_GDB_TK%g
7723s%@build_configargs@%$build_configargs%g
7724s%@build_configdirs@%$build_configdirs%g
7725s%@host_configargs@%$host_configargs%g
7726s%@configdirs@%$configdirs%g
7727s%@target_configargs@%$target_configargs%g
7728s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
7729s%@config_shell@%$config_shell%g
7730s%@YACC@%$YACC%g
7731s%@BISON@%$BISON%g
7732s%@M4@%$M4%g
7733s%@LEX@%$LEX%g
7734s%@FLEX@%$FLEX%g
7735s%@MAKEINFO@%$MAKEINFO%g
7736s%@EXPECT@%$EXPECT%g
7737s%@RUNTEST@%$RUNTEST%g
7738s%@AR@%$AR%g
7739s%@AS@%$AS%g
7740s%@DLLTOOL@%$DLLTOOL%g
7741s%@LD@%$LD%g
7742s%@LIPO@%$LIPO%g
7743s%@NM@%$NM%g
7744s%@RANLIB@%$RANLIB%g
7745s%@STRIP@%$STRIP%g
7746s%@WINDRES@%$WINDRES%g
7747s%@OBJCOPY@%$OBJCOPY%g
7748s%@OBJDUMP@%$OBJDUMP%g
7749s%@CXX@%$CXX%g
7750s%@CFLAGS_FOR_BUILD@%$CFLAGS_FOR_BUILD%g
7751s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
7752s%@CXX_FOR_TARGET@%$CXX_FOR_TARGET%g
7753s%@GCC_FOR_TARGET@%$GCC_FOR_TARGET%g
7754s%@GCJ_FOR_TARGET@%$GCJ_FOR_TARGET%g
7755s%@GFORTRAN_FOR_TARGET@%$GFORTRAN_FOR_TARGET%g
7756s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
7757s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
7758s%@DLLTOOL_FOR_TARGET@%$DLLTOOL_FOR_TARGET%g
7759s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
7760s%@LIPO_FOR_TARGET@%$LIPO_FOR_TARGET%g
7761s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
7762s%@OBJDUMP_FOR_TARGET@%$OBJDUMP_FOR_TARGET%g
7763s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
7764s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
7765s%@WINDRES_FOR_TARGET@%$WINDRES_FOR_TARGET%g
7766s%@RAW_CXX_FOR_TARGET@%$RAW_CXX_FOR_TARGET%g
7767s%@FLAGS_FOR_TARGET@%$FLAGS_FOR_TARGET%g
7768s%@COMPILER_AS_FOR_TARGET@%$COMPILER_AS_FOR_TARGET%g
7769s%@COMPILER_LD_FOR_TARGET@%$COMPILER_LD_FOR_TARGET%g
7770s%@COMPILER_NM_FOR_TARGET@%$COMPILER_NM_FOR_TARGET%g
7771s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
7772s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
7773s%@MAINT@%$MAINT%g
7774s%@stage1_cflags@%$stage1_cflags%g
7775s%@stage1_checking@%$stage1_checking%g
7776s%@stage2_werror_flag@%$stage2_werror_flag%g
7777s%@datarootdir@%$datarootdir%g
7778s%@docdir@%$docdir%g
7779s%@htmldir@%$htmldir%g
7780
671aa708 7781CEOF
af71363e 7782EOF
79c06341 7783
af71363e
AS
7784cat >> $CONFIG_STATUS <<\EOF
7785
7786# Split the substitutions into bite-sized pieces for seds with
7787# small command number limits, like on Digital OSF/1 and HP-UX.
7788ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
7789ac_file=1 # Number of current file.
7790ac_beg=1 # First line for current file.
7791ac_end=$ac_max_sed_cmds # Line after last line for current file.
7792ac_more_lines=:
7793ac_sed_cmds=""
7794while $ac_more_lines; do
7795 if test $ac_beg -gt 1; then
7796 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
7797 else
7798 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
7799 fi
7800 if test ! -s conftest.s$ac_file; then
7801 ac_more_lines=false
7802 rm -f conftest.s$ac_file
7803 else
7804 if test -z "$ac_sed_cmds"; then
7805 ac_sed_cmds="sed -f conftest.s$ac_file"
671aa708 7806 else
af71363e 7807 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
671aa708 7808 fi
af71363e
AS
7809 ac_file=`expr $ac_file + 1`
7810 ac_beg=$ac_end
7811 ac_end=`expr $ac_end + $ac_max_sed_cmds`
4977bab6 7812 fi
af71363e
AS
7813done
7814if test -z "$ac_sed_cmds"; then
7815 ac_sed_cmds=cat
7816fi
7817EOF
79c06341 7818
af71363e
AS
7819cat >> $CONFIG_STATUS <<EOF
7820
7821CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
7822EOF
7823cat >> $CONFIG_STATUS <<\EOF
7824for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
671aa708 7825 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
af71363e
AS
7826 case "$ac_file" in
7827 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
7828 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
7829 *) ac_file_in="${ac_file}.in" ;;
671aa708 7830 esac
79c06341 7831
af71363e 7832 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
0b0dc272 7833
af71363e
AS
7834 # Remove last slash and all that follows it. Not all systems have dirname.
7835 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
7836 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7837 # The file is in a subdirectory.
7838 test ! -d "$ac_dir" && mkdir "$ac_dir"
7839 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
7840 # A "../" for each directory in $ac_dir_suffix.
7841 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
7842 else
7843 ac_dir_suffix= ac_dots=
7844 fi
0b0dc272 7845
af71363e
AS
7846 case "$ac_given_srcdir" in
7847 .) srcdir=.
7848 if test -z "$ac_dots"; then top_srcdir=.
7849 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
7850 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
671aa708 7851 *) # Relative path.
af71363e
AS
7852 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
7853 top_srcdir="$ac_dots$ac_given_srcdir" ;;
7854 esac
a4b9e93e 7855
af71363e
AS
7856 case "$ac_given_INSTALL" in
7857 [/$]*) INSTALL="$ac_given_INSTALL" ;;
7858 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
7859 esac
0b0dc272 7860
af71363e
AS
7861 echo creating "$ac_file"
7862 rm -f "$ac_file"
7863 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
7864 case "$ac_file" in
7865 *Makefile*) ac_comsub="1i\\
7866# $configure_input" ;;
7867 *) ac_comsub= ;;
671aa708 7868 esac
79c06341 7869
af71363e
AS
7870 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
7871 sed -e "$ac_comsub
7872s%@configure_input@%$configure_input%g
7873s%@srcdir@%$srcdir%g
7874s%@top_srcdir@%$top_srcdir%g
7875s%@INSTALL@%$INSTALL%g
7876" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
7877fi; done
7878rm -f conftest.s*
79c06341 7879
af71363e
AS
7880EOF
7881cat >> $CONFIG_STATUS <<EOF
79c06341 7882
af71363e
AS
7883EOF
7884cat >> $CONFIG_STATUS <<\EOF
79c06341 7885
af71363e
AS
7886exit 0
7887EOF
671aa708 7888chmod +x $CONFIG_STATUS
af71363e
AS
7889rm -fr confdefs* $ac_clean_files
7890test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
79c06341 7891