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