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