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