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