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