PR tui/1995
[deliverable/binutils-gdb.git] / configure
CommitLineData
a0da8069 1#! /bin/sh
cac3d6c4 2
a0da8069 3# Guess values for system-dependent variables and create Makefiles.
cac3d6c4
CM
4# Generated automatically using autoconf version 2.13
5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
a0da8069
NN
6#
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9
cac3d6c4
CM
10# Defaults:
11ac_help=
a0da8069 12ac_default_prefix=/usr/local
cac3d6c4
CM
13# Any additions from configure.in:
14ac_help="$ac_help
15 --enable-libada Builds libada directory"
16ac_help="$ac_help
17 --enable-libssp Builds libssp directory"
18ac_help="$ac_help
19 --with-mpfr-dir=PATH Specify source directory for MPFR library"
20ac_help="$ac_help
21 --with-mpfr=PATH Specify directory for installed MPFR library"
22ac_help="$ac_help
23 --with-gmp-dir=PATH Specify source directory for GMP library"
24ac_help="$ac_help
25 --with-gmp=PATH Specify directory for installed GMP library"
26ac_help="$ac_help
27 --with-build-sysroot=sysroot
28 use sysroot as the system root during the build"
29ac_help="$ac_help
30 --enable-bootstrap[=lean] Enable bootstrapping [no]"
31ac_help="$ac_help
32 --enable-serial-[{host,target,build}-]configure
33 Force sequential configuration of
34 sub-packages for the host, target or build
35 machine, or all sub-packages"
36ac_help="$ac_help
37 --enable-maintainer-mode enable make rules and dependencies not useful
38 (and sometimes confusing) to the casual installer"
39ac_help="$ac_help
40 --enable-werror enable -Werror in bootstrap stage2 and later"
a0da8069
NN
41
42# Initialize some variables set by options.
43# The variables have the same names as the options, with
44# dashes changed to underlines.
cac3d6c4
CM
45build=NONE
46cache_file=./config.cache
a0da8069 47exec_prefix=NONE
cac3d6c4 48host=NONE
a0da8069 49no_create=
cac3d6c4 50nonopt=NONE
a0da8069
NN
51no_recursion=
52prefix=NONE
53program_prefix=NONE
54program_suffix=NONE
55program_transform_name=s,x,x,
56silent=
57site=
58srcdir=
cac3d6c4 59target=NONE
a0da8069
NN
60verbose=
61x_includes=NONE
62x_libraries=NONE
63bindir='${exec_prefix}/bin'
64sbindir='${exec_prefix}/sbin'
65libexecdir='${exec_prefix}/libexec'
66datadir='${prefix}/share'
67sysconfdir='${prefix}/etc'
68sharedstatedir='${prefix}/com'
69localstatedir='${prefix}/var'
70libdir='${exec_prefix}/lib'
71includedir='${prefix}/include'
72oldincludedir='/usr/include'
73infodir='${prefix}/info'
74mandir='${prefix}/man'
252b5132 75
cac3d6c4
CM
76# Initialize some other variables.
77subdirs=
78MFLAGS= MAKEFLAGS=
79SHELL=${CONFIG_SHELL-/bin/sh}
80# Maximum number of lines to put in a shell here document.
81ac_max_here_lines=12
82
a0da8069
NN
83ac_prev=
84for ac_option
85do
cac3d6c4 86
a0da8069
NN
87 # If the previous option needs an argument, assign it.
88 if test -n "$ac_prev"; then
89 eval "$ac_prev=\$ac_option"
90 ac_prev=
91 continue
92 fi
252b5132 93
cac3d6c4
CM
94 case "$ac_option" in
95 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
96 *) ac_optarg= ;;
97 esac
a0da8069
NN
98
99 # Accept the important Cygnus configure options, so we can diagnose typos.
100
cac3d6c4 101 case "$ac_option" in
a0da8069
NN
102
103 -bindir | --bindir | --bindi | --bind | --bin | --bi)
104 ac_prev=bindir ;;
105 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
cac3d6c4 106 bindir="$ac_optarg" ;;
a0da8069
NN
107
108 -build | --build | --buil | --bui | --bu)
cac3d6c4 109 ac_prev=build ;;
a0da8069 110 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
cac3d6c4 111 build="$ac_optarg" ;;
a0da8069
NN
112
113 -cache-file | --cache-file | --cache-fil | --cache-fi \
114 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
115 ac_prev=cache_file ;;
116 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
117 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
cac3d6c4 118 cache_file="$ac_optarg" ;;
a0da8069
NN
119
120 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
121 ac_prev=datadir ;;
122 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
123 | --da=*)
cac3d6c4 124 datadir="$ac_optarg" ;;
a0da8069
NN
125
126 -disable-* | --disable-*)
cac3d6c4 127 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
a0da8069 128 # Reject names that are not valid shell variable names.
cac3d6c4
CM
129 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
130 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
131 fi
132 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
133 eval "enable_${ac_feature}=no" ;;
a0da8069
NN
134
135 -enable-* | --enable-*)
cac3d6c4 136 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
a0da8069 137 # Reject names that are not valid shell variable names.
cac3d6c4
CM
138 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
139 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
140 fi
141 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
142 case "$ac_option" in
143 *=*) ;;
a0da8069
NN
144 *) ac_optarg=yes ;;
145 esac
cac3d6c4 146 eval "enable_${ac_feature}='$ac_optarg'" ;;
a0da8069
NN
147
148 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
149 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
150 | --exec | --exe | --ex)
151 ac_prev=exec_prefix ;;
152 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
153 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
154 | --exec=* | --exe=* | --ex=*)
cac3d6c4 155 exec_prefix="$ac_optarg" ;;
a0da8069
NN
156
157 -gas | --gas | --ga | --g)
158 # Obsolete; use --with-gas.
159 with_gas=yes ;;
160
cac3d6c4
CM
161 -help | --help | --hel | --he)
162 # Omit some internal or obsolete options to make the list less imposing.
163 # This message is too long to be a string in the A/UX 3.1 sh.
164 cat << EOF
165Usage: configure [options] [host]
166Options: [defaults in brackets after descriptions]
167Configuration:
168 --cache-file=FILE cache test results in FILE
169 --help print this message
170 --no-create do not create output files
171 --quiet, --silent do not print \`checking...' messages
172 --version print the version of autoconf that created configure
173Directory and file names:
174 --prefix=PREFIX install architecture-independent files in PREFIX
175 [$ac_default_prefix]
176 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
177 [same as prefix]
178 --bindir=DIR user executables in DIR [EPREFIX/bin]
179 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
180 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
181 --datadir=DIR read-only architecture-independent data in DIR
182 [PREFIX/share]
183 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
184 --sharedstatedir=DIR modifiable architecture-independent data in DIR
185 [PREFIX/com]
186 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
187 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
188 --includedir=DIR C header files in DIR [PREFIX/include]
189 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
190 --infodir=DIR info documentation in DIR [PREFIX/info]
191 --mandir=DIR man documentation in DIR [PREFIX/man]
192 --srcdir=DIR find the sources in DIR [configure dir or ..]
193 --program-prefix=PREFIX prepend PREFIX to installed program names
194 --program-suffix=SUFFIX append SUFFIX to installed program names
195 --program-transform-name=PROGRAM
196 run sed PROGRAM on installed program names
197EOF
198 cat << EOF
199Host type:
200 --build=BUILD configure for building on BUILD [BUILD=HOST]
201 --host=HOST configure for HOST [guessed]
202 --target=TARGET configure for TARGET [TARGET=HOST]
203Features and packages:
204 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
205 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
206 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
207 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
208 --x-includes=DIR X include files are in DIR
209 --x-libraries=DIR X library files are in DIR
210EOF
211 if test -n "$ac_help"; then
212 echo "--enable and --with options recognized:$ac_help"
213 fi
214 exit 0 ;;
a0da8069
NN
215
216 -host | --host | --hos | --ho)
cac3d6c4 217 ac_prev=host ;;
a0da8069 218 -host=* | --host=* | --hos=* | --ho=*)
cac3d6c4 219 host="$ac_optarg" ;;
a0da8069
NN
220
221 -includedir | --includedir | --includedi | --included | --include \
222 | --includ | --inclu | --incl | --inc)
223 ac_prev=includedir ;;
224 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
225 | --includ=* | --inclu=* | --incl=* | --inc=*)
cac3d6c4 226 includedir="$ac_optarg" ;;
a0da8069
NN
227
228 -infodir | --infodir | --infodi | --infod | --info | --inf)
229 ac_prev=infodir ;;
230 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
cac3d6c4 231 infodir="$ac_optarg" ;;
a0da8069
NN
232
233 -libdir | --libdir | --libdi | --libd)
234 ac_prev=libdir ;;
235 -libdir=* | --libdir=* | --libdi=* | --libd=*)
cac3d6c4 236 libdir="$ac_optarg" ;;
a0da8069
NN
237
238 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
239 | --libexe | --libex | --libe)
240 ac_prev=libexecdir ;;
241 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
242 | --libexe=* | --libex=* | --libe=*)
cac3d6c4 243 libexecdir="$ac_optarg" ;;
a0da8069
NN
244
245 -localstatedir | --localstatedir | --localstatedi | --localstated \
246 | --localstate | --localstat | --localsta | --localst \
247 | --locals | --local | --loca | --loc | --lo)
248 ac_prev=localstatedir ;;
249 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
250 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
251 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
cac3d6c4 252 localstatedir="$ac_optarg" ;;
a0da8069
NN
253
254 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
255 ac_prev=mandir ;;
256 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
cac3d6c4 257 mandir="$ac_optarg" ;;
a0da8069
NN
258
259 -nfp | --nfp | --nf)
260 # Obsolete; use --without-fp.
261 with_fp=no ;;
262
263 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
cac3d6c4 264 | --no-cr | --no-c)
a0da8069
NN
265 no_create=yes ;;
266
267 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
268 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
269 no_recursion=yes ;;
270
271 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
272 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
273 | --oldin | --oldi | --old | --ol | --o)
274 ac_prev=oldincludedir ;;
275 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
276 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
277 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
cac3d6c4 278 oldincludedir="$ac_optarg" ;;
a0da8069
NN
279
280 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
281 ac_prev=prefix ;;
282 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
cac3d6c4 283 prefix="$ac_optarg" ;;
a0da8069
NN
284
285 -program-prefix | --program-prefix | --program-prefi | --program-pref \
286 | --program-pre | --program-pr | --program-p)
287 ac_prev=program_prefix ;;
288 -program-prefix=* | --program-prefix=* | --program-prefi=* \
289 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
cac3d6c4 290 program_prefix="$ac_optarg" ;;
a0da8069
NN
291
292 -program-suffix | --program-suffix | --program-suffi | --program-suff \
293 | --program-suf | --program-su | --program-s)
294 ac_prev=program_suffix ;;
295 -program-suffix=* | --program-suffix=* | --program-suffi=* \
296 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
cac3d6c4 297 program_suffix="$ac_optarg" ;;
a0da8069
NN
298
299 -program-transform-name | --program-transform-name \
300 | --program-transform-nam | --program-transform-na \
301 | --program-transform-n | --program-transform- \
302 | --program-transform | --program-transfor \
303 | --program-transfo | --program-transf \
304 | --program-trans | --program-tran \
305 | --progr-tra | --program-tr | --program-t)
306 ac_prev=program_transform_name ;;
307 -program-transform-name=* | --program-transform-name=* \
308 | --program-transform-nam=* | --program-transform-na=* \
309 | --program-transform-n=* | --program-transform-=* \
310 | --program-transform=* | --program-transfor=* \
311 | --program-transfo=* | --program-transf=* \
312 | --program-trans=* | --program-tran=* \
313 | --progr-tra=* | --program-tr=* | --program-t=*)
cac3d6c4 314 program_transform_name="$ac_optarg" ;;
a0da8069
NN
315
316 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
317 | -silent | --silent | --silen | --sile | --sil)
318 silent=yes ;;
319
320 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
321 ac_prev=sbindir ;;
322 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
323 | --sbi=* | --sb=*)
cac3d6c4 324 sbindir="$ac_optarg" ;;
a0da8069
NN
325
326 -sharedstatedir | --sharedstatedir | --sharedstatedi \
327 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
328 | --sharedst | --shareds | --shared | --share | --shar \
329 | --sha | --sh)
330 ac_prev=sharedstatedir ;;
331 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
332 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
333 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
334 | --sha=* | --sh=*)
cac3d6c4 335 sharedstatedir="$ac_optarg" ;;
a0da8069
NN
336
337 -site | --site | --sit)
338 ac_prev=site ;;
339 -site=* | --site=* | --sit=*)
cac3d6c4 340 site="$ac_optarg" ;;
a0da8069
NN
341
342 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
343 ac_prev=srcdir ;;
344 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
cac3d6c4 345 srcdir="$ac_optarg" ;;
a0da8069
NN
346
347 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
348 | --syscon | --sysco | --sysc | --sys | --sy)
349 ac_prev=sysconfdir ;;
350 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
351 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
cac3d6c4 352 sysconfdir="$ac_optarg" ;;
a0da8069
NN
353
354 -target | --target | --targe | --targ | --tar | --ta | --t)
cac3d6c4 355 ac_prev=target ;;
a0da8069 356 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
cac3d6c4 357 target="$ac_optarg" ;;
a0da8069
NN
358
359 -v | -verbose | --verbose | --verbos | --verbo | --verb)
360 verbose=yes ;;
361
cac3d6c4
CM
362 -version | --version | --versio | --versi | --vers)
363 echo "configure generated by autoconf version 2.13"
364 exit 0 ;;
a0da8069
NN
365
366 -with-* | --with-*)
cac3d6c4 367 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
a0da8069 368 # Reject names that are not valid shell variable names.
cac3d6c4
CM
369 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
370 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
371 fi
a0da8069 372 ac_package=`echo $ac_package| sed 's/-/_/g'`
cac3d6c4
CM
373 case "$ac_option" in
374 *=*) ;;
a0da8069
NN
375 *) ac_optarg=yes ;;
376 esac
cac3d6c4 377 eval "with_${ac_package}='$ac_optarg'" ;;
a0da8069
NN
378
379 -without-* | --without-*)
cac3d6c4 380 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
a0da8069 381 # Reject names that are not valid shell variable names.
cac3d6c4
CM
382 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
383 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
384 fi
385 ac_package=`echo $ac_package| sed 's/-/_/g'`
386 eval "with_${ac_package}=no" ;;
a0da8069
NN
387
388 --x)
389 # Obsolete; use --with-x.
390 with_x=yes ;;
391
392 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
393 | --x-incl | --x-inc | --x-in | --x-i)
394 ac_prev=x_includes ;;
395 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
396 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
cac3d6c4 397 x_includes="$ac_optarg" ;;
a0da8069
NN
398
399 -x-libraries | --x-libraries | --x-librarie | --x-librari \
400 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
401 ac_prev=x_libraries ;;
402 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
403 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
cac3d6c4 404 x_libraries="$ac_optarg" ;;
a0da8069 405
cac3d6c4 406 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
a0da8069
NN
407 ;;
408
409 *)
cac3d6c4
CM
410 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
411 echo "configure: warning: $ac_option: invalid host type" 1>&2
412 fi
413 if test "x$nonopt" != xNONE; then
414 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
415 fi
416 nonopt="$ac_option"
a0da8069
NN
417 ;;
418
419 esac
420done
421
422if test -n "$ac_prev"; then
cac3d6c4 423 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
a0da8069 424fi
a0da8069 425
cac3d6c4
CM
426trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
427
428# File descriptor usage:
429# 0 standard input
430# 1 file creation
431# 2 errors and warnings
432# 3 some systems may open it to /dev/tty
433# 4 used on the Kubota Titan
434# 6 checking for... messages and results
435# 5 compiler messages saved in config.log
436if test "$silent" = yes; then
437 exec 6>/dev/null
438else
439 exec 6>&1
440fi
441exec 5>./config.log
442
443echo "\
444This file contains any messages produced by compilers while
445running configure, to aid debugging if configure makes a mistake.
446" 1>&5
a0da8069 447
cac3d6c4
CM
448# Strip out --no-create and --no-recursion so they do not pile up.
449# Also quote any args containing shell metacharacters.
450ac_configure_args=
451for ac_arg
a0da8069 452do
cac3d6c4
CM
453 case "$ac_arg" in
454 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
455 | --no-cr | --no-c) ;;
456 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
457 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
458 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
459 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
460 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
a0da8069
NN
461 esac
462done
463
cac3d6c4
CM
464# NLS nuisances.
465# Only set these to C if already set. These must not be set unconditionally
466# because not all systems understand e.g. LANG=C (notably SCO).
467# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
468# Non-C LC_CTYPE values break the ctype check.
469if test "${LANG+set}" = set; then LANG=C; export LANG; fi
470if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
471if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
472if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
376a0e54 473
cac3d6c4
CM
474# confdefs.h avoids OS command line length limits that DEFS can exceed.
475rm -rf conftest* confdefs.h
476# AIX cpp loses on an empty file, so make sure it contains at least a newline.
477echo > confdefs.h
a0da8069 478
cac3d6c4
CM
479# A filename unique to this package, relative to the directory that
480# configure is in, which we can look for to find out if srcdir is correct.
481ac_unique_file=move-if-change
a0da8069
NN
482
483# Find the source files, if location was not specified.
484if test -z "$srcdir"; then
485 ac_srcdir_defaulted=yes
486 # Try the directory containing this script, then its parent.
cac3d6c4
CM
487 ac_prog=$0
488 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
489 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
a0da8069
NN
490 srcdir=$ac_confdir
491 if test ! -r $srcdir/$ac_unique_file; then
492 srcdir=..
493 fi
494else
495 ac_srcdir_defaulted=no
496fi
497if test ! -r $srcdir/$ac_unique_file; then
498 if test "$ac_srcdir_defaulted" = yes; then
cac3d6c4 499 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
a0da8069 500 else
cac3d6c4 501 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
a0da8069
NN
502 fi
503fi
cac3d6c4 504srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
a0da8069
NN
505
506# Prefer explicitly selected file to automatically selected ones.
e3c770b1
EB
507if test -z "$CONFIG_SITE"; then
508 if test "x$prefix" != xNONE; then
509 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
510 else
511 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
a0da8069
NN
512 fi
513fi
514for ac_site_file in $CONFIG_SITE; do
515 if test -r "$ac_site_file"; then
cac3d6c4 516 echo "loading site script $ac_site_file"
a0da8069
NN
517 . "$ac_site_file"
518 fi
519done
520
521if test -r "$cache_file"; then
cac3d6c4
CM
522 echo "loading cache $cache_file"
523 . $cache_file
a0da8069 524else
cac3d6c4
CM
525 echo "creating cache $cache_file"
526 > $cache_file
a0da8069
NN
527fi
528
529ac_ext=c
cac3d6c4 530# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
a0da8069 531ac_cpp='$CPP $CPPFLAGS'
cac3d6c4
CM
532ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
533ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
534cross_compiling=$ac_cv_prog_cc_cross
535
536ac_exeext=
537ac_objext=o
538if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
539 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
540 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
541 ac_n= ac_c='
542' ac_t=' '
543 else
544 ac_n=-n ac_c= ac_t=
545 fi
546else
547 ac_n= ac_c='\c' ac_t=
548fi
a0da8069
NN
549
550
75778ec4 551
a0da8069 552ac_aux_dir=
315b3b02 553for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
a0da8069
NN
554 if test -f $ac_dir/install-sh; then
555 ac_aux_dir=$ac_dir
556 ac_install_sh="$ac_aux_dir/install-sh -c"
557 break
558 elif test -f $ac_dir/install.sh; then
559 ac_aux_dir=$ac_dir
560 ac_install_sh="$ac_aux_dir/install.sh -c"
561 break
562 fi
563done
564if test -z "$ac_aux_dir"; then
cac3d6c4 565 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
a0da8069 566fi
cac3d6c4
CM
567ac_config_guess=$ac_aux_dir/config.guess
568ac_config_sub=$ac_aux_dir/config.sub
569ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
a0da8069
NN
570
571
cac3d6c4
CM
572# Do some error checking and defaulting for the host and target type.
573# The inputs are:
574# configure --host=HOST --target=TARGET --build=BUILD NONOPT
575#
576# The rules are:
577# 1. You are not allowed to specify --host, --target, and nonopt at the
578# same time.
579# 2. Host defaults to nonopt.
580# 3. If nonopt is not specified, then host defaults to the current host,
581# as determined by config.guess.
582# 4. Target and build default to nonopt.
583# 5. If nonopt is not specified, then target and build default to host.
a0da8069
NN
584
585# The aliases save the names the user supplied, while $host etc.
586# will get canonicalized.
cac3d6c4
CM
587case $host---$target---$nonopt in
588NONE---*---* | *---NONE---* | *---*---NONE) ;;
589*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
590esac
591
592
593# Make sure we can run config.sub.
594if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
595else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
596fi
597
598echo $ac_n "checking host system type""... $ac_c" 1>&6
599echo "configure:600: checking host system type" >&5
600
601host_alias=$host
602case "$host_alias" in
603NONE)
604 case $nonopt in
605 NONE)
606 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
607 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
608 fi ;;
609 *) host_alias=$nonopt ;;
610 esac ;;
611esac
612
613host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
614host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
615host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
616host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
617echo "$ac_t""$host" 1>&6
618
619echo $ac_n "checking target system type""... $ac_c" 1>&6
620echo "configure:621: checking target system type" >&5
621
622target_alias=$target
623case "$target_alias" in
624NONE)
625 case $nonopt in
626 NONE) target_alias=$host_alias ;;
627 *) target_alias=$nonopt ;;
628 esac ;;
629esac
630
631target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
632target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
633target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
634target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
635echo "$ac_t""$target" 1>&6
636
637echo $ac_n "checking build system type""... $ac_c" 1>&6
638echo "configure:639: checking build system type" >&5
639
640build_alias=$build
641case "$build_alias" in
642NONE)
643 case $nonopt in
644 NONE) build_alias=$host_alias ;;
645 *) build_alias=$nonopt ;;
646 esac ;;
647esac
648
649build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
650build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
651build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
652build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
653echo "$ac_t""$build" 1>&6
654
655test "$host_alias" != "$target_alias" &&
a0da8069
NN
656 test "$program_prefix$program_suffix$program_transform_name" = \
657 NONENONEs,x,x, &&
658 program_prefix=${target_alias}-
cac3d6c4
CM
659
660if test "$program_transform_name" = s,x,x,; then
661 program_transform_name=
662else
663 # Double any \ or $. echo might interpret backslashes.
664 cat <<\EOF_SED > conftestsed
665s,\\,\\\\,g; s,\$,$$,g
666EOF_SED
667 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
668 rm -f conftestsed
669fi
a0da8069 670test "$program_prefix" != NONE &&
cac3d6c4 671 program_transform_name="s,^,${program_prefix},; $program_transform_name"
a0da8069
NN
672# Use a double $ so make ignores it.
673test "$program_suffix" != NONE &&
cac3d6c4
CM
674 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
675
676# sed with no file args requires a program.
677test "$program_transform_name" = "" && program_transform_name="s,x,x,"
a0da8069
NN
678
679
e5c3f801
NN
680# Get 'install' or 'install-sh' and its variants.
681# Find a good install program. We prefer a C program (faster),
682# so one script is as good as another. But avoid the broken or
683# incompatible versions:
684# SysV /etc/install, /usr/sbin/install
685# SunOS /usr/etc/install
686# IRIX /sbin/install
687# AIX /bin/install
688# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
689# AFS /usr/afsws/bin/install, which mishandles nonexistent args
690# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
691# ./install, which can be erroneously created by make from ./install.sh.
cac3d6c4
CM
692echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
693echo "configure:694: checking for a BSD compatible install" >&5
e5c3f801 694if test -z "$INSTALL"; then
cac3d6c4
CM
695if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
696 echo $ac_n "(cached) $ac_c" 1>&6
697else
698 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
699 for ac_dir in $PATH; do
700 # Account for people who put trailing slashes in PATH elements.
701 case "$ac_dir/" in
702 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
703 *)
704 # OSF1 and SCO ODT 3.0 have their own names for install.
705 # Don't use installbsd from OSF since it installs stuff as root
706 # by default.
707 for ac_prog in ginstall scoinst install; do
708 if test -f $ac_dir/$ac_prog; then
e5c3f801 709 if test $ac_prog = install &&
cac3d6c4 710 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
e5c3f801
NN
711 # AIX install. It has an incompatible calling convention.
712 :
713 else
cac3d6c4
CM
714 ac_cv_path_install="$ac_dir/$ac_prog -c"
715 break 2
e5c3f801
NN
716 fi
717 fi
718 done
cac3d6c4
CM
719 ;;
720 esac
721 done
722 IFS="$ac_save_IFS"
e5c3f801
NN
723
724fi
725 if test "${ac_cv_path_install+set}" = set; then
cac3d6c4 726 INSTALL="$ac_cv_path_install"
e5c3f801
NN
727 else
728 # As a last resort, use the slow shell script. We don't cache a
729 # path for INSTALL within a source directory, because that will
730 # break other packages using the cache if that directory is
731 # removed, or if the path is relative.
cac3d6c4 732 INSTALL="$ac_install_sh"
e5c3f801
NN
733 fi
734fi
cac3d6c4 735echo "$ac_t""$INSTALL" 1>&6
e5c3f801
NN
736
737# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
738# It thinks the first close brace ends the variable substitution.
739test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
740
cac3d6c4 741test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
e5c3f801
NN
742
743test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
744
cac3d6c4
CM
745echo $ac_n "checking whether ln works""... $ac_c" 1>&6
746echo "configure:747: checking whether ln works" >&5
747if eval "test \"`echo '$''{'acx_cv_prog_LN'+set}'`\" = set"; then
748 echo $ac_n "(cached) $ac_c" 1>&6
656fdd47
PB
749else
750 rm -f conftestdata_t
751echo >conftestdata_f
752if ln conftestdata_f conftestdata_t 2>/dev/null
753then
754 acx_cv_prog_LN=ln
755else
756 acx_cv_prog_LN=no
757fi
758rm -f conftestdata_f conftestdata_t
759
760fi
761if test $acx_cv_prog_LN = no; then
762 LN="cp"
cac3d6c4 763 echo "$ac_t""no, using $LN" 1>&6
656fdd47
PB
764else
765 LN="$acx_cv_prog_LN"
cac3d6c4 766 echo "$ac_t""yes" 1>&6
656fdd47
PB
767fi
768
cac3d6c4
CM
769echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
770echo "configure:771: checking whether ln -s works" >&5
771if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
772 echo $ac_n "(cached) $ac_c" 1>&6
773else
774 rm -f conftestdata
775if ln -s X conftestdata 2>/dev/null
776then
777 rm -f conftestdata
778 ac_cv_prog_LN_S="ln -s"
779else
780 ac_cv_prog_LN_S=ln
781fi
782fi
783LN_S="$ac_cv_prog_LN_S"
784if test "$ac_cv_prog_LN_S" = "ln -s"; then
785 echo "$ac_t""yes" 1>&6
dfdffa2c 786else
cac3d6c4 787 echo "$ac_t""no" 1>&6
dfdffa2c
PB
788fi
789
e5c3f801 790
252b5132 791### we might need to use some other shell than /bin/sh for running subshells
252b5132
RH
792### If we are on Windows, search for the shell. This will permit people
793### to not have /bin/sh, but to be able to see /SOME/PATH/sh configure
794### without also having to set CONFIG_SHELL. This code will work when
795### using bash, which sets OSTYPE.
796case "${OSTYPE}" in
797*win32*)
a0da8069
NN
798 if test x${CONFIG_SHELL} = x ; then
799 if test ! -f /bin/sh ; then
800 if test x${SHELL} != x && test -f ${SHELL} ; then
252b5132
RH
801 CONFIG_SHELL=${SHELL}
802 export CONFIG_SHELL
803 else
804 for prog in sh sh.exe bash bash.exe; do
805 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
806 for dir in $PATH; do
807 test -z "$dir" && dir=.
808 if test -f $dir/$prog; then
809 CONFIG_SHELL=$dir/$prog
810 export CONFIG_SHELL
811 break
812 fi
813 done
814 IFS="$save_ifs"
815 test -n "${CONFIG_SHELL}" && break
816 done
817 fi
818 fi
819 fi
820 ;;
821esac
822
823config_shell=${CONFIG_SHELL-/bin/sh}
824
252b5132
RH
825progname=$0
826# if PWD already has a value, it is probably wrong.
a0da8069 827if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
252b5132 828
d2cc0e0d 829# Export original configure arguments for use by sub-configures. These
8ff944f6
DJ
830# will be expanded by make, so quote '$'.
831tmp="$progname $@"
832sed -e 's,\$,$$,g' <<EOF_SED > conftestsed.out
833$tmp
d2cc0e0d 834EOF_SED
8ff944f6
DJ
835TOPLEVEL_CONFIGURE_ARGUMENTS=`cat conftestsed.out`
836rm -f conftestsed.out
586c0873 837
75205f78 838
a0da8069 839moveifchange=${srcdir}/move-if-change
252b5132 840
0fdbe983
DJ
841srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
842
843# We pass INSTALL explicitly to sub-makes. Make sure that it is not
844# a relative path.
845if test "$INSTALL" = "${srcdir}/install-sh -c"; then
846 INSTALL="${srcpwd}/install-sh -c"
847fi
848
a0da8069
NN
849# Set srcdir to "." if that's what it is.
850# This is important for multilib support.
851pwd=`${PWDCMD-pwd}`
a0da8069
NN
852if test "${pwd}" = "${srcpwd}" ; then
853 srcdir=.
252b5132
RH
854fi
855
a0da8069 856topsrcdir=$srcpwd
252b5132 857
a0da8069 858extra_host_args=
afefada0 859
a0da8069
NN
860### To add a new directory to the tree, first choose whether it is a target
861### or a host dependent tool. Then put it into the appropriate list
862### (library or tools, host or target), doing a dependency sort.
252b5132 863
cac3d6c4 864# Subdirs will be configured in the order listed in build_configdirs,
a0da8069 865# configdirs, or target_configdirs; see the serialization section below.
252b5132 866
cac3d6c4
CM
867# Dependency sorting is only needed when *configuration* must be done in
868# a particular order. In all cases a dependency should be specified in
a0da8069 869# the Makefile, whether or not it's implicitly specified here.
252b5132 870
a0da8069
NN
871# Double entries in build_configdirs, configdirs, or target_configdirs may
872# cause circular dependencies and break everything horribly.
252b5132 873
6a9cf61e
PB
874# these library is used by various programs built for the build
875# environment
876#
877build_libs="build-libiberty"
878
879# these tools are built for the build environment
ee025550 880build_tools="build-texinfo build-byacc build-flex build-bison build-m4 build-fixincludes"
6a9cf61e 881
a0da8069
NN
882# these libraries are used by various programs built for the host environment
883#
be75bbe1 884host_libs="intl mmalloc libiberty opcodes bfd readline tcl tk itcl libgui zlib libcpp"
a0da8069 885
a0da8069
NN
886# these tools are built for the host environment
887# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
888# know that we are building the simulator.
889# binutils, gas and ld appear in that order because it makes sense to run
890# "make check" in that particular order.
b00612cc 891host_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"
a0da8069
NN
892
893# libgcj represents the runtime libraries only used by gcj.
894libgcj="target-libffi \
895 target-boehm-gc \
896 target-zlib \
897 target-qthreads \
898 target-libjava"
899
900# these libraries are built for the target environment, and are built after
901# the host libraries and the host tools (which may be a cross compiler)
902#
9c14acb8 903target_libraries="target-libiberty \
a0da8069
NN
904 target-libgloss \
905 target-newlib \
b9459e83 906 target-libstdc++-v3 \
4b1cb4fe 907 target-libmudflap \
bb780410 908 target-libssp \
4b1cb4fe 909 target-libgfortran \
83326456 910 ${libgcj} \
a2592b1b
DD
911 target-libobjc \
912 target-libada"
a0da8069 913
9c14acb8
NN
914# these tools are built using the target libraries, and are intended to
915# run only in the target environment
a0da8069 916#
9c14acb8 917# note: any program that *uses* libraries that are in the "target_libraries"
a0da8069
NN
918# list belongs in this list. those programs are also very likely
919# candidates for the "native_only" list which follows
920#
a3dd767d 921target_tools="target-examples target-groff target-gperf target-rda"
252b5132 922
a0da8069 923################################################################################
252b5132 924
a0da8069
NN
925## All tools belong in one of the four categories, and are assigned above
926## We assign ${configdirs} this way to remove all embedded newlines. This
927## is important because configure will choke if they ever get through.
928## ${configdirs} is directories we build using the host tools.
929## ${target_configdirs} is directories we build using the target tools.
a0da8069 930configdirs=`echo ${host_libs} ${host_tools}`
9c14acb8 931target_configdirs=`echo ${target_libraries} ${target_tools}`
ee025550 932build_configdirs=`echo ${build_libs} ${build_tools}`
dd12c3a8 933
a0da8069 934################################################################################
252b5132 935
a0da8069 936srcname="gnu development package"
252b5132 937
a0da8069
NN
938# This gets set non-empty for some net releases of packages.
939appdirs=""
252b5132 940
a0da8069
NN
941# Define is_cross_compiler to save on calls to 'test'.
942is_cross_compiler=
943if test x"${host}" = x"${target}" ; then
944 is_cross_compiler=no
252b5132 945else
a0da8069 946 is_cross_compiler=yes
cac3d6c4 947fi
252b5132 948
9175bfc0 949# Find the build and target subdir names.
dd12c3a8
NN
950 case ${build_alias} in
951 "") build_noncanonical=${build} ;;
952 *) build_noncanonical=${build_alias} ;;
953esac
954
955 case ${host_alias} in
956 "") host_noncanonical=${build_noncanonical} ;;
957 *) host_noncanonical=${host_alias} ;;
958esac
959
960 case ${target_alias} in
961 "") target_noncanonical=${host_noncanonical} ;;
962 *) target_noncanonical=${target_alias} ;;
963esac
964
965 # Prefix 'build-' so this never conflicts with target_subdir.
966build_subdir="build-${build_noncanonical}"
b00612cc
PB
967# --srcdir=. covers the toplevel, while "test -d" covers the subdirectories
968if ( test $srcdir = . && test -d gcc ) \
969 || test -d $srcdir/../host-${host_noncanonical}; then
970 host_subdir="host-${host_noncanonical}"
971else
972 host_subdir=.
973fi
dd12c3a8
NN
974# No prefix.
975target_subdir=${target_noncanonical}
cac3d6c4 976
252b5132 977
a0da8069
NN
978# Skipdirs are removed silently.
979skipdirs=
980# Noconfigdirs are removed loudly.
981noconfigdirs=""
252b5132 982
a0da8069
NN
983use_gnu_ld=
984# Make sure we don't let GNU ld be added if we didn't want it.
985if test x$with_gnu_ld = xno ; then
986 use_gnu_ld=no
987 noconfigdirs="$noconfigdirs ld"
252b5132
RH
988fi
989
a0da8069
NN
990use_gnu_as=
991# Make sure we don't let GNU as be added if we didn't want it.
992if test x$with_gnu_as = xno ; then
993 use_gnu_as=no
994 noconfigdirs="$noconfigdirs gas"
252b5132
RH
995fi
996
cac3d6c4 997# some tools are so dependent upon X11 that if we're not building with X,
a0da8069 998# it's not even worth trying to configure, much less build, that tool.
252b5132 999
a0da8069
NN
1000case ${with_x} in
1001 yes | "") ;; # the default value for this tree is that X11 is available
1002 no)
675c6968 1003 skipdirs="${skipdirs} tk itcl libgui"
a0da8069 1004 # We won't be able to build gdbtk without X.
cac3d6c4 1005 enable_gdbtk=no
a0da8069
NN
1006 ;;
1007 *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
1008esac
252b5132 1009
a0da8069 1010# Some tools are only suitable for building in a "native" situation.
cac3d6c4 1011# Remove these if host!=target.
91f0e695 1012native_only="autoconf automake libtool fileutils find gawk gettext gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl time ash bash bzip2 prms gnuserv target-gperf"
252b5132 1013
a0da8069
NN
1014# Similarly, some are only suitable for cross toolchains.
1015# Remove these if host=target.
1016cross_only="target-libgloss target-newlib target-opcodes"
1017
1018case $is_cross_compiler in
1019 no) skipdirs="${skipdirs} ${cross_only}" ;;
1020 yes) skipdirs="${skipdirs} ${native_only}" ;;
1021esac
252b5132 1022
a0da8069
NN
1023# If both --with-headers and --with-libs are specified, default to
1024# --without-newlib.
32be62b5
RS
1025if test x"${with_headers}" != x && test x"${with_headers}" != xno \
1026 && test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
a0da8069
NN
1027 if test x"${with_newlib}" = x ; then
1028 with_newlib=no
1029 fi
252b5132
RH
1030fi
1031
a0da8069
NN
1032# Recognize --with-newlib/--without-newlib.
1033case ${with_newlib} in
1034 no) skipdirs="${skipdirs} target-newlib" ;;
1035 yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
1036esac
252b5132 1037
a0da8069 1038# Configure extra directories which are host specific
252b5132 1039
a0da8069
NN
1040case "${host}" in
1041 *-cygwin*)
1042 configdirs="$configdirs libtermcap" ;;
1043esac
252b5132 1044
59f7ec45
HPN
1045# A target can indicate whether a language isn't supported for some reason.
1046# Only spaces may be used in this macro; not newlines or tabs.
1047unsupported_languages=
1048
cac3d6c4 1049# Remove more programs from consideration, based on the host or
a0da8069
NN
1050# target this usually means that a port of the program doesn't
1051# exist yet.
252b5132 1052
a0da8069
NN
1053case "${host}" in
1054 hppa*64*-*-*)
1055 noconfigdirs="$noconfigdirs byacc"
1056 ;;
ec11bdc6 1057 i[3456789]86-*-vsta)
675c6968 1058 noconfigdirs="$noconfigdirs tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl gnuserv gettext"
a0da8069 1059 ;;
ec11bdc6 1060 i[3456789]86-*-go32* | i[3456789]86-*-msdosdjgpp*)
675c6968 1061 noconfigdirs="$noconfigdirs tcl tk expect dejagnu send-pr uudecode guile itcl gnuserv libffi"
bba45b8b 1062 ;;
ec11bdc6 1063 i[3456789]86-*-mingw32*)
675c6968 1064 # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl gnuserv"
a92834c8 1065 noconfigdirs="$noconfigdirs expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
bba45b8b 1066 ;;
ec11bdc6 1067 i[3456789]86-*-beos*)
675c6968 1068 noconfigdirs="$noconfigdirs tk itcl libgui gdb"
bba45b8b 1069 ;;
a0da8069 1070 *-*-cygwin*)
a92834c8 1071 noconfigdirs="$noconfigdirs autoconf automake send-pr rcs guile perl"
a0da8069
NN
1072 ;;
1073 *-*-netbsd*)
a92834c8 1074 noconfigdirs="$noconfigdirs rcs"
a0da8069
NN
1075 ;;
1076 ppc*-*-pe)
675c6968 1077 noconfigdirs="$noconfigdirs patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl gnuserv"
a0da8069
NN
1078 ;;
1079 powerpc-*-beos*)
675c6968 1080 noconfigdirs="$noconfigdirs tk itcl libgui gdb dejagnu readline"
a0da8069 1081 ;;
a0da8069 1082esac
252b5132 1083
4b1cb4fe 1084
a2592b1b
DD
1085# Check whether --enable-libada or --disable-libada was given.
1086if test "${enable_libada+set}" = set; then
1087 enableval="$enable_libada"
1088 ENABLE_LIBADA=$enableval
1089else
1090 ENABLE_LIBADA=yes
cac3d6c4
CM
1091fi
1092
a2592b1b
DD
1093if test "${ENABLE_LIBADA}" != "yes" ; then
1094 noconfigdirs="$noconfigdirs target-libada"
b00612cc 1095 noconfigdirs="$noconfigdirs gnattools"
a2592b1b
DD
1096fi
1097
5f128533
KH
1098# Check whether --enable-libssp or --disable-libssp was given.
1099if test "${enable_libssp+set}" = set; then
1100 enableval="$enable_libssp"
1101 ENABLE_LIBSSP=$enableval
1102else
1103 ENABLE_LIBSSP=yes
cac3d6c4
CM
1104fi
1105
5f128533 1106if test "${ENABLE_LIBSSP}" != "yes" ; then
bb780410 1107 noconfigdirs="$noconfigdirs target-libssp"
5f128533
KH
1108fi
1109
a0da8069
NN
1110# Save it here so that, even in case of --enable-libgcj, if the Java
1111# front-end isn't enabled, we still get libgcj disabled.
1112libgcj_saved=$libgcj
1113case $enable_libgcj in
1114yes)
1115 # If we reset it here, it won't get added to noconfigdirs in the
1116 # target-specific build rules, so it will be forcibly enabled
1117 # (unless the Java language itself isn't enabled).
1118 libgcj=
1119 ;;
1120no)
1121 # Make sure we get it printed in the list of not supported target libs.
1122 noconfigdirs="$noconfigdirs ${libgcj}"
1123 ;;
1124esac
252b5132 1125
4b1cb4fe
DD
1126
1127# Allow --disable-libmudflap to exclude target-libmudflap
1128case $enable_libmudflap in
3e707e94 1129yes)
4b1cb4fe
DD
1130 ;;
1131no)
1132 noconfigdirs="$noconfigdirs target-libmudflap"
1133 ;;
3e707e94
PB
1134"")
1135 case "${target}" in
3d6dfe0f
NN
1136 *-*-linux*-gnu | *-*-gnu* | *-*-k*bsd*-gnu)
1137 # Enable libmudflap by default in GNU and friends.
3e707e94
PB
1138 ;;
1139 *-*-freebsd*)
1140 # Enable libmudflap by default in FreeBSD.
1141 ;;
1142 *)
1143 # Disable it by default everywhere else.
1144 noconfigdirs="$noconfigdirs target-libmudflap"
1145 ;;
1146 esac
4b1cb4fe
DD
1147esac
1148
1149
a0da8069
NN
1150case "${target}" in
1151 *-*-chorusos)
1152 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1153 ;;
04d1ab34 1154 powerpc-*-darwin*)
b3f16a9b 1155 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
4e3fc8e5 1156 noconfigdirs="$noconfigdirs sim target-rda"
b3f16a9b 1157 ;;
04d1ab34 1158 *-*-darwin*)
d320aacb 1159 noconfigdirs="$noconfigdirs ld gas gdb gprof"
4e3fc8e5 1160 noconfigdirs="$noconfigdirs sim target-rda"
fe69863c 1161 noconfigdirs="$noconfigdirs ${libgcj}"
04d1ab34 1162 ;;
a0da8069
NN
1163 *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
1164 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1165 ;;
de0b4a87 1166 *-*-freebsd*)
4b1cb4fe
DD
1167 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1168 if test "x$with_gmp" = x && test "x$with_gmp_dir" = x \
1169 && test -f /usr/local/include/gmp.h; then
1170 with_gmp=/usr/local
1171 fi
1172
1173 # Skip some stuff that's unsupported on some FreeBSD configurations.
1174 case "${target}" in
1175 i*86-*-*) ;;
1176 alpha*-*-*) ;;
1177 *)
1178 noconfigdirs="$noconfigdirs ${libgcj}"
1179 ;;
1180 esac
1181 ;;
f8a495c8
NC
1182 *-*-kaos*)
1183 # Remove unsupported stuff on all kaOS configurations.
80b200a1 1184 skipdirs="target-libiberty ${libgcj} target-libstdc++-v3 target-librx"
f8a495c8
NC
1185 skipdirs="$skipdirs target-libobjc target-examples target-groff target-gperf"
1186 skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
1187 noconfigdirs="$noconfigdirs target-libgloss"
1188 ;;
a0da8069
NN
1189 *-*-netbsd*)
1190 # Skip some stuff on all NetBSD configurations.
1191 noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss"
1192
1193 # Skip some stuff that's unsupported on some NetBSD configurations.
1194 case "${target}" in
1195 i*86-*-netbsdelf*) ;;
5b474aa8 1196 arm*-*-netbsdelf*) ;;
a0da8069
NN
1197 *)
1198 noconfigdirs="$noconfigdirs ${libgcj}"
1199 ;;
1200 esac
1201 ;;
2a3124ca
RH
1202 *-*-netware*)
1203 noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss ${libgcj} target-libmudflap"
a0da8069
NN
1204 ;;
1205 *-*-rtems*)
1206 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
a0da8069 1207 ;;
1587117a
EC
1208 # The tpf target doesn't support gdb yet.
1209 *-*-tpf*)
1210 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty ${libgcj} target-libmudflap gdb tcl tk libgui itcl"
1211 ;;
c1968181
DD
1212 *-*-uclinux*)
1213 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-rda ${libgcj}"
1214 ;;
a0da8069 1215 *-*-vxworks*)
6dd2fda9 1216 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty target-libstdc++-v3 ${libgcj}"
a0da8069 1217 ;;
49f58d10
JB
1218 m32c-*-*)
1219 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1220 ;;
a0da8069
NN
1221 alpha*-dec-osf*)
1222 # ld works, but does not support shared libraries.
1223 # newlib is not 64 bit ready. I'm not sure about fileutils.
1224 # gas doesn't generate exception information.
1225 noconfigdirs="$noconfigdirs gas ld fileutils target-newlib target-libgloss"
1226 ;;
1227 alpha*-*-*vms*)
69e57115 1228 noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss ${libgcj}"
a0da8069
NN
1229 ;;
1230 alpha*-*-linux*)
1231 # newlib is not 64 bit ready
1232 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1233 ;;
a0da8069
NN
1234 alpha*-*-*)
1235 # newlib is not 64 bit ready
1236 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1237 ;;
4a18bd6b
AO
1238 am33_2.0-*-linux*)
1239 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
1240 ;;
a0da8069
NN
1241 sh-*-linux*)
1242 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
cac3d6c4 1243 ;;
a0da8069
NN
1244 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
1245 noconfigdirs="$noconfigdirs ${libgcj}"
1246 noconfigdirs="$noconfigdirs target-examples"
1247 noconfigdirs="$noconfigdirs target-libiberty texinfo send-pr"
675c6968 1248 noconfigdirs="$noconfigdirs tcl tk itcl libgui sim"
a0da8069
NN
1249 noconfigdirs="$noconfigdirs expect dejagnu"
1250 # the C++ libraries don't build on top of CE's C libraries
b9459e83 1251 noconfigdirs="$noconfigdirs target-libstdc++-v3"
a0da8069
NN
1252 noconfigdirs="$noconfigdirs target-newlib"
1253 case "${host}" in
1254 *-*-cygwin*) ;; # keep gdb and readline
b9459e83 1255 *) noconfigdirs="$noconfigdirs gdb readline"
a0da8069
NN
1256 ;;
1257 esac
1258 ;;
1259 arc-*-*)
1260 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1261 ;;
caeba88f 1262 arm-semi-aof )
caeba88f 1263 ;;
a0da8069
NN
1264 arm-*-coff | strongarm-*-coff | xscale-*-coff)
1265 noconfigdirs="$noconfigdirs ${libgcj}"
1266 ;;
11b04d1f 1267 arm-*-elf* | strongarm-*-elf* | xscale-*-elf* | arm*-*-eabi* )
a0da8069
NN
1268 noconfigdirs="$noconfigdirs target-libffi target-qthreads"
1269 ;;
bd70a46f
KH
1270 arm*-*-linux-gnueabi)
1271 noconfigdirs="$noconfigdirs target-libffi target-qthreads"
1272 noconfigdirs="$noconfigdirs target-libjava target-libobjc"
1273 ;;
df4a6958
MM
1274 arm*-*-symbianelf*)
1275 noconfigdirs="$noconfigdirs ${libgcj} target-libiberty"
1276 ;;
a0da8069
NN
1277 arm-*-pe*)
1278 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1279 ;;
a0da8069
NN
1280 thumb-*-coff)
1281 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1282 ;;
1283 thumb-*-elf)
1284 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1285 ;;
a0da8069
NN
1286 thumb-*-pe)
1287 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1288 ;;
1289 arm-*-riscix*)
1290 noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
1291 ;;
1292 avr-*-*)
69e57115 1293 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
a0da8069 1294 ;;
376a0e54
CM
1295 bfin-*-*)
1296 noconfigdirs="$noconfigdirs target-libgloss gdb"
3cf3372e 1297 if test x${is_cross_compiler} != xno ; then
376a0e54
CM
1298 target_configdirs="${target_configdirs} target-bsp target-cygmon"
1299 fi
1300 ;;
a0da8069 1301 c4x-*-* | tic4x-*-*)
b9459e83 1302 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
a0da8069
NN
1303 ;;
1304 c54x*-*-* | tic54x-*-*)
b9459e83 1305 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} gcc gdb newlib"
a0da8069 1306 ;;
c7e66c6d 1307 cris-*-* | crisv32-*-*)
59f7ec45 1308 unsupported_languages="$unsupported_languages java"
c7e66c6d 1309 case "${target}" in
2faa2958 1310 *-*-aout)
096f7d00 1311 unsupported_languages="$unsupported_languages fortran"
59f7ec45 1312 noconfigdirs="$noconfigdirs target-libffi target-boehm-gc";;
2faa2958 1313 *-*-elf)
096f7d00 1314 unsupported_languages="$unsupported_languages fortran"
5e818318 1315 noconfigdirs="$noconfigdirs target-boehm-gc";;
2faa2958 1316 *-*-linux*)
5e818318 1317 noconfigdirs="$noconfigdirs target-newlib target-libgloss";;
c7e66c6d 1318 *)
096f7d00 1319 unsupported_languages="$unsupported_languages fortran"
c7e66c6d
HPN
1320 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss";;
1321 esac
a0da8069 1322 ;;
3e707e94 1323 crx-*-*)
0490e016 1324 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-mudflap ${libgcj}"
3e707e94 1325 ;;
a0da8069 1326 d10v-*-*)
b9459e83 1327 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
a0da8069
NN
1328 ;;
1329 d30v-*-*)
b07c2aad 1330 noconfigdirs="$noconfigdirs ${libgcj} gdb"
a0da8069
NN
1331 ;;
1332 fr30-*-elf*)
b07c2aad 1333 noconfigdirs="$noconfigdirs ${libgcj} gdb"
a0da8069
NN
1334 ;;
1335 frv-*-*)
1336 noconfigdirs="$noconfigdirs ${libgcj}"
1337 ;;
1338 h8300*-*-*)
80b200a1 1339 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
a0da8069
NN
1340 ;;
1341 h8500-*-*)
80b200a1 1342 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
a0da8069 1343 ;;
caeba88f 1344 hppa1.1-*-osf* | hppa1.1-*-bsd* )
caeba88f 1345 ;;
a0da8069
NN
1346 hppa*64*-*-linux* | parisc*64*-*-linux*)
1347 # In this case, it's because the hppa64-linux target is for
1348 # the kernel only at this point and has no libc, and thus no
1349 # headers, crt*.o, etc., all of which are needed by these.
1350 noconfigdirs="$noconfigdirs target-zlib"
1351 ;;
5dcac624
DA
1352 parisc*-*-linux* | hppa*-*-linux*)
1353 ;;
a0da8069 1354 hppa*-*-*elf* | \
a0da8069
NN
1355 hppa*-*-lites* | \
1356 hppa*-*-openbsd* | \
1357 hppa*64*-*-*)
1358 noconfigdirs="$noconfigdirs ${libgcj}"
a0da8069
NN
1359 ;;
1360 hppa*-*-*)
1361 # According to Alexandre Oliva <aoliva@redhat.com>, libjava won't
1362 # build on HP-UX 10.20.
1363 noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
1364 ;;
b07c2aad
HPN
1365 i960-*-*)
1366 noconfigdirs="$noconfigdirs ${libgcj} gdb"
1367 ;;
a0da8069
NN
1368 ia64*-*-elf*)
1369 # No gdb support yet.
675c6968 1370 noconfigdirs="$noconfigdirs readline mmalloc libgui itcl gdb"
a0da8069
NN
1371 ;;
1372 ia64*-**-hpux*)
1373 # No gdb or ld support yet.
675c6968 1374 noconfigdirs="$noconfigdirs ${libgcj} readline mmalloc libgui itcl gdb ld"
a0da8069 1375 ;;
caeba88f 1376 i370-*-opened*)
caeba88f 1377 ;;
ec11bdc6 1378 i[3456789]86-*-coff | i[3456789]86-*-elf)
a0da8069
NN
1379 noconfigdirs="$noconfigdirs ${libgcj}"
1380 ;;
ec11bdc6 1381 i[3456789]86-*-linux*)
a0da8069
NN
1382 # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
1383 # not build java stuff by default.
1384 case "${target}" in
1385 *-*-*libc1*)
1386 noconfigdirs="$noconfigdirs ${libgcj}";;
1387 esac
1388
1389 # This section makes it possible to build newlib natively on linux.
1390 # If we are using a cross compiler then don't configure newlib.
1391 if test x${is_cross_compiler} != xno ; then
bba45b8b 1392 noconfigdirs="$noconfigdirs target-newlib"
a0da8069
NN
1393 fi
1394 noconfigdirs="$noconfigdirs target-libgloss"
1395 # If we are not using a cross compiler, do configure newlib.
1396 # Note however, that newlib will only be configured in this situation
1397 # if the --with-newlib option has been given, because otherwise
1398 # 'target-newlib' will appear in skipdirs.
1399 ;;
ec11bdc6 1400 i[3456789]86-*-mingw32*)
a0da8069 1401 target_configdirs="$target_configdirs target-mingw"
69e57115 1402 noconfigdirs="$noconfigdirs expect target-libgloss ${libgcj}"
a0da8069
NN
1403
1404 # Can't build gdb for mingw32 if not native.
1405 case "${host}" in
ec11bdc6 1406 i[3456789]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
675c6968 1407 *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl gnuserv"
a0da8069
NN
1408 ;;
1409 esac
cac3d6c4 1410 ;;
a0da8069
NN
1411 *-*-cygwin*)
1412 target_configdirs="$target_configdirs target-libtermcap target-winsup"
69e57115 1413 noconfigdirs="$noconfigdirs target-gperf target-libgloss ${libgcj}"
b76d7de0 1414 # always build newlib if winsup directory is present.
ac0fa625 1415 if test -d "$srcdir/winsup"; then
b76d7de0 1416 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
ac0fa625 1417 elif test -d "$srcdir/newlib"; then
b76d7de0
CV
1418 echo "Warning: winsup is missing so newlib can't be built."
1419 fi
a0da8069
NN
1420
1421 # Can't build gdb for Cygwin if not native.
1422 case "${host}" in
1423 *-*-cygwin*) ;; # keep gdb tcl tk expect etc.
675c6968 1424 *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl libgui gnuserv"
a0da8069
NN
1425 ;;
1426 esac
cac3d6c4 1427 ;;
caeba88f
AL
1428 i[3456789]86-moss-msdos | i[3456789]86-*-moss* | \
1429 i[3456789]86-*-uwin* | i[3456789]86-*-interix* )
caeba88f 1430 ;;
ec11bdc6 1431 i[3456789]86-*-pe)
69e57115 1432 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
a0da8069 1433 ;;
ec11bdc6 1434 i[3456789]86-*-sco3.2v5*)
a0da8069
NN
1435 # The linker does not yet know about weak symbols in COFF,
1436 # and is not configured to handle mixed ELF and COFF.
1437 noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
1438 ;;
ec11bdc6 1439 i[3456789]86-*-sco*)
a0da8069
NN
1440 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1441 ;;
ec11bdc6 1442 i[3456789]86-*-solaris2*)
a0da8069
NN
1443 noconfigdirs="$noconfigdirs target-libgloss"
1444 ;;
ec11bdc6 1445 i[3456789]86-*-sysv4*)
a0da8069
NN
1446 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1447 ;;
ec11bdc6 1448 i[3456789]86-*-beos*)
bba45b8b
NN
1449 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
1450 ;;
b07c2aad 1451 m32r-*-*)
970f29af 1452 noconfigdirs="$noconfigdirs ${libgcj}"
b07c2aad 1453 ;;
a0da8069 1454 m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
b9459e83 1455 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
a0da8069
NN
1456 ;;
1457 m68k-*-elf*)
1458 noconfigdirs="$noconfigdirs ${libgcj}"
1459 ;;
1460 m68k-*-coff*)
1461 noconfigdirs="$noconfigdirs ${libgcj}"
1462 ;;
1463 mcore-*-pe*)
1464 # The EPOC C++ environment does not support exceptions or rtti,
1465 # and so building libstdc++-v3 tends not to always work.
1466 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1467 ;;
1468 mmix-*-*)
59f7ec45 1469 noconfigdirs="$noconfigdirs target-libffi target-boehm-gc gdb libgloss"
096f7d00 1470 unsupported_languages="$unsupported_languages fortran java"
a0da8069
NN
1471 ;;
1472 mn10200-*-*)
1473 noconfigdirs="$noconfigdirs ${libgcj}"
1474 ;;
1475 mn10300-*-*)
1476 noconfigdirs="$noconfigdirs ${libgcj}"
1477 ;;
cdb9b172
AH
1478 ms1-*-*)
1479 noconfigdirs="$noconfigdirs sim"
1480 ;;
a0da8069
NN
1481 powerpc-*-aix*)
1482 # copied from rs6000-*-* entry
096f7d00 1483 noconfigdirs="$noconfigdirs gprof target-libgloss target-libssp ${libgcj}"
a0da8069
NN
1484 ;;
1485 powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
1486 target_configdirs="$target_configdirs target-winsup"
675c6968 1487 noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl gnuserv ${libgcj}"
a0da8069
NN
1488 # always build newlib.
1489 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
1490 ;;
1491 # This is temporary until we can link against shared libraries
1492 powerpcle-*-solaris*)
675c6968 1493 noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl gnuserv ${libgcj}"
a0da8069
NN
1494 ;;
1495 powerpc-*-beos*)
1496 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
1497 ;;
a0da8069 1498 powerpc-*-eabi)
69e57115 1499 noconfigdirs="$noconfigdirs ${libgcj}"
caeba88f
AL
1500 ;;
1501 powerpc-*-eabi* | powerpcle-*-eabi* | powerpc-*-rtems* )
a0da8069 1502 ;;
a0da8069
NN
1503 rs6000-*-lynxos*)
1504 noconfigdirs="$noconfigdirs target-newlib gprof ${libgcj}"
1505 ;;
1506 rs6000-*-aix*)
096f7d00 1507 noconfigdirs="$noconfigdirs gprof target-libgloss target-libssp ${libgcj}"
a0da8069
NN
1508 ;;
1509 rs6000-*-*)
1510 noconfigdirs="$noconfigdirs gprof ${libgcj}"
1511 ;;
1512 m68k-apollo-*)
1513 noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
1514 ;;
1515 mips*-*-irix5*)
0f260896 1516 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
a0da8069
NN
1517 ;;
1518 mips*-*-irix6*)
a0da8069
NN
1519 # Linking libjava exceeds command-line length limits on at least
1520 # IRIX 6.2, but not on IRIX 6.5.
1521 # Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
1522 # <oldham@codesourcery.com>
aa236487 1523 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
a0da8069
NN
1524 ;;
1525 mips*-dec-bsd*)
1526 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1527 ;;
1528 mips*-*-bsd*)
1529 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1530 ;;
1531 mipstx39-*-*)
1532 noconfigdirs="$noconfigdirs gprof ${libgcj}" # same as generic mips
bba45b8b 1533 ;;
1712ab83
RS
1534 mips64*-*-linux*)
1535 noconfigdirs="$noconfigdirs target-newlib ${libgcj}"
1536 ;;
a0da8069
NN
1537 mips*-*-linux*)
1538 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1539 ;;
1540 mips*-*-*)
1541 noconfigdirs="$noconfigdirs gprof ${libgcj}"
1542 ;;
1543 romp-*-*)
1544 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
1545 ;;
dbf85af7 1546 sh-*-* | sh64-*-*)
a0da8069 1547 case "${host}" in
ec11bdc6
DD
1548 i[3456789]86-*-vsta) ;; # don't add gprof back in
1549 i[3456789]86-*-go32*) ;; # don't add gprof back in
1550 i[3456789]86-*-msdosdjgpp*) ;; # don't add gprof back in
a0da8069
NN
1551 *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
1552 esac
1553 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1554 ;;
a0da8069
NN
1555 sparc-*-elf*)
1556 noconfigdirs="$noconfigdirs ${libgcj}"
1557 ;;
1558 sparc64-*-elf*)
1559 noconfigdirs="$noconfigdirs ${libgcj}"
1560 ;;
1561 sparclite-*-*)
1562 noconfigdirs="$noconfigdirs ${libgcj}"
1563 ;;
1564 sparc-*-sunos4*)
1565 noconfigdirs="$noconfigdirs ${libgcj}"
1566 if test x${is_cross_compiler} != xno ; then
1567 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
1568 else
1569 use_gnu_ld=no
1570 fi
1571 ;;
e3c770b1
EB
1572 sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
1573 noconfigdirs="$noconfigdirs ${libgcj}"
1574 ;;
a0da8069
NN
1575 sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
1576 ;;
1577 v810-*-*)
b9459e83 1578 noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libstdc++-v3 opcodes target-libgloss ${libgcj}"
a0da8069
NN
1579 ;;
1580 v850-*-*)
1581 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1582 ;;
1583 v850e-*-*)
1584 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1585 ;;
1586 v850ea-*-*)
1587 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1588 ;;
1589 vax-*-vms)
1590 noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
1591 ;;
1592 vax-*-*)
1593 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1594 ;;
fbd1054d
BW
1595 xtensa-*-*)
1596 noconfigdirs="$noconfigdirs ${libgcj}"
1597 ;;
a0da8069 1598 ip2k-*-*)
b9459e83 1599 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
a0da8069 1600 ;;
de0b4a87 1601 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
a0da8069
NN
1602 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1603 ;;
1604 *-*-lynxos*)
1605 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
cac3d6c4 1606 ;;
a0da8069
NN
1607 *-*-*)
1608 noconfigdirs="$noconfigdirs ${libgcj}"
1609 ;;
1610esac
252b5132 1611
a0da8069
NN
1612# If we aren't building newlib, then don't build libgloss, since libgloss
1613# depends upon some newlib header files.
1614case "${noconfigdirs}" in
1615 *target-libgloss*) ;;
1616 *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
1617esac
1618
a0da8069
NN
1619# Work in distributions that contain no compiler tools, like Autoconf.
1620tentative_cc=""
1621host_makefile_frag=/dev/null
1622if test -d ${srcdir}/config ; then
1623case "${host}" in
1624 m68k-hp-hpux*)
1625 # Avoid "too much defining" errors from HPUX compiler.
1626 tentative_cc="cc -Wp,-H256000"
1627 # If "ar" in $PATH is GNU ar, the symbol table may need rebuilding.
1628 # If it's HP/UX ar, this should be harmless.
1629 RANLIB="ar ts"
1630 ;;
1631 m68k-apollo-sysv*)
1632 tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
1633 ;;
1634 m68k-apollo-bsd*)
1635 #None of the Apollo compilers can compile gas or binutils. The preprocessor
1636 # chokes on bfd, the compiler won't let you assign integers to enums, and
1637 # other problems. Defining CC to gcc is a questionable way to say "don't use
1638 # the apollo compiler" (the preferred version of GCC could be called cc,
1639 # or whatever), but I'm not sure leaving CC as cc is any better...
1640 #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
1641 # Used to have BISON=yacc.
1642 tentative_cc=gcc
1643 ;;
1644 m88k-dg-dgux*)
1645 tentative_cc="gcc -Wall -ansi -D__using_DGUX"
a0da8069
NN
1646 ;;
1647 m88k-harris-cxux*)
1648 # Under CX/UX, we want to tell the compiler to use ANSI mode.
1649 tentative_cc="cc -Xa"
1650 host_makefile_frag="config/mh-cxux"
1651 ;;
1652 m88k-motorola-sysv*)
1653 ;;
1654 mips*-dec-ultrix*)
1655 tentative_cc="cc -Wf,-XNg1000"
1656 host_makefile_frag="config/mh-decstation"
1657 ;;
1658 mips*-nec-sysv4*)
1659 # The C compiler on NEC MIPS SVR4 needs bigger tables.
1660 tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
1661 host_makefile_frag="config/mh-necv4"
1662 ;;
1663 mips*-sgi-irix4*)
1664 # Tell compiler to use K&R C. We can't compile under the SGI Ansi
1665 # environment. Also bump switch table size so that cp-parse will
1666 # compile. Bump string length limit so linker builds.
1667 tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
1668 ;;
1669 mips*-*-sysv4*)
1670 host_makefile_frag="config/mh-sysv4"
1671 ;;
1672 mips*-*-sysv*)
1673 # This is for a MIPS running RISC/os 4.52C.
1674
1675 # This is needed for GDB, but needs to be in the top-level make because
1676 # if a library is compiled with the bsd headers and gets linked with the
1677 # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
1678 # a different size).
1679 # ptrace(2) apparently has problems in the BSD environment. No workaround is
1680 # known except to select the sysv environment. Could we use /proc instead?
1681 # These "sysv environments" and "bsd environments" often end up being a pain.
1682 #
1683 # This is not part of CFLAGS because perhaps not all C compilers have this
1684 # option.
1685 tentative_cc="cc -systype sysv"
1686 ;;
1687 i370-ibm-opened*)
1688 tentative_cc="c89"
1689 ;;
ec11bdc6 1690 i[3456789]86-*-sysv5*)
a0da8069
NN
1691 host_makefile_frag="config/mh-sysv5"
1692 ;;
ec11bdc6 1693 i[3456789]86-*-dgux*)
a0da8069
NN
1694 tentative_cc="gcc -Wall -ansi -D__using_DGUX"
1695 host_makefile_frag="config/mh-dgux386"
1696 ;;
ec11bdc6 1697 i[3456789]86-ncr-sysv4.3*)
a0da8069
NN
1698 # The MetaWare compiler will generate a copyright message unless you
1699 # turn it off by adding the -Hnocopyr flag.
1700 tentative_cc="cc -Hnocopyr"
1701 ;;
ec11bdc6 1702 i[3456789]86-ncr-sysv4*)
a0da8069
NN
1703 # for an NCR 3000 (i486/SVR4) system.
1704 # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
1705 # This compiler not only emits obnoxious copyright messages every time
1706 # you run it, but it chokes and dies on a whole bunch of GNU source
1707 # files. Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
1708 tentative_cc="/usr/ccs/ATT/cc"
1709 host_makefile_frag="config/mh-ncr3000"
1710 ;;
ec11bdc6 1711 i[3456789]86-*-sco3.2v5*)
a0da8069 1712 ;;
ec11bdc6 1713 i[3456789]86-*-sco*)
a0da8069
NN
1714 # The native C compiler botches some simple uses of const. Unfortunately,
1715 # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
1716 tentative_cc="cc -Dconst="
1717 host_makefile_frag="config/mh-sco"
1718 ;;
ec11bdc6 1719 i[3456789]86-*-udk*)
a0da8069
NN
1720 host_makefile_frag="config/mh-sysv5"
1721 ;;
ec11bdc6 1722 i[3456789]86-*-solaris2*)
a0da8069
NN
1723 host_makefile_frag="config/mh-sysv4"
1724 ;;
ec11bdc6 1725 i[3456789]86-*-msdosdjgpp*)
a0da8069
NN
1726 host_makefile_frag="config/mh-djgpp"
1727 ;;
1728 *-cygwin*)
1729 host_makefile_frag="config/mh-cygwin"
1730 ;;
1731 *-mingw32*)
a0da8069
NN
1732 ;;
1733 *-interix*)
1734 host_makefile_frag="config/mh-interix"
1735 ;;
1736 vax-*-ultrix2*)
1737 # The old BSD pcc isn't up to compiling parts of gdb so use gcc
1738 tentative_cc=gcc
1739 ;;
1740 *-*-solaris2*)
1741 host_makefile_frag="config/mh-solaris"
1742 ;;
1743 m68k-sun-sunos*)
1744 # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
1745 # without overflowing the jump tables (-J says to use a 32 bit table)
1746 tentative_cc="cc -J"
1747 ;;
1748 *-hp-hpux*)
1749 tentative_cc="cc -Wp,-H256000"
1750 ;;
1751 *-*-hiux*)
1752 tentative_cc="cc -Wp,-H256000"
1753 ;;
1754 rs6000-*-lynxos*)
1755 # /bin/cc is less than useful for our purposes. Always use GCC
1756 tentative_cc="/usr/cygnus/progressive/bin/gcc"
1757 host_makefile_frag="config/mh-lynxrs6k"
1758 ;;
0df3d27f
PB
1759 powerpc-*-darwin*)
1760 host_makefile_frag="config/mh-ppc-darwin"
1761 ;;
a0da8069
NN
1762 *-*-lynxos*)
1763 # /bin/cc is less than useful for our purposes. Always use GCC
1764 tentative_cc="/bin/gcc"
1765 ;;
1766 *-*-sysv4*)
1767 host_makefile_frag="config/mh-sysv4"
1768 ;;
fe69863c
DD
1769 # This is placed last to prevent interfering with the cases above.
1770 i[3456789]86-*-*)
1771 # Build the stage2 and stage3 compilers with -fomit-frame-pointer.
1772 host_makefile_frag="config/mh-x86omitfp"
1773 ;;
a0da8069
NN
1774esac
1775fi
1776
9e07f89d
NN
1777# If we aren't going to be using gcc, see if we can extract a definition
1778# of CC from the fragment.
1779# Actually, use the 'pre-extracted' version above.
1780if test -z "${CC}" && test "${build}" = "${host}" ; then
1781 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
1782 found=
1783 for dir in $PATH; do
1784 test -z "$dir" && dir=.
1785 if test -f $dir/gcc; then
1786 found=yes
1787 break
1788 fi
1789 done
1790 IFS="$save_ifs"
1791 if test -z "${found}" && test -n "${tentative_cc}" ; then
1792 CC=$tentative_cc
1793 fi
1794fi
1795
1796if test "${build}" != "${host}" ; then
1797 # If we are doing a Canadian Cross, in which the host and build systems
1798 # are not the same, we set reasonable default values for the tools.
1799
9e07f89d
NN
1800 CC=${CC-${host_alias}-gcc}
1801 CFLAGS=${CFLAGS-"-g -O2"}
1802 CXX=${CXX-${host_alias}-c++}
1803 CXXFLAGS=${CXXFLAGS-"-g -O2"}
1804 CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
9e07f89d
NN
1805 BUILD_PREFIX=${build_alias}-
1806 BUILD_PREFIX_1=${build_alias}-
9e07f89d
NN
1807
1808else
1809 # Set reasonable default values for some tools even if not Canadian.
1810 # Of course, these are different reasonable default values, originally
1811 # specified directly in the Makefile.
1812 # We don't export, so that autoconf can do its job.
1813 # Note that all these settings are above the fragment inclusion point
1814 # in Makefile.in, so can still be overridden by fragments.
1815 # This is all going to change when we autoconfiscate...
1816
9e07f89d 1817 CC_FOR_BUILD="\$(CC)"
9e07f89d
NN
1818 BUILD_PREFIX=
1819 BUILD_PREFIX_1=loser-
9e07f89d 1820
6a9cf61e 1821 # Extract the first word of "gcc", so it can be a program name with args.
9e07f89d 1822set dummy gcc; ac_word=$2
cac3d6c4 1823echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 1824echo "configure:1825: checking for $ac_word" >&5
cac3d6c4
CM
1825if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1826 echo $ac_n "(cached) $ac_c" 1>&6
9e07f89d
NN
1827else
1828 if test -n "$CC"; then
1829 ac_cv_prog_CC="$CC" # Let the user override the test.
1830else
cac3d6c4
CM
1831 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1832 ac_dummy="$PATH"
1833 for ac_dir in $ac_dummy; do
1834 test -z "$ac_dir" && ac_dir=.
1835 if test -f $ac_dir/$ac_word; then
1836 ac_cv_prog_CC="gcc"
1837 break
1838 fi
1839 done
1840 IFS="$ac_save_ifs"
9e07f89d
NN
1841fi
1842fi
cac3d6c4 1843CC="$ac_cv_prog_CC"
9e07f89d 1844if test -n "$CC"; then
cac3d6c4 1845 echo "$ac_t""$CC" 1>&6
9e07f89d 1846else
cac3d6c4 1847 echo "$ac_t""no" 1>&6
9e07f89d
NN
1848fi
1849
1850if test -z "$CC"; then
1851 # Extract the first word of "cc", so it can be a program name with args.
1852set dummy cc; ac_word=$2
cac3d6c4 1853echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 1854echo "configure:1855: checking for $ac_word" >&5
cac3d6c4
CM
1855if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1856 echo $ac_n "(cached) $ac_c" 1>&6
9e07f89d
NN
1857else
1858 if test -n "$CC"; then
1859 ac_cv_prog_CC="$CC" # Let the user override the test.
1860else
cac3d6c4 1861 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
9e07f89d 1862 ac_prog_rejected=no
cac3d6c4
CM
1863 ac_dummy="$PATH"
1864 for ac_dir in $ac_dummy; do
1865 test -z "$ac_dir" && ac_dir=.
1866 if test -f $ac_dir/$ac_word; then
1867 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1868 ac_prog_rejected=yes
1869 continue
1870 fi
1871 ac_cv_prog_CC="cc"
1872 break
1873 fi
1874 done
1875 IFS="$ac_save_ifs"
9e07f89d
NN
1876if test $ac_prog_rejected = yes; then
1877 # We found a bogon in the path, so make sure we never use it.
1878 set dummy $ac_cv_prog_CC
1879 shift
cac3d6c4 1880 if test $# -gt 0; then
9e07f89d
NN
1881 # We chose a different compiler from the bogus one.
1882 # However, it has the same basename, so the bogon will be chosen
1883 # first if we set CC to just the basename; use the full file name.
1884 shift
cac3d6c4
CM
1885 set dummy "$ac_dir/$ac_word" "$@"
1886 shift
1887 ac_cv_prog_CC="$@"
9e07f89d
NN
1888 fi
1889fi
1890fi
1891fi
cac3d6c4 1892CC="$ac_cv_prog_CC"
9e07f89d 1893if test -n "$CC"; then
cac3d6c4 1894 echo "$ac_t""$CC" 1>&6
9e07f89d 1895else
cac3d6c4 1896 echo "$ac_t""no" 1>&6
9e07f89d
NN
1897fi
1898
cac3d6c4
CM
1899 if test -z "$CC"; then
1900 case "`uname -s`" in
1901 *win32* | *WIN32*)
1902 # Extract the first word of "cl", so it can be a program name with args.
1903set dummy cl; ac_word=$2
1904echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 1905echo "configure:1906: checking for $ac_word" >&5
cac3d6c4
CM
1906if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1907 echo $ac_n "(cached) $ac_c" 1>&6
9e07f89d
NN
1908else
1909 if test -n "$CC"; then
1910 ac_cv_prog_CC="$CC" # Let the user override the test.
1911else
cac3d6c4
CM
1912 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
1913 ac_dummy="$PATH"
1914 for ac_dir in $ac_dummy; do
1915 test -z "$ac_dir" && ac_dir=.
1916 if test -f $ac_dir/$ac_word; then
1917 ac_cv_prog_CC="cl"
1918 break
1919 fi
1920 done
1921 IFS="$ac_save_ifs"
9e07f89d
NN
1922fi
1923fi
cac3d6c4 1924CC="$ac_cv_prog_CC"
9e07f89d 1925if test -n "$CC"; then
cac3d6c4 1926 echo "$ac_t""$CC" 1>&6
9e07f89d 1927else
cac3d6c4 1928 echo "$ac_t""no" 1>&6
9e07f89d 1929fi
cac3d6c4
CM
1930 ;;
1931 esac
376a0e54 1932 fi
cac3d6c4 1933 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
9e07f89d
NN
1934fi
1935
cac3d6c4 1936echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
bd70a46f 1937echo "configure:1938: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
9e07f89d 1938
cac3d6c4
CM
1939ac_ext=c
1940# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1941ac_cpp='$CPP $CPPFLAGS'
1942ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1943ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1944cross_compiling=$ac_cv_prog_cc_cross
1945
1946cat > conftest.$ac_ext << EOF
1947
bd70a46f 1948#line 1949 "configure"
cac3d6c4
CM
1949#include "confdefs.h"
1950
1951main(){return(0);}
1952EOF
bd70a46f 1953if { (eval echo configure:1954: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
cac3d6c4
CM
1954 ac_cv_prog_cc_works=yes
1955 # If we can't run a trivial program, we are probably using a cross compiler.
1956 if (./conftest; exit) 2>/dev/null; then
1957 ac_cv_prog_cc_cross=no
376a0e54 1958 else
cac3d6c4 1959 ac_cv_prog_cc_cross=yes
376a0e54 1960 fi
cac3d6c4
CM
1961else
1962 echo "configure: failed program was:" >&5
1963 cat conftest.$ac_ext >&5
1964 ac_cv_prog_cc_works=no
9e07f89d 1965fi
cac3d6c4
CM
1966rm -fr conftest*
1967ac_ext=c
1968# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1969ac_cpp='$CPP $CPPFLAGS'
1970ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1971ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1972cross_compiling=$ac_cv_prog_cc_cross
1973
1974echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1975if test $ac_cv_prog_cc_works = no; then
1976 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1977fi
1978echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
bd70a46f 1979echo "configure:1980: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
cac3d6c4
CM
1980echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1981cross_compiling=$ac_cv_prog_cc_cross
1982
1983echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
bd70a46f 1984echo "configure:1985: checking whether we are using GNU C" >&5
cac3d6c4
CM
1985if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1986 echo $ac_n "(cached) $ac_c" 1>&6
1987else
1988 cat > conftest.c <<EOF
1989#ifdef __GNUC__
1990 yes;
1991#endif
1992EOF
bd70a46f 1993if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1994: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
cac3d6c4 1994 ac_cv_prog_gcc=yes
376a0e54 1995else
cac3d6c4
CM
1996 ac_cv_prog_gcc=no
1997fi
1998fi
1999
2000echo "$ac_t""$ac_cv_prog_gcc" 1>&6
2001
2002if test $ac_cv_prog_gcc = yes; then
2003 GCC=yes
9e07f89d 2004else
cac3d6c4
CM
2005 GCC=
2006fi
376a0e54 2007
cac3d6c4
CM
2008ac_test_CFLAGS="${CFLAGS+set}"
2009ac_save_CFLAGS="$CFLAGS"
2010CFLAGS=
2011echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
bd70a46f 2012echo "configure:2013: checking whether ${CC-cc} accepts -g" >&5
cac3d6c4
CM
2013if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
2014 echo $ac_n "(cached) $ac_c" 1>&6
2015else
2016 echo 'void f(){}' > conftest.c
2017if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
9e07f89d
NN
2018 ac_cv_prog_cc_g=yes
2019else
cac3d6c4 2020 ac_cv_prog_cc_g=no
9e07f89d 2021fi
cac3d6c4
CM
2022rm -f conftest*
2023
376a0e54 2024fi
cac3d6c4
CM
2025
2026echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
9e07f89d 2027if test "$ac_test_CFLAGS" = set; then
cac3d6c4 2028 CFLAGS="$ac_save_CFLAGS"
9e07f89d
NN
2029elif test $ac_cv_prog_cc_g = yes; then
2030 if test "$GCC" = yes; then
2031 CFLAGS="-g -O2"
2032 else
2033 CFLAGS="-g"
2034 fi
2035else
2036 if test "$GCC" = yes; then
2037 CFLAGS="-O2"
2038 else
2039 CFLAGS=
2040 fi
2041fi
2042
2043
6a9cf61e
PB
2044 # We must set the default linker to the linker used by gcc for the correct
2045 # operation of libtool. If LD is not defined and we are using gcc, try to
2046 # set the LD default to the ld used by gcc.
2047 if test -z "$LD"; then
2048 if test "$GCC" = yes; then
2049 case $build in
2050 *-*-mingw*)
2051 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
2052 *)
2053 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
2054 esac
2055 case $gcc_prog_ld in
2056 # Accept absolute paths.
2057 [\\/]* | [A-Za-z]:[\\/]*)
2058 LD="$gcc_prog_ld" ;;
2059 esac
2060 fi
2061 fi
2062
2063 CXX=${CXX-"c++"}
2064 CFLAGS=${CFLAGS-"-g"}
2065 CXXFLAGS=${CXXFLAGS-"-g -O2"}
2066fi
2067
cac3d6c4
CM
2068if test $host != $build; then
2069 ac_tool_prefix=${host_alias}-
2070else
2071 ac_tool_prefix=
2072fi
6a9cf61e
PB
2073
2074
9e07f89d 2075
cac3d6c4 2076# Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args.
9e07f89d 2077set dummy ${ac_tool_prefix}gnatbind; ac_word=$2
cac3d6c4 2078echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2079echo "configure:2080: checking for $ac_word" >&5
cac3d6c4
CM
2080if eval "test \"`echo '$''{'ac_cv_prog_GNATBIND'+set}'`\" = set"; then
2081 echo $ac_n "(cached) $ac_c" 1>&6
9e07f89d
NN
2082else
2083 if test -n "$GNATBIND"; then
2084 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
2085else
cac3d6c4
CM
2086 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2087 ac_dummy="$PATH"
2088 for ac_dir in $ac_dummy; do
2089 test -z "$ac_dir" && ac_dir=.
2090 if test -f $ac_dir/$ac_word; then
2091 ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind"
2092 break
2093 fi
2094 done
2095 IFS="$ac_save_ifs"
9e07f89d
NN
2096fi
2097fi
cac3d6c4 2098GNATBIND="$ac_cv_prog_GNATBIND"
9e07f89d 2099if test -n "$GNATBIND"; then
cac3d6c4 2100 echo "$ac_t""$GNATBIND" 1>&6
9e07f89d 2101else
cac3d6c4 2102 echo "$ac_t""no" 1>&6
9e07f89d
NN
2103fi
2104
cac3d6c4 2105
9e07f89d 2106if test -z "$ac_cv_prog_GNATBIND"; then
cac3d6c4 2107if test -n "$ac_tool_prefix"; then
9e07f89d
NN
2108 # Extract the first word of "gnatbind", so it can be a program name with args.
2109set dummy gnatbind; ac_word=$2
cac3d6c4 2110echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2111echo "configure:2112: checking for $ac_word" >&5
cac3d6c4
CM
2112if eval "test \"`echo '$''{'ac_cv_prog_GNATBIND'+set}'`\" = set"; then
2113 echo $ac_n "(cached) $ac_c" 1>&6
9e07f89d 2114else
cac3d6c4
CM
2115 if test -n "$GNATBIND"; then
2116 ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
9e07f89d 2117else
cac3d6c4
CM
2118 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2119 ac_dummy="$PATH"
2120 for ac_dir in $ac_dummy; do
2121 test -z "$ac_dir" && ac_dir=.
2122 if test -f $ac_dir/$ac_word; then
2123 ac_cv_prog_GNATBIND="gnatbind"
2124 break
2125 fi
2126 done
2127 IFS="$ac_save_ifs"
2128 test -z "$ac_cv_prog_GNATBIND" && ac_cv_prog_GNATBIND="no"
9e07f89d
NN
2129fi
2130fi
cac3d6c4
CM
2131GNATBIND="$ac_cv_prog_GNATBIND"
2132if test -n "$GNATBIND"; then
2133 echo "$ac_t""$GNATBIND" 1>&6
9e07f89d 2134else
cac3d6c4 2135 echo "$ac_t""no" 1>&6
9e07f89d
NN
2136fi
2137
2138else
cac3d6c4
CM
2139 GNATBIND="no"
2140fi
9e07f89d
NN
2141fi
2142
cac3d6c4 2143echo $ac_n "checking whether compiler driver understands Ada""... $ac_c" 1>&6
bd70a46f 2144echo "configure:2145: checking whether compiler driver understands Ada" >&5
cac3d6c4
CM
2145if eval "test \"`echo '$''{'acx_cv_cc_gcc_supports_ada'+set}'`\" = set"; then
2146 echo $ac_n "(cached) $ac_c" 1>&6
9e07f89d
NN
2147else
2148 cat >conftest.adb <<EOF
2149procedure conftest is begin null; end conftest;
2150EOF
2151acx_cv_cc_gcc_supports_ada=no
2152# There is a bug in old released versions of GCC which causes the
2153# driver to exit successfully when the appropriate language module
2154# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
2155# Therefore we must check for the error message as well as an
2156# unsuccessful exit.
b8908782
DD
2157# Other compilers, like HP Tru64 UNIX cc, exit successfully when
2158# given a .adb file, but produce no object file. So we must check
2159# if an object file was really produced to guard against this.
9e07f89d 2160errors=`(${CC} -c conftest.adb) 2>&1 || echo failure`
b8908782 2161if test x"$errors" = x && test -f conftest.$ac_objext; then
9e07f89d 2162 acx_cv_cc_gcc_supports_ada=yes
9e07f89d
NN
2163fi
2164rm -f conftest.*
2165fi
cac3d6c4
CM
2166
2167echo "$ac_t""$acx_cv_cc_gcc_supports_ada" 1>&6
9e07f89d 2168
b8908782 2169if test x$GNATBIND != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
9e07f89d
NN
2170 have_gnat=yes
2171else
2172 have_gnat=no
2173fi
2174
cac3d6c4 2175echo $ac_n "checking how to compare bootstrapped objects""... $ac_c" 1>&6
bd70a46f 2176echo "configure:2177: checking how to compare bootstrapped objects" >&5
cac3d6c4
CM
2177if eval "test \"`echo '$''{'gcc_cv_prog_cmp_skip'+set}'`\" = set"; then
2178 echo $ac_n "(cached) $ac_c" 1>&6
b8908782
DD
2179else
2180 echo abfoo >t1
2181 echo cdfoo >t2
2182 gcc_cv_prog_cmp_skip='tail +16c $$f1 > tmp-foo1; tail +16c $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
4b1cb4fe
DD
2183 if cmp t1 t2 2 2 > /dev/null 2>&1; then
2184 if cmp t1 t2 1 1 > /dev/null 2>&1; then
2185 :
2186 else
2187 gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
2188 fi
2189 fi
b8908782
DD
2190 if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
2191 if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
4b1cb4fe 2192 :
b8908782
DD
2193 else
2194 gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
2195 fi
2196 fi
2197 rm t1 t2
2198
2199fi
cac3d6c4
CM
2200
2201echo "$ac_t""$gcc_cv_prog_cmp_skip" 1>&6
b8908782
DD
2202do_compare="$gcc_cv_prog_cmp_skip"
2203
2204
9e07f89d 2205
11b04d1f 2206# Check for GMP and MPFR
4b1cb4fe
DD
2207gmplibs=
2208gmpinc=
2209have_gmp=yes
11b04d1f
DD
2210# Specify a location for mpfr
2211# check for this first so it ends up on the link line before gmp.
2212# Check whether --with-mpfr-dir or --without-mpfr-dir was given.
2213if test "${with_mpfr_dir+set}" = set; then
2214 withval="$with_mpfr_dir"
cac3d6c4
CM
2215 :
2216fi
11b04d1f
DD
2217
2218
2219if test "x$with_mpfr_dir" != x; then
c10e9ba7 2220 gmpinc="-I$with_mpfr_dir"
11b04d1f
DD
2221 gmplibs="$with_mpfr_dir/libmpfr.a"
2222else
2223 gmplibs="-lmpfr"
2224fi
2225
2226# Check whether --with-mpfr or --without-mpfr was given.
2227if test "${with_mpfr+set}" = set; then
2228 withval="$with_mpfr"
cac3d6c4
CM
2229 :
2230fi
11b04d1f
DD
2231
2232
2233if test "x$with_mpfr" != x; then
2234 gmplibs="-L$with_mpfr/lib $gmplibs"
2235 gmpinc="-I$with_mpfr/include"
2236fi
2237
4b1cb4fe
DD
2238# Specify a location for gmp
2239# Check whether --with-gmp-dir or --without-gmp-dir was given.
2240if test "${with_gmp_dir+set}" = set; then
2241 withval="$with_gmp_dir"
cac3d6c4
CM
2242 :
2243fi
4b1cb4fe
DD
2244
2245
11b04d1f
DD
2246if test "x$with_gmp_dir" != x; then
2247 gmpinc="$gmpinc -I$with_gmp_dir"
4b1cb4fe 2248 if test -f "$with_gmp_dir/.libs/libgmp.a"; then
11b04d1f 2249 gmplibs="$gmplibs $with_gmp_dir/.libs/libgmp.a"
4b1cb4fe 2250 elif test -f "$with_gmp_dir/_libs/libgmp.a"; then
11b04d1f 2251 gmplibs="$gmplibs $with_gmp_dir/_libs/libgmp.a"
4b1cb4fe
DD
2252 fi
2253 # One of the later tests will catch the error if neither library is present.
11b04d1f
DD
2254else
2255 gmplibs="$gmplibs -lgmp"
4b1cb4fe
DD
2256fi
2257
2258# Check whether --with-gmp or --without-gmp was given.
2259if test "${with_gmp+set}" = set; then
2260 withval="$with_gmp"
cac3d6c4
CM
2261 :
2262fi
4b1cb4fe
DD
2263
2264
11b04d1f
DD
2265if test "x$with_gmp" != x; then
2266 gmplibs="-L$with_gmp/lib $gmplibs"
2267 gmpinc="-I$with_gmp/include $gmpinc"
4b1cb4fe
DD
2268fi
2269
2270saved_CFLAGS="$CFLAGS"
2271CFLAGS="$CFLAGS $gmpinc"
2272# Check GMP actually works
cac3d6c4 2273echo $ac_n "checking for correct version of gmp.h""... $ac_c" 1>&6
bd70a46f 2274echo "configure:2275: checking for correct version of gmp.h" >&5
cac3d6c4 2275cat > conftest.$ac_ext <<EOF
bd70a46f 2276#line 2277 "configure"
cac3d6c4 2277#include "confdefs.h"
4b1cb4fe 2278#include "gmp.h"
cac3d6c4 2279int main() {
4b1cb4fe
DD
2280
2281#if __GNU_MP_VERSION < 3
2282choke me
2283#endif
2284
cac3d6c4
CM
2285; return 0; }
2286EOF
bd70a46f 2287if { (eval echo configure:2288: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
cac3d6c4
CM
2288 rm -rf conftest*
2289 echo "$ac_t""yes" 1>&6
2290else
2291 echo "configure: failed program was:" >&5
2292 cat conftest.$ac_ext >&5
2293 rm -rf conftest*
2294 echo "$ac_t""no" 1>&6; have_gmp=no
2295fi
2296rm -f conftest*
4b1cb4fe
DD
2297
2298if test x"$have_gmp" = xyes; then
cac3d6c4 2299 echo $ac_n "checking for MPFR""... $ac_c" 1>&6
bd70a46f 2300echo "configure:2301: checking for MPFR" >&5
4b1cb4fe
DD
2301
2302 saved_LIBS="$LIBS"
2303 LIBS="$LIBS $gmplibs"
cac3d6c4 2304 cat > conftest.$ac_ext <<EOF
bd70a46f 2305#line 2306 "configure"
cac3d6c4 2306#include "confdefs.h"
4b1cb4fe 2307#include <gmp.h>
11b04d1f 2308#include <mpfr.h>
cac3d6c4 2309int main() {
11b04d1f 2310mpfr_t n; mpfr_init(n);
cac3d6c4
CM
2311; return 0; }
2312EOF
bd70a46f 2313if { (eval echo configure:2314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
cac3d6c4
CM
2314 rm -rf conftest*
2315 echo "$ac_t""yes" 1>&6
2316else
2317 echo "configure: failed program was:" >&5
2318 cat conftest.$ac_ext >&5
2319 rm -rf conftest*
2320 echo "$ac_t""no" 1>&6; have_gmp=no
2321fi
2322rm -f conftest*
4b1cb4fe
DD
2323 LIBS="$saved_LIBS"
2324 CFLAGS="$saved_CFLAGS"
2325fi
2326
11b04d1f 2327# Flags needed for both GMP and/or MPFR
4b1cb4fe
DD
2328
2329
2330
947f426e 2331# By default, C is the only stage 1 language.
1d39f329
NN
2332stage1_languages=c
2333
2334
9e07f89d
NN
2335# Figure out what language subdirectories are present.
2336# Look if the user specified --enable-languages="..."; if not, use
2337# the environment variable $LANGUAGES if defined. $LANGUAGES might
2338# go away some day.
2339# NB: embedded tabs in this IF block -- do not untabify
2340if test -d ${srcdir}/gcc; then
2341 if test x"${enable_languages+set}" != xset; then
2342 if test x"${LANGUAGES+set}" = xset; then
2343 enable_languages="${LANGUAGES}"
2344 echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
2345 else
2346 enable_languages=all
2347 fi
2348 else
2349 if test x"${enable_languages}" = x ||
2350 test x"${enable_languages}" = xyes;
2351 then
2352 echo configure.in: --enable-languages needs at least one language argument 1>&2
2353 exit 1
2354 fi
2355 fi
2356 enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
2357
096f7d00
DE
2358 # 'f95' is the old name for the 'fortran' language. We issue a warning
2359 # and make the substitution.
2360 case ,${enable_languages}, in
2361 *,f95,*)
2362 echo configure.in: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
2363 enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
2364 ;;
2365 esac
2366
9e07f89d
NN
2367 # First scan to see if an enabled language requires some other language.
2368 # We assume that a given config-lang.in will list all the language
2369 # front ends it requires, even if some are required indirectly.
2370 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
2371 case ${lang_frag} in
2372 ..) ;;
2373 # The odd quoting in the next line works around
2374 # an apparent bug in bash 1.12 on linux.
2375 ${srcdir}/gcc/[*]/config-lang.in) ;;
2376 *)
2377 # From the config-lang.in, get $language, $lang_requires
2378 language=
2379 lang_requires=
2380 . ${lang_frag}
2381 for other in ${lang_requires} ; do
2382 case ,${enable_languages}, in
2383 *,$other,*) ;;
2384 *,all,*) ;;
2385 *,$language,*)
2386 echo " \`$other' language required by \`$language'; enabling" 1>&2
2387 enable_languages="${enable_languages},${other}"
2388 ;;
2389 esac
2390 done
2391 ;;
2392 esac
2393 done
2394
2395 new_enable_languages=c
2396 missing_languages=`echo ",$enable_languages," | sed -e s/,all,/,/ -e s/,c,/,/ `
9cb3fa6f 2397 potential_languages=c
9e07f89d
NN
2398
2399 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
2400 case ${lang_frag} in
2401 ..) ;;
2402 # The odd quoting in the next line works around
2403 # an apparent bug in bash 1.12 on linux.
2404 ${srcdir}/gcc/[*]/config-lang.in) ;;
2405 *)
cac3d6c4 2406 # From the config-lang.in, get $language, $target_libs,
1d39f329 2407 # $lang_dirs, $boot_language, and $build_by_default
9e07f89d
NN
2408 language=
2409 target_libs=
2410 lang_dirs=
1d39f329 2411 boot_language=
9e07f89d 2412 build_by_default=
9cb3fa6f 2413 need_gmp=
9e07f89d 2414 . ${lang_frag}
9cb3fa6f 2415 potential_languages="${potential_languages},${language}"
9e07f89d
NN
2416 # This is quite sensitive to the ordering of the case statement arms.
2417 case ,${enable_languages},:${language}:${have_gnat}:${build_by_default} in
2418 *::*:*)
2419 echo "${lang_frag} doesn't set \$language." 1>&2
2420 exit 1
9cb3fa6f 2421 ;;
9e07f89d
NN
2422 *:ada:no:*)
2423 # Ada was requested with no preexisting GNAT. Disable unconditionally.
2424 add_this_lang=no
2425 ;;
2426 *,${language},*:*:*:*)
2427 # Language was explicitly selected; include it.
2428 add_this_lang=yes
2429 ;;
2430 *,all,*:*:*:no)
2431 # 'all' was selected, but this is not a default language
9cb3fa6f 2432 # so do not include it.
9e07f89d 2433 add_this_lang=no
9cb3fa6f 2434 ;;
9e07f89d
NN
2435 *,all,*:*:*:*)
2436 # 'all' was selected and this is a default language; include it.
2437 add_this_lang=yes
2438 ;;
2439 *)
2440 add_this_lang=no
2441 ;;
2442 esac
4b1cb4fe 2443
9cb3fa6f
PB
2444 # Disable languages that need GMP if it isn't available.
2445 case ,${enable_languages},:${have_gmp}:${need_gmp} in
2446 *,${language},*:no:yes)
2447 # Specifically requested language; tell them.
cac3d6c4 2448 { echo "configure: error: GMP with MPFR support is required to build $language" 1>&2; exit 1; }
9cb3fa6f
PB
2449 ;;
2450 *:no:yes)
2451 # Silently disable.
2452 add_this_lang=no
2453 ;;
2454 esac
59f7ec45
HPN
2455
2456 # Disable a language that is unsupported by the target.
2457 case " $unsupported_languages " in
2458 *" $language "*)
2459 add_this_lang=no
2460 ;;
2461 esac
2462
4b1cb4fe 2463 case $add_this_lang in
9e07f89d
NN
2464 no)
2465 # Remove language-dependent dirs.
1d39f329
NN
2466 eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
2467 ;;
9e07f89d
NN
2468 *)
2469 new_enable_languages="$new_enable_languages,$language"
1d39f329
NN
2470 missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
2471 case ${boot_language} in
2472 yes)
4fa63067
NN
2473 # Add to (comma-separated) list of stage 1 languages.
2474 stage1_languages="${stage1_languages},${language}"
1d39f329
NN
2475 ;;
2476 esac
2477 ;;
9e07f89d
NN
2478 esac
2479 ;;
2480 esac
2481 done
2482
4b0ac75d 2483 missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
9e07f89d 2484 if test "x$missing_languages" != x; then
cac3d6c4 2485 { echo "configure: error:
27258dd4 2486The following requested languages could not be built: ${missing_languages}
cac3d6c4 2487Recognised languages are: ${potential_languages}" 1>&2; exit 1; }
9e07f89d
NN
2488 fi
2489
2490 if test "x$new_enable_languages" != "x$enable_languages"; then
2491 echo The following languages will be built: ${new_enable_languages}
2492 fi
2493 enable_languages="$new_enable_languages"
2e70b094 2494 ac_configure_args=`echo " $ac_configure_args" | sed -e 's/ --enable-languages=[^ ]*//' -e 's/$/ --enable-languages='"$enable_languages"/ `
9e07f89d
NN
2495fi
2496
caeba88f
AL
2497# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
2498# $build_configdirs and $target_configdirs.
9e07f89d
NN
2499# If we have the source for $noconfigdirs entries, add them to $notsupp.
2500
2501notsupp=""
2502for dir in . $skipdirs $noconfigdirs ; do
caeba88f 2503 dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
9e07f89d
NN
2504 if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2505 configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
2506 if test -r $srcdir/$dirname/configure ; then
2507 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2508 true
2509 else
2510 notsupp="$notsupp $dir"
2511 fi
2512 fi
2513 fi
caeba88f
AL
2514 if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2515 build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
2516 if test -r $srcdir/$dirname/configure ; then
2517 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2518 true
2519 else
2520 notsupp="$notsupp $dir"
2521 fi
2522 fi
2523 fi
9e07f89d
NN
2524 if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2525 target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
2526 if test -r $srcdir/$dirname/configure ; then
2527 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2528 true
2529 else
2530 notsupp="$notsupp $dir"
2531 fi
2532 fi
2533 fi
2534done
2535
2536# Sometimes the tools are distributed with libiberty but with no other
2537# libraries. In that case, we don't want to build target-libiberty.
2538if test -n "${target_configdirs}" ; then
2539 others=
2540 for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
2541 if test "$i" != "libiberty" ; then
2542 if test -r $srcdir/$i/configure ; then
2543 others=yes;
2544 break;
2545 fi
2546 fi
2547 done
2548 if test -z "${others}" ; then
2549 target_configdirs=
2550 fi
2551fi
2552
2553# Quietly strip out all directories which aren't configurable in this tree.
2554# This relies on all configurable subdirectories being autoconfiscated, which
2555# is now the case.
6a9cf61e
PB
2556build_configdirs_all="$build_configdirs"
2557build_configdirs=
2558for i in ${build_configdirs_all} ; do
cac3d6c4 2559 j=`echo $i | sed -e s/build-//g`
6a9cf61e
PB
2560 if test -f ${srcdir}/$j/configure ; then
2561 build_configdirs="${build_configdirs} $i"
2562 fi
2563done
2564
9e07f89d
NN
2565configdirs_all="$configdirs"
2566configdirs=
2567for i in ${configdirs_all} ; do
2568 if test -f ${srcdir}/$i/configure ; then
2569 configdirs="${configdirs} $i"
2570 fi
2571done
6a9cf61e 2572
9e07f89d
NN
2573target_configdirs_all="$target_configdirs"
2574target_configdirs=
2575for i in ${target_configdirs_all} ; do
cac3d6c4 2576 j=`echo $i | sed -e s/target-//g`
9e07f89d
NN
2577 if test -f ${srcdir}/$j/configure ; then
2578 target_configdirs="${target_configdirs} $i"
2579 fi
2580done
2581
2582# Produce a warning message for the subdirs we can't configure.
2583# This isn't especially interesting in the Cygnus tree, but in the individual
2584# FSF releases, it's important to let people know when their machine isn't
2585# supported by the one or two programs in a package.
2586
2587if test -n "${notsupp}" && test -z "${norecursion}" ; then
2588 # If $appdirs is non-empty, at least one of those directories must still
2589 # be configured, or we error out. (E.g., if the gas release supports a
2590 # specified target in some subdirs but not the gas subdir, we shouldn't
2591 # pretend that all is well.)
2592 if test -n "$appdirs" ; then
2593 for dir in $appdirs ; do
2594 if test -r $dir/Makefile.in ; then
2595 if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
2596 appdirs=""
2597 break
2598 fi
6a9cf61e 2599 if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
9e07f89d
NN
2600 appdirs=""
2601 break
2602 fi
2603 fi
2604 done
2605 if test -n "$appdirs" ; then
2606 echo "*** This configuration is not supported by this package." 1>&2
2607 exit 1
2608 fi
2609 fi
2610 # Okay, some application will build, or we don't care to check. Still
2611 # notify of subdirs not getting built.
2612 echo "*** This configuration is not supported in the following subdirectories:" 1>&2
2613 echo " ${notsupp}" 1>&2
2614 echo " (Any other directories should still work fine.)" 1>&2
2615fi
2616
2617case "$host" in
2618 *msdosdjgpp*)
2619 enable_gdbtk=no ;;
2620esac
2621
2622copy_dirs=
2623
a19b6204
MM
2624# Check whether --with-build-sysroot or --without-build-sysroot was given.
2625if test "${with_build_sysroot+set}" = set; then
2626 withval="$with_build_sysroot"
2627 if test x"$withval" != x ; then
2628 SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
2629 fi
2630else
2631 SYSROOT_CFLAGS_FOR_TARGET=
cac3d6c4
CM
2632fi
2633
a19b6204
MM
2634
2635
9e07f89d
NN
2636# Handle --with-headers=XXX. If the value is not "yes", the contents of
2637# the named directory are copied to $(tooldir)/sys-include.
2638if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
2639 if test x${is_cross_compiler} = xno ; then
2640 echo 1>&2 '***' --with-headers is only supported when cross compiling
2641 exit 1
2642 fi
2643 if test x"${with_headers}" != xyes ; then
2644 case "${exec_prefixoption}" in
2645 "") x=${prefix} ;;
2646 *) x=${exec_prefix} ;;
2647 esac
2648 copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
2649 fi
2650fi
2651
2652# Handle --with-libs=XXX. If the value is not "yes", the contents of
2653# the name directories are copied to $(tooldir)/lib. Multiple directories
2654# are permitted.
2655if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
2656 if test x${is_cross_compiler} = xno ; then
2657 echo 1>&2 '***' --with-libs is only supported when cross compiling
2658 exit 1
2659 fi
2660 if test x"${with_libs}" != xyes ; then
2661 # Copy the libraries in reverse order, so that files in the first named
2662 # library override files in subsequent libraries.
2663 case "${exec_prefixoption}" in
2664 "") x=${prefix} ;;
2665 *) x=${exec_prefix} ;;
2666 esac
2667 for l in ${with_libs}; do
2668 copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
2669 done
2670 fi
2671fi
2672
2673# Handle ${copy_dirs}
2674set fnord ${copy_dirs}
2675shift
2676while test $# != 0 ; do
2677 if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
2678 :
2679 else
2680 echo Copying $1 to $2
2681
2682 # Use the install script to create the directory and all required
2683 # parent directories.
2684 if test -d $2 ; then
2685 :
2686 else
2687 echo >config.temp
2688 ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
2689 fi
2690
2691 # Copy the directory, assuming we have tar.
2692 # FIXME: Should we use B in the second tar? Not all systems support it.
2693 (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
2694
2695 # It is the responsibility of the user to correctly adjust all
2696 # symlinks. If somebody can figure out how to handle them correctly
2697 # here, feel free to add the code.
2698
2699 echo $1 > $2/COPIED
2700 fi
2701 shift; shift
2702done
2703
a0da8069
NN
2704extra_arflags_for_target=
2705extra_nmflags_for_target=
2706extra_ranlibflags_for_target=
2707target_makefile_frag=/dev/null
2708case "${target}" in
2a3124ca 2709 *-*-netware*)
a0da8069
NN
2710 target_makefile_frag="config/mt-netware"
2711 ;;
3d6dfe0f
NN
2712 *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu)
2713 target_makefile_frag="config/mt-gnu"
a0da8069
NN
2714 ;;
2715 *-*-aix4.[3456789]* | *-*-aix[56789].*)
cac3d6c4 2716 # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
a0da8069
NN
2717 # commands to handle both 32-bit and 64-bit objects. These flags are
2718 # harmless if we're using GNU nm or ar.
2719 extra_arflags_for_target=" -X32_64"
2720 extra_nmflags_for_target=" -B -X32_64"
2721 ;;
2722 *-*-darwin*)
2723 # ranlib from Darwin requires the -c flag to look at common symbols.
2724 extra_ranlibflags_for_target=" -c"
2725 ;;
2726 mips*-*-pe | sh*-*-pe | *arm-wince-pe)
2727 target_makefile_frag="config/mt-wince"
2728 ;;
2729esac
2730
2731alphaieee_frag=/dev/null
2732case $target in
2733 alpha*-*-*)
2734 # This just makes sure to use the -mieee option to build target libs.
2735 # This should probably be set individually by each library.
2736 alphaieee_frag="config/mt-alphaieee"
2737 ;;
2738esac
2739
2740# If --enable-target-optspace always use -Os instead of -O2 to build
2741# the target libraries, similarly if it is not specified, use -Os
2742# on selected platforms.
2743ospace_frag=/dev/null
2744case "${enable_target_optspace}:${target}" in
2745 yes:*)
2746 ospace_frag="config/mt-ospace"
2747 ;;
2748 :d30v-*)
2749 ospace_frag="config/mt-d30v"
2750 ;;
2751 :m32r-* | :d10v-* | :fr30-*)
2752 ospace_frag="config/mt-ospace"
2753 ;;
2754 no:* | :*)
2755 ;;
2756 *)
2757 echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
2758 ;;
2759esac
2760
2761# Set with_gnu_as and with_gnu_ld as appropriate.
2762#
2763# This is done by determining whether or not the appropriate directory
2764# is available, and by checking whether or not specific configurations
2765# have requested that this magic not happen.
cac3d6c4
CM
2766#
2767# The command line options always override the explicit settings in
a0da8069
NN
2768# configure.in, and the settings in configure.in override this magic.
2769#
cac3d6c4 2770# If the default for a toolchain is to use GNU as and ld, and you don't
a0da8069
NN
2771# want to do that, then you should use the --without-gnu-as and
2772# --without-gnu-ld options for the configure script.
2773
2774if test x${use_gnu_as} = x &&
2775 echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
2776 with_gnu_as=yes
2777 extra_host_args="$extra_host_args --with-gnu-as"
2778fi
2779
2780if test x${use_gnu_ld} = x &&
2781 echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
2782 with_gnu_ld=yes
2783 extra_host_args="$extra_host_args --with-gnu-ld"
2784fi
2785
2786# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
2787# can detect this case.
2788
2789if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
2790 with_newlib=yes
2791 extra_host_args="$extra_host_args --with-newlib"
2792fi
2793
a0da8069
NN
2794# Default to using --with-stabs for certain targets.
2795if test x${with_stabs} = x ; then
2796 case "${target}" in
e31d1ea3 2797 mips*-*-irix[56]*)
a0da8069
NN
2798 ;;
2799 mips*-*-* | alpha*-*-osf*)
2800 with_stabs=yes;
2801 extra_host_args="${extra_host_args} --with-stabs"
2802 ;;
2803 esac
2804fi
2805
2806# hpux11 in 64bit mode has libraries in a weird place. Arrange to find
2807# them automatically.
2808case "${host}" in
cac3d6c4 2809 hppa*64*-*-hpux11*)
a0da8069
NN
2810 extra_host_args="$extra_host_args -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
2811 ;;
2812esac
2813
a0da8069
NN
2814# Some systems (e.g., one of the i386-aix systems the gas testers are
2815# using) don't handle "\$" correctly, so don't use it here.
61fa5f72 2816tooldir='${exec_prefix}'/${target_alias}
a0da8069
NN
2817build_tooldir=${tooldir}
2818
6a9cf61e
PB
2819# Generate default definitions for YACC, M4, LEX and other programs that run
2820# on the build machine. These are used if the Makefile can't locate these
2821# programs in objdir.
947f426e 2822MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
6a9cf61e
PB
2823for ac_prog in bison
2824do
cac3d6c4 2825# Extract the first word of "$ac_prog", so it can be a program name with args.
6a9cf61e 2826set dummy $ac_prog; ac_word=$2
cac3d6c4 2827echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2828echo "configure:2829: checking for $ac_word" >&5
cac3d6c4
CM
2829if eval "test \"`echo '$''{'ac_cv_prog_CONFIGURED_BISON'+set}'`\" = set"; then
2830 echo $ac_n "(cached) $ac_c" 1>&6
6a9cf61e
PB
2831else
2832 if test -n "$CONFIGURED_BISON"; then
2833 ac_cv_prog_CONFIGURED_BISON="$CONFIGURED_BISON" # Let the user override the test.
2834else
cac3d6c4
CM
2835 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2836 ac_dummy="$PATH"
2837 for ac_dir in $ac_dummy; do
2838 test -z "$ac_dir" && ac_dir=.
2839 if test -f $ac_dir/$ac_word; then
2840 ac_cv_prog_CONFIGURED_BISON="$ac_prog"
2841 break
2842 fi
2843 done
2844 IFS="$ac_save_ifs"
6a9cf61e
PB
2845fi
2846fi
cac3d6c4 2847CONFIGURED_BISON="$ac_cv_prog_CONFIGURED_BISON"
6a9cf61e 2848if test -n "$CONFIGURED_BISON"; then
cac3d6c4 2849 echo "$ac_t""$CONFIGURED_BISON" 1>&6
6a9cf61e 2850else
cac3d6c4 2851 echo "$ac_t""no" 1>&6
6a9cf61e
PB
2852fi
2853
cac3d6c4 2854test -n "$CONFIGURED_BISON" && break
6a9cf61e
PB
2855done
2856test -n "$CONFIGURED_BISON" || CONFIGURED_BISON="$MISSING bison"
2857
947f426e 2858for ac_prog in 'bison -y' byacc yacc
a0da8069 2859do
cac3d6c4 2860# Extract the first word of "$ac_prog", so it can be a program name with args.
947f426e 2861set dummy $ac_prog; ac_word=$2
cac3d6c4 2862echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2863echo "configure:2864: checking for $ac_word" >&5
cac3d6c4
CM
2864if eval "test \"`echo '$''{'ac_cv_prog_CONFIGURED_YACC'+set}'`\" = set"; then
2865 echo $ac_n "(cached) $ac_c" 1>&6
947f426e 2866else
6a9cf61e
PB
2867 if test -n "$CONFIGURED_YACC"; then
2868 ac_cv_prog_CONFIGURED_YACC="$CONFIGURED_YACC" # Let the user override the test.
947f426e 2869else
cac3d6c4
CM
2870 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2871 ac_dummy="$PATH"
2872 for ac_dir in $ac_dummy; do
2873 test -z "$ac_dir" && ac_dir=.
2874 if test -f $ac_dir/$ac_word; then
2875 ac_cv_prog_CONFIGURED_YACC="$ac_prog"
2876 break
2877 fi
2878 done
2879 IFS="$ac_save_ifs"
947f426e
NN
2880fi
2881fi
cac3d6c4 2882CONFIGURED_YACC="$ac_cv_prog_CONFIGURED_YACC"
6a9cf61e 2883if test -n "$CONFIGURED_YACC"; then
cac3d6c4 2884 echo "$ac_t""$CONFIGURED_YACC" 1>&6
947f426e 2885else
cac3d6c4 2886 echo "$ac_t""no" 1>&6
947f426e 2887fi
a0da8069 2888
cac3d6c4 2889test -n "$CONFIGURED_YACC" && break
a0da8069 2890done
6a9cf61e 2891test -n "$CONFIGURED_YACC" || CONFIGURED_YACC="$MISSING bison -y"
a0da8069 2892
947f426e 2893for ac_prog in gm4 gnum4 m4
a0da8069 2894do
cac3d6c4 2895# Extract the first word of "$ac_prog", so it can be a program name with args.
947f426e 2896set dummy $ac_prog; ac_word=$2
cac3d6c4 2897echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2898echo "configure:2899: checking for $ac_word" >&5
cac3d6c4
CM
2899if eval "test \"`echo '$''{'ac_cv_prog_CONFIGURED_M4'+set}'`\" = set"; then
2900 echo $ac_n "(cached) $ac_c" 1>&6
6a9cf61e
PB
2901else
2902 if test -n "$CONFIGURED_M4"; then
2903 ac_cv_prog_CONFIGURED_M4="$CONFIGURED_M4" # Let the user override the test.
2904else
cac3d6c4
CM
2905 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2906 ac_dummy="$PATH"
2907 for ac_dir in $ac_dummy; do
2908 test -z "$ac_dir" && ac_dir=.
2909 if test -f $ac_dir/$ac_word; then
2910 ac_cv_prog_CONFIGURED_M4="$ac_prog"
2911 break
2912 fi
2913 done
2914 IFS="$ac_save_ifs"
6a9cf61e
PB
2915fi
2916fi
cac3d6c4 2917CONFIGURED_M4="$ac_cv_prog_CONFIGURED_M4"
6a9cf61e 2918if test -n "$CONFIGURED_M4"; then
cac3d6c4 2919 echo "$ac_t""$CONFIGURED_M4" 1>&6
6a9cf61e 2920else
cac3d6c4 2921 echo "$ac_t""no" 1>&6
6a9cf61e
PB
2922fi
2923
cac3d6c4 2924test -n "$CONFIGURED_M4" && break
6a9cf61e
PB
2925done
2926test -n "$CONFIGURED_M4" || CONFIGURED_M4="$MISSING m4"
2927
2928for ac_prog in flex
2929do
cac3d6c4 2930# Extract the first word of "$ac_prog", so it can be a program name with args.
6a9cf61e 2931set dummy $ac_prog; ac_word=$2
cac3d6c4 2932echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2933echo "configure:2934: checking for $ac_word" >&5
cac3d6c4
CM
2934if eval "test \"`echo '$''{'ac_cv_prog_CONFIGURED_FLEX'+set}'`\" = set"; then
2935 echo $ac_n "(cached) $ac_c" 1>&6
947f426e 2936else
6a9cf61e
PB
2937 if test -n "$CONFIGURED_FLEX"; then
2938 ac_cv_prog_CONFIGURED_FLEX="$CONFIGURED_FLEX" # Let the user override the test.
947f426e 2939else
cac3d6c4
CM
2940 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2941 ac_dummy="$PATH"
2942 for ac_dir in $ac_dummy; do
2943 test -z "$ac_dir" && ac_dir=.
2944 if test -f $ac_dir/$ac_word; then
2945 ac_cv_prog_CONFIGURED_FLEX="$ac_prog"
2946 break
2947 fi
2948 done
2949 IFS="$ac_save_ifs"
947f426e
NN
2950fi
2951fi
cac3d6c4 2952CONFIGURED_FLEX="$ac_cv_prog_CONFIGURED_FLEX"
6a9cf61e 2953if test -n "$CONFIGURED_FLEX"; then
cac3d6c4 2954 echo "$ac_t""$CONFIGURED_FLEX" 1>&6
947f426e 2955else
cac3d6c4 2956 echo "$ac_t""no" 1>&6
947f426e 2957fi
a0da8069 2958
cac3d6c4 2959test -n "$CONFIGURED_FLEX" && break
a0da8069 2960done
6a9cf61e 2961test -n "$CONFIGURED_FLEX" || CONFIGURED_FLEX="$MISSING flex"
a0da8069 2962
947f426e 2963for ac_prog in flex lex
a0da8069 2964do
cac3d6c4 2965# Extract the first word of "$ac_prog", so it can be a program name with args.
947f426e 2966set dummy $ac_prog; ac_word=$2
cac3d6c4 2967echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 2968echo "configure:2969: checking for $ac_word" >&5
cac3d6c4
CM
2969if eval "test \"`echo '$''{'ac_cv_prog_CONFIGURED_LEX'+set}'`\" = set"; then
2970 echo $ac_n "(cached) $ac_c" 1>&6
947f426e 2971else
6a9cf61e
PB
2972 if test -n "$CONFIGURED_LEX"; then
2973 ac_cv_prog_CONFIGURED_LEX="$CONFIGURED_LEX" # Let the user override the test.
947f426e 2974else
cac3d6c4
CM
2975 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2976 ac_dummy="$PATH"
2977 for ac_dir in $ac_dummy; do
2978 test -z "$ac_dir" && ac_dir=.
2979 if test -f $ac_dir/$ac_word; then
2980 ac_cv_prog_CONFIGURED_LEX="$ac_prog"
2981 break
2982 fi
2983 done
2984 IFS="$ac_save_ifs"
947f426e
NN
2985fi
2986fi
cac3d6c4 2987CONFIGURED_LEX="$ac_cv_prog_CONFIGURED_LEX"
6a9cf61e 2988if test -n "$CONFIGURED_LEX"; then
cac3d6c4 2989 echo "$ac_t""$CONFIGURED_LEX" 1>&6
947f426e 2990else
cac3d6c4 2991 echo "$ac_t""no" 1>&6
947f426e 2992fi
a0da8069 2993
cac3d6c4 2994test -n "$CONFIGURED_LEX" && break
a0da8069 2995done
6a9cf61e
PB
2996test -n "$CONFIGURED_LEX" || CONFIGURED_LEX="$MISSING flex"
2997
2998for ac_prog in makeinfo
2999do
cac3d6c4 3000# Extract the first word of "$ac_prog", so it can be a program name with args.
6a9cf61e 3001set dummy $ac_prog; ac_word=$2
cac3d6c4 3002echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3003echo "configure:3004: checking for $ac_word" >&5
cac3d6c4
CM
3004if eval "test \"`echo '$''{'ac_cv_prog_CONFIGURED_MAKEINFO'+set}'`\" = set"; then
3005 echo $ac_n "(cached) $ac_c" 1>&6
6a9cf61e
PB
3006else
3007 if test -n "$CONFIGURED_MAKEINFO"; then
3008 ac_cv_prog_CONFIGURED_MAKEINFO="$CONFIGURED_MAKEINFO" # Let the user override the test.
3009else
cac3d6c4
CM
3010 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3011 ac_dummy="$PATH"
3012 for ac_dir in $ac_dummy; do
3013 test -z "$ac_dir" && ac_dir=.
3014 if test -f $ac_dir/$ac_word; then
3015 ac_cv_prog_CONFIGURED_MAKEINFO="$ac_prog"
3016 break
3017 fi
3018 done
3019 IFS="$ac_save_ifs"
6a9cf61e
PB
3020fi
3021fi
cac3d6c4 3022CONFIGURED_MAKEINFO="$ac_cv_prog_CONFIGURED_MAKEINFO"
6a9cf61e 3023if test -n "$CONFIGURED_MAKEINFO"; then
cac3d6c4 3024 echo "$ac_t""$CONFIGURED_MAKEINFO" 1>&6
6a9cf61e 3025else
cac3d6c4 3026 echo "$ac_t""no" 1>&6
6a9cf61e
PB
3027fi
3028
cac3d6c4 3029test -n "$CONFIGURED_MAKEINFO" && break
6a9cf61e
PB
3030done
3031test -n "$CONFIGURED_MAKEINFO" || CONFIGURED_MAKEINFO="$MISSING makeinfo"
947f426e 3032
a0da8069 3033
a0da8069
NN
3034# Create a .gdbinit file which runs the one in srcdir
3035# and tells GDB to look there for source files.
3036
3037if test -r ${srcdir}/.gdbinit ; then
3038 case ${srcdir} in
3039 .) ;;
3040 *) cat > ./.gdbinit <<EOF
3041# ${NO_EDIT}
3042dir ${srcdir}
3043dir .
3044source ${srcdir}/.gdbinit
3045EOF
3046 ;;
3047 esac
3048fi
3049
a0da8069
NN
3050# Make sure that the compiler is able to generate an executable. If it
3051# can't, we are probably in trouble. We don't care whether we can run the
3052# executable--we might be using a cross compiler--we only care whether it
3053# can be created. At this point the main configure script has set CC.
3054we_are_ok=no
3055echo "int main () { return 0; }" > conftest.c
3056${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
3057if test $? = 0 ; then
3058 if test -s conftest || test -s conftest.exe ; then
3059 we_are_ok=yes
3060 fi
cac3d6c4 3061fi
a0da8069
NN
3062case $we_are_ok in
3063 no)
3064 echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
3065 echo 1>&2 "*** You must set the environment variable CC to a working compiler."
3066 rm -f conftest*
3067 exit 1
3068 ;;
3069esac
3070rm -f conftest*
3071
3072# The Solaris /usr/ucb/cc compiler does not appear to work.
3073case "${host}" in
3074 sparc-sun-solaris2*)
3075 CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
3076 if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
3077 could_use=
3078 test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
3079 if test -d /opt/cygnus/bin ; then
3080 if test "$could_use" = "" ; then
3081 could_use="/opt/cygnus/bin"
3082 else
3083 could_use="$could_use or /opt/cygnus/bin"
3084 fi
3085 fi
3086 if test "$could_use" = "" ; then
3087 echo "Warning: compilation may fail because you're using"
3088 echo "/usr/ucb/cc. You should change your PATH or CC "
3089 echo "variable and rerun configure."
3090 else
3091 echo "Warning: compilation may fail because you're using"
3092 echo "/usr/ucb/cc, when you should use the C compiler from"
3093 echo "$could_use. You should change your"
3094 echo "PATH or CC variable and rerun configure."
3095 fi
3096 fi
3097 ;;
3098esac
3099
a0da8069
NN
3100case "${host}" in
3101 *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
9a237d9e 3102 *-*-darwin* | *-*-rhapsody* ) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
a0da8069
NN
3103 *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
3104esac
3105
3106# Record target_configdirs and the configure arguments for target and
3107# build configuration in Makefile.
3108target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
6a9cf61e 3109build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
a0da8069 3110
a0da8069
NN
3111# Determine whether gdb needs tk/tcl or not.
3112# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
3113# and in that case we want gdb to be built without tk. Ugh!
3114# In fact I believe gdb is the *only* package directly dependent on tk,
3115# so we should be able to put the 'maybe's in unconditionally and
3116# leave out the maybe dependencies when enable_gdbtk is false. I'm not
3117# 100% sure that that's safe though.
c180f501 3118
675c6968 3119gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
a0da8069
NN
3120case "$enable_gdbtk" in
3121 no)
3122 GDB_TK="" ;;
c180f501
AC
3123 yes)
3124 GDB_TK="${gdb_tk}" ;;
a0da8069 3125 *)
c180f501
AC
3126 # Only add the dependency on gdbtk when GDBtk is part of the gdb
3127 # distro. Eventually someone will fix this and move Insight, nee
3128 # gdbtk to a separate directory.
3129 if test -d ${srcdir}/gdb/gdbtk ; then
3130 GDB_TK="${gdb_tk}"
3131 else
3132 GDB_TK=""
3133 fi
3134 ;;
a0da8069
NN
3135esac
3136
6bd3dfaa 3137# Strip out unwanted targets.
dd12c3a8
NN
3138
3139# While at that, we remove Makefiles if we were started for recursive
3140# configuration, so that the top-level Makefile reconfigures them,
3141# like we used to do when configure itself was recursive.
dd12c3a8 3142
6bd3dfaa
PB
3143# Loop over modules. $extrasub must be used with care, limiting as
3144# much as possible the usage of range addresses. That's because autoconf
3145# splits the sed script to overcome limits in the number of commands,
3146# and relying on carefully-timed sed passes may turn out to be very hard
3147# to maintain later. In this particular case, you just have to be careful
3148# not to nest @if/@endif pairs, because configure will not warn you at all.
dd12c3a8 3149
319cab08
PB
3150# Check whether --enable-bootstrap or --disable-bootstrap was given.
3151if test "${enable_bootstrap+set}" = set; then
3152 enableval="$enable_bootstrap"
cac3d6c4 3153 :
319cab08 3154else
9cb3fa6f 3155 enable_bootstrap=default
cac3d6c4
CM
3156fi
3157
319cab08 3158
9cb3fa6f
PB
3159# Issue errors and warnings for invalid/strange bootstrap combinations.
3160case "$configdirs" in
3161 *gcc*) have_compiler=yes ;;
3162 *) have_compiler=no ;;
3163esac
3164
3165case "$have_compiler:$host:$target:$enable_bootstrap" in
3166 *:*:*:no) ;;
3167
3168 # Default behavior. (We'll) enable bootstrap if we have a compiler
3169 # and we are in a native configuration.
3170 yes:$build:$build:default)
3171 # This will become 'yes'
3172 enable_bootstrap=no ;;
3173
3174 *:*:*:default)
3175 enable_bootstrap=no ;;
3176
3177 # We have a compiler and we are in a native configuration, bootstrap is ok
3178 yes:$build:$build:yes | yes:$build:$build:lean)
3179 ;;
3180
3181 # Other configurations, but we have a compiler. Assume the user knows
3182 # what he's doing.
3183 yes:*:*:yes | yes:*:*:lean)
cac3d6c4 3184 echo "configure: warning: trying to bootstrap a cross compiler" 1>&2
9cb3fa6f
PB
3185 ;;
3186
3187 # No compiler: if they passed --enable-bootstrap explicitly, fail
3188 no:*:*:yes | no:*:*:lean)
cac3d6c4 3189 { echo "configure: error: cannot bootstrap without a compiler" 1>&2; exit 1; } ;;
9cb3fa6f
PB
3190
3191 # Fail if wrong command line
3192 *)
cac3d6c4 3193 { echo "configure: error: invalid option for --enable-bootstrap" 1>&2; exit 1; }
9cb3fa6f
PB
3194 ;;
3195esac
3196
3197# Adjust the toplevel makefile according to whether bootstrap was selected.
319cab08
PB
3198case "$enable_bootstrap" in
3199 yes)
9cb3fa6f 3200 bootstrap_lean='#'
9cb3fa6f
PB
3201 bootstrap_suffix=bootstrap ;;
3202 lean)
3203 bootstrap_lean=''
498d4a71 3204 bootstrap_suffix=bootstrap ;;
319cab08 3205 no)
498d4a71 3206 bootstrap_suffix=no-bootstrap ;;
319cab08
PB
3207esac
3208
3209
6a9cf61e 3210for module in ${build_configdirs} ; do
498d4a71
CF
3211 if test -z "${no_recursion}" \
3212 && test -f ${build_subdir}/${module}/Makefile; then
3213 echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
3214 rm -f ${build_subdir}/${module}/Makefile
3215 fi
3216 extrasub="$extrasub
3217/^@if build-$module\$/d
3218/^@endif build-$module\$/d
3219/^@if build-$module-$bootstrap_suffix\$/d
3220/^@endif build-$module-$bootstrap_suffix\$/d"
3221done
3222for module in ${configdirs} ; do
3223 if test -z "${no_recursion}" \
3224 && test -f ${module}/Makefile; then
3225 echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
3226 rm -f ${module}/Makefile
3227 fi
3228 extrasub="$extrasub
3229/^@if $module\$/d
3230/^@endif $module\$/d
3231/^@if $module-$bootstrap_suffix\$/d
3232/^@endif $module-$bootstrap_suffix\$/d"
3233done
3234for module in ${target_configdirs} ; do
3235 if test -z "${no_recursion}" \
3236 && test -f ${target_subdir}/${module}/Makefile; then
3237 echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
3238 rm -f ${target_subdir}/${module}/Makefile
3239 fi
3240 extrasub="$extrasub
3241/^@if target-$module\$/d
3242/^@endif target-$module\$/d
3243/^@if target-$module-$bootstrap_suffix\$/d
3244/^@endif target-$module-$bootstrap_suffix\$/d"
3245done
3246
6bd3dfaa
PB
3247extrasub="$extrasub
3248/^@if /,/^@endif /d"
a0da8069
NN
3249
3250# Create the serialization dependencies. This uses a temporary file.
3251
e6bfb94a
AO
3252# Check whether --enable-serial-configure or --disable-serial-configure was given.
3253if test "${enable_serial_configure+set}" = set; then
3254 enableval="$enable_serial_configure"
cac3d6c4
CM
3255 :
3256fi
e6bfb94a
AO
3257
3258
1047cb91
DD
3259case ${enable_serial_configure} in
3260 yes)
3261 enable_serial_build_configure=yes
3262 enable_serial_host_configure=yes
3263 enable_serial_target_configure=yes
3264 ;;
3265esac
3266
a0da8069
NN
3267# These force 'configure's to be done one at a time, to avoid problems
3268# with contention over a shared config.cache.
3269rm -f serdep.tmp
e6bfb94a 3270echo '# serdep.tmp' > serdep.tmp
a0da8069 3271olditem=
1047cb91 3272test "x${enable_serial_build_configure}" = xyes &&
a0da8069
NN
3273for item in ${build_configdirs} ; do
3274 case ${olditem} in
3275 "") ;;
e6bfb94a 3276 *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
a0da8069
NN
3277 esac
3278 olditem=${item}
3279done
3280olditem=
1047cb91 3281test "x${enable_serial_host_configure}" = xyes &&
a0da8069
NN
3282for item in ${configdirs} ; do
3283 case ${olditem} in
3284 "") ;;
e6bfb94a 3285 *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
a0da8069
NN
3286 esac
3287 olditem=${item}
3288done
3289olditem=
1047cb91 3290test "x${enable_serial_target_configure}" = xyes &&
a0da8069
NN
3291for item in ${target_configdirs} ; do
3292 case ${olditem} in
3293 "") ;;
e6bfb94a 3294 *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
a0da8069
NN
3295 esac
3296 olditem=${item}
3297done
3298serialization_dependencies=serdep.tmp
3299
3300
e6bfb94a
AO
3301# Base args. Strip norecursion, cache-file, srcdir, host, build,
3302# target and nonopt. These are the ones we might not want to pass
f27d4f92
DJ
3303# down to subconfigures. Also strip program-prefix, program-suffix,
3304# and program-transform-name, so that we can pass down a consistent
3305# program-transform-name. If autoconf has put single quotes around
3306# any of these arguments (because they contain shell metacharacters)
3307# then this will fail; in practice this only happens for
3308# --program-transform-name, so be sure to override --program-transform-name
3309# at the end of the argument list.
3310# These will be expanded by make, so quote '$'.
d2cc0e0d 3311cat <<\EOF_SED > conftestsed
54752a6b
NN
3312s/ --no[^ ]*/ /g
3313s/ --c[a-z-]*[= ][^ ]*//g
3314s/ --sr[a-z-]*[= ][^ ]*//g
3315s/ --ho[a-z-]*[= ][^ ]*//g
3316s/ --bu[a-z-]*[= ][^ ]*//g
3317s/ --t[a-z-]*[= ][^ ]*//g
3318s/ --program-[pst][a-z-]*[= ][^ ]*//g
3319s/ -cache-file[= ][^ ]*//g
3320s/ -srcdir[= ][^ ]*//g
3321s/ -host[= ][^ ]*//g
3322s/ -build[= ][^ ]*//g
3323s/ -target[= ][^ ]*//g
3324s/ -program-prefix[= ][^ ]*//g
3325s/ -program-suffix[= ][^ ]*//g
3326s/ -program-transform-name[= ][^ ]*//g
d2cc0e0d
GK
3327s/ [^' -][^ ]* / /
3328s/^ *//;s/ *$//
8ff944f6
DJ
3329s,\$,$$,g
3330EOF_SED
3331sed -f conftestsed <<EOF_SED > conftestsed.out
cac3d6c4 3332 ${ac_configure_args}
d2cc0e0d 3333EOF_SED
8ff944f6
DJ
3334baseargs=`cat conftestsed.out`
3335rm -f conftestsed conftestsed.out
a0da8069 3336
f27d4f92
DJ
3337# Add in --program-transform-name, after --program-prefix and
3338# --program-suffix have been applied to it. Autoconf has already
3339# doubled dollar signs and backslashes in program_transform_name; we want
3340# the backslashes un-doubled, and then the entire thing wrapped in single
cac3d6c4 3341# quotes, because this will be expanded first by make and then by the shell.
f27d4f92
DJ
3342# Also, because we want to override the logic in subdir configure scripts to
3343# choose program_transform_name, replace any s,x,x, with s,y,y,.
3344sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
3345${program_transform_name}
3346EOF_SED
3347gcc_transform_name=`cat conftestsed.out`
3348rm -f conftestsed.out
3349baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
3350
a0da8069
NN
3351# For the build-side libraries, we just need to pretend we're native,
3352# and not use the same cache file. Multilibs are neither needed nor
3353# desired.
69e57115 3354build_configargs="--cache-file=../config.cache --build=${build_alias} --host=${build_alias} --target=${target_alias} ${baseargs}"
a0da8069
NN
3355
3356# For host modules, accept cache file option, or specification as blank.
3357case "${cache_file}" in
3358"") # empty
3359 cache_file_option="" ;;
3360/* | [A-Za-z]:[\\/]* ) # absolute path
3361 cache_file_option="--cache-file=${cache_file}" ;;
3362*) # relative path
3363 cache_file_option="--cache-file=../${cache_file}" ;;
3364esac
3365
82252c06
NN
3366# Host dirs don't like to share a cache file either, horribly enough.
3367# This seems to be due to autoconf 2.5x stupidity.
bb5dca17 3368host_configargs="--cache-file=./config.cache --build=${build_alias} --host=${host_alias} --target=${target_alias} ${extra_host_args} ${baseargs}"
a0da8069
NN
3369
3370target_configargs=${baseargs}
3371
3372# Passing a --with-cross-host argument lets the target libraries know
3373# whether they are being built with a cross-compiler or being built
3374# native. However, it would be better to use other mechanisms to make the
3375# sorts of decisions they want to make on this basis. Please consider
3376# this option to be deprecated. FIXME.
3377if test x${is_cross_compiler} = xyes ; then
3378 target_configargs="--with-cross-host=${host_alias} ${target_configargs}"
3379fi
3380
3381# Default to --enable-multilib.
3382if test x${enable_multilib} = x ; then
3383 target_configargs="--enable-multilib ${target_configargs}"
3384fi
3385
3386# Pass --with-newlib if appropriate. Note that target_configdirs has
3387# changed from the earlier setting of with_newlib.
3388if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
3389 target_configargs="--with-newlib ${target_configargs}"
3390fi
3391
95036d20
NN
3392# Different target subdirs use different values of certain variables
3393# (notably CXX). Worse, multilibs use *lots* of different values.
3394# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
3395# it doesn't automatically accept command-line overrides of them.
3396# This means it's not safe for target subdirs to share a cache file,
3397# which is disgusting, but there you have it. Hopefully this can be
3398# fixed in future. It's still worthwhile to use a cache file for each
3399# directory. I think.
3400
ae380b45
MS
3401# Pass the appropriate --build, --host, --target and --cache-file arguments.
3402# We need to pass --target, as newer autoconf's requires consistency
3403# for target_alias and gcc doesn't manage it consistently.
3404target_configargs="--cache-file=./config.cache --build=${build_alias} --host=${target_alias} --target=${target_alias} ${target_configargs}"
a0da8069 3405
a0da8069
NN
3406FLAGS_FOR_TARGET=
3407case " $target_configdirs " in
3408 *" newlib "*)
3409 case " $target_configargs " in
3410 *" --with-newlib "*)
3411 case "$target" in
3412 *-cygwin*)
564b43e5 3413 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' ;;
a0da8069
NN
3414 esac
3415
3416 # If we're not building GCC, don't discard standard headers.
3417 if test -d ${srcdir}/gcc; then
3418 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
3419
3420 if test "${build}" != "${host}"; then
3421 # On Canadian crosses, CC_FOR_TARGET will have already been set
3422 # by `configure', so we won't have an opportunity to add -Bgcc/
3423 # to it. This is right: we don't want to search that directory
3424 # for binaries, but we want the header files in there, so add
3425 # them explicitly.
b00612cc 3426 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include'
a0da8069
NN
3427
3428 # Someone might think of using the pre-installed headers on
3429 # Canadian crosses, in case the installed compiler is not fully
3430 # compatible with the compiler being built. In this case, it
3431 # would be better to flag an error than risking having
3432 # incompatible object files being constructed. We can't
3433 # guarantee that an error will be flagged, but let's hope the
3434 # compiler will do it, when presented with incompatible header
3435 # files.
3436 fi
3437 fi
3438
3439 case "${target}-${is_cross_compiler}" in
ec11bdc6 3440 i[3456789]86-*-linux*-no)
a0da8069
NN
3441 # Here host == target, so we don't need to build gcc,
3442 # so we don't want to discard standard headers.
3443 FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
3444 ;;
3445 *)
3446 # If we're building newlib, use its generic headers last, but search
3447 # for any libc-related directories first (so make it the last -B
3448 # switch).
3449 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
3450 ;;
3451 esac
3452 ;;
3453 esac
3454 ;;
3455esac
3456
5fbad20a
DD
3457# Allow the user to override the flags for
3458# our build compiler if desired.
3459CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
3460
a0da8069
NN
3461# On Canadian crosses, we'll be searching the right directories for
3462# the previously-installed cross compiler, so don't bother to add
3463# flags for directories within the install tree of the compiler
3464# being built; programs in there won't even run.
3465if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
3466 # Search for pre-installed headers if nothing else fits.
bba45b8b 3467 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
a0da8069
NN
3468fi
3469
3470if test "x${use_gnu_ld}" = x &&
3471 echo " ${configdirs} " | grep " ld " > /dev/null ; then
3472 # Arrange for us to find uninstalled linker scripts.
b00612cc 3473 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
a0da8069
NN
3474fi
3475
a0da8069 3476# Makefile fragments.
3e707e94
PB
3477for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
3478do
3479 eval fragval=\$$frag
3480 if test $fragval != /dev/null; then
3481 eval $frag=${srcdir}/$fragval
3482 fi
3483done
a0da8069
NN
3484
3485
3486
3487
3488
3489# Miscellanea: directories, flags, etc.
3490
3491
3492
3493
3494
3495
3496
6a9cf61e 3497# Build module lists & subconfigure args.
a0da8069
NN
3498
3499
3500
a0da8069
NN
3501# Host module lists & subconfigure args.
3502
3503
3504
a0da8069
NN
3505# Target module lists & subconfigure args.
3506
3507
3508
a0da8069
NN
3509# Build tools.
3510
3511
3512
a0da8069 3513# Host tools.
859789af
AC
3514ncn_tool_prefix=
3515test -n "$host_alias" && ncn_tool_prefix=$host_alias-
3516ncn_target_tool_prefix=
3517test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
3518
05cbd757
PB
3519 for ncn_progname in ar; do
3520 if test -n "$ncn_tool_prefix"; then
3521 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3522set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3523echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3524echo "configure:3525: checking for $ac_word" >&5
cac3d6c4
CM
3525if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
3526 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3527else
3528 if test -n "$AR"; then
3529 ac_cv_prog_AR="$AR" # Let the user override the test.
3530else
cac3d6c4
CM
3531 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3532 ac_dummy="$PATH"
3533 for ac_dir in $ac_dummy; do
3534 test -z "$ac_dir" && ac_dir=.
3535 if test -f $ac_dir/$ac_word; then
3536 ac_cv_prog_AR="${ncn_tool_prefix}${ncn_progname}"
3537 break
3538 fi
3539 done
3540 IFS="$ac_save_ifs"
859789af
AC
3541fi
3542fi
cac3d6c4 3543AR="$ac_cv_prog_AR"
859789af 3544if test -n "$AR"; then
cac3d6c4 3545 echo "$ac_t""$AR" 1>&6
859789af 3546else
cac3d6c4 3547 echo "$ac_t""no" 1>&6
859789af
AC
3548fi
3549
05cbd757
PB
3550 fi
3551 if test -z "$ac_cv_prog_AR" && test $build = $host ; then
3552 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3553set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3554echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3555echo "configure:3556: checking for $ac_word" >&5
cac3d6c4
CM
3556if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
3557 echo $ac_n "(cached) $ac_c" 1>&6
859789af 3558else
05cbd757
PB
3559 if test -n "$AR"; then
3560 ac_cv_prog_AR="$AR" # Let the user override the test.
859789af 3561else
cac3d6c4
CM
3562 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3563 ac_dummy="$PATH"
3564 for ac_dir in $ac_dummy; do
3565 test -z "$ac_dir" && ac_dir=.
3566 if test -f $ac_dir/$ac_word; then
3567 ac_cv_prog_AR="${ncn_progname}"
3568 break
3569 fi
3570 done
3571 IFS="$ac_save_ifs"
859789af
AC
3572fi
3573fi
cac3d6c4 3574AR="$ac_cv_prog_AR"
05cbd757 3575if test -n "$AR"; then
cac3d6c4 3576 echo "$ac_t""$AR" 1>&6
859789af 3577else
cac3d6c4 3578 echo "$ac_t""no" 1>&6
859789af 3579fi
cac3d6c4 3580
05cbd757
PB
3581 fi
3582 test -n "$ac_cv_prog_AR" && break
3583done
3584
3585if test -z "$ac_cv_prog_AR" ; then
3586 set dummy ar
3587 if test $build = $host ; then
3588 AR="$2"
859789af 3589 else
05cbd757 3590 AR="${ncn_tool_prefix}$2"
859789af 3591 fi
859789af
AC
3592fi
3593
05cbd757
PB
3594 for ncn_progname in as; do
3595 if test -n "$ncn_tool_prefix"; then
3596 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3597set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3598echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3599echo "configure:3600: checking for $ac_word" >&5
cac3d6c4
CM
3600if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
3601 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3602else
3603 if test -n "$AS"; then
3604 ac_cv_prog_AS="$AS" # Let the user override the test.
3605else
cac3d6c4
CM
3606 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3607 ac_dummy="$PATH"
3608 for ac_dir in $ac_dummy; do
3609 test -z "$ac_dir" && ac_dir=.
3610 if test -f $ac_dir/$ac_word; then
3611 ac_cv_prog_AS="${ncn_tool_prefix}${ncn_progname}"
3612 break
3613 fi
3614 done
3615 IFS="$ac_save_ifs"
859789af
AC
3616fi
3617fi
cac3d6c4 3618AS="$ac_cv_prog_AS"
859789af 3619if test -n "$AS"; then
cac3d6c4 3620 echo "$ac_t""$AS" 1>&6
859789af 3621else
cac3d6c4 3622 echo "$ac_t""no" 1>&6
859789af
AC
3623fi
3624
05cbd757
PB
3625 fi
3626 if test -z "$ac_cv_prog_AS" && test $build = $host ; then
3627 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3628set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3629echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3630echo "configure:3631: checking for $ac_word" >&5
cac3d6c4
CM
3631if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
3632 echo $ac_n "(cached) $ac_c" 1>&6
859789af 3633else
05cbd757
PB
3634 if test -n "$AS"; then
3635 ac_cv_prog_AS="$AS" # Let the user override the test.
859789af 3636else
cac3d6c4
CM
3637 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3638 ac_dummy="$PATH"
3639 for ac_dir in $ac_dummy; do
3640 test -z "$ac_dir" && ac_dir=.
3641 if test -f $ac_dir/$ac_word; then
3642 ac_cv_prog_AS="${ncn_progname}"
3643 break
3644 fi
3645 done
3646 IFS="$ac_save_ifs"
859789af
AC
3647fi
3648fi
cac3d6c4 3649AS="$ac_cv_prog_AS"
05cbd757 3650if test -n "$AS"; then
cac3d6c4 3651 echo "$ac_t""$AS" 1>&6
859789af 3652else
cac3d6c4 3653 echo "$ac_t""no" 1>&6
859789af 3654fi
cac3d6c4 3655
05cbd757
PB
3656 fi
3657 test -n "$ac_cv_prog_AS" && break
3658done
3659
3660if test -z "$ac_cv_prog_AS" ; then
3661 set dummy as
3662 if test $build = $host ; then
3663 AS="$2"
859789af 3664 else
05cbd757 3665 AS="${ncn_tool_prefix}$2"
859789af 3666 fi
859789af
AC
3667fi
3668
05cbd757
PB
3669 for ncn_progname in dlltool; do
3670 if test -n "$ncn_tool_prefix"; then
3671 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3672set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3673echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3674echo "configure:3675: checking for $ac_word" >&5
cac3d6c4
CM
3675if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
3676 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3677else
3678 if test -n "$DLLTOOL"; then
3679 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
3680else
cac3d6c4
CM
3681 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3682 ac_dummy="$PATH"
3683 for ac_dir in $ac_dummy; do
3684 test -z "$ac_dir" && ac_dir=.
3685 if test -f $ac_dir/$ac_word; then
3686 ac_cv_prog_DLLTOOL="${ncn_tool_prefix}${ncn_progname}"
3687 break
3688 fi
3689 done
3690 IFS="$ac_save_ifs"
859789af
AC
3691fi
3692fi
cac3d6c4 3693DLLTOOL="$ac_cv_prog_DLLTOOL"
859789af 3694if test -n "$DLLTOOL"; then
cac3d6c4 3695 echo "$ac_t""$DLLTOOL" 1>&6
859789af 3696else
cac3d6c4 3697 echo "$ac_t""no" 1>&6
859789af
AC
3698fi
3699
05cbd757
PB
3700 fi
3701 if test -z "$ac_cv_prog_DLLTOOL" && test $build = $host ; then
3702 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3703set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3704echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3705echo "configure:3706: checking for $ac_word" >&5
cac3d6c4
CM
3706if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
3707 echo $ac_n "(cached) $ac_c" 1>&6
859789af 3708else
05cbd757
PB
3709 if test -n "$DLLTOOL"; then
3710 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
859789af 3711else
cac3d6c4
CM
3712 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3713 ac_dummy="$PATH"
3714 for ac_dir in $ac_dummy; do
3715 test -z "$ac_dir" && ac_dir=.
3716 if test -f $ac_dir/$ac_word; then
3717 ac_cv_prog_DLLTOOL="${ncn_progname}"
3718 break
3719 fi
3720 done
3721 IFS="$ac_save_ifs"
859789af
AC
3722fi
3723fi
cac3d6c4 3724DLLTOOL="$ac_cv_prog_DLLTOOL"
05cbd757 3725if test -n "$DLLTOOL"; then
cac3d6c4 3726 echo "$ac_t""$DLLTOOL" 1>&6
859789af 3727else
cac3d6c4 3728 echo "$ac_t""no" 1>&6
859789af 3729fi
cac3d6c4 3730
05cbd757
PB
3731 fi
3732 test -n "$ac_cv_prog_DLLTOOL" && break
3733done
3734
3735if test -z "$ac_cv_prog_DLLTOOL" ; then
3736 set dummy dlltool
3737 if test $build = $host ; then
3738 DLLTOOL="$2"
859789af 3739 else
05cbd757 3740 DLLTOOL="${ncn_tool_prefix}$2"
859789af 3741 fi
859789af
AC
3742fi
3743
05cbd757
PB
3744 for ncn_progname in ld; do
3745 if test -n "$ncn_tool_prefix"; then
3746 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3747set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3748echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3749echo "configure:3750: checking for $ac_word" >&5
cac3d6c4
CM
3750if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
3751 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3752else
3753 if test -n "$LD"; then
3754 ac_cv_prog_LD="$LD" # Let the user override the test.
3755else
cac3d6c4
CM
3756 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3757 ac_dummy="$PATH"
3758 for ac_dir in $ac_dummy; do
3759 test -z "$ac_dir" && ac_dir=.
3760 if test -f $ac_dir/$ac_word; then
3761 ac_cv_prog_LD="${ncn_tool_prefix}${ncn_progname}"
3762 break
3763 fi
3764 done
3765 IFS="$ac_save_ifs"
859789af
AC
3766fi
3767fi
cac3d6c4 3768LD="$ac_cv_prog_LD"
859789af 3769if test -n "$LD"; then
cac3d6c4 3770 echo "$ac_t""$LD" 1>&6
859789af 3771else
cac3d6c4 3772 echo "$ac_t""no" 1>&6
859789af
AC
3773fi
3774
05cbd757
PB
3775 fi
3776 if test -z "$ac_cv_prog_LD" && test $build = $host ; then
3777 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3778set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3779echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3780echo "configure:3781: checking for $ac_word" >&5
cac3d6c4
CM
3781if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
3782 echo $ac_n "(cached) $ac_c" 1>&6
859789af 3783else
05cbd757
PB
3784 if test -n "$LD"; then
3785 ac_cv_prog_LD="$LD" # Let the user override the test.
376a0e54 3786else
cac3d6c4
CM
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_LD="${ncn_progname}"
3793 break
3794 fi
3795 done
3796 IFS="$ac_save_ifs"
859789af
AC
3797fi
3798fi
cac3d6c4 3799LD="$ac_cv_prog_LD"
05cbd757 3800if test -n "$LD"; then
cac3d6c4 3801 echo "$ac_t""$LD" 1>&6
859789af 3802else
cac3d6c4 3803 echo "$ac_t""no" 1>&6
859789af 3804fi
cac3d6c4 3805
05cbd757
PB
3806 fi
3807 test -n "$ac_cv_prog_LD" && break
3808done
3809
3810if test -z "$ac_cv_prog_LD" ; then
3811 set dummy ld
3812 if test $build = $host ; then
3813 LD="$2"
859789af 3814 else
05cbd757 3815 LD="${ncn_tool_prefix}$2"
859789af 3816 fi
859789af
AC
3817fi
3818
05cbd757
PB
3819 for ncn_progname in nm; do
3820 if test -n "$ncn_tool_prefix"; then
3821 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3822set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3823echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3824echo "configure:3825: checking for $ac_word" >&5
cac3d6c4
CM
3825if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
3826 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3827else
3828 if test -n "$NM"; then
3829 ac_cv_prog_NM="$NM" # Let the user override the test.
3830else
cac3d6c4
CM
3831 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3832 ac_dummy="$PATH"
3833 for ac_dir in $ac_dummy; do
3834 test -z "$ac_dir" && ac_dir=.
3835 if test -f $ac_dir/$ac_word; then
3836 ac_cv_prog_NM="${ncn_tool_prefix}${ncn_progname}"
3837 break
3838 fi
3839 done
3840 IFS="$ac_save_ifs"
859789af
AC
3841fi
3842fi
cac3d6c4 3843NM="$ac_cv_prog_NM"
859789af 3844if test -n "$NM"; then
cac3d6c4 3845 echo "$ac_t""$NM" 1>&6
859789af 3846else
cac3d6c4 3847 echo "$ac_t""no" 1>&6
859789af
AC
3848fi
3849
05cbd757
PB
3850 fi
3851 if test -z "$ac_cv_prog_NM" && test $build = $host ; then
3852 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3853set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3854echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3855echo "configure:3856: checking for $ac_word" >&5
cac3d6c4
CM
3856if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
3857 echo $ac_n "(cached) $ac_c" 1>&6
859789af 3858else
05cbd757
PB
3859 if test -n "$NM"; then
3860 ac_cv_prog_NM="$NM" # Let the user override the test.
859789af 3861else
cac3d6c4
CM
3862 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3863 ac_dummy="$PATH"
3864 for ac_dir in $ac_dummy; do
3865 test -z "$ac_dir" && ac_dir=.
3866 if test -f $ac_dir/$ac_word; then
3867 ac_cv_prog_NM="${ncn_progname}"
3868 break
3869 fi
3870 done
3871 IFS="$ac_save_ifs"
859789af
AC
3872fi
3873fi
cac3d6c4 3874NM="$ac_cv_prog_NM"
05cbd757 3875if test -n "$NM"; then
cac3d6c4 3876 echo "$ac_t""$NM" 1>&6
859789af 3877else
cac3d6c4 3878 echo "$ac_t""no" 1>&6
859789af 3879fi
cac3d6c4 3880
05cbd757
PB
3881 fi
3882 test -n "$ac_cv_prog_NM" && break
3883done
3884
3885if test -z "$ac_cv_prog_NM" ; then
3886 set dummy nm
3887 if test $build = $host ; then
3888 NM="$2"
859789af 3889 else
05cbd757 3890 NM="${ncn_tool_prefix}$2"
859789af 3891 fi
859789af
AC
3892fi
3893
05cbd757
PB
3894 for ncn_progname in ranlib; do
3895 if test -n "$ncn_tool_prefix"; then
3896 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3897set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3898echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3899echo "configure:3900: checking for $ac_word" >&5
cac3d6c4
CM
3900if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
3901 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3902else
3903 if test -n "$RANLIB"; then
3904 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3905else
cac3d6c4
CM
3906 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3907 ac_dummy="$PATH"
3908 for ac_dir in $ac_dummy; do
3909 test -z "$ac_dir" && ac_dir=.
3910 if test -f $ac_dir/$ac_word; then
3911 ac_cv_prog_RANLIB="${ncn_tool_prefix}${ncn_progname}"
3912 break
3913 fi
3914 done
3915 IFS="$ac_save_ifs"
859789af
AC
3916fi
3917fi
cac3d6c4 3918RANLIB="$ac_cv_prog_RANLIB"
859789af 3919if test -n "$RANLIB"; then
cac3d6c4 3920 echo "$ac_t""$RANLIB" 1>&6
859789af 3921else
cac3d6c4 3922 echo "$ac_t""no" 1>&6
859789af
AC
3923fi
3924
05cbd757
PB
3925 fi
3926 if test -z "$ac_cv_prog_RANLIB" && test $build = $host ; then
3927 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3928set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3929echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3930echo "configure:3931: checking for $ac_word" >&5
cac3d6c4
CM
3931if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
3932 echo $ac_n "(cached) $ac_c" 1>&6
859789af 3933else
05cbd757
PB
3934 if test -n "$RANLIB"; then
3935 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
859789af 3936else
cac3d6c4
CM
3937 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3938 ac_dummy="$PATH"
3939 for ac_dir in $ac_dummy; do
3940 test -z "$ac_dir" && ac_dir=.
3941 if test -f $ac_dir/$ac_word; then
3942 ac_cv_prog_RANLIB="${ncn_progname}"
3943 break
3944 fi
3945 done
3946 IFS="$ac_save_ifs"
859789af
AC
3947fi
3948fi
cac3d6c4 3949RANLIB="$ac_cv_prog_RANLIB"
05cbd757 3950if test -n "$RANLIB"; then
cac3d6c4 3951 echo "$ac_t""$RANLIB" 1>&6
859789af 3952else
cac3d6c4 3953 echo "$ac_t""no" 1>&6
859789af 3954fi
cac3d6c4 3955
859789af 3956 fi
05cbd757
PB
3957 test -n "$ac_cv_prog_RANLIB" && break
3958done
3959
3960if test -z "$ac_cv_prog_RANLIB" ; then
3961 RANLIB=":"
859789af
AC
3962fi
3963
05cbd757
PB
3964 for ncn_progname in windres; do
3965 if test -n "$ncn_tool_prefix"; then
3966 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
3967set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 3968echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 3969echo "configure:3970: checking for $ac_word" >&5
cac3d6c4
CM
3970if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
3971 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
3972else
3973 if test -n "$WINDRES"; then
3974 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
3975else
cac3d6c4
CM
3976 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3977 ac_dummy="$PATH"
3978 for ac_dir in $ac_dummy; do
3979 test -z "$ac_dir" && ac_dir=.
3980 if test -f $ac_dir/$ac_word; then
3981 ac_cv_prog_WINDRES="${ncn_tool_prefix}${ncn_progname}"
3982 break
3983 fi
3984 done
3985 IFS="$ac_save_ifs"
859789af
AC
3986fi
3987fi
cac3d6c4 3988WINDRES="$ac_cv_prog_WINDRES"
859789af 3989if test -n "$WINDRES"; then
cac3d6c4 3990 echo "$ac_t""$WINDRES" 1>&6
859789af 3991else
cac3d6c4 3992 echo "$ac_t""no" 1>&6
859789af
AC
3993fi
3994
05cbd757
PB
3995 fi
3996 if test -z "$ac_cv_prog_WINDRES" && test $build = $host ; then
3997 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
3998set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 3999echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4000echo "configure:4001: checking for $ac_word" >&5
cac3d6c4
CM
4001if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
4002 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4003else
05cbd757
PB
4004 if test -n "$WINDRES"; then
4005 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
859789af 4006else
cac3d6c4
CM
4007 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4008 ac_dummy="$PATH"
4009 for ac_dir in $ac_dummy; do
4010 test -z "$ac_dir" && ac_dir=.
4011 if test -f $ac_dir/$ac_word; then
4012 ac_cv_prog_WINDRES="${ncn_progname}"
4013 break
4014 fi
4015 done
4016 IFS="$ac_save_ifs"
859789af
AC
4017fi
4018fi
cac3d6c4 4019WINDRES="$ac_cv_prog_WINDRES"
05cbd757 4020if test -n "$WINDRES"; then
cac3d6c4 4021 echo "$ac_t""$WINDRES" 1>&6
859789af 4022else
cac3d6c4 4023 echo "$ac_t""no" 1>&6
859789af 4024fi
cac3d6c4 4025
05cbd757
PB
4026 fi
4027 test -n "$ac_cv_prog_WINDRES" && break
4028done
4029
4030if test -z "$ac_cv_prog_WINDRES" ; then
4031 set dummy windres
4032 if test $build = $host ; then
4033 WINDRES="$2"
859789af 4034 else
05cbd757 4035 WINDRES="${ncn_tool_prefix}$2"
859789af 4036 fi
859789af
AC
4037fi
4038
05cbd757
PB
4039 for ncn_progname in objcopy; do
4040 if test -n "$ncn_tool_prefix"; then
4041 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4042set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4043echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4044echo "configure:4045: checking for $ac_word" >&5
cac3d6c4
CM
4045if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
4046 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
4047else
4048 if test -n "$OBJCOPY"; then
4049 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
4050else
cac3d6c4
CM
4051 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4052 ac_dummy="$PATH"
4053 for ac_dir in $ac_dummy; do
4054 test -z "$ac_dir" && ac_dir=.
4055 if test -f $ac_dir/$ac_word; then
4056 ac_cv_prog_OBJCOPY="${ncn_tool_prefix}${ncn_progname}"
4057 break
4058 fi
4059 done
4060 IFS="$ac_save_ifs"
859789af
AC
4061fi
4062fi
cac3d6c4 4063OBJCOPY="$ac_cv_prog_OBJCOPY"
859789af 4064if test -n "$OBJCOPY"; then
cac3d6c4 4065 echo "$ac_t""$OBJCOPY" 1>&6
859789af 4066else
cac3d6c4 4067 echo "$ac_t""no" 1>&6
859789af
AC
4068fi
4069
05cbd757
PB
4070 fi
4071 if test -z "$ac_cv_prog_OBJCOPY" && test $build = $host ; then
4072 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4073set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4074echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4075echo "configure:4076: checking for $ac_word" >&5
cac3d6c4
CM
4076if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
4077 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4078else
05cbd757
PB
4079 if test -n "$OBJCOPY"; then
4080 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
859789af 4081else
cac3d6c4
CM
4082 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4083 ac_dummy="$PATH"
4084 for ac_dir in $ac_dummy; do
4085 test -z "$ac_dir" && ac_dir=.
4086 if test -f $ac_dir/$ac_word; then
4087 ac_cv_prog_OBJCOPY="${ncn_progname}"
4088 break
4089 fi
4090 done
4091 IFS="$ac_save_ifs"
859789af
AC
4092fi
4093fi
cac3d6c4 4094OBJCOPY="$ac_cv_prog_OBJCOPY"
05cbd757 4095if test -n "$OBJCOPY"; then
cac3d6c4 4096 echo "$ac_t""$OBJCOPY" 1>&6
859789af 4097else
cac3d6c4 4098 echo "$ac_t""no" 1>&6
859789af 4099fi
cac3d6c4 4100
05cbd757
PB
4101 fi
4102 test -n "$ac_cv_prog_OBJCOPY" && break
4103done
4104
4105if test -z "$ac_cv_prog_OBJCOPY" ; then
4106 set dummy objcopy
4107 if test $build = $host ; then
4108 OBJCOPY="$2"
859789af 4109 else
05cbd757 4110 OBJCOPY="${ncn_tool_prefix}$2"
859789af 4111 fi
859789af
AC
4112fi
4113
05cbd757
PB
4114 for ncn_progname in objdump; do
4115 if test -n "$ncn_tool_prefix"; then
4116 # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
4117set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4118echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4119echo "configure:4120: checking for $ac_word" >&5
cac3d6c4
CM
4120if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
4121 echo $ac_n "(cached) $ac_c" 1>&6
859789af
AC
4122else
4123 if test -n "$OBJDUMP"; then
4124 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
4125else
cac3d6c4
CM
4126 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4127 ac_dummy="$PATH"
4128 for ac_dir in $ac_dummy; do
4129 test -z "$ac_dir" && ac_dir=.
4130 if test -f $ac_dir/$ac_word; then
4131 ac_cv_prog_OBJDUMP="${ncn_tool_prefix}${ncn_progname}"
4132 break
4133 fi
4134 done
4135 IFS="$ac_save_ifs"
859789af
AC
4136fi
4137fi
cac3d6c4 4138OBJDUMP="$ac_cv_prog_OBJDUMP"
859789af 4139if test -n "$OBJDUMP"; then
cac3d6c4 4140 echo "$ac_t""$OBJDUMP" 1>&6
859789af 4141else
cac3d6c4 4142 echo "$ac_t""no" 1>&6
859789af
AC
4143fi
4144
05cbd757
PB
4145 fi
4146 if test -z "$ac_cv_prog_OBJDUMP" && test $build = $host ; then
4147 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4148set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4149echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4150echo "configure:4151: checking for $ac_word" >&5
cac3d6c4
CM
4151if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
4152 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4153else
05cbd757
PB
4154 if test -n "$OBJDUMP"; then
4155 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
859789af 4156else
cac3d6c4
CM
4157 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4158 ac_dummy="$PATH"
4159 for ac_dir in $ac_dummy; do
4160 test -z "$ac_dir" && ac_dir=.
4161 if test -f $ac_dir/$ac_word; then
4162 ac_cv_prog_OBJDUMP="${ncn_progname}"
4163 break
4164 fi
4165 done
4166 IFS="$ac_save_ifs"
859789af
AC
4167fi
4168fi
cac3d6c4 4169OBJDUMP="$ac_cv_prog_OBJDUMP"
05cbd757 4170if test -n "$OBJDUMP"; then
cac3d6c4 4171 echo "$ac_t""$OBJDUMP" 1>&6
859789af 4172else
cac3d6c4 4173 echo "$ac_t""no" 1>&6
859789af 4174fi
cac3d6c4 4175
05cbd757
PB
4176 fi
4177 test -n "$ac_cv_prog_OBJDUMP" && break
4178done
4179
4180if test -z "$ac_cv_prog_OBJDUMP" ; then
4181 set dummy objdump
4182 if test $build = $host ; then
4183 OBJDUMP="$2"
859789af 4184 else
05cbd757 4185 OBJDUMP="${ncn_tool_prefix}$2"
859789af 4186 fi
859789af
AC
4187fi
4188
a0da8069
NN
4189
4190
4191
4192
4193
4194
55db4b87
PB
4195# Target tools. Do the tests using the names they may have passed in
4196# the environment, then move it to CONFIGURED_*_FOR_TARGET.
05cbd757
PB
4197 for ncn_progname in ar; do
4198 if test -n "$ncn_target_tool_prefix"; then
4199 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4200set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4201echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4202echo "configure:4203: checking for $ac_word" >&5
cac3d6c4
CM
4203if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
4204 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4205else
55db4b87
PB
4206 if test -n "$AR_FOR_TARGET"; then
4207 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
859789af 4208else
cac3d6c4
CM
4209 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4210 ac_dummy="$PATH"
4211 for ac_dir in $ac_dummy; do
4212 test -z "$ac_dir" && ac_dir=.
4213 if test -f $ac_dir/$ac_word; then
4214 ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4215 break
4216 fi
4217 done
4218 IFS="$ac_save_ifs"
859789af
AC
4219fi
4220fi
cac3d6c4 4221AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
55db4b87 4222if test -n "$AR_FOR_TARGET"; then
cac3d6c4 4223 echo "$ac_t""$AR_FOR_TARGET" 1>&6
859789af 4224else
cac3d6c4 4225 echo "$ac_t""no" 1>&6
859789af
AC
4226fi
4227
05cbd757
PB
4228 fi
4229 if test -z "$ac_cv_prog_AR_FOR_TARGET" && test $build = $target ; then
4230 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4231set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4232echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4233echo "configure:4234: checking for $ac_word" >&5
cac3d6c4
CM
4234if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
4235 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4236else
05cbd757
PB
4237 if test -n "$AR_FOR_TARGET"; then
4238 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
859789af 4239else
cac3d6c4
CM
4240 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4241 ac_dummy="$PATH"
4242 for ac_dir in $ac_dummy; do
4243 test -z "$ac_dir" && ac_dir=.
4244 if test -f $ac_dir/$ac_word; then
4245 ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
4246 break
4247 fi
4248 done
4249 IFS="$ac_save_ifs"
859789af
AC
4250fi
4251fi
cac3d6c4 4252AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
05cbd757 4253if test -n "$AR_FOR_TARGET"; then
cac3d6c4 4254 echo "$ac_t""$AR_FOR_TARGET" 1>&6
859789af 4255else
cac3d6c4 4256 echo "$ac_t""no" 1>&6
859789af 4257fi
cac3d6c4 4258
05cbd757
PB
4259 fi
4260 test -n "$ac_cv_prog_AR_FOR_TARGET" && break
4261done
4262
4263if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
4264 set dummy ar
4265 if test $build = $target ; then
4266 AR_FOR_TARGET="$2"
859789af 4267 else
05cbd757 4268 AR_FOR_TARGET="${ncn_target_tool_prefix}$2"
859789af 4269 fi
859789af
AC
4270fi
4271
05cbd757
PB
4272 for ncn_progname in as; do
4273 if test -n "$ncn_target_tool_prefix"; then
4274 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4275set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4276echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4277echo "configure:4278: checking for $ac_word" >&5
cac3d6c4
CM
4278if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
4279 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4280else
55db4b87
PB
4281 if test -n "$AS_FOR_TARGET"; then
4282 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
859789af 4283else
cac3d6c4
CM
4284 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4285 ac_dummy="$PATH"
4286 for ac_dir in $ac_dummy; do
4287 test -z "$ac_dir" && ac_dir=.
4288 if test -f $ac_dir/$ac_word; then
4289 ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4290 break
4291 fi
4292 done
4293 IFS="$ac_save_ifs"
859789af
AC
4294fi
4295fi
cac3d6c4 4296AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
55db4b87 4297if test -n "$AS_FOR_TARGET"; then
cac3d6c4 4298 echo "$ac_t""$AS_FOR_TARGET" 1>&6
859789af 4299else
cac3d6c4 4300 echo "$ac_t""no" 1>&6
859789af
AC
4301fi
4302
05cbd757
PB
4303 fi
4304 if test -z "$ac_cv_prog_AS_FOR_TARGET" && test $build = $target ; then
4305 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4306set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4307echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4308echo "configure:4309: checking for $ac_word" >&5
cac3d6c4
CM
4309if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
4310 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4311else
05cbd757
PB
4312 if test -n "$AS_FOR_TARGET"; then
4313 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
859789af 4314else
cac3d6c4
CM
4315 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4316 ac_dummy="$PATH"
4317 for ac_dir in $ac_dummy; do
4318 test -z "$ac_dir" && ac_dir=.
4319 if test -f $ac_dir/$ac_word; then
4320 ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
4321 break
4322 fi
4323 done
4324 IFS="$ac_save_ifs"
859789af
AC
4325fi
4326fi
cac3d6c4 4327AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
05cbd757 4328if test -n "$AS_FOR_TARGET"; then
cac3d6c4 4329 echo "$ac_t""$AS_FOR_TARGET" 1>&6
859789af 4330else
cac3d6c4 4331 echo "$ac_t""no" 1>&6
859789af 4332fi
cac3d6c4 4333
05cbd757
PB
4334 fi
4335 test -n "$ac_cv_prog_AS_FOR_TARGET" && break
4336done
4337
4338if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
4339 set dummy as
4340 if test $build = $target ; then
4341 AS_FOR_TARGET="$2"
859789af 4342 else
05cbd757 4343 AS_FOR_TARGET="${ncn_target_tool_prefix}$2"
859789af 4344 fi
55db4b87
PB
4345fi
4346
05cbd757
PB
4347 for ncn_progname in cc gcc; do
4348 if test -n "$ncn_target_tool_prefix"; then
4349 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4350set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4351echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4352echo "configure:4353: checking for $ac_word" >&5
cac3d6c4
CM
4353if eval "test \"`echo '$''{'ac_cv_prog_CC_FOR_TARGET'+set}'`\" = set"; then
4354 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87
PB
4355else
4356 if test -n "$CC_FOR_TARGET"; then
4357 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
4358else
cac3d6c4
CM
4359 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4360 ac_dummy="$PATH"
4361 for ac_dir in $ac_dummy; do
4362 test -z "$ac_dir" && ac_dir=.
4363 if test -f $ac_dir/$ac_word; then
4364 ac_cv_prog_CC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4365 break
4366 fi
4367 done
4368 IFS="$ac_save_ifs"
55db4b87
PB
4369fi
4370fi
cac3d6c4 4371CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
55db4b87 4372if test -n "$CC_FOR_TARGET"; then
cac3d6c4 4373 echo "$ac_t""$CC_FOR_TARGET" 1>&6
55db4b87 4374else
cac3d6c4 4375 echo "$ac_t""no" 1>&6
55db4b87
PB
4376fi
4377
05cbd757
PB
4378 fi
4379 if test -z "$ac_cv_prog_CC_FOR_TARGET" && test $build = $target ; then
4380 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4381set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4382echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4383echo "configure:4384: checking for $ac_word" >&5
cac3d6c4
CM
4384if eval "test \"`echo '$''{'ac_cv_prog_CC_FOR_TARGET'+set}'`\" = set"; then
4385 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87 4386else
05cbd757
PB
4387 if test -n "$CC_FOR_TARGET"; then
4388 ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
55db4b87 4389else
cac3d6c4
CM
4390 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4391 ac_dummy="$PATH"
4392 for ac_dir in $ac_dummy; do
4393 test -z "$ac_dir" && ac_dir=.
4394 if test -f $ac_dir/$ac_word; then
4395 ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
4396 break
4397 fi
4398 done
4399 IFS="$ac_save_ifs"
55db4b87
PB
4400fi
4401fi
cac3d6c4 4402CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
05cbd757 4403if test -n "$CC_FOR_TARGET"; then
cac3d6c4 4404 echo "$ac_t""$CC_FOR_TARGET" 1>&6
55db4b87 4405else
cac3d6c4 4406 echo "$ac_t""no" 1>&6
55db4b87 4407fi
cac3d6c4 4408
05cbd757
PB
4409 fi
4410 test -n "$ac_cv_prog_CC_FOR_TARGET" && break
4411done
4412
4413if test -z "$ac_cv_prog_CC_FOR_TARGET" ; then
4414 set dummy cc gcc
4415 if test $build = $target ; then
4416 CC_FOR_TARGET="$2"
55db4b87 4417 else
05cbd757 4418 CC_FOR_TARGET="${ncn_target_tool_prefix}$2"
55db4b87 4419 fi
55db4b87
PB
4420fi
4421
05cbd757
PB
4422 for ncn_progname in c++ g++ cxx gxx; do
4423 if test -n "$ncn_target_tool_prefix"; then
4424 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4425set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4426echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4427echo "configure:4428: checking for $ac_word" >&5
cac3d6c4
CM
4428if eval "test \"`echo '$''{'ac_cv_prog_CXX_FOR_TARGET'+set}'`\" = set"; then
4429 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87
PB
4430else
4431 if test -n "$CXX_FOR_TARGET"; then
4432 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
4433else
cac3d6c4
CM
4434 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4435 ac_dummy="$PATH"
4436 for ac_dir in $ac_dummy; do
4437 test -z "$ac_dir" && ac_dir=.
4438 if test -f $ac_dir/$ac_word; then
4439 ac_cv_prog_CXX_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4440 break
4441 fi
4442 done
4443 IFS="$ac_save_ifs"
55db4b87
PB
4444fi
4445fi
cac3d6c4 4446CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
55db4b87 4447if test -n "$CXX_FOR_TARGET"; then
cac3d6c4 4448 echo "$ac_t""$CXX_FOR_TARGET" 1>&6
55db4b87 4449else
cac3d6c4 4450 echo "$ac_t""no" 1>&6
55db4b87
PB
4451fi
4452
05cbd757
PB
4453 fi
4454 if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test $build = $target ; then
4455 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4456set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4457echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4458echo "configure:4459: checking for $ac_word" >&5
cac3d6c4
CM
4459if eval "test \"`echo '$''{'ac_cv_prog_CXX_FOR_TARGET'+set}'`\" = set"; then
4460 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87 4461else
05cbd757
PB
4462 if test -n "$CXX_FOR_TARGET"; then
4463 ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
55db4b87 4464else
cac3d6c4
CM
4465 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4466 ac_dummy="$PATH"
4467 for ac_dir in $ac_dummy; do
4468 test -z "$ac_dir" && ac_dir=.
4469 if test -f $ac_dir/$ac_word; then
4470 ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
4471 break
4472 fi
4473 done
4474 IFS="$ac_save_ifs"
55db4b87
PB
4475fi
4476fi
cac3d6c4 4477CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
05cbd757 4478if test -n "$CXX_FOR_TARGET"; then
cac3d6c4 4479 echo "$ac_t""$CXX_FOR_TARGET" 1>&6
55db4b87 4480else
cac3d6c4 4481 echo "$ac_t""no" 1>&6
55db4b87 4482fi
cac3d6c4 4483
05cbd757
PB
4484 fi
4485 test -n "$ac_cv_prog_CXX_FOR_TARGET" && break
4486done
4487
4488if test -z "$ac_cv_prog_CXX_FOR_TARGET" ; then
4489 set dummy c++ g++ cxx gxx
4490 if test $build = $target ; then
4491 CXX_FOR_TARGET="$2"
55db4b87 4492 else
05cbd757 4493 CXX_FOR_TARGET="${ncn_target_tool_prefix}$2"
55db4b87 4494 fi
859789af
AC
4495fi
4496
05cbd757
PB
4497 for ncn_progname in dlltool; do
4498 if test -n "$ncn_target_tool_prefix"; then
4499 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4500set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4501echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4502echo "configure:4503: checking for $ac_word" >&5
cac3d6c4
CM
4503if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
4504 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4505else
55db4b87
PB
4506 if test -n "$DLLTOOL_FOR_TARGET"; then
4507 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
859789af 4508else
cac3d6c4
CM
4509 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4510 ac_dummy="$PATH"
4511 for ac_dir in $ac_dummy; do
4512 test -z "$ac_dir" && ac_dir=.
4513 if test -f $ac_dir/$ac_word; then
4514 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4515 break
4516 fi
4517 done
4518 IFS="$ac_save_ifs"
859789af
AC
4519fi
4520fi
cac3d6c4 4521DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
55db4b87 4522if test -n "$DLLTOOL_FOR_TARGET"; then
cac3d6c4 4523 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
859789af 4524else
cac3d6c4 4525 echo "$ac_t""no" 1>&6
859789af
AC
4526fi
4527
05cbd757
PB
4528 fi
4529 if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test $build = $target ; then
4530 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4531set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4532echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4533echo "configure:4534: checking for $ac_word" >&5
cac3d6c4
CM
4534if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
4535 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4536else
05cbd757
PB
4537 if test -n "$DLLTOOL_FOR_TARGET"; then
4538 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
859789af 4539else
cac3d6c4
CM
4540 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4541 ac_dummy="$PATH"
4542 for ac_dir in $ac_dummy; do
4543 test -z "$ac_dir" && ac_dir=.
4544 if test -f $ac_dir/$ac_word; then
4545 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
4546 break
4547 fi
4548 done
4549 IFS="$ac_save_ifs"
859789af
AC
4550fi
4551fi
cac3d6c4 4552DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
05cbd757 4553if test -n "$DLLTOOL_FOR_TARGET"; then
cac3d6c4 4554 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
859789af 4555else
cac3d6c4 4556 echo "$ac_t""no" 1>&6
859789af 4557fi
cac3d6c4 4558
05cbd757
PB
4559 fi
4560 test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET" && break
4561done
4562
4563if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
4564 set dummy dlltool
4565 if test $build = $target ; then
4566 DLLTOOL_FOR_TARGET="$2"
859789af 4567 else
05cbd757 4568 DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
859789af 4569 fi
55db4b87
PB
4570fi
4571
05cbd757
PB
4572 for ncn_progname in gcc; do
4573 if test -n "$ncn_target_tool_prefix"; then
4574 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4575set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4576echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4577echo "configure:4578: checking for $ac_word" >&5
cac3d6c4
CM
4578if eval "test \"`echo '$''{'ac_cv_prog_GCC_FOR_TARGET'+set}'`\" = set"; then
4579 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87
PB
4580else
4581 if test -n "$GCC_FOR_TARGET"; then
4582 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
4583else
cac3d6c4
CM
4584 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4585 ac_dummy="$PATH"
4586 for ac_dir in $ac_dummy; do
4587 test -z "$ac_dir" && ac_dir=.
4588 if test -f $ac_dir/$ac_word; then
4589 ac_cv_prog_GCC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4590 break
4591 fi
4592 done
4593 IFS="$ac_save_ifs"
55db4b87
PB
4594fi
4595fi
cac3d6c4 4596GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
55db4b87 4597if test -n "$GCC_FOR_TARGET"; then
cac3d6c4 4598 echo "$ac_t""$GCC_FOR_TARGET" 1>&6
55db4b87 4599else
cac3d6c4 4600 echo "$ac_t""no" 1>&6
55db4b87
PB
4601fi
4602
05cbd757
PB
4603 fi
4604 if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test $build = $target ; then
4605 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4606set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4607echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4608echo "configure:4609: checking for $ac_word" >&5
cac3d6c4
CM
4609if eval "test \"`echo '$''{'ac_cv_prog_GCC_FOR_TARGET'+set}'`\" = set"; then
4610 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87 4611else
05cbd757
PB
4612 if test -n "$GCC_FOR_TARGET"; then
4613 ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
55db4b87 4614else
cac3d6c4
CM
4615 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4616 ac_dummy="$PATH"
4617 for ac_dir in $ac_dummy; do
4618 test -z "$ac_dir" && ac_dir=.
4619 if test -f $ac_dir/$ac_word; then
4620 ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
4621 break
4622 fi
4623 done
4624 IFS="$ac_save_ifs"
55db4b87
PB
4625fi
4626fi
cac3d6c4 4627GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
05cbd757 4628if test -n "$GCC_FOR_TARGET"; then
cac3d6c4 4629 echo "$ac_t""$GCC_FOR_TARGET" 1>&6
55db4b87 4630else
cac3d6c4 4631 echo "$ac_t""no" 1>&6
55db4b87 4632fi
cac3d6c4 4633
55db4b87 4634 fi
05cbd757
PB
4635 test -n "$ac_cv_prog_GCC_FOR_TARGET" && break
4636done
4637
4638if test -z "$ac_cv_prog_GCC_FOR_TARGET" ; then
4639 GCC_FOR_TARGET="${CC_FOR_TARGET}"
55db4b87
PB
4640fi
4641
05cbd757
PB
4642 for ncn_progname in gcj; do
4643 if test -n "$ncn_target_tool_prefix"; then
4644 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4645set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4646echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4647echo "configure:4648: checking for $ac_word" >&5
cac3d6c4
CM
4648if eval "test \"`echo '$''{'ac_cv_prog_GCJ_FOR_TARGET'+set}'`\" = set"; then
4649 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87
PB
4650else
4651 if test -n "$GCJ_FOR_TARGET"; then
4652 ac_cv_prog_GCJ_FOR_TARGET="$GCJ_FOR_TARGET" # Let the user override the test.
4653else
cac3d6c4
CM
4654 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4655 ac_dummy="$PATH"
4656 for ac_dir in $ac_dummy; do
4657 test -z "$ac_dir" && ac_dir=.
4658 if test -f $ac_dir/$ac_word; then
4659 ac_cv_prog_GCJ_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4660 break
4661 fi
4662 done
4663 IFS="$ac_save_ifs"
55db4b87
PB
4664fi
4665fi
cac3d6c4 4666GCJ_FOR_TARGET="$ac_cv_prog_GCJ_FOR_TARGET"
55db4b87 4667if test -n "$GCJ_FOR_TARGET"; then
cac3d6c4 4668 echo "$ac_t""$GCJ_FOR_TARGET" 1>&6
55db4b87 4669else
cac3d6c4 4670 echo "$ac_t""no" 1>&6
55db4b87
PB
4671fi
4672
05cbd757
PB
4673 fi
4674 if test -z "$ac_cv_prog_GCJ_FOR_TARGET" && test $build = $target ; then
4675 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4676set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4677echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4678echo "configure:4679: checking for $ac_word" >&5
cac3d6c4
CM
4679if eval "test \"`echo '$''{'ac_cv_prog_GCJ_FOR_TARGET'+set}'`\" = set"; then
4680 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87 4681else
05cbd757
PB
4682 if test -n "$GCJ_FOR_TARGET"; then
4683 ac_cv_prog_GCJ_FOR_TARGET="$GCJ_FOR_TARGET" # Let the user override the test.
55db4b87 4684else
cac3d6c4
CM
4685 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4686 ac_dummy="$PATH"
4687 for ac_dir in $ac_dummy; do
4688 test -z "$ac_dir" && ac_dir=.
4689 if test -f $ac_dir/$ac_word; then
4690 ac_cv_prog_GCJ_FOR_TARGET="${ncn_progname}"
4691 break
4692 fi
4693 done
4694 IFS="$ac_save_ifs"
55db4b87
PB
4695fi
4696fi
cac3d6c4 4697GCJ_FOR_TARGET="$ac_cv_prog_GCJ_FOR_TARGET"
05cbd757 4698if test -n "$GCJ_FOR_TARGET"; then
cac3d6c4 4699 echo "$ac_t""$GCJ_FOR_TARGET" 1>&6
55db4b87 4700else
cac3d6c4 4701 echo "$ac_t""no" 1>&6
55db4b87 4702fi
cac3d6c4 4703
05cbd757
PB
4704 fi
4705 test -n "$ac_cv_prog_GCJ_FOR_TARGET" && break
4706done
4707
4708if test -z "$ac_cv_prog_GCJ_FOR_TARGET" ; then
4709 set dummy gcj
4710 if test $build = $target ; then
4711 GCJ_FOR_TARGET="$2"
55db4b87 4712 else
05cbd757 4713 GCJ_FOR_TARGET="${ncn_target_tool_prefix}$2"
55db4b87 4714 fi
55db4b87
PB
4715fi
4716
05cbd757
PB
4717 for ncn_progname in gfortran; do
4718 if test -n "$ncn_target_tool_prefix"; then
4719 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4720set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4721echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4722echo "configure:4723: checking for $ac_word" >&5
cac3d6c4
CM
4723if eval "test \"`echo '$''{'ac_cv_prog_GFORTRAN_FOR_TARGET'+set}'`\" = set"; then
4724 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87
PB
4725else
4726 if test -n "$GFORTRAN_FOR_TARGET"; then
4727 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
4728else
cac3d6c4
CM
4729 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4730 ac_dummy="$PATH"
4731 for ac_dir in $ac_dummy; do
4732 test -z "$ac_dir" && ac_dir=.
4733 if test -f $ac_dir/$ac_word; then
4734 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4735 break
4736 fi
4737 done
4738 IFS="$ac_save_ifs"
55db4b87
PB
4739fi
4740fi
cac3d6c4 4741GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
55db4b87 4742if test -n "$GFORTRAN_FOR_TARGET"; then
cac3d6c4 4743 echo "$ac_t""$GFORTRAN_FOR_TARGET" 1>&6
55db4b87 4744else
cac3d6c4 4745 echo "$ac_t""no" 1>&6
55db4b87
PB
4746fi
4747
05cbd757
PB
4748 fi
4749 if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test $build = $target ; then
4750 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4751set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4752echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4753echo "configure:4754: checking for $ac_word" >&5
cac3d6c4
CM
4754if eval "test \"`echo '$''{'ac_cv_prog_GFORTRAN_FOR_TARGET'+set}'`\" = set"; then
4755 echo $ac_n "(cached) $ac_c" 1>&6
55db4b87 4756else
05cbd757
PB
4757 if test -n "$GFORTRAN_FOR_TARGET"; then
4758 ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
55db4b87 4759else
cac3d6c4
CM
4760 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4761 ac_dummy="$PATH"
4762 for ac_dir in $ac_dummy; do
4763 test -z "$ac_dir" && ac_dir=.
4764 if test -f $ac_dir/$ac_word; then
4765 ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
4766 break
4767 fi
4768 done
4769 IFS="$ac_save_ifs"
55db4b87
PB
4770fi
4771fi
cac3d6c4 4772GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
05cbd757 4773if test -n "$GFORTRAN_FOR_TARGET"; then
cac3d6c4 4774 echo "$ac_t""$GFORTRAN_FOR_TARGET" 1>&6
55db4b87 4775else
cac3d6c4 4776 echo "$ac_t""no" 1>&6
55db4b87 4777fi
cac3d6c4 4778
05cbd757
PB
4779 fi
4780 test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET" && break
4781done
4782
4783if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" ; then
4784 set dummy gfortran
4785 if test $build = $target ; then
4786 GFORTRAN_FOR_TARGET="$2"
55db4b87 4787 else
05cbd757 4788 GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}$2"
55db4b87 4789 fi
859789af
AC
4790fi
4791
05cbd757
PB
4792 for ncn_progname in ld; do
4793 if test -n "$ncn_target_tool_prefix"; then
4794 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4795set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4796echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4797echo "configure:4798: checking for $ac_word" >&5
cac3d6c4
CM
4798if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
4799 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4800else
55db4b87
PB
4801 if test -n "$LD_FOR_TARGET"; then
4802 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
859789af 4803else
cac3d6c4
CM
4804 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4805 ac_dummy="$PATH"
4806 for ac_dir in $ac_dummy; do
4807 test -z "$ac_dir" && ac_dir=.
4808 if test -f $ac_dir/$ac_word; then
4809 ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4810 break
4811 fi
4812 done
4813 IFS="$ac_save_ifs"
859789af
AC
4814fi
4815fi
cac3d6c4 4816LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
55db4b87 4817if test -n "$LD_FOR_TARGET"; then
cac3d6c4 4818 echo "$ac_t""$LD_FOR_TARGET" 1>&6
859789af 4819else
cac3d6c4 4820 echo "$ac_t""no" 1>&6
859789af
AC
4821fi
4822
05cbd757
PB
4823 fi
4824 if test -z "$ac_cv_prog_LD_FOR_TARGET" && test $build = $target ; then
4825 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4826set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4827echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4828echo "configure:4829: checking for $ac_word" >&5
cac3d6c4
CM
4829if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
4830 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4831else
05cbd757
PB
4832 if test -n "$LD_FOR_TARGET"; then
4833 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
859789af 4834else
cac3d6c4
CM
4835 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4836 ac_dummy="$PATH"
4837 for ac_dir in $ac_dummy; do
4838 test -z "$ac_dir" && ac_dir=.
4839 if test -f $ac_dir/$ac_word; then
4840 ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
4841 break
4842 fi
4843 done
4844 IFS="$ac_save_ifs"
859789af
AC
4845fi
4846fi
cac3d6c4 4847LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
05cbd757 4848if test -n "$LD_FOR_TARGET"; then
cac3d6c4 4849 echo "$ac_t""$LD_FOR_TARGET" 1>&6
859789af 4850else
cac3d6c4 4851 echo "$ac_t""no" 1>&6
859789af 4852fi
cac3d6c4 4853
05cbd757
PB
4854 fi
4855 test -n "$ac_cv_prog_LD_FOR_TARGET" && break
4856done
4857
4858if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
4859 set dummy ld
4860 if test $build = $target ; then
4861 LD_FOR_TARGET="$2"
859789af 4862 else
05cbd757 4863 LD_FOR_TARGET="${ncn_target_tool_prefix}$2"
859789af 4864 fi
859789af
AC
4865fi
4866
7e0f7140 4867 for ncn_progname in lipo; do
05cbd757
PB
4868 if test -n "$ncn_target_tool_prefix"; then
4869 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4870set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4871echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4872echo "configure:4873: checking for $ac_word" >&5
cac3d6c4
CM
4873if eval "test \"`echo '$''{'ac_cv_prog_LIPO_FOR_TARGET'+set}'`\" = set"; then
4874 echo $ac_n "(cached) $ac_c" 1>&6
7e0f7140
GK
4875else
4876 if test -n "$LIPO_FOR_TARGET"; then
4877 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
4878else
cac3d6c4
CM
4879 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4880 ac_dummy="$PATH"
4881 for ac_dir in $ac_dummy; do
4882 test -z "$ac_dir" && ac_dir=.
4883 if test -f $ac_dir/$ac_word; then
4884 ac_cv_prog_LIPO_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4885 break
4886 fi
4887 done
4888 IFS="$ac_save_ifs"
7e0f7140
GK
4889fi
4890fi
cac3d6c4 4891LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
7e0f7140 4892if test -n "$LIPO_FOR_TARGET"; then
cac3d6c4 4893 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
7e0f7140 4894else
cac3d6c4 4895 echo "$ac_t""no" 1>&6
7e0f7140
GK
4896fi
4897
4898 fi
4899 if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test $build = $target ; then
4900 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4901set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4902echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4903echo "configure:4904: checking for $ac_word" >&5
cac3d6c4
CM
4904if eval "test \"`echo '$''{'ac_cv_prog_LIPO_FOR_TARGET'+set}'`\" = set"; then
4905 echo $ac_n "(cached) $ac_c" 1>&6
7e0f7140
GK
4906else
4907 if test -n "$LIPO_FOR_TARGET"; then
cac3d6c4
CM
4908 ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
4909else
4910 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4911 ac_dummy="$PATH"
4912 for ac_dir in $ac_dummy; do
4913 test -z "$ac_dir" && ac_dir=.
4914 if test -f $ac_dir/$ac_word; then
4915 ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
4916 break
4917 fi
4918 done
4919 IFS="$ac_save_ifs"
7e0f7140
GK
4920fi
4921fi
cac3d6c4 4922LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
7e0f7140 4923if test -n "$LIPO_FOR_TARGET"; then
cac3d6c4 4924 echo "$ac_t""$LIPO_FOR_TARGET" 1>&6
7e0f7140 4925else
cac3d6c4 4926 echo "$ac_t""no" 1>&6
7e0f7140 4927fi
cac3d6c4 4928
7e0f7140
GK
4929 fi
4930 test -n "$ac_cv_prog_LIPO_FOR_TARGET" && break
4931done
4932
4933if test -z "$ac_cv_prog_LIPO_FOR_TARGET" ; then
4934 set dummy lipo
4935 if test $build = $target ; then
4936 LIPO_FOR_TARGET="$2"
4937 else
4938 LIPO_FOR_TARGET="${ncn_target_tool_prefix}$2"
4939 fi
4940fi
4941
4942 for ncn_progname in nm; do
4943 if test -n "$ncn_target_tool_prefix"; then
4944 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
4945set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 4946echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4947echo "configure:4948: checking for $ac_word" >&5
cac3d6c4
CM
4948if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
4949 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4950else
55db4b87
PB
4951 if test -n "$NM_FOR_TARGET"; then
4952 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
859789af 4953else
cac3d6c4
CM
4954 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4955 ac_dummy="$PATH"
4956 for ac_dir in $ac_dummy; do
4957 test -z "$ac_dir" && ac_dir=.
4958 if test -f $ac_dir/$ac_word; then
4959 ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
4960 break
4961 fi
4962 done
4963 IFS="$ac_save_ifs"
859789af
AC
4964fi
4965fi
cac3d6c4 4966NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
55db4b87 4967if test -n "$NM_FOR_TARGET"; then
cac3d6c4 4968 echo "$ac_t""$NM_FOR_TARGET" 1>&6
859789af 4969else
cac3d6c4 4970 echo "$ac_t""no" 1>&6
859789af
AC
4971fi
4972
05cbd757
PB
4973 fi
4974 if test -z "$ac_cv_prog_NM_FOR_TARGET" && test $build = $target ; then
4975 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
4976set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 4977echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 4978echo "configure:4979: checking for $ac_word" >&5
cac3d6c4
CM
4979if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
4980 echo $ac_n "(cached) $ac_c" 1>&6
859789af 4981else
05cbd757
PB
4982 if test -n "$NM_FOR_TARGET"; then
4983 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
859789af 4984else
cac3d6c4
CM
4985 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
4986 ac_dummy="$PATH"
4987 for ac_dir in $ac_dummy; do
4988 test -z "$ac_dir" && ac_dir=.
4989 if test -f $ac_dir/$ac_word; then
4990 ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
4991 break
4992 fi
4993 done
4994 IFS="$ac_save_ifs"
859789af
AC
4995fi
4996fi
cac3d6c4 4997NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
05cbd757 4998if test -n "$NM_FOR_TARGET"; then
cac3d6c4 4999 echo "$ac_t""$NM_FOR_TARGET" 1>&6
859789af 5000else
cac3d6c4 5001 echo "$ac_t""no" 1>&6
859789af 5002fi
cac3d6c4 5003
05cbd757
PB
5004 fi
5005 test -n "$ac_cv_prog_NM_FOR_TARGET" && break
5006done
5007
5008if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
5009 set dummy nm
5010 if test $build = $target ; then
5011 NM_FOR_TARGET="$2"
859789af 5012 else
05cbd757 5013 NM_FOR_TARGET="${ncn_target_tool_prefix}$2"
859789af 5014 fi
859789af
AC
5015fi
5016
5ae72758 5017 for ncn_progname in objdump; do
05cbd757
PB
5018 if test -n "$ncn_target_tool_prefix"; then
5019 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5020set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 5021echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5022echo "configure:5023: checking for $ac_word" >&5
5ae72758
DJ
5023if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
5024 echo $ac_n "(cached) $ac_c" 1>&6
5025else
5026 if test -n "$OBJDUMP_FOR_TARGET"; then
5027 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
5028else
5029 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5030 ac_dummy="$PATH"
5031 for ac_dir in $ac_dummy; do
5032 test -z "$ac_dir" && ac_dir=.
5033 if test -f $ac_dir/$ac_word; then
5034 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5035 break
5036 fi
5037 done
5038 IFS="$ac_save_ifs"
5039fi
5040fi
5041OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
5042if test -n "$OBJDUMP_FOR_TARGET"; then
5043 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
5044else
5045 echo "$ac_t""no" 1>&6
5046fi
5047
5048 fi
5049 if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test $build = $target ; then
5050 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5051set dummy ${ncn_progname}; ac_word=$2
5052echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5053echo "configure:5054: checking for $ac_word" >&5
5ae72758
DJ
5054if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP_FOR_TARGET'+set}'`\" = set"; then
5055 echo $ac_n "(cached) $ac_c" 1>&6
5056else
5057 if test -n "$OBJDUMP_FOR_TARGET"; then
5058 ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
5059else
5060 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5061 ac_dummy="$PATH"
5062 for ac_dir in $ac_dummy; do
5063 test -z "$ac_dir" && ac_dir=.
5064 if test -f $ac_dir/$ac_word; then
5065 ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
5066 break
5067 fi
5068 done
5069 IFS="$ac_save_ifs"
5070fi
5071fi
5072OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
5073if test -n "$OBJDUMP_FOR_TARGET"; then
5074 echo "$ac_t""$OBJDUMP_FOR_TARGET" 1>&6
5075else
5076 echo "$ac_t""no" 1>&6
5077fi
5078
5079 fi
5080 test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET" && break
5081done
5082
5083if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" ; then
5084 set dummy objdump
5085 if test $build = $target ; then
5086 OBJDUMP_FOR_TARGET="$2"
5087 else
5088 OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}$2"
5089 fi
5090fi
5091
5092 for ncn_progname in ranlib; do
5093 if test -n "$ncn_target_tool_prefix"; then
5094 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5095set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
5096echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5097echo "configure:5098: checking for $ac_word" >&5
cac3d6c4
CM
5098if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
5099 echo $ac_n "(cached) $ac_c" 1>&6
859789af 5100else
55db4b87
PB
5101 if test -n "$RANLIB_FOR_TARGET"; then
5102 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
859789af 5103else
cac3d6c4
CM
5104 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5105 ac_dummy="$PATH"
5106 for ac_dir in $ac_dummy; do
5107 test -z "$ac_dir" && ac_dir=.
5108 if test -f $ac_dir/$ac_word; then
5109 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5110 break
5111 fi
5112 done
5113 IFS="$ac_save_ifs"
859789af
AC
5114fi
5115fi
cac3d6c4 5116RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
55db4b87 5117if test -n "$RANLIB_FOR_TARGET"; then
cac3d6c4 5118 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
859789af 5119else
cac3d6c4 5120 echo "$ac_t""no" 1>&6
859789af
AC
5121fi
5122
05cbd757
PB
5123 fi
5124 if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test $build = $target ; then
5125 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5126set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 5127echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5128echo "configure:5129: checking for $ac_word" >&5
cac3d6c4
CM
5129if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
5130 echo $ac_n "(cached) $ac_c" 1>&6
859789af 5131else
05cbd757
PB
5132 if test -n "$RANLIB_FOR_TARGET"; then
5133 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
859789af 5134else
cac3d6c4
CM
5135 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5136 ac_dummy="$PATH"
5137 for ac_dir in $ac_dummy; do
5138 test -z "$ac_dir" && ac_dir=.
5139 if test -f $ac_dir/$ac_word; then
5140 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
5141 break
5142 fi
5143 done
5144 IFS="$ac_save_ifs"
859789af
AC
5145fi
5146fi
cac3d6c4 5147RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
05cbd757 5148if test -n "$RANLIB_FOR_TARGET"; then
cac3d6c4 5149 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
859789af 5150else
cac3d6c4 5151 echo "$ac_t""no" 1>&6
859789af 5152fi
cac3d6c4 5153
859789af 5154 fi
05cbd757
PB
5155 test -n "$ac_cv_prog_RANLIB_FOR_TARGET" && break
5156done
5157
5158if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
5159 RANLIB_FOR_TARGET=":"
859789af
AC
5160fi
5161
7e0f7140
GK
5162 for ncn_progname in strip; do
5163 if test -n "$ncn_target_tool_prefix"; then
5164 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5165set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 5166echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5167echo "configure:5168: checking for $ac_word" >&5
cac3d6c4
CM
5168if eval "test \"`echo '$''{'ac_cv_prog_STRIP_FOR_TARGET'+set}'`\" = set"; then
5169 echo $ac_n "(cached) $ac_c" 1>&6
7e0f7140
GK
5170else
5171 if test -n "$STRIP_FOR_TARGET"; then
5172 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
5173else
cac3d6c4
CM
5174 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5175 ac_dummy="$PATH"
5176 for ac_dir in $ac_dummy; do
5177 test -z "$ac_dir" && ac_dir=.
5178 if test -f $ac_dir/$ac_word; then
5179 ac_cv_prog_STRIP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5180 break
5181 fi
5182 done
5183 IFS="$ac_save_ifs"
7e0f7140
GK
5184fi
5185fi
cac3d6c4 5186STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
7e0f7140 5187if test -n "$STRIP_FOR_TARGET"; then
cac3d6c4 5188 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
7e0f7140 5189else
cac3d6c4 5190 echo "$ac_t""no" 1>&6
7e0f7140
GK
5191fi
5192
5193 fi
5194 if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test $build = $target ; then
5195 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5196set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 5197echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5198echo "configure:5199: checking for $ac_word" >&5
cac3d6c4
CM
5199if eval "test \"`echo '$''{'ac_cv_prog_STRIP_FOR_TARGET'+set}'`\" = set"; then
5200 echo $ac_n "(cached) $ac_c" 1>&6
7e0f7140
GK
5201else
5202 if test -n "$STRIP_FOR_TARGET"; then
5203 ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
5204else
cac3d6c4
CM
5205 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5206 ac_dummy="$PATH"
5207 for ac_dir in $ac_dummy; do
5208 test -z "$ac_dir" && ac_dir=.
5209 if test -f $ac_dir/$ac_word; then
5210 ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
5211 break
5212 fi
5213 done
5214 IFS="$ac_save_ifs"
7e0f7140
GK
5215fi
5216fi
cac3d6c4 5217STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
7e0f7140 5218if test -n "$STRIP_FOR_TARGET"; then
cac3d6c4 5219 echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
7e0f7140 5220else
cac3d6c4 5221 echo "$ac_t""no" 1>&6
7e0f7140 5222fi
cac3d6c4 5223
7e0f7140
GK
5224 fi
5225 test -n "$ac_cv_prog_STRIP_FOR_TARGET" && break
5226done
5227
5228if test -z "$ac_cv_prog_STRIP_FOR_TARGET" ; then
5229 set dummy strip
5230 if test $build = $target ; then
5231 STRIP_FOR_TARGET="$2"
5232 else
5233 STRIP_FOR_TARGET="${ncn_target_tool_prefix}$2"
5234 fi
5235fi
5236
05cbd757
PB
5237 for ncn_progname in windres; do
5238 if test -n "$ncn_target_tool_prefix"; then
5239 # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
5240set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
cac3d6c4 5241echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5242echo "configure:5243: checking for $ac_word" >&5
cac3d6c4
CM
5243if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
5244 echo $ac_n "(cached) $ac_c" 1>&6
859789af 5245else
55db4b87
PB
5246 if test -n "$WINDRES_FOR_TARGET"; then
5247 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
859789af 5248else
cac3d6c4
CM
5249 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5250 ac_dummy="$PATH"
5251 for ac_dir in $ac_dummy; do
5252 test -z "$ac_dir" && ac_dir=.
5253 if test -f $ac_dir/$ac_word; then
5254 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
5255 break
5256 fi
5257 done
5258 IFS="$ac_save_ifs"
859789af
AC
5259fi
5260fi
cac3d6c4 5261WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
55db4b87 5262if test -n "$WINDRES_FOR_TARGET"; then
cac3d6c4 5263 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
859789af 5264else
cac3d6c4 5265 echo "$ac_t""no" 1>&6
859789af
AC
5266fi
5267
05cbd757
PB
5268 fi
5269 if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test $build = $target ; then
5270 # Extract the first word of "${ncn_progname}", so it can be a program name with args.
5271set dummy ${ncn_progname}; ac_word=$2
cac3d6c4 5272echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
bd70a46f 5273echo "configure:5274: checking for $ac_word" >&5
cac3d6c4
CM
5274if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
5275 echo $ac_n "(cached) $ac_c" 1>&6
859789af 5276else
05cbd757
PB
5277 if test -n "$WINDRES_FOR_TARGET"; then
5278 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
859789af 5279else
cac3d6c4
CM
5280 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
5281 ac_dummy="$PATH"
5282 for ac_dir in $ac_dummy; do
5283 test -z "$ac_dir" && ac_dir=.
5284 if test -f $ac_dir/$ac_word; then
5285 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
5286 break
5287 fi
5288 done
5289 IFS="$ac_save_ifs"
859789af
AC
5290fi
5291fi
cac3d6c4 5292WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
05cbd757 5293if test -n "$WINDRES_FOR_TARGET"; then
cac3d6c4 5294 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
859789af 5295else
cac3d6c4 5296 echo "$ac_t""no" 1>&6
859789af 5297fi
cac3d6c4 5298
05cbd757
PB
5299 fi
5300 test -n "$ac_cv_prog_WINDRES_FOR_TARGET" && break
5301done
5302
5303if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
5304 set dummy windres
5305 if test $build = $target ; then
5306 WINDRES_FOR_TARGET="$2"
859789af 5307 else
05cbd757 5308 WINDRES_FOR_TARGET="${ncn_target_tool_prefix}$2"
859789af 5309 fi
859789af
AC
5310fi
5311
852e5f18 5312
55db4b87
PB
5313CONFIGURED_AR_FOR_TARGET="$AR_FOR_TARGET"
5314CONFIGURED_AS_FOR_TARGET="$AS_FOR_TARGET"
5315CONFIGURED_CC_FOR_TARGET="$CC_FOR_TARGET"
5316CONFIGURED_CXX_FOR_TARGET="$CXX_FOR_TARGET"
5317CONFIGURED_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET"
5318CONFIGURED_GCC_FOR_TARGET="$GCC_FOR_TARGET"
5319CONFIGURED_GCJ_FOR_TARGET="$GCJ_FOR_TARGET"
5320CONFIGURED_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET"
5321CONFIGURED_LD_FOR_TARGET="$LD_FOR_TARGET"
7e0f7140 5322CONFIGURED_LIPO_FOR_TARGET="$LIPO_FOR_TARGET"
55db4b87 5323CONFIGURED_NM_FOR_TARGET="$NM_FOR_TARGET"
5ae72758 5324CONFIGURED_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET"
55db4b87 5325CONFIGURED_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET"
7e0f7140 5326CONFIGURED_STRIP_FOR_TARGET="$STRIP_FOR_TARGET"
55db4b87 5327CONFIGURED_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET"
252b5132 5328
a0da8069 5329
4b1cb4fe 5330
a0da8069
NN
5331# Fix up target tools.
5332if test "x${build}" = "x${host}" ; then
5333 # In this case, the newly built tools can and should be used,
5334 # so we override the results of the autoconf tests.
5335 # This should really only happen when the tools are actually being built,
5336 # but that's a further refinement. The new build scheme, where
5337 # tools are built into a structure paralleling where they're installed,
5338 # should also eliminate all of this cleanly.
5339 AR_FOR_TARGET="\$(USUAL_AR_FOR_TARGET)"
5340 AS_FOR_TARGET="\$(USUAL_AS_FOR_TARGET)"
55db4b87
PB
5341 CC_FOR_TARGET="\$(USUAL_CC_FOR_TARGET)"
5342 CXX_FOR_TARGET="\$(USUAL_CXX_FOR_TARGET)"
5343 RAW_CXX_FOR_TARGET="\$(USUAL_RAW_CXX_FOR_TARGET)"
a0da8069 5344 DLLTOOL_FOR_TARGET="\$(USUAL_DLLTOOL_FOR_TARGET)"
55db4b87
PB
5345 GCC_FOR_TARGET="\$(USUAL_GCC_FOR_TARGET)"
5346 GCJ_FOR_TARGET="\$(USUAL_GCJ_FOR_TARGET)"
5347 GFORTRAN_FOR_TARGET="\$(USUAL_GFORTRAN_FOR_TARGET)"
a0da8069 5348 LD_FOR_TARGET="\$(USUAL_LD_FOR_TARGET)"
7e0f7140 5349 LIPO_FOR_TARGET="\$(USUAL_LIPO_FOR_TARGET)"
a0da8069 5350 NM_FOR_TARGET="\$(USUAL_NM_FOR_TARGET)"
5ae72758 5351 OBJDUMP_FOR_TARGET="\$(USUAL_OBJDUMP_FOR_TARGET)"
a0da8069 5352 RANLIB_FOR_TARGET="\$(USUAL_RANLIB_FOR_TARGET)"
7e0f7140 5353 STRIP_FOR_TARGET="\$(USUAL_STRIP_FOR_TARGET)"
a0da8069 5354 WINDRES_FOR_TARGET="\$(USUAL_WINDRES_FOR_TARGET)"
54752a6b
NN
5355else
5356 # Just use the ones we found.
5357 AR_FOR_TARGET="\$(CONFIGURED_AR_FOR_TARGET)"
5358 AS_FOR_TARGET="\$(CONFIGURED_AS_FOR_TARGET)"
55db4b87
PB
5359 CC_FOR_TARGET="\$(CONFIGURED_CC_FOR_TARGET)"
5360 CXX_FOR_TARGET="\$(CONFIGURED_CXX_FOR_TARGET)"
5361 RAW_CXX_FOR_TARGET="\$(CONFIGURED_CXX_FOR_TARGET)"
54752a6b 5362 DLLTOOL_FOR_TARGET="\$(CONFIGURED_DLLTOOL_FOR_TARGET)"
55db4b87
PB
5363 GCC_FOR_TARGET="\$(CONFIGURED_GCC_FOR_TARGET)"
5364 GCJ_FOR_TARGET="\$(CONFIGURED_GCJ_FOR_TARGET)"
5365 GFORTRAN_FOR_TARGET="\$(CONFIGURED_GFORTRAN_FOR_TARGET)"
54752a6b 5366 LD_FOR_TARGET="\$(CONFIGURED_LD_FOR_TARGET)"
7e0f7140 5367 LIPO_FOR_TARGET="\$(CONFIGURED_LIPO_FOR_TARGET)"
54752a6b 5368 NM_FOR_TARGET="\$(CONFIGURED_NM_FOR_TARGET)"
5ae72758 5369 OBJDUMP_FOR_TARGET="\$(CONFIGURED_OBJDUMP_FOR_TARGET)"
54752a6b 5370 RANLIB_FOR_TARGET="\$(CONFIGURED_RANLIB_FOR_TARGET)"
7e0f7140 5371 STRIP_FOR_TARGET="\$(CONFIGURED_STRIP_FOR_TARGET)"
cac3d6c4 5372 WINDRES_FOR_TARGET="\$(CONFIGURED_WINDRES_FOR_TARGET)"
a0da8069 5373fi
54752a6b
NN
5374
5375
5376
a0da8069
NN
5377# Certain tools may need extra flags.
5378AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
5379RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
5380NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
5381
cac3d6c4 5382echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
bd70a46f 5383echo "configure:5384: checking whether to enable maintainer-specific portions of Makefiles" >&5
3d5e36ae
AO
5384# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
5385if test "${enable_maintainer_mode+set}" = set; then
5386 enableval="$enable_maintainer_mode"
5387 USE_MAINTAINER_MODE=$enableval
5388else
5389 USE_MAINTAINER_MODE=no
cac3d6c4
CM
5390fi
5391
5392echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
3d5e36ae
AO
5393
5394
5395if test "$USE_MAINTAINER_MODE" = yes; then
5396 MAINTAINER_MODE_TRUE=
5397 MAINTAINER_MODE_FALSE='#'
5398else
5399 MAINTAINER_MODE_TRUE='#'
5400 MAINTAINER_MODE_FALSE=
cac3d6c4 5401fi
3d5e36ae
AO
5402MAINT=$MAINTAINER_MODE_TRUE
5403
1d39f329
NN
5404# ---------------------
5405# GCC bootstrap support
5406# ---------------------
5407
5408# Stage specific cflags for build.
5409stage1_cflags="-g"
5410case $build in
5411 vax-*-*)
5412 case ${GCC} in
5413 yes) stage1_cflags="-g -Wa,-J" ;;
5414 *) stage1_cflags="-g -J" ;;
5415 esac ;;
5416 powerpc-*-darwin*)
5417 # The spiffy cpp-precomp chokes on some legitimate constructs in GCC
5418 # sources; use -no-cpp-precomp to get to GNU cpp.
5419 # Apple's GCC has bugs in designated initializer handling, so disable
5420 # that too.
5421 stage1_cflags="-g -no-cpp-precomp -DHAVE_DESIGNATED_INITIALIZERS=0"
5422 ;;
5423esac
5424
5425
dfdffa2c 5426# It makes debugging easier if we create as symlinks the stage directories
9cb3fa6f 5427# gcc for stageN-gcc and stagePREV-gcc for stage(N-1). In case this is not
dfdffa2c 5428# possible, however, we can resort to mv.
cac3d6c4 5429echo $ac_n "checking if symbolic links between directories work""... $ac_c" 1>&6
bd70a46f 5430echo "configure:5431: checking if symbolic links between directories work" >&5
cac3d6c4
CM
5431if eval "test \"`echo '$''{'gcc_cv_prog_ln_s_dir'+set}'`\" = set"; then
5432 echo $ac_n "(cached) $ac_c" 1>&6
dfdffa2c
PB
5433else
5434 if test "${LN_S}" = "ln -s" \
5435 && mkdir confdir.s1 \
5436 && ln -s confdir.s1 confdir.s2 \
5437 && echo timestamp1 > confdir.s1/conftest.1 \
5438 && cmp confdir.s1/conftest.1 confdir.s2/conftest.1 \
5439 && echo timestamp2 > confdir.s2/conftest.2 \
5440 && cmp confdir.s1/conftest.2 confdir.s1/conftest.2 \
5441 && rm -f confdir.s2; then
5442 gcc_cv_prog_ln_s_dir=yes
5443else
b00612cc 5444 gcc_cv_prog_ln_s_dir=no
dfdffa2c
PB
5445fi
5446rm -rf confdir.s1 confdir.s2
5447fi
cac3d6c4
CM
5448
5449echo "$ac_t""$gcc_cv_prog_ln_s_dir" 1>&6
dfdffa2c
PB
5450
5451case ${gcc_cv_prog_ln_s_dir} in
5452 yes)
5453 CREATE_LINK_TO_DIR='ln -s $$1 $$2'
5454 UNDO_LINK_TO_DIR='rm -f $$1' ;;
5455 *)
5456 CREATE_LINK_TO_DIR='mv $$1 $$2'
5457 UNDO_LINK_TO_DIR='mv $$1 $$2' ;;
5458esac
5459
5460
5461
1d39f329
NN
5462# Enable -Werror in bootstrap stage2 and later.
5463# Change the default to "no" on release branches.
5464# Check whether --enable-werror or --disable-werror was given.
5465if test "${enable_werror+set}" = set; then
5466 enableval="$enable_werror"
cac3d6c4 5467 :
1d39f329
NN
5468else
5469 enable_werror=yes
cac3d6c4
CM
5470fi
5471
1a6f2dc7
NN
5472case ${enable_werror} in
5473 yes) stage2_werror_flag="--enable-werror-always" ;;
5474 *) stage2_werror_flag="" ;;
1d39f329
NN
5475esac
5476
5477
cac3d6c4
CM
5478trap '' 1 2 15
5479cat > confcache <<\EOF
a0da8069
NN
5480# This file is a shell script that caches the results of configure
5481# tests run on this system so they can be shared between configure
cac3d6c4
CM
5482# scripts and configure runs. It is not useful on other systems.
5483# If it contains results you don't want to keep, you may remove or edit it.
a0da8069 5484#
cac3d6c4
CM
5485# By default, configure uses ./config.cache as the cache file,
5486# creating it if it does not exist already. You can give configure
5487# the --cache-file=FILE option to use a different cache file; that is
5488# what configure does when it calls configure scripts in
5489# subdirectories, so they share the cache.
5490# Giving --cache-file=/dev/null disables caching, for debugging configure.
5491# config.status only pays attention to the cache file if you give it the
5492# --recheck option to rerun configure.
a0da8069 5493#
cac3d6c4 5494EOF
a0da8069
NN
5495# The following way of writing the cache mishandles newlines in values,
5496# but we know of no workaround that is simple, portable, and efficient.
5497# So, don't put newlines in cache variables' values.
5498# Ultrix sh set writes to stderr and can't be redirected directly,
5499# and sets the high bit in the cache file unless we assign to the vars.
cac3d6c4
CM
5500(set) 2>&1 |
5501 case `(ac_space=' '; set | grep ac_space) 2>&1` in
5502 *ac_space=\ *)
5503 # `set' does not quote correctly, so add quotes (double-quote substitution
5504 # turns \\\\ into \\, and sed turns \\ into \).
5505 sed -n \
5506 -e "s/'/'\\\\''/g" \
5507 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
5508 ;;
5509 *)
5510 # `set' quotes correctly as required by POSIX, so do not add quotes.
5511 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
5512 ;;
5513 esac >> confcache
5514if cmp -s $cache_file confcache; then
5515 :
5516else
a0da8069 5517 if test -w $cache_file; then
cac3d6c4
CM
5518 echo "updating cache $cache_file"
5519 cat confcache > $cache_file
a0da8069
NN
5520 else
5521 echo "not updating unwritable cache $cache_file"
5522 fi
852e5f18 5523fi
a0da8069 5524rm -f confcache
852e5f18 5525
cac3d6c4
CM
5526trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
5527
a0da8069
NN
5528test "x$prefix" = xNONE && prefix=$ac_default_prefix
5529# Let make expand exec_prefix.
5530test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
852e5f18 5531
cac3d6c4
CM
5532# Any assignment to VPATH causes Sun make to only execute
5533# the first set of double-colon rules, so remove it if not needed.
5534# If there is a colon in the path, we need to keep it.
a0da8069 5535if test "x$srcdir" = x.; then
cac3d6c4 5536 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
a0da8069 5537fi
252b5132 5538
cac3d6c4
CM
5539trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
5540
a0da8069
NN
5541# Transform confdefs.h into DEFS.
5542# Protect against shell expansion while executing Makefile rules.
5543# Protect against Makefile macro expansion.
cac3d6c4
CM
5544cat > conftest.defs <<\EOF
5545s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
5546s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
5547s%\[%\\&%g
5548s%\]%\\&%g
5549s%\$%$$%g
5550EOF
5551DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
5552rm -f conftest.defs
852e5f18 5553
376a0e54 5554
cac3d6c4 5555# Without the "./", some shells look in PATH for config.status.
376a0e54 5556: ${CONFIG_STATUS=./config.status}
cac3d6c4
CM
5557
5558echo creating $CONFIG_STATUS
5559rm -f $CONFIG_STATUS
5560cat > $CONFIG_STATUS <<EOF
5561#! /bin/sh
5562# Generated automatically by configure.
a0da8069 5563# Run this file to recreate the current configuration.
cac3d6c4
CM
5564# This directory was configured as follows,
5565# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5566#
5567# $0 $ac_configure_args
5568#
a0da8069 5569# Compiler output produced by configure, useful for debugging
cac3d6c4 5570# configure, is in ./config.log if it exists.
376a0e54 5571
cac3d6c4
CM
5572ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
5573for ac_option
a0da8069 5574do
cac3d6c4 5575 case "\$ac_option" in
a0da8069 5576 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
cac3d6c4
CM
5577 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
5578 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
5579 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
5580 echo "$CONFIG_STATUS generated by autoconf version 2.13"
5581 exit 0 ;;
5582 -help | --help | --hel | --he | --h)
5583 echo "\$ac_cs_usage"; exit 0 ;;
5584 *) echo "\$ac_cs_usage"; exit 1 ;;
376a0e54
CM
5585 esac
5586done
5587
cac3d6c4
CM
5588ac_given_srcdir=$srcdir
5589ac_given_INSTALL="$INSTALL"
376a0e54 5590
cac3d6c4
CM
5591trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
5592EOF
5593cat >> $CONFIG_STATUS <<EOF
376a0e54 5594
cac3d6c4
CM
5595# Protect against being on the right side of a sed subst in config.status.
5596sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
5597 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
5598$ac_vpsub
5599$extrasub
5600s%@SHELL@%$SHELL%g
5601s%@CFLAGS@%$CFLAGS%g
5602s%@CPPFLAGS@%$CPPFLAGS%g
5603s%@CXXFLAGS@%$CXXFLAGS%g
5604s%@FFLAGS@%$FFLAGS%g
5605s%@DEFS@%$DEFS%g
5606s%@LDFLAGS@%$LDFLAGS%g
5607s%@LIBS@%$LIBS%g
5608s%@exec_prefix@%$exec_prefix%g
5609s%@prefix@%$prefix%g
5610s%@program_transform_name@%$program_transform_name%g
5611s%@bindir@%$bindir%g
5612s%@sbindir@%$sbindir%g
5613s%@libexecdir@%$libexecdir%g
5614s%@datadir@%$datadir%g
5615s%@sysconfdir@%$sysconfdir%g
5616s%@sharedstatedir@%$sharedstatedir%g
5617s%@localstatedir@%$localstatedir%g
5618s%@libdir@%$libdir%g
5619s%@includedir@%$includedir%g
5620s%@oldincludedir@%$oldincludedir%g
5621s%@infodir@%$infodir%g
5622s%@mandir@%$mandir%g
5623s%@host@%$host%g
5624s%@host_alias@%$host_alias%g
5625s%@host_cpu@%$host_cpu%g
5626s%@host_vendor@%$host_vendor%g
5627s%@host_os@%$host_os%g
5628s%@target@%$target%g
5629s%@target_alias@%$target_alias%g
5630s%@target_cpu@%$target_cpu%g
5631s%@target_vendor@%$target_vendor%g
5632s%@target_os@%$target_os%g
5633s%@build@%$build%g
5634s%@build_alias@%$build_alias%g
5635s%@build_cpu@%$build_cpu%g
5636s%@build_vendor@%$build_vendor%g
5637s%@build_os@%$build_os%g
5638s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5639s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
5640s%@INSTALL_DATA@%$INSTALL_DATA%g
5641s%@LN@%$LN%g
5642s%@LN_S@%$LN_S%g
5643s%@TOPLEVEL_CONFIGURE_ARGUMENTS@%$TOPLEVEL_CONFIGURE_ARGUMENTS%g
5644s%@build_subdir@%$build_subdir%g
5645s%@host_subdir@%$host_subdir%g
5646s%@target_subdir@%$target_subdir%g
5647s%@CC@%$CC%g
5648s%@GNATBIND@%$GNATBIND%g
5649s%@do_compare@%$do_compare%g
5650s%@gmplibs@%$gmplibs%g
5651s%@gmpinc@%$gmpinc%g
5652s%@stage1_languages@%$stage1_languages%g
5653s%@SYSROOT_CFLAGS_FOR_TARGET@%$SYSROOT_CFLAGS_FOR_TARGET%g
5654s%@CONFIGURED_BISON@%$CONFIGURED_BISON%g
5655s%@CONFIGURED_YACC@%$CONFIGURED_YACC%g
5656s%@CONFIGURED_M4@%$CONFIGURED_M4%g
5657s%@CONFIGURED_FLEX@%$CONFIGURED_FLEX%g
5658s%@CONFIGURED_LEX@%$CONFIGURED_LEX%g
5659s%@CONFIGURED_MAKEINFO@%$CONFIGURED_MAKEINFO%g
5660s%@bootstrap_lean@%$bootstrap_lean%g
a0da8069 5661/@serialization_dependencies@/r $serialization_dependencies
cac3d6c4 5662s%@serialization_dependencies@%%g
a0da8069 5663/@host_makefile_frag@/r $host_makefile_frag
cac3d6c4 5664s%@host_makefile_frag@%%g
a0da8069 5665/@target_makefile_frag@/r $target_makefile_frag
cac3d6c4 5666s%@target_makefile_frag@%%g
a0da8069 5667/@alphaieee_frag@/r $alphaieee_frag
cac3d6c4 5668s%@alphaieee_frag@%%g
a0da8069 5669/@ospace_frag@/r $ospace_frag
cac3d6c4
CM
5670s%@ospace_frag@%%g
5671s%@RPATH_ENVVAR@%$RPATH_ENVVAR%g
5672s%@BUILD_PREFIX@%$BUILD_PREFIX%g
5673s%@BUILD_PREFIX_1@%$BUILD_PREFIX_1%g
5674s%@tooldir@%$tooldir%g
5675s%@build_tooldir@%$build_tooldir%g
5676s%@GDB_TK@%$GDB_TK%g
5677s%@build_configargs@%$build_configargs%g
5678s%@build_configdirs@%$build_configdirs%g
5679s%@host_configargs@%$host_configargs%g
5680s%@configdirs@%$configdirs%g
5681s%@target_configargs@%$target_configargs%g
5682s%@target_configdirs@%$target_configdirs%g
5683s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
5684s%@config_shell@%$config_shell%g
5685s%@AR@%$AR%g
5686s%@AS@%$AS%g
5687s%@DLLTOOL@%$DLLTOOL%g
5688s%@LD@%$LD%g
5689s%@NM@%$NM%g
5690s%@RANLIB@%$RANLIB%g
5691s%@WINDRES@%$WINDRES%g
5692s%@OBJCOPY@%$OBJCOPY%g
5693s%@OBJDUMP@%$OBJDUMP%g
5694s%@CXX@%$CXX%g
5695s%@CFLAGS_FOR_BUILD@%$CFLAGS_FOR_BUILD%g
5696s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
5697s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
5698s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
5699s%@CXX_FOR_TARGET@%$CXX_FOR_TARGET%g
5700s%@DLLTOOL_FOR_TARGET@%$DLLTOOL_FOR_TARGET%g
5701s%@GCC_FOR_TARGET@%$GCC_FOR_TARGET%g
5702s%@GCJ_FOR_TARGET@%$GCJ_FOR_TARGET%g
5703s%@GFORTRAN_FOR_TARGET@%$GFORTRAN_FOR_TARGET%g
5704s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
5705s%@LIPO_FOR_TARGET@%$LIPO_FOR_TARGET%g
5706s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
5ae72758 5707s%@OBJDUMP_FOR_TARGET@%$OBJDUMP_FOR_TARGET%g
cac3d6c4
CM
5708s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
5709s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
5710s%@WINDRES_FOR_TARGET@%$WINDRES_FOR_TARGET%g
5711s%@CONFIGURED_AR_FOR_TARGET@%$CONFIGURED_AR_FOR_TARGET%g
5712s%@CONFIGURED_AS_FOR_TARGET@%$CONFIGURED_AS_FOR_TARGET%g
5713s%@CONFIGURED_CC_FOR_TARGET@%$CONFIGURED_CC_FOR_TARGET%g
5714s%@CONFIGURED_CXX_FOR_TARGET@%$CONFIGURED_CXX_FOR_TARGET%g
5715s%@CONFIGURED_DLLTOOL_FOR_TARGET@%$CONFIGURED_DLLTOOL_FOR_TARGET%g
5716s%@CONFIGURED_GCC_FOR_TARGET@%$CONFIGURED_GCC_FOR_TARGET%g
5717s%@CONFIGURED_GCJ_FOR_TARGET@%$CONFIGURED_GCJ_FOR_TARGET%g
5718s%@CONFIGURED_GFORTRAN_FOR_TARGET@%$CONFIGURED_GFORTRAN_FOR_TARGET%g
5719s%@CONFIGURED_LD_FOR_TARGET@%$CONFIGURED_LD_FOR_TARGET%g
5720s%@CONFIGURED_LIPO_FOR_TARGET@%$CONFIGURED_LIPO_FOR_TARGET%g
5721s%@CONFIGURED_NM_FOR_TARGET@%$CONFIGURED_NM_FOR_TARGET%g
5ae72758 5722s%@CONFIGURED_OBJDUMP_FOR_TARGET@%$CONFIGURED_OBJDUMP_FOR_TARGET%g
cac3d6c4
CM
5723s%@CONFIGURED_RANLIB_FOR_TARGET@%$CONFIGURED_RANLIB_FOR_TARGET%g
5724s%@CONFIGURED_STRIP_FOR_TARGET@%$CONFIGURED_STRIP_FOR_TARGET%g
5725s%@CONFIGURED_WINDRES_FOR_TARGET@%$CONFIGURED_WINDRES_FOR_TARGET%g
5726s%@FLAGS_FOR_TARGET@%$FLAGS_FOR_TARGET%g
5727s%@RAW_CXX_FOR_TARGET@%$RAW_CXX_FOR_TARGET%g
5728s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
5729s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
5730s%@MAINT@%$MAINT%g
5731s%@stage1_cflags@%$stage1_cflags%g
5732s%@CREATE_LINK_TO_DIR@%$CREATE_LINK_TO_DIR%g
5733s%@UNDO_LINK_TO_DIR@%$UNDO_LINK_TO_DIR%g
5734s%@stage2_werror_flag@%$stage2_werror_flag%g
5735
a0da8069 5736CEOF
cac3d6c4 5737EOF
252b5132 5738
cac3d6c4
CM
5739cat >> $CONFIG_STATUS <<\EOF
5740
5741# Split the substitutions into bite-sized pieces for seds with
5742# small command number limits, like on Digital OSF/1 and HP-UX.
5743ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5744ac_file=1 # Number of current file.
5745ac_beg=1 # First line for current file.
5746ac_end=$ac_max_sed_cmds # Line after last line for current file.
5747ac_more_lines=:
5748ac_sed_cmds=""
5749while $ac_more_lines; do
5750 if test $ac_beg -gt 1; then
5751 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5752 else
5753 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5754 fi
5755 if test ! -s conftest.s$ac_file; then
5756 ac_more_lines=false
5757 rm -f conftest.s$ac_file
5758 else
5759 if test -z "$ac_sed_cmds"; then
5760 ac_sed_cmds="sed -f conftest.s$ac_file"
a0da8069 5761 else
cac3d6c4 5762 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
a0da8069 5763 fi
cac3d6c4
CM
5764 ac_file=`expr $ac_file + 1`
5765 ac_beg=$ac_end
5766 ac_end=`expr $ac_end + $ac_max_sed_cmds`
852e5f18 5767 fi
cac3d6c4
CM
5768done
5769if test -z "$ac_sed_cmds"; then
5770 ac_sed_cmds=cat
5771fi
5772EOF
5773
5774cat >> $CONFIG_STATUS <<EOF
252b5132 5775
cac3d6c4
CM
5776CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
5777EOF
5778cat >> $CONFIG_STATUS <<\EOF
5779for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
a0da8069 5780 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
cac3d6c4
CM
5781 case "$ac_file" in
5782 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5783 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5784 *) ac_file_in="${ac_file}.in" ;;
a0da8069 5785 esac
252b5132 5786
cac3d6c4 5787 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
376a0e54 5788
cac3d6c4
CM
5789 # Remove last slash and all that follows it. Not all systems have dirname.
5790 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5791 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5792 # The file is in a subdirectory.
5793 test ! -d "$ac_dir" && mkdir "$ac_dir"
5794 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
5795 # A "../" for each directory in $ac_dir_suffix.
5796 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
5797 else
5798 ac_dir_suffix= ac_dots=
5799 fi
252b5132 5800
cac3d6c4
CM
5801 case "$ac_given_srcdir" in
5802 .) srcdir=.
5803 if test -z "$ac_dots"; then top_srcdir=.
5804 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
5805 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
a0da8069 5806 *) # Relative path.
cac3d6c4
CM
5807 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
5808 top_srcdir="$ac_dots$ac_given_srcdir" ;;
5809 esac
252b5132 5810
cac3d6c4
CM
5811 case "$ac_given_INSTALL" in
5812 [/$]*) INSTALL="$ac_given_INSTALL" ;;
5813 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
5814 esac
252b5132 5815
cac3d6c4
CM
5816 echo creating "$ac_file"
5817 rm -f "$ac_file"
5818 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
5819 case "$ac_file" in
5820 *Makefile*) ac_comsub="1i\\
5821# $configure_input" ;;
5822 *) ac_comsub= ;;
a0da8069 5823 esac
252b5132 5824
cac3d6c4
CM
5825 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5826 sed -e "$ac_comsub
5827s%@configure_input@%$configure_input%g
5828s%@srcdir@%$srcdir%g
5829s%@top_srcdir@%$top_srcdir%g
5830s%@INSTALL@%$INSTALL%g
5831" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
5832fi; done
5833rm -f conftest.s*
c148b4cb 5834
cac3d6c4
CM
5835EOF
5836cat >> $CONFIG_STATUS <<EOF
c148b4cb 5837
cac3d6c4
CM
5838EOF
5839cat >> $CONFIG_STATUS <<\EOF
c148b4cb 5840
cac3d6c4
CM
5841exit 0
5842EOF
c148b4cb 5843chmod +x $CONFIG_STATUS
cac3d6c4
CM
5844rm -fr confdefs* $ac_clean_files
5845test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
c148b4cb 5846
This page took 0.656875 seconds and 4 git commands to generate.