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