OSDN Git Service

* Makefile.in (build_tooldir): new variable, same as old
[pf3gnuchains/gcc-fork.git] / gcc / configure
1 #! /bin/sh
2
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.12.1 
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:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15   --with-gnu-ld           arrange to work with GNU ld."
16 ac_help="$ac_help
17   --with-ld               arrange to use the specified ld (full pathname)."
18 ac_help="$ac_help
19   --with-gnu-as           arrange to work with GNU as."
20 ac_help="$ac_help
21   --with-as               arrange to use the specified as (full pathname)."
22 ac_help="$ac_help
23   --with-stabs            arrange to use stabs instead of host debug format."
24 ac_help="$ac_help
25   --with-elf              arrange to use ELF instead of host debug format."
26 ac_help="$ac_help
27   --with-local-prefix=DIR specifies directory to put local include."
28 ac_help="$ac_help
29   --with-gxx-include-dir=DIR
30                           specifies directory to put g++ header files."
31 ac_help="$ac_help
32   --enable-checking       enable expensive run-time checks."
33 ac_help="$ac_help
34   --enable-cpplib         use cpplib for the C preprocessor."
35 ac_help="$ac_help
36   --enable-c-cpplib       link cpplib directly into C and C++ compilers
37                           (implies --enable-cpplib)."
38 ac_help="$ac_help
39   --enable-c-mbchar       enable multibyte characters for C and C++."
40 ac_help="$ac_help
41   --enable-haifa          use the experimental scheduler.
42   --disable-haifa         don't use the experimental scheduler for the
43                           targets which normally enable it."
44 ac_help="$ac_help
45   --with-fast-fixincludes    use a faster fixinclude program (experimental)"
46 ac_help="$ac_help
47   --enable-init-priority  use attributes to assign initialization order
48                           for static objects.
49   --disable-init-priority conform to ISO C++ rules for ordering static objects
50                           (i.e. initialized in order of declaration). "
51 ac_help="$ac_help
52   --enable-threads        enable thread usage for target GCC.
53   --enable-threads=LIB    use LIB thread package for target GCC."
54 ac_help="$ac_help
55   --enable-objc-gc        enable the use of Boehm's garbage collector with
56                           the GNU Objective-C runtime."
57
58 # Initialize some variables set by options.
59 # The variables have the same names as the options, with
60 # dashes changed to underlines.
61 build=NONE
62 cache_file=./config.cache
63 exec_prefix=NONE
64 host=NONE
65 no_create=
66 nonopt=NONE
67 no_recursion=
68 prefix=NONE
69 program_prefix=NONE
70 program_suffix=NONE
71 program_transform_name=s,x,x,
72 silent=
73 site=
74 srcdir=
75 target=NONE
76 verbose=
77 x_includes=NONE
78 x_libraries=NONE
79 bindir='${exec_prefix}/bin'
80 sbindir='${exec_prefix}/sbin'
81 libexecdir='${exec_prefix}/libexec'
82 datadir='${prefix}/share'
83 sysconfdir='${prefix}/etc'
84 sharedstatedir='${prefix}/com'
85 localstatedir='${prefix}/var'
86 libdir='${exec_prefix}/lib'
87 includedir='${prefix}/include'
88 oldincludedir='/usr/include'
89 infodir='${prefix}/info'
90 mandir='${prefix}/man'
91
92 # Initialize some other variables.
93 subdirs=
94 MFLAGS= MAKEFLAGS=
95 SHELL=${CONFIG_SHELL-/bin/sh}
96 # Maximum number of lines to put in a shell here document.
97 ac_max_here_lines=12
98
99 ac_prev=
100 for ac_option
101 do
102
103   # If the previous option needs an argument, assign it.
104   if test -n "$ac_prev"; then
105     eval "$ac_prev=\$ac_option"
106     ac_prev=
107     continue
108   fi
109
110   case "$ac_option" in
111   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
112   *) ac_optarg= ;;
113   esac
114
115   # Accept the important Cygnus configure options, so we can diagnose typos.
116
117   case "$ac_option" in
118
119   -bindir | --bindir | --bindi | --bind | --bin | --bi)
120     ac_prev=bindir ;;
121   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
122     bindir="$ac_optarg" ;;
123
124   -build | --build | --buil | --bui | --bu)
125     ac_prev=build ;;
126   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
127     build="$ac_optarg" ;;
128
129   -cache-file | --cache-file | --cache-fil | --cache-fi \
130   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
131     ac_prev=cache_file ;;
132   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
133   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
134     cache_file="$ac_optarg" ;;
135
136   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
137     ac_prev=datadir ;;
138   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
139   | --da=*)
140     datadir="$ac_optarg" ;;
141
142   -disable-* | --disable-*)
143     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
144     # Reject names that are not valid shell variable names.
145     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
146       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
147     fi
148     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
149     eval "enable_${ac_feature}=no" ;;
150
151   -enable-* | --enable-*)
152     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
153     # Reject names that are not valid shell variable names.
154     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
155       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
156     fi
157     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
158     case "$ac_option" in
159       *=*) ;;
160       *) ac_optarg=yes ;;
161     esac
162     eval "enable_${ac_feature}='$ac_optarg'" ;;
163
164   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
165   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
166   | --exec | --exe | --ex)
167     ac_prev=exec_prefix ;;
168   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
169   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
170   | --exec=* | --exe=* | --ex=*)
171     exec_prefix="$ac_optarg" ;;
172
173   -gas | --gas | --ga | --g)
174     # Obsolete; use --with-gas.
175     with_gas=yes ;;
176
177   -help | --help | --hel | --he)
178     # Omit some internal or obsolete options to make the list less imposing.
179     # This message is too long to be a string in the A/UX 3.1 sh.
180     cat << EOF
181 Usage: configure [options] [host]
182 Options: [defaults in brackets after descriptions]
183 Configuration:
184   --cache-file=FILE       cache test results in FILE
185   --help                  print this message
186   --no-create             do not create output files
187   --quiet, --silent       do not print \`checking...' messages
188   --version               print the version of autoconf that created configure
189 Directory and file names:
190   --prefix=PREFIX         install architecture-independent files in PREFIX
191                           [$ac_default_prefix]
192   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
193                           [same as prefix]
194   --bindir=DIR            user executables in DIR [EPREFIX/bin]
195   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
196   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
197   --datadir=DIR           read-only architecture-independent data in DIR
198                           [PREFIX/share]
199   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
200   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
201                           [PREFIX/com]
202   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
203   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
204   --includedir=DIR        C header files in DIR [PREFIX/include]
205   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
206   --infodir=DIR           info documentation in DIR [PREFIX/info]
207   --mandir=DIR            man documentation in DIR [PREFIX/man]
208   --srcdir=DIR            find the sources in DIR [configure dir or ..]
209   --program-prefix=PREFIX prepend PREFIX to installed program names
210   --program-suffix=SUFFIX append SUFFIX to installed program names
211   --program-transform-name=PROGRAM
212                           run sed PROGRAM on installed program names
213 EOF
214     cat << EOF
215 Host type:
216   --build=BUILD           configure for building on BUILD [BUILD=HOST]
217   --host=HOST             configure for HOST [guessed]
218   --target=TARGET         configure for TARGET [TARGET=HOST]
219 Features and packages:
220   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
221   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
222   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
223   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
224   --x-includes=DIR        X include files are in DIR
225   --x-libraries=DIR       X library files are in DIR
226 EOF
227     if test -n "$ac_help"; then
228       echo "--enable and --with options recognized:$ac_help"
229     fi
230     exit 0 ;;
231
232   -host | --host | --hos | --ho)
233     ac_prev=host ;;
234   -host=* | --host=* | --hos=* | --ho=*)
235     host="$ac_optarg" ;;
236
237   -includedir | --includedir | --includedi | --included | --include \
238   | --includ | --inclu | --incl | --inc)
239     ac_prev=includedir ;;
240   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
241   | --includ=* | --inclu=* | --incl=* | --inc=*)
242     includedir="$ac_optarg" ;;
243
244   -infodir | --infodir | --infodi | --infod | --info | --inf)
245     ac_prev=infodir ;;
246   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
247     infodir="$ac_optarg" ;;
248
249   -libdir | --libdir | --libdi | --libd)
250     ac_prev=libdir ;;
251   -libdir=* | --libdir=* | --libdi=* | --libd=*)
252     libdir="$ac_optarg" ;;
253
254   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
255   | --libexe | --libex | --libe)
256     ac_prev=libexecdir ;;
257   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
258   | --libexe=* | --libex=* | --libe=*)
259     libexecdir="$ac_optarg" ;;
260
261   -localstatedir | --localstatedir | --localstatedi | --localstated \
262   | --localstate | --localstat | --localsta | --localst \
263   | --locals | --local | --loca | --loc | --lo)
264     ac_prev=localstatedir ;;
265   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
266   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
267   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
268     localstatedir="$ac_optarg" ;;
269
270   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
271     ac_prev=mandir ;;
272   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
273     mandir="$ac_optarg" ;;
274
275   -nfp | --nfp | --nf)
276     # Obsolete; use --without-fp.
277     with_fp=no ;;
278
279   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
280   | --no-cr | --no-c)
281     no_create=yes ;;
282
283   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
284   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
285     no_recursion=yes ;;
286
287   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
288   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
289   | --oldin | --oldi | --old | --ol | --o)
290     ac_prev=oldincludedir ;;
291   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
292   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
293   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
294     oldincludedir="$ac_optarg" ;;
295
296   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
297     ac_prev=prefix ;;
298   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
299     prefix="$ac_optarg" ;;
300
301   -program-prefix | --program-prefix | --program-prefi | --program-pref \
302   | --program-pre | --program-pr | --program-p)
303     ac_prev=program_prefix ;;
304   -program-prefix=* | --program-prefix=* | --program-prefi=* \
305   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
306     program_prefix="$ac_optarg" ;;
307
308   -program-suffix | --program-suffix | --program-suffi | --program-suff \
309   | --program-suf | --program-su | --program-s)
310     ac_prev=program_suffix ;;
311   -program-suffix=* | --program-suffix=* | --program-suffi=* \
312   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
313     program_suffix="$ac_optarg" ;;
314
315   -program-transform-name | --program-transform-name \
316   | --program-transform-nam | --program-transform-na \
317   | --program-transform-n | --program-transform- \
318   | --program-transform | --program-transfor \
319   | --program-transfo | --program-transf \
320   | --program-trans | --program-tran \
321   | --progr-tra | --program-tr | --program-t)
322     ac_prev=program_transform_name ;;
323   -program-transform-name=* | --program-transform-name=* \
324   | --program-transform-nam=* | --program-transform-na=* \
325   | --program-transform-n=* | --program-transform-=* \
326   | --program-transform=* | --program-transfor=* \
327   | --program-transfo=* | --program-transf=* \
328   | --program-trans=* | --program-tran=* \
329   | --progr-tra=* | --program-tr=* | --program-t=*)
330     program_transform_name="$ac_optarg" ;;
331
332   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
333   | -silent | --silent | --silen | --sile | --sil)
334     silent=yes ;;
335
336   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
337     ac_prev=sbindir ;;
338   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
339   | --sbi=* | --sb=*)
340     sbindir="$ac_optarg" ;;
341
342   -sharedstatedir | --sharedstatedir | --sharedstatedi \
343   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
344   | --sharedst | --shareds | --shared | --share | --shar \
345   | --sha | --sh)
346     ac_prev=sharedstatedir ;;
347   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
348   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
349   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
350   | --sha=* | --sh=*)
351     sharedstatedir="$ac_optarg" ;;
352
353   -site | --site | --sit)
354     ac_prev=site ;;
355   -site=* | --site=* | --sit=*)
356     site="$ac_optarg" ;;
357
358   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
359     ac_prev=srcdir ;;
360   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
361     srcdir="$ac_optarg" ;;
362
363   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
364   | --syscon | --sysco | --sysc | --sys | --sy)
365     ac_prev=sysconfdir ;;
366   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
367   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
368     sysconfdir="$ac_optarg" ;;
369
370   -target | --target | --targe | --targ | --tar | --ta | --t)
371     ac_prev=target ;;
372   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
373     target="$ac_optarg" ;;
374
375   -v | -verbose | --verbose | --verbos | --verbo | --verb)
376     verbose=yes ;;
377
378   -version | --version | --versio | --versi | --vers)
379     echo "configure generated by autoconf version 2.12.1"
380     exit 0 ;;
381
382   -with-* | --with-*)
383     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
384     # Reject names that are not valid shell variable names.
385     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
386       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
387     fi
388     ac_package=`echo $ac_package| sed 's/-/_/g'`
389     case "$ac_option" in
390       *=*) ;;
391       *) ac_optarg=yes ;;
392     esac
393     eval "with_${ac_package}='$ac_optarg'" ;;
394
395   -without-* | --without-*)
396     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
397     # Reject names that are not valid shell variable names.
398     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
399       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
400     fi
401     ac_package=`echo $ac_package| sed 's/-/_/g'`
402     eval "with_${ac_package}=no" ;;
403
404   --x)
405     # Obsolete; use --with-x.
406     with_x=yes ;;
407
408   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
409   | --x-incl | --x-inc | --x-in | --x-i)
410     ac_prev=x_includes ;;
411   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
412   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
413     x_includes="$ac_optarg" ;;
414
415   -x-libraries | --x-libraries | --x-librarie | --x-librari \
416   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
417     ac_prev=x_libraries ;;
418   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
419   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
420     x_libraries="$ac_optarg" ;;
421
422   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
423     ;;
424
425   *)
426     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
427       echo "configure: warning: $ac_option: invalid host type" 1>&2
428     fi
429     if test "x$nonopt" != xNONE; then
430       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
431     fi
432     nonopt="$ac_option"
433     ;;
434
435   esac
436 done
437
438 if test -n "$ac_prev"; then
439   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
440 fi
441
442 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
443
444 # File descriptor usage:
445 # 0 standard input
446 # 1 file creation
447 # 2 errors and warnings
448 # 3 some systems may open it to /dev/tty
449 # 4 used on the Kubota Titan
450 # 6 checking for... messages and results
451 # 5 compiler messages saved in config.log
452 if test "$silent" = yes; then
453   exec 6>/dev/null
454 else
455   exec 6>&1
456 fi
457 exec 5>./config.log
458
459 echo "\
460 This file contains any messages produced by compilers while
461 running configure, to aid debugging if configure makes a mistake.
462 " 1>&5
463
464 # Strip out --no-create and --no-recursion so they do not pile up.
465 # Also quote any args containing shell metacharacters.
466 ac_configure_args=
467 for ac_arg
468 do
469   case "$ac_arg" in
470   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
471   | --no-cr | --no-c) ;;
472   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
473   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
474   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
475   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
476   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
477   esac
478 done
479
480 # NLS nuisances.
481 # Only set these to C if already set.  These must not be set unconditionally
482 # because not all systems understand e.g. LANG=C (notably SCO).
483 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
484 # Non-C LC_CTYPE values break the ctype check.
485 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
486 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
487 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
488 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
489
490 # confdefs.h avoids OS command line length limits that DEFS can exceed.
491 rm -rf conftest* confdefs.h
492 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
493 echo > confdefs.h
494
495 # A filename unique to this package, relative to the directory that
496 # configure is in, which we can look for to find out if srcdir is correct.
497 ac_unique_file=tree.c
498
499 # Find the source files, if location was not specified.
500 if test -z "$srcdir"; then
501   ac_srcdir_defaulted=yes
502   # Try the directory containing this script, then its parent.
503   ac_prog=$0
504   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
505   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
506   srcdir=$ac_confdir
507   if test ! -r $srcdir/$ac_unique_file; then
508     srcdir=..
509   fi
510 else
511   ac_srcdir_defaulted=no
512 fi
513 if test ! -r $srcdir/$ac_unique_file; then
514   if test "$ac_srcdir_defaulted" = yes; then
515     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
516   else
517     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
518   fi
519 fi
520 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
521
522 # Prefer explicitly selected file to automatically selected ones.
523 if test -z "$CONFIG_SITE"; then
524   if test "x$prefix" != xNONE; then
525     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
526   else
527     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
528   fi
529 fi
530 for ac_site_file in $CONFIG_SITE; do
531   if test -r "$ac_site_file"; then
532     echo "loading site script $ac_site_file"
533     . "$ac_site_file"
534   fi
535 done
536
537 if test -r "$cache_file"; then
538   echo "loading cache $cache_file"
539   . $cache_file
540 else
541   echo "creating cache $cache_file"
542   > $cache_file
543 fi
544
545 ac_ext=c
546 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
547 ac_cpp='$CPP $CPPFLAGS'
548 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
549 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
550 cross_compiling=$ac_cv_prog_cc_cross
551
552 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
553   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
554   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
555     ac_n= ac_c='
556 ' ac_t='        '
557   else
558     ac_n=-n ac_c= ac_t=
559   fi
560 else
561   ac_n= ac_c='\c' ac_t=
562 fi
563
564
565
566
567 remove=rm
568 hard_link=ln
569 symbolic_link='ln -s'
570 copy=cp
571
572 # Check for bogus environment variables.
573 # Test if LIBRARY_PATH contains the notation for the current directory
574 # since this would lead to problems installing/building glibc.
575 # LIBRARY_PATH contains the current directory if one of the following
576 # is true:
577 # - one of the terminals (":" and ";") is the first or last sign
578 # - two terminals occur directly after each other
579 # - the path contains an element with a dot in it
580 echo $ac_n "checking LIBRARY_PATH variable""... $ac_c" 1>&6
581 echo "configure:582: checking LIBRARY_PATH variable" >&5
582 case ${LIBRARY_PATH} in
583   [:\;]* | *[:\;] | *[:\;][:\;]* |  *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
584     library_path_setting="contains current directory"
585     ;;
586   *)
587     library_path_setting="ok"
588     ;;
589 esac
590 echo "$ac_t""$library_path_setting" 1>&6
591 if test "$library_path_setting" != "ok"; then
592 { echo "configure: error: 
593 *** LIBRARY_PATH shouldn't contain the current directory when
594 *** building egcs. Please change the environment variable
595 *** and run configure again." 1>&2; exit 1; }
596 fi
597
598 # Test if GCC_EXEC_PREFIX contains the notation for the current directory
599 # since this would lead to problems installing/building glibc.
600 # GCC_EXEC_PREFIX contains the current directory if one of the following
601 # is true:
602 # - one of the terminals (":" and ";") is the first or last sign
603 # - two terminals occur directly after each other
604 # - the path contains an element with a dot in it
605 echo $ac_n "checking GCC_EXEC_PREFIX variable""... $ac_c" 1>&6
606 echo "configure:607: checking GCC_EXEC_PREFIX variable" >&5
607 case ${GCC_EXEC_PREFIX} in
608   [:\;]* | *[:\;] | *[:\;][:\;]* |  *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* )
609     gcc_exec_prefix_setting="contains current directory"
610     ;;
611   *)
612     gcc_exec_prefix_setting="ok"
613     ;;
614 esac
615 echo "$ac_t""$gcc_exec_prefix_setting" 1>&6
616 if test "$gcc_exec_prefix_setting" != "ok"; then
617 { echo "configure: error: 
618 *** GCC_EXEC_PREFIX shouldn't contain the current directory when
619 *** building egcs. Please change the environment variable
620 *** and run configure again." 1>&2; exit 1; }
621 fi
622
623 # Check for additional parameters
624
625 # With GNU ld
626 # Check whether --with-gnu-ld or --without-gnu-ld was given.
627 if test "${with_gnu_ld+set}" = set; then
628   withval="$with_gnu_ld"
629   gnu_ld_flag="$with_gnu_ld"
630 else
631   gnu_ld_flag=no
632 fi
633
634
635 # With pre-defined ld
636 # Check whether --with-ld or --without-ld was given.
637 if test "${with_ld+set}" = set; then
638   withval="$with_ld"
639   LD="$with_ld"
640 fi
641
642 if test x"${LD+set}" = x"set"; then
643   if test ! -x "$LD"; then
644     echo "configure: warning: cannot execute: $LD: check --with-ld or env. var. LD" 1>&2
645   elif test "GNU" = `$LD -v </dev/null 2>&1 | sed '1s/^GNU.*/GNU/;q'`; then
646     gnu_ld_flag=yes
647   fi
648   cat >> confdefs.h <<EOF
649 #define DEFAULT_LINKER "$LD"
650 EOF
651
652 fi
653
654 # With GNU as
655 # Check whether --with-gnu-as or --without-gnu-as was given.
656 if test "${with_gnu_as+set}" = set; then
657   withval="$with_gnu_as"
658   gas_flag="$with_gnu_as"
659 else
660   gas_flag=no
661 fi
662
663
664 # Check whether --with-as or --without-as was given.
665 if test "${with_as+set}" = set; then
666   withval="$with_as"
667   AS="$with_as"
668 fi
669
670 if test x"${AS+set}" = x"set"; then
671   if test ! -x "$AS"; then
672     echo "configure: warning: cannot execute: $AS: check --with-as or env. var. AS" 1>&2
673   elif test "GNU" = `$AS -v </dev/null 2>&1 | sed '1s/^GNU.*/GNU/;q'`; then
674     gas_flag=yes
675   fi
676   cat >> confdefs.h <<EOF
677 #define DEFAULT_ASSEMBLER "$AS"
678 EOF
679
680 fi
681
682 # With stabs
683 # Check whether --with-stabs or --without-stabs was given.
684 if test "${with_stabs+set}" = set; then
685   withval="$with_stabs"
686   stabs="$with_stabs"
687 else
688   stabs=no
689 fi
690
691
692 # With ELF
693 # Check whether --with-elf or --without-elf was given.
694 if test "${with_elf+set}" = set; then
695   withval="$with_elf"
696   elf="$with_elf"
697 else
698   elf=no
699 fi
700
701
702 # Specify the local prefix
703 local_prefix=
704 # Check whether --with-local-prefix or --without-local-prefix was given.
705 if test "${with_local_prefix+set}" = set; then
706   withval="$with_local_prefix"
707   case "${withval}" in
708 yes)    { echo "configure: error: bad value ${withval} given for local include directory prefix" 1>&2; exit 1; } ;;
709 no)     ;;
710 *)      local_prefix=$with_local_prefix ;;
711 esac
712 fi
713
714
715 # Default local prefix if it is empty
716 if test x$local_prefix = x; then
717         local_prefix=/usr/local
718 fi
719
720 gxx_include_dir=
721 # Specify the g++ header file directory
722 # Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
723 if test "${with_gxx_include_dir+set}" = set; then
724   withval="$with_gxx_include_dir"
725   case "${withval}" in
726 yes)    { echo "configure: error: bad value ${withval} given for g++ include directory" 1>&2; exit 1; } ;;
727 no)     ;;
728 *)      gxx_include_dir=$with_gxx_include_dir ;;
729 esac
730 fi
731
732
733 if test x${gxx_include_dir} = x; then
734   if test x${enable_version_specific_runtime_libs} = xyes; then
735     gxx_include_dir='${libsubdir}/include/g++'
736   else
737     topsrcdir=${srcdir}/.. . ${srcdir}/../config.if
738     gxx_include_dir="\$(libsubdir)/\$(unlibsubdir)/..\`echo \$(exec_prefix) | sed -e 's|^\$(prefix)||' -e 's|/^/*|/..|g'\`/include/g++"-${libstdcxx_interface}
739   fi
740 fi
741
742 # Enable expensive internal checks
743 # Check whether --enable-checking or --disable-checking was given.
744 if test "${enable_checking+set}" = set; then
745   enableval="$enable_checking"
746   case "${enableval}" in
747 yes)    cat >> confdefs.h <<\EOF
748 #define ENABLE_CHECKING 1
749 EOF
750  ;;
751 no)     ;;
752 *)      { echo "configure: error: bad value ${enableval} given for checking option" 1>&2; exit 1; } ;;
753 esac
754 fi
755
756
757 # Use cpplib+cppmain for the preprocessor, but don't link it with the compiler.
758 cpp_main=cccp
759 # Check whether --enable-cpplib or --disable-cpplib was given.
760 if test "${enable_cpplib+set}" = set; then
761   enableval="$enable_cpplib"
762   if test x$enable_cpplib != xno; then
763   cpp_main=cppmain
764 fi
765 fi
766
767
768 # Link cpplib into the compiler proper, for C/C++/ObjC.
769 # Check whether --enable-c-cpplib or --disable-c-cpplib was given.
770 if test "${enable_c_cpplib+set}" = set; then
771   enableval="$enable_c_cpplib"
772   if test x$enable_c_cpplib != xno; then
773   extra_c_objs="${extra_c_objs} cpplib.o cppexp.o cpphash.o cpperror.o"
774   extra_c_objs="${extra_c_objs} prefix.o"
775   extra_cxx_objs="${extra_cxx_objs} ../cpplib.o ../cppexp.o ../cpphash.o ../cpperror.o ../prefix.o"
776   extra_c_flags=-DUSE_CPPLIB=1
777   cpp_main=cppmain
778 fi
779 fi
780
781
782 # Enable Multibyte Characters for C/C++
783 # Check whether --enable-c-mbchar or --disable-c-mbchar was given.
784 if test "${enable_c_mbchar+set}" = set; then
785   enableval="$enable_c_mbchar"
786   if test x$enable_c_mbchar != xno; then
787   extra_c_flags=-DMULTIBYTE_CHARS=1
788 fi
789 fi
790
791   
792 # Enable Haifa scheduler.
793 # Check whether --enable-haifa or --disable-haifa was given.
794 if test "${enable_haifa+set}" = set; then
795   enableval="$enable_haifa"
796   :
797 fi
798
799 # Fast fixincludes
800 #
801 # This is a work in progress...
802 # Check whether --with-fast-fixincludes or --without-fast-fixincludes was given.
803 if test "${with_fast_fixincludes+set}" = set; then
804   withval="$with_fast_fixincludes"
805   fast_fixinc="$with_fast_fixincludes"
806 else
807   fast_fixinc=no
808 fi
809
810
811 # Enable init_priority.
812 # Check whether --enable-init-priority or --disable-init-priority was given.
813 if test "${enable_init_priority+set}" = set; then
814   enableval="$enable_init_priority"
815   if test x$enable_init_priority != xno; then
816   extra_c_flags=-DUSE_INIT_PRIORITY
817 fi
818 fi
819
820
821 # Enable threads
822 # Pass with no value to take the default
823 # Pass with a value to specify a thread package
824 # Check whether --enable-threads or --disable-threads was given.
825 if test "${enable_threads+set}" = set; then
826   enableval="$enable_threads"
827   if test x$enable_threads = xno; then
828         enable_threads=''
829 fi
830 else
831   enable_threads=''
832 fi
833
834
835 enable_threads_flag=$enable_threads
836 # Check if a valid thread package
837 case x${enable_threads_flag} in
838         x | xno)
839                 # No threads
840                 target_thread_file='single'
841                 ;;
842         xyes)
843                 # default
844                 target_thread_file=''
845                 ;;
846         xdecosf1 | xirix | xmach | xos2 | xposix | xpthreads | xsingle | \
847         xsolaris | xwin32 | xdce | xvxworks)
848                 target_thread_file=$enable_threads_flag
849                 ;;
850         *)
851                 echo "$enable_threads is an unknown thread package" 1>&2
852                 exit 1
853                 ;;
854 esac
855
856 # Check whether --enable-objc-gc or --disable-objc-gc was given.
857 if test "${enable_objc_gc+set}" = set; then
858   enableval="$enable_objc_gc"
859   if [ x$enable_objc_gc = xno ]; then
860         objc_boehm_gc=''
861 else
862         objc_boehm_gc=1
863 fi
864 else
865   objc_boehm_gc=''
866 fi
867
868
869 # Determine the host, build, and target systems
870 ac_aux_dir=
871 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
872   if test -f $ac_dir/install-sh; then
873     ac_aux_dir=$ac_dir
874     ac_install_sh="$ac_aux_dir/install-sh -c"
875     break
876   elif test -f $ac_dir/install.sh; then
877     ac_aux_dir=$ac_dir
878     ac_install_sh="$ac_aux_dir/install.sh -c"
879     break
880   fi
881 done
882 if test -z "$ac_aux_dir"; then
883   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
884 fi
885 ac_config_guess=$ac_aux_dir/config.guess
886 ac_config_sub=$ac_aux_dir/config.sub
887 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
888
889
890 # Do some error checking and defaulting for the host and target type.
891 # The inputs are:
892 #    configure --host=HOST --target=TARGET --build=BUILD NONOPT
893 #
894 # The rules are:
895 # 1. You are not allowed to specify --host, --target, and nonopt at the
896 #    same time.
897 # 2. Host defaults to nonopt.
898 # 3. If nonopt is not specified, then host defaults to the current host,
899 #    as determined by config.guess.
900 # 4. Target and build default to nonopt.
901 # 5. If nonopt is not specified, then target and build default to host.
902
903 # The aliases save the names the user supplied, while $host etc.
904 # will get canonicalized.
905 case $host---$target---$nonopt in
906 NONE---*---* | *---NONE---* | *---*---NONE) ;;
907 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
908 esac
909
910
911 # Make sure we can run config.sub.
912 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
913 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
914 fi
915
916 echo $ac_n "checking host system type""... $ac_c" 1>&6
917 echo "configure:918: checking host system type" >&5
918
919 host_alias=$host
920 case "$host_alias" in
921 NONE)
922   case $nonopt in
923   NONE)
924     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
925     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
926     fi ;;
927   *) host_alias=$nonopt ;;
928   esac ;;
929 esac
930
931 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
932 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
933 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
934 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
935 echo "$ac_t""$host" 1>&6
936
937 echo $ac_n "checking target system type""... $ac_c" 1>&6
938 echo "configure:939: checking target system type" >&5
939
940 target_alias=$target
941 case "$target_alias" in
942 NONE)
943   case $nonopt in
944   NONE) target_alias=$host_alias ;;
945   *) target_alias=$nonopt ;;
946   esac ;;
947 esac
948
949 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
950 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
951 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
952 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
953 echo "$ac_t""$target" 1>&6
954
955 echo $ac_n "checking build system type""... $ac_c" 1>&6
956 echo "configure:957: checking build system type" >&5
957
958 build_alias=$build
959 case "$build_alias" in
960 NONE)
961   case $nonopt in
962   NONE) build_alias=$host_alias ;;
963   *) build_alias=$nonopt ;;
964   esac ;;
965 esac
966
967 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
968 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
969 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
970 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
971 echo "$ac_t""$build" 1>&6
972
973 test "$host_alias" != "$target_alias" &&
974   test "$program_prefix$program_suffix$program_transform_name" = \
975     NONENONEs,x,x, &&
976   program_prefix=${target_alias}-
977
978
979 # Find the native compiler
980 # Extract the first word of "gcc", so it can be a program name with args.
981 set dummy gcc; ac_word=$2
982 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
983 echo "configure:984: checking for $ac_word" >&5
984 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
985   echo $ac_n "(cached) $ac_c" 1>&6
986 else
987   if test -n "$CC"; then
988   ac_cv_prog_CC="$CC" # Let the user override the test.
989 else
990   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
991   for ac_dir in $PATH; do
992     test -z "$ac_dir" && ac_dir=.
993     if test -f $ac_dir/$ac_word; then
994       ac_cv_prog_CC="gcc"
995       break
996     fi
997   done
998   IFS="$ac_save_ifs"
999 fi
1000 fi
1001 CC="$ac_cv_prog_CC"
1002 if test -n "$CC"; then
1003   echo "$ac_t""$CC" 1>&6
1004 else
1005   echo "$ac_t""no" 1>&6
1006 fi
1007
1008 if test -z "$CC"; then
1009   # Extract the first word of "cc", so it can be a program name with args.
1010 set dummy cc; ac_word=$2
1011 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1012 echo "configure:1013: checking for $ac_word" >&5
1013 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1014   echo $ac_n "(cached) $ac_c" 1>&6
1015 else
1016   if test -n "$CC"; then
1017   ac_cv_prog_CC="$CC" # Let the user override the test.
1018 else
1019   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1020   ac_prog_rejected=no
1021   for ac_dir in $PATH; do
1022     test -z "$ac_dir" && ac_dir=.
1023     if test -f $ac_dir/$ac_word; then
1024       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1025         ac_prog_rejected=yes
1026         continue
1027       fi
1028       ac_cv_prog_CC="cc"
1029       break
1030     fi
1031   done
1032   IFS="$ac_save_ifs"
1033 if test $ac_prog_rejected = yes; then
1034   # We found a bogon in the path, so make sure we never use it.
1035   set dummy $ac_cv_prog_CC
1036   shift
1037   if test $# -gt 0; then
1038     # We chose a different compiler from the bogus one.
1039     # However, it has the same basename, so the bogon will be chosen
1040     # first if we set CC to just the basename; use the full file name.
1041     shift
1042     set dummy "$ac_dir/$ac_word" "$@"
1043     shift
1044     ac_cv_prog_CC="$@"
1045   fi
1046 fi
1047 fi
1048 fi
1049 CC="$ac_cv_prog_CC"
1050 if test -n "$CC"; then
1051   echo "$ac_t""$CC" 1>&6
1052 else
1053   echo "$ac_t""no" 1>&6
1054 fi
1055
1056   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1057 fi
1058
1059 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1060 echo "configure:1061: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1061
1062 ac_ext=c
1063 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1064 ac_cpp='$CPP $CPPFLAGS'
1065 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1066 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1067 cross_compiling=$ac_cv_prog_cc_cross
1068
1069 cat > conftest.$ac_ext <<EOF
1070 #line 1071 "configure"
1071 #include "confdefs.h"
1072 main(){return(0);}
1073 EOF
1074 if { (eval echo configure:1075: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1075   ac_cv_prog_cc_works=yes
1076   # If we can't run a trivial program, we are probably using a cross compiler.
1077   if (./conftest; exit) 2>/dev/null; then
1078     ac_cv_prog_cc_cross=no
1079   else
1080     ac_cv_prog_cc_cross=yes
1081   fi
1082 else
1083   echo "configure: failed program was:" >&5
1084   cat conftest.$ac_ext >&5
1085   ac_cv_prog_cc_works=no
1086 fi
1087 rm -fr conftest*
1088
1089 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1090 if test $ac_cv_prog_cc_works = no; then
1091   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1092 fi
1093 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1094 echo "configure:1095: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1095 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1096 cross_compiling=$ac_cv_prog_cc_cross
1097
1098 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1099 echo "configure:1100: checking whether we are using GNU C" >&5
1100 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1101   echo $ac_n "(cached) $ac_c" 1>&6
1102 else
1103   cat > conftest.c <<EOF
1104 #ifdef __GNUC__
1105   yes;
1106 #endif
1107 EOF
1108 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1109: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1109   ac_cv_prog_gcc=yes
1110 else
1111   ac_cv_prog_gcc=no
1112 fi
1113 fi
1114
1115 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1116
1117 if test $ac_cv_prog_gcc = yes; then
1118   GCC=yes
1119   ac_test_CFLAGS="${CFLAGS+set}"
1120   ac_save_CFLAGS="$CFLAGS"
1121   CFLAGS=
1122   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1123 echo "configure:1124: checking whether ${CC-cc} accepts -g" >&5
1124 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1125   echo $ac_n "(cached) $ac_c" 1>&6
1126 else
1127   echo 'void f(){}' > conftest.c
1128 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1129   ac_cv_prog_cc_g=yes
1130 else
1131   ac_cv_prog_cc_g=no
1132 fi
1133 rm -f conftest*
1134
1135 fi
1136
1137 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1138   if test "$ac_test_CFLAGS" = set; then
1139     CFLAGS="$ac_save_CFLAGS"
1140   elif test $ac_cv_prog_cc_g = yes; then
1141     CFLAGS="-g -O2"
1142   else
1143     CFLAGS="-O2"
1144   fi
1145 else
1146   GCC=
1147   test "${CFLAGS+set}" = set || CFLAGS="-g"
1148 fi
1149
1150
1151 # If the native compiler is GCC, we can enable warnings even in stage1.  
1152 # That's useful for people building cross-compilers, or just running a
1153 # quick `make'.
1154 if test "x$GCC" = "xyes"; then 
1155   stage1_warn_cflags='$(WARN_CFLAGS)'
1156 else
1157   stage1_warn_cflags=""
1158 fi
1159
1160
1161 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1162 echo "configure:1163: checking whether ${MAKE-make} sets \${MAKE}" >&5
1163 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1164 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1165   echo $ac_n "(cached) $ac_c" 1>&6
1166 else
1167   cat > conftestmake <<\EOF
1168 all:
1169         @echo 'ac_maketemp="${MAKE}"'
1170 EOF
1171 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1172 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1173 if test -n "$ac_maketemp"; then
1174   eval ac_cv_prog_make_${ac_make}_set=yes
1175 else
1176   eval ac_cv_prog_make_${ac_make}_set=no
1177 fi
1178 rm -f conftestmake
1179 fi
1180 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1181   echo "$ac_t""yes" 1>&6
1182   SET_MAKE=
1183 else
1184   echo "$ac_t""no" 1>&6
1185   SET_MAKE="MAKE=${MAKE-make}"
1186 fi
1187
1188
1189 echo $ac_n "checking whether a default assembler was specified""... $ac_c" 1>&6
1190 echo "configure:1191: checking whether a default assembler was specified" >&5
1191 if test x"${AS+set}" = x"set"; then
1192     if test x"$with_gas" = x"no"; then
1193         echo "$ac_t""yes ($AS)" 1>&6
1194     else
1195         echo "$ac_t""yes ($AS - GNU as)" 1>&6
1196     fi
1197 else
1198     echo "$ac_t""no" 1>&6
1199 fi
1200
1201 echo $ac_n "checking whether a default linker was specified""... $ac_c" 1>&6
1202 echo "configure:1203: checking whether a default linker was specified" >&5
1203 if test x"${LD+set}" = x"set"; then
1204     if test x"$with_gnu_ld" = x"no"; then
1205         echo "$ac_t""yes ($LD)" 1>&6
1206     else
1207         echo "$ac_t""yes ($LD - GNU ld)" 1>&6
1208     fi
1209 else
1210     echo "$ac_t""no" 1>&6
1211 fi
1212
1213 # Find some useful tools
1214 for ac_prog in mawk gawk nawk awk
1215 do
1216 # Extract the first word of "$ac_prog", so it can be a program name with args.
1217 set dummy $ac_prog; ac_word=$2
1218 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1219 echo "configure:1220: checking for $ac_word" >&5
1220 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
1221   echo $ac_n "(cached) $ac_c" 1>&6
1222 else
1223   if test -n "$AWK"; then
1224   ac_cv_prog_AWK="$AWK" # Let the user override the test.
1225 else
1226   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1227   for ac_dir in $PATH; do
1228     test -z "$ac_dir" && ac_dir=.
1229     if test -f $ac_dir/$ac_word; then
1230       ac_cv_prog_AWK="$ac_prog"
1231       break
1232     fi
1233   done
1234   IFS="$ac_save_ifs"
1235 fi
1236 fi
1237 AWK="$ac_cv_prog_AWK"
1238 if test -n "$AWK"; then
1239   echo "$ac_t""$AWK" 1>&6
1240 else
1241   echo "$ac_t""no" 1>&6
1242 fi
1243
1244 test -n "$AWK" && break
1245 done
1246
1247 # Extract the first word of "flex", so it can be a program name with args.
1248 set dummy flex; ac_word=$2
1249 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1250 echo "configure:1251: checking for $ac_word" >&5
1251 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1252   echo $ac_n "(cached) $ac_c" 1>&6
1253 else
1254   if test -n "$LEX"; then
1255   ac_cv_prog_LEX="$LEX" # Let the user override the test.
1256 else
1257   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1258   for ac_dir in $PATH; do
1259     test -z "$ac_dir" && ac_dir=.
1260     if test -f $ac_dir/$ac_word; then
1261       ac_cv_prog_LEX="flex"
1262       break
1263     fi
1264   done
1265   IFS="$ac_save_ifs"
1266   test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1267 fi
1268 fi
1269 LEX="$ac_cv_prog_LEX"
1270 if test -n "$LEX"; then
1271   echo "$ac_t""$LEX" 1>&6
1272 else
1273   echo "$ac_t""no" 1>&6
1274 fi
1275
1276 if test -z "$LEXLIB"
1277 then
1278   case "$LEX" in
1279   flex*) ac_lib=fl ;;
1280   *) ac_lib=l ;;
1281   esac
1282   echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
1283 echo "configure:1284: checking for yywrap in -l$ac_lib" >&5
1284 ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
1285 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1286   echo $ac_n "(cached) $ac_c" 1>&6
1287 else
1288   ac_save_LIBS="$LIBS"
1289 LIBS="-l$ac_lib  $LIBS"
1290 cat > conftest.$ac_ext <<EOF
1291 #line 1292 "configure"
1292 #include "confdefs.h"
1293 /* Override any gcc2 internal prototype to avoid an error.  */
1294 /* We use char because int might match the return type of a gcc2
1295     builtin and then its argument prototype would still apply.  */
1296 char yywrap();
1297
1298 int main() {
1299 yywrap()
1300 ; return 0; }
1301 EOF
1302 if { (eval echo configure:1303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1303   rm -rf conftest*
1304   eval "ac_cv_lib_$ac_lib_var=yes"
1305 else
1306   echo "configure: failed program was:" >&5
1307   cat conftest.$ac_ext >&5
1308   rm -rf conftest*
1309   eval "ac_cv_lib_$ac_lib_var=no"
1310 fi
1311 rm -f conftest*
1312 LIBS="$ac_save_LIBS"
1313
1314 fi
1315 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1316   echo "$ac_t""yes" 1>&6
1317   LEXLIB="-l$ac_lib"
1318 else
1319   echo "$ac_t""no" 1>&6
1320 fi
1321
1322 fi
1323
1324 echo $ac_n "checking whether ln works""... $ac_c" 1>&6
1325 echo "configure:1326: checking whether ln works" >&5
1326 if eval "test \"`echo '$''{'gcc_cv_prog_LN'+set}'`\" = set"; then
1327   echo $ac_n "(cached) $ac_c" 1>&6
1328 else
1329   rm -f conftestdata_t
1330 echo >conftestdata_f
1331 if ln conftestdata_f conftestdata_t 2>/dev/null
1332 then
1333   gcc_cv_prog_LN="ln"
1334 else
1335   if ln -s conftestdata_f conftestdata_t 2>/dev/null
1336   then
1337     gcc_cv_prog_LN="ln -s"
1338   else
1339     gcc_cv_prog_LN=cp
1340   fi
1341 fi
1342 rm -f conftestdata_f conftestdata_t
1343
1344 fi
1345 LN="$gcc_cv_prog_LN"
1346 if test "$gcc_cv_prog_LN" = "ln"; then
1347   echo "$ac_t""yes" 1>&6
1348 else
1349   if test "$gcc_cv_prog_LN" = "ln -s"; then
1350     echo "$ac_t""no, using ln -s" 1>&6
1351   else
1352     echo "$ac_t""no, and neither does ln -s, so using cp" 1>&6
1353   fi
1354 fi
1355
1356 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1357 echo "configure:1358: checking whether ln -s works" >&5
1358 if eval "test \"`echo '$''{'gcc_cv_prog_LN_S'+set}'`\" = set"; then
1359   echo $ac_n "(cached) $ac_c" 1>&6
1360 else
1361   rm -f conftestdata_t
1362 echo >conftestdata_f
1363 if ln -s conftestdata_f conftestdata_t 2>/dev/null
1364 then
1365   gcc_cv_prog_LN_S="ln -s"
1366 else
1367   if ln conftestdata_f conftestdata_t 2>/dev/null
1368   then
1369     gcc_cv_prog_LN_S=ln
1370   else
1371     gcc_cv_prog_LN_S=cp
1372   fi
1373 fi
1374 rm -f conftestdata_f conftestdata_t
1375
1376 fi
1377 LN_S="$gcc_cv_prog_LN_S"
1378 if test "$gcc_cv_prog_LN_S" = "ln -s"; then
1379   echo "$ac_t""yes" 1>&6
1380 else
1381   if test "$gcc_cv_prog_LN_S" = "ln"; then
1382     echo "$ac_t""no, using ln" 1>&6
1383   else
1384     echo "$ac_t""no, and neither does ln, so using cp" 1>&6
1385   fi
1386 fi
1387
1388 echo $ac_n "checking for volatile""... $ac_c" 1>&6
1389 echo "configure:1390: checking for volatile" >&5
1390 if eval "test \"`echo '$''{'gcc_cv_c_volatile'+set}'`\" = set"; then
1391   echo $ac_n "(cached) $ac_c" 1>&6
1392 else
1393   cat > conftest.$ac_ext <<EOF
1394 #line 1395 "configure"
1395 #include "confdefs.h"
1396
1397 int main() {
1398 volatile int foo;
1399 ; return 0; }
1400 EOF
1401 if { (eval echo configure:1402: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1402   rm -rf conftest*
1403   gcc_cv_c_volatile=yes
1404 else
1405   echo "configure: failed program was:" >&5
1406   cat conftest.$ac_ext >&5
1407   rm -rf conftest*
1408   gcc_cv_c_volatile=no
1409 fi
1410 rm -f conftest*
1411 fi
1412
1413 echo "$ac_t""$gcc_cv_c_volatile" 1>&6
1414 if test $gcc_cv_c_volatile = yes ; then
1415   cat >> confdefs.h <<\EOF
1416 #define HAVE_VOLATILE 1
1417 EOF
1418
1419 fi
1420
1421 # Extract the first word of "ranlib", so it can be a program name with args.
1422 set dummy ranlib; ac_word=$2
1423 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1424 echo "configure:1425: checking for $ac_word" >&5
1425 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1426   echo $ac_n "(cached) $ac_c" 1>&6
1427 else
1428   if test -n "$RANLIB"; then
1429   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1430 else
1431   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1432   for ac_dir in $PATH; do
1433     test -z "$ac_dir" && ac_dir=.
1434     if test -f $ac_dir/$ac_word; then
1435       ac_cv_prog_RANLIB="ranlib"
1436       break
1437     fi
1438   done
1439   IFS="$ac_save_ifs"
1440   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1441 fi
1442 fi
1443 RANLIB="$ac_cv_prog_RANLIB"
1444 if test -n "$RANLIB"; then
1445   echo "$ac_t""$RANLIB" 1>&6
1446 else
1447   echo "$ac_t""no" 1>&6
1448 fi
1449
1450 for ac_prog in 'bison -y' byacc
1451 do
1452 # Extract the first word of "$ac_prog", so it can be a program name with args.
1453 set dummy $ac_prog; ac_word=$2
1454 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1455 echo "configure:1456: checking for $ac_word" >&5
1456 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
1457   echo $ac_n "(cached) $ac_c" 1>&6
1458 else
1459   if test -n "$YACC"; then
1460   ac_cv_prog_YACC="$YACC" # Let the user override the test.
1461 else
1462   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1463   for ac_dir in $PATH; do
1464     test -z "$ac_dir" && ac_dir=.
1465     if test -f $ac_dir/$ac_word; then
1466       ac_cv_prog_YACC="$ac_prog"
1467       break
1468     fi
1469   done
1470   IFS="$ac_save_ifs"
1471 fi
1472 fi
1473 YACC="$ac_cv_prog_YACC"
1474 if test -n "$YACC"; then
1475   echo "$ac_t""$YACC" 1>&6
1476 else
1477   echo "$ac_t""no" 1>&6
1478 fi
1479
1480 test -n "$YACC" && break
1481 done
1482 test -n "$YACC" || YACC="yacc"
1483
1484 # Find a good install program.  We prefer a C program (faster),
1485 # so one script is as good as another.  But avoid the broken or
1486 # incompatible versions:
1487 # SysV /etc/install, /usr/sbin/install
1488 # SunOS /usr/etc/install
1489 # IRIX /sbin/install
1490 # AIX /bin/install
1491 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
1492 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1493 # ./install, which can be erroneously created by make from ./install.sh.
1494 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1495 echo "configure:1496: checking for a BSD compatible install" >&5
1496 if test -z "$INSTALL"; then
1497 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1498   echo $ac_n "(cached) $ac_c" 1>&6
1499 else
1500     IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
1501   for ac_dir in $PATH; do
1502     # Account for people who put trailing slashes in PATH elements.
1503     case "$ac_dir/" in
1504     /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1505     *)
1506       # OSF1 and SCO ODT 3.0 have their own names for install.
1507       for ac_prog in ginstall scoinst install; do
1508         if test -f $ac_dir/$ac_prog; then
1509           if test $ac_prog = install &&
1510             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1511             # AIX install.  It has an incompatible calling convention.
1512             # OSF/1 installbsd also uses dspmsg, but is usable.
1513             :
1514           else
1515             ac_cv_path_install="$ac_dir/$ac_prog -c"
1516             break 2
1517           fi
1518         fi
1519       done
1520       ;;
1521     esac
1522   done
1523   IFS="$ac_save_IFS"
1524
1525 fi
1526   if test "${ac_cv_path_install+set}" = set; then
1527     INSTALL="$ac_cv_path_install"
1528   else
1529     # As a last resort, use the slow shell script.  We don't cache a
1530     # path for INSTALL within a source directory, because that will
1531     # break other packages using the cache if that directory is
1532     # removed, or if the path is relative.
1533     INSTALL="$ac_install_sh"
1534   fi
1535 fi
1536 echo "$ac_t""$INSTALL" 1>&6
1537
1538 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1539 # It thinks the first close brace ends the variable substitution.
1540 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1541
1542 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1543
1544
1545 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1546 echo "configure:1547: checking how to run the C preprocessor" >&5
1547 # On Suns, sometimes $CPP names a directory.
1548 if test -n "$CPP" && test -d "$CPP"; then
1549   CPP=
1550 fi
1551 if test -z "$CPP"; then
1552 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1553   echo $ac_n "(cached) $ac_c" 1>&6
1554 else
1555     # This must be in double quotes, not single quotes, because CPP may get
1556   # substituted into the Makefile and "${CC-cc}" will confuse make.
1557   CPP="${CC-cc} -E"
1558   # On the NeXT, cc -E runs the code through the compiler's parser,
1559   # not just through cpp.
1560   cat > conftest.$ac_ext <<EOF
1561 #line 1562 "configure"
1562 #include "confdefs.h"
1563 #include <assert.h>
1564 Syntax Error
1565 EOF
1566 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1567 { (eval echo configure:1568: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1568 ac_err=`grep -v '^ *+' conftest.out`
1569 if test -z "$ac_err"; then
1570   :
1571 else
1572   echo "$ac_err" >&5
1573   echo "configure: failed program was:" >&5
1574   cat conftest.$ac_ext >&5
1575   rm -rf conftest*
1576   CPP="${CC-cc} -E -traditional-cpp"
1577   cat > conftest.$ac_ext <<EOF
1578 #line 1579 "configure"
1579 #include "confdefs.h"
1580 #include <assert.h>
1581 Syntax Error
1582 EOF
1583 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1584 { (eval echo configure:1585: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1585 ac_err=`grep -v '^ *+' conftest.out`
1586 if test -z "$ac_err"; then
1587   :
1588 else
1589   echo "$ac_err" >&5
1590   echo "configure: failed program was:" >&5
1591   cat conftest.$ac_ext >&5
1592   rm -rf conftest*
1593   CPP=/lib/cpp
1594 fi
1595 rm -f conftest*
1596 fi
1597 rm -f conftest*
1598   ac_cv_prog_CPP="$CPP"
1599 fi
1600   CPP="$ac_cv_prog_CPP"
1601 else
1602   ac_cv_prog_CPP="$CPP"
1603 fi
1604 echo "$ac_t""$CPP" 1>&6
1605
1606 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1607 echo "configure:1608: checking for ANSI C header files" >&5
1608 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1609   echo $ac_n "(cached) $ac_c" 1>&6
1610 else
1611   cat > conftest.$ac_ext <<EOF
1612 #line 1613 "configure"
1613 #include "confdefs.h"
1614 #include <stdlib.h>
1615 #include <stdarg.h>
1616 #include <string.h>
1617 #include <float.h>
1618 EOF
1619 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1620 { (eval echo configure:1621: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1621 ac_err=`grep -v '^ *+' conftest.out`
1622 if test -z "$ac_err"; then
1623   rm -rf conftest*
1624   ac_cv_header_stdc=yes
1625 else
1626   echo "$ac_err" >&5
1627   echo "configure: failed program was:" >&5
1628   cat conftest.$ac_ext >&5
1629   rm -rf conftest*
1630   ac_cv_header_stdc=no
1631 fi
1632 rm -f conftest*
1633
1634 if test $ac_cv_header_stdc = yes; then
1635   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1636 cat > conftest.$ac_ext <<EOF
1637 #line 1638 "configure"
1638 #include "confdefs.h"
1639 #include <string.h>
1640 EOF
1641 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1642   egrep "memchr" >/dev/null 2>&1; then
1643   :
1644 else
1645   rm -rf conftest*
1646   ac_cv_header_stdc=no
1647 fi
1648 rm -f conftest*
1649
1650 fi
1651
1652 if test $ac_cv_header_stdc = yes; then
1653   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1654 cat > conftest.$ac_ext <<EOF
1655 #line 1656 "configure"
1656 #include "confdefs.h"
1657 #include <stdlib.h>
1658 EOF
1659 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1660   egrep "free" >/dev/null 2>&1; then
1661   :
1662 else
1663   rm -rf conftest*
1664   ac_cv_header_stdc=no
1665 fi
1666 rm -f conftest*
1667
1668 fi
1669
1670 if test $ac_cv_header_stdc = yes; then
1671   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1672 if test "$cross_compiling" = yes; then
1673   :
1674 else
1675   cat > conftest.$ac_ext <<EOF
1676 #line 1677 "configure"
1677 #include "confdefs.h"
1678 #include <ctype.h>
1679 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1680 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1681 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1682 int main () { int i; for (i = 0; i < 256; i++)
1683 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1684 exit (0); }
1685
1686 EOF
1687 if { (eval echo configure:1688: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1688 then
1689   :
1690 else
1691   echo "configure: failed program was:" >&5
1692   cat conftest.$ac_ext >&5
1693   rm -fr conftest*
1694   ac_cv_header_stdc=no
1695 fi
1696 rm -fr conftest*
1697 fi
1698
1699 fi
1700 fi
1701
1702 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1703 if test $ac_cv_header_stdc = yes; then
1704   cat >> confdefs.h <<\EOF
1705 #define STDC_HEADERS 1
1706 EOF
1707
1708 fi
1709
1710 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1711 echo "configure:1712: checking whether time.h and sys/time.h may both be included" >&5
1712 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1713   echo $ac_n "(cached) $ac_c" 1>&6
1714 else
1715   cat > conftest.$ac_ext <<EOF
1716 #line 1717 "configure"
1717 #include "confdefs.h"
1718 #include <sys/types.h>
1719 #include <sys/time.h>
1720 #include <time.h>
1721 int main() {
1722 struct tm *tp;
1723 ; return 0; }
1724 EOF
1725 if { (eval echo configure:1726: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1726   rm -rf conftest*
1727   ac_cv_header_time=yes
1728 else
1729   echo "configure: failed program was:" >&5
1730   cat conftest.$ac_ext >&5
1731   rm -rf conftest*
1732   ac_cv_header_time=no
1733 fi
1734 rm -f conftest*
1735 fi
1736
1737 echo "$ac_t""$ac_cv_header_time" 1>&6
1738 if test $ac_cv_header_time = yes; then
1739   cat >> confdefs.h <<\EOF
1740 #define TIME_WITH_SYS_TIME 1
1741 EOF
1742
1743 fi
1744
1745 echo $ac_n "checking whether string.h and strings.h may both be included""... $ac_c" 1>&6
1746 echo "configure:1747: checking whether string.h and strings.h may both be included" >&5
1747 if eval "test \"`echo '$''{'gcc_cv_header_string'+set}'`\" = set"; then
1748   echo $ac_n "(cached) $ac_c" 1>&6
1749 else
1750   cat > conftest.$ac_ext <<EOF
1751 #line 1752 "configure"
1752 #include "confdefs.h"
1753 #include <string.h>
1754 #include <strings.h>
1755 int main() {
1756
1757 ; return 0; }
1758 EOF
1759 if { (eval echo configure:1760: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1760   rm -rf conftest*
1761   gcc_cv_header_string=yes
1762 else
1763   echo "configure: failed program was:" >&5
1764   cat conftest.$ac_ext >&5
1765   rm -rf conftest*
1766   gcc_cv_header_string=no
1767 fi
1768 rm -f conftest*
1769 fi
1770
1771 echo "$ac_t""$gcc_cv_header_string" 1>&6
1772 if test $gcc_cv_header_string = yes; then
1773   cat >> confdefs.h <<\EOF
1774 #define STRING_WITH_STRINGS 1
1775 EOF
1776
1777 fi
1778
1779 for ac_hdr in limits.h stddef.h string.h strings.h stdlib.h time.h fcntl.h unistd.h stab.h sys/file.h sys/time.h sys/resource.h sys/param.h sys/times.h wait.h sys/wait.h
1780 do
1781 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1782 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1783 echo "configure:1784: checking for $ac_hdr" >&5
1784 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1785   echo $ac_n "(cached) $ac_c" 1>&6
1786 else
1787   cat > conftest.$ac_ext <<EOF
1788 #line 1789 "configure"
1789 #include "confdefs.h"
1790 #include <$ac_hdr>
1791 EOF
1792 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1793 { (eval echo configure:1794: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1794 ac_err=`grep -v '^ *+' conftest.out`
1795 if test -z "$ac_err"; then
1796   rm -rf conftest*
1797   eval "ac_cv_header_$ac_safe=yes"
1798 else
1799   echo "$ac_err" >&5
1800   echo "configure: failed program was:" >&5
1801   cat conftest.$ac_ext >&5
1802   rm -rf conftest*
1803   eval "ac_cv_header_$ac_safe=no"
1804 fi
1805 rm -f conftest*
1806 fi
1807 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1808   echo "$ac_t""yes" 1>&6
1809     ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1810   cat >> confdefs.h <<EOF
1811 #define $ac_tr_hdr 1
1812 EOF
1813  
1814 else
1815   echo "$ac_t""no" 1>&6
1816 fi
1817 done
1818
1819
1820 # Check for thread headers.
1821 ac_safe=`echo "thread.h" | sed 'y%./+-%__p_%'`
1822 echo $ac_n "checking for thread.h""... $ac_c" 1>&6
1823 echo "configure:1824: checking for thread.h" >&5
1824 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1825   echo $ac_n "(cached) $ac_c" 1>&6
1826 else
1827   cat > conftest.$ac_ext <<EOF
1828 #line 1829 "configure"
1829 #include "confdefs.h"
1830 #include <thread.h>
1831 EOF
1832 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1833 { (eval echo configure:1834: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1834 ac_err=`grep -v '^ *+' conftest.out`
1835 if test -z "$ac_err"; then
1836   rm -rf conftest*
1837   eval "ac_cv_header_$ac_safe=yes"
1838 else
1839   echo "$ac_err" >&5
1840   echo "configure: failed program was:" >&5
1841   cat conftest.$ac_ext >&5
1842   rm -rf conftest*
1843   eval "ac_cv_header_$ac_safe=no"
1844 fi
1845 rm -f conftest*
1846 fi
1847 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1848   echo "$ac_t""yes" 1>&6
1849   have_thread_h=yes
1850 else
1851   echo "$ac_t""no" 1>&6
1852 have_thread_h=
1853 fi
1854
1855 ac_safe=`echo "pthread.h" | sed 'y%./+-%__p_%'`
1856 echo $ac_n "checking for pthread.h""... $ac_c" 1>&6
1857 echo "configure:1858: checking for pthread.h" >&5
1858 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1859   echo $ac_n "(cached) $ac_c" 1>&6
1860 else
1861   cat > conftest.$ac_ext <<EOF
1862 #line 1863 "configure"
1863 #include "confdefs.h"
1864 #include <pthread.h>
1865 EOF
1866 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1867 { (eval echo configure:1868: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1868 ac_err=`grep -v '^ *+' conftest.out`
1869 if test -z "$ac_err"; then
1870   rm -rf conftest*
1871   eval "ac_cv_header_$ac_safe=yes"
1872 else
1873   echo "$ac_err" >&5
1874   echo "configure: failed program was:" >&5
1875   cat conftest.$ac_ext >&5
1876   rm -rf conftest*
1877   eval "ac_cv_header_$ac_safe=no"
1878 fi
1879 rm -f conftest*
1880 fi
1881 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1882   echo "$ac_t""yes" 1>&6
1883   have_pthread_h=yes
1884 else
1885   echo "$ac_t""no" 1>&6
1886 have_pthread_h=
1887 fi
1888
1889
1890 # See if GNAT has been installed
1891 # Extract the first word of "gnatbind", so it can be a program name with args.
1892 set dummy gnatbind; ac_word=$2
1893 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1894 echo "configure:1895: checking for $ac_word" >&5
1895 if eval "test \"`echo '$''{'ac_cv_prog_gnat'+set}'`\" = set"; then
1896   echo $ac_n "(cached) $ac_c" 1>&6
1897 else
1898   if test -n "$gnat"; then
1899   ac_cv_prog_gnat="$gnat" # Let the user override the test.
1900 else
1901   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1902   for ac_dir in $PATH; do
1903     test -z "$ac_dir" && ac_dir=.
1904     if test -f $ac_dir/$ac_word; then
1905       ac_cv_prog_gnat="yes"
1906       break
1907     fi
1908   done
1909   IFS="$ac_save_ifs"
1910   test -z "$ac_cv_prog_gnat" && ac_cv_prog_gnat="no"
1911 fi
1912 fi
1913 gnat="$ac_cv_prog_gnat"
1914 if test -n "$gnat"; then
1915   echo "$ac_t""$gnat" 1>&6
1916 else
1917   echo "$ac_t""no" 1>&6
1918 fi
1919
1920
1921 # See if the system preprocessor understands the ANSI C preprocessor
1922 # stringification operator.
1923 echo $ac_n "checking whether cpp understands the stringify operator""... $ac_c" 1>&6
1924 echo "configure:1925: checking whether cpp understands the stringify operator" >&5
1925 if eval "test \"`echo '$''{'gcc_cv_c_have_stringify'+set}'`\" = set"; then
1926   echo $ac_n "(cached) $ac_c" 1>&6
1927 else
1928   cat > conftest.$ac_ext <<EOF
1929 #line 1930 "configure"
1930 #include "confdefs.h"
1931
1932 int main() {
1933 #define S(x)   #x
1934 char *test = S(foo);
1935 ; return 0; }
1936 EOF
1937 if { (eval echo configure:1938: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1938   rm -rf conftest*
1939   gcc_cv_c_have_stringify=yes
1940 else
1941   echo "configure: failed program was:" >&5
1942   cat conftest.$ac_ext >&5
1943   rm -rf conftest*
1944   gcc_cv_c_have_stringify=no
1945 fi
1946 rm -f conftest*
1947 fi
1948
1949 echo "$ac_t""$gcc_cv_c_have_stringify" 1>&6
1950 if test $gcc_cv_c_have_stringify = yes; then
1951   cat >> confdefs.h <<\EOF
1952 #define HAVE_CPP_STRINGIFY 1
1953 EOF
1954
1955 fi
1956
1957 # Use <inttypes.h> only if it exists,
1958 # doesn't clash with <sys/types.h>, and declares intmax_t.
1959 echo $ac_n "checking for inttypes.h""... $ac_c" 1>&6
1960 echo "configure:1961: checking for inttypes.h" >&5
1961 if eval "test \"`echo '$''{'gcc_cv_header_inttypes_h'+set}'`\" = set"; then
1962   echo $ac_n "(cached) $ac_c" 1>&6
1963 else
1964   cat > conftest.$ac_ext <<EOF
1965 #line 1966 "configure"
1966 #include "confdefs.h"
1967 #include <sys/types.h>
1968 #include <inttypes.h>
1969 int main() {
1970 intmax_t i = -1;
1971 ; return 0; }
1972 EOF
1973 if { (eval echo configure:1974: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1974   rm -rf conftest*
1975   cat >> confdefs.h <<EOF
1976 #define HAVE_INTTYPES_H 1
1977 EOF
1978
1979    gcc_cv_header_inttypes_h=yes
1980 else
1981   echo "configure: failed program was:" >&5
1982   cat conftest.$ac_ext >&5
1983   rm -rf conftest*
1984   gcc_cv_header_inttypes_h=no
1985 fi
1986 rm -f conftest*
1987 fi
1988
1989 echo "$ac_t""$gcc_cv_header_inttypes_h" 1>&6
1990
1991 for ac_func in strtoul bsearch strerror putenv popen bcopy bzero bcmp \
1992         index rindex strchr strrchr kill getrlimit setrlimit atoll atoq \
1993         sysconf isascii gettimeofday strsignal
1994 do
1995 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1996 echo "configure:1997: checking for $ac_func" >&5
1997 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1998   echo $ac_n "(cached) $ac_c" 1>&6
1999 else
2000   cat > conftest.$ac_ext <<EOF
2001 #line 2002 "configure"
2002 #include "confdefs.h"
2003 /* System header to define __stub macros and hopefully few prototypes,
2004     which can conflict with char $ac_func(); below.  */
2005 #include <assert.h>
2006 /* Override any gcc2 internal prototype to avoid an error.  */
2007 /* We use char because int might match the return type of a gcc2
2008     builtin and then its argument prototype would still apply.  */
2009 char $ac_func();
2010
2011 int main() {
2012
2013 /* The GNU C library defines this for functions which it implements
2014     to always fail with ENOSYS.  Some functions are actually named
2015     something starting with __ and the normal name is an alias.  */
2016 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2017 choke me
2018 #else
2019 $ac_func();
2020 #endif
2021
2022 ; return 0; }
2023 EOF
2024 if { (eval echo configure:2025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2025   rm -rf conftest*
2026   eval "ac_cv_func_$ac_func=yes"
2027 else
2028   echo "configure: failed program was:" >&5
2029   cat conftest.$ac_ext >&5
2030   rm -rf conftest*
2031   eval "ac_cv_func_$ac_func=no"
2032 fi
2033 rm -f conftest*
2034 fi
2035
2036 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2037   echo "$ac_t""yes" 1>&6
2038     ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2039   cat >> confdefs.h <<EOF
2040 #define $ac_tr_func 1
2041 EOF
2042  
2043 else
2044   echo "$ac_t""no" 1>&6
2045 fi
2046 done
2047
2048
2049 # Make sure wchar_t is available
2050 #AC_CHECK_TYPE(wchar_t, unsigned int)
2051
2052 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
2053 echo "configure:2054: checking for vprintf" >&5
2054 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
2055   echo $ac_n "(cached) $ac_c" 1>&6
2056 else
2057   cat > conftest.$ac_ext <<EOF
2058 #line 2059 "configure"
2059 #include "confdefs.h"
2060 /* System header to define __stub macros and hopefully few prototypes,
2061     which can conflict with char vprintf(); below.  */
2062 #include <assert.h>
2063 /* Override any gcc2 internal prototype to avoid an error.  */
2064 /* We use char because int might match the return type of a gcc2
2065     builtin and then its argument prototype would still apply.  */
2066 char vprintf();
2067
2068 int main() {
2069
2070 /* The GNU C library defines this for functions which it implements
2071     to always fail with ENOSYS.  Some functions are actually named
2072     something starting with __ and the normal name is an alias.  */
2073 #if defined (__stub_vprintf) || defined (__stub___vprintf)
2074 choke me
2075 #else
2076 vprintf();
2077 #endif
2078
2079 ; return 0; }
2080 EOF
2081 if { (eval echo configure:2082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2082   rm -rf conftest*
2083   eval "ac_cv_func_vprintf=yes"
2084 else
2085   echo "configure: failed program was:" >&5
2086   cat conftest.$ac_ext >&5
2087   rm -rf conftest*
2088   eval "ac_cv_func_vprintf=no"
2089 fi
2090 rm -f conftest*
2091 fi
2092
2093 if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
2094   echo "$ac_t""yes" 1>&6
2095   cat >> confdefs.h <<\EOF
2096 #define HAVE_VPRINTF 1
2097 EOF
2098
2099 else
2100   echo "$ac_t""no" 1>&6
2101 fi
2102
2103 if test "$ac_cv_func_vprintf" != yes; then
2104 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
2105 echo "configure:2106: checking for _doprnt" >&5
2106 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
2107   echo $ac_n "(cached) $ac_c" 1>&6
2108 else
2109   cat > conftest.$ac_ext <<EOF
2110 #line 2111 "configure"
2111 #include "confdefs.h"
2112 /* System header to define __stub macros and hopefully few prototypes,
2113     which can conflict with char _doprnt(); below.  */
2114 #include <assert.h>
2115 /* Override any gcc2 internal prototype to avoid an error.  */
2116 /* We use char because int might match the return type of a gcc2
2117     builtin and then its argument prototype would still apply.  */
2118 char _doprnt();
2119
2120 int main() {
2121
2122 /* The GNU C library defines this for functions which it implements
2123     to always fail with ENOSYS.  Some functions are actually named
2124     something starting with __ and the normal name is an alias.  */
2125 #if defined (__stub__doprnt) || defined (__stub____doprnt)
2126 choke me
2127 #else
2128 _doprnt();
2129 #endif
2130
2131 ; return 0; }
2132 EOF
2133 if { (eval echo configure:2134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2134   rm -rf conftest*
2135   eval "ac_cv_func__doprnt=yes"
2136 else
2137   echo "configure: failed program was:" >&5
2138   cat conftest.$ac_ext >&5
2139   rm -rf conftest*
2140   eval "ac_cv_func__doprnt=no"
2141 fi
2142 rm -f conftest*
2143 fi
2144
2145 if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
2146   echo "$ac_t""yes" 1>&6
2147   cat >> confdefs.h <<\EOF
2148 #define HAVE_DOPRNT 1
2149 EOF
2150
2151 else
2152   echo "$ac_t""no" 1>&6
2153 fi
2154
2155 fi
2156
2157 vfprintf=
2158 doprint=
2159 if test $ac_cv_func_vprintf != yes ; then
2160   vfprintf=vfprintf.o
2161   if test $ac_cv_func__doprnt != yes ; then
2162     doprint=doprint.o
2163   fi
2164 fi
2165
2166
2167
2168 echo $ac_n "checking whether the printf functions support %p""... $ac_c" 1>&6
2169 echo "configure:2170: checking whether the printf functions support %p" >&5
2170 if eval "test \"`echo '$''{'gcc_cv_func_printf_ptr'+set}'`\" = set"; then
2171   echo $ac_n "(cached) $ac_c" 1>&6
2172 else
2173   if test "$cross_compiling" = yes; then
2174   gcc_cv_func_printf_ptr=no
2175 else
2176   cat > conftest.$ac_ext <<EOF
2177 #line 2178 "configure"
2178 #include "confdefs.h"
2179 #include <stdio.h>
2180
2181 main()
2182 {
2183   char buf[64];
2184   char *p = buf, *q = NULL;
2185   sprintf(buf, "%p", p);
2186   sscanf(buf, "%p", &q);
2187   exit (p != q);
2188 }
2189 EOF
2190 if { (eval echo configure:2191: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
2191 then
2192   gcc_cv_func_printf_ptr=yes
2193 else
2194   echo "configure: failed program was:" >&5
2195   cat conftest.$ac_ext >&5
2196   rm -fr conftest*
2197   gcc_cv_func_printf_ptr=no
2198 fi
2199 rm -fr conftest*
2200 fi
2201
2202 rm -f core core.* *.core
2203 fi
2204
2205 echo "$ac_t""$gcc_cv_func_printf_ptr" 1>&6
2206 if test $gcc_cv_func_printf_ptr = yes ; then
2207   cat >> confdefs.h <<\EOF
2208 #define HAVE_PRINTF_PTR 1
2209 EOF
2210
2211 fi
2212
2213
2214 for ac_func in malloc realloc calloc free bcopy bzero bcmp \
2215         index rindex getenv atol sbrk abort atof strerror getcwd getwd \
2216         strsignal
2217 do
2218 echo $ac_n "checking whether $ac_func must be declared""... $ac_c" 1>&6
2219 echo "configure:2220: checking whether $ac_func must be declared" >&5
2220 if eval "test \"`echo '$''{'gcc_cv_decl_needed_$ac_func'+set}'`\" = set"; then
2221   echo $ac_n "(cached) $ac_c" 1>&6
2222 else
2223   cat > conftest.$ac_ext <<EOF
2224 #line 2225 "configure"
2225 #include "confdefs.h"
2226
2227 #include <stdio.h>
2228 #ifdef STRING_WITH_STRINGS
2229 # include <string.h>
2230 # include <strings.h>
2231 #else
2232 # ifdef HAVE_STRING_H
2233 #  include <string.h>
2234 # else
2235 #  ifdef HAVE_STRINGS_H
2236 #   include <strings.h>
2237 #  endif
2238 # endif
2239 #endif
2240 #ifdef HAVE_STDLIB_H
2241 #include <stdlib.h>
2242 #endif
2243 #ifdef HAVE_UNISTD_H
2244 #include <unistd.h>
2245 #endif
2246 #ifndef HAVE_RINDEX
2247 #define rindex strrchr
2248 #endif
2249 #ifndef HAVE_INDEX
2250 #define index strchr
2251 #endif
2252
2253 int main() {
2254 char *(*pfn) = (char *(*)) $ac_func
2255 ; return 0; }
2256 EOF
2257 if { (eval echo configure:2258: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2258   rm -rf conftest*
2259   eval "gcc_cv_decl_needed_$ac_func=no"
2260 else
2261   echo "configure: failed program was:" >&5
2262   cat conftest.$ac_ext >&5
2263   rm -rf conftest*
2264   eval "gcc_cv_decl_needed_$ac_func=yes"
2265 fi
2266 rm -f conftest*
2267 fi
2268
2269 if eval "test \"`echo '$gcc_cv_decl_needed_'$ac_func`\" = yes"; then
2270   echo "$ac_t""yes" 1>&6
2271   gcc_tr_decl=NEED_DECLARATION_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2272   cat >> confdefs.h <<EOF
2273 #define $gcc_tr_decl 1
2274 EOF
2275
2276 else
2277   echo "$ac_t""no" 1>&6
2278 fi
2279
2280 done
2281
2282
2283 for ac_func in getrlimit setrlimit
2284 do
2285 echo $ac_n "checking whether $ac_func must be declared""... $ac_c" 1>&6
2286 echo "configure:2287: checking whether $ac_func must be declared" >&5
2287 if eval "test \"`echo '$''{'gcc_cv_decl_needed_$ac_func'+set}'`\" = set"; then
2288   echo $ac_n "(cached) $ac_c" 1>&6
2289 else
2290   cat > conftest.$ac_ext <<EOF
2291 #line 2292 "configure"
2292 #include "confdefs.h"
2293
2294 #include <stdio.h>
2295 #ifdef STRING_WITH_STRINGS
2296 # include <string.h>
2297 # include <strings.h>
2298 #else
2299 # ifdef HAVE_STRING_H
2300 #  include <string.h>
2301 # else
2302 #  ifdef HAVE_STRINGS_H
2303 #   include <strings.h>
2304 #  endif
2305 # endif
2306 #endif
2307 #ifdef HAVE_STDLIB_H
2308 #include <stdlib.h>
2309 #endif
2310 #ifdef HAVE_UNISTD_H
2311 #include <unistd.h>
2312 #endif
2313 #ifndef HAVE_RINDEX
2314 #define rindex strrchr
2315 #endif
2316 #ifndef HAVE_INDEX
2317 #define index strchr
2318 #endif
2319 #include <sys/types.h>
2320 #ifdef HAVE_SYS_RESOURCE_H
2321 #include <sys/resource.h>
2322 #endif
2323
2324 int main() {
2325 char *(*pfn) = (char *(*)) $ac_func
2326 ; return 0; }
2327 EOF
2328 if { (eval echo configure:2329: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2329   rm -rf conftest*
2330   eval "gcc_cv_decl_needed_$ac_func=no"
2331 else
2332   echo "configure: failed program was:" >&5
2333   cat conftest.$ac_ext >&5
2334   rm -rf conftest*
2335   eval "gcc_cv_decl_needed_$ac_func=yes"
2336 fi
2337 rm -f conftest*
2338 fi
2339
2340 if eval "test \"`echo '$gcc_cv_decl_needed_'$ac_func`\" = yes"; then
2341   echo "$ac_t""yes" 1>&6
2342   gcc_tr_decl=NEED_DECLARATION_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2343   cat >> confdefs.h <<EOF
2344 #define $gcc_tr_decl 1
2345 EOF
2346
2347 else
2348   echo "$ac_t""no" 1>&6
2349 fi
2350
2351 done
2352
2353
2354 echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6
2355 echo "configure:2356: checking for sys_siglist declaration in signal.h or unistd.h" >&5
2356 if eval "test \"`echo '$''{'ac_cv_decl_sys_siglist'+set}'`\" = set"; then
2357   echo $ac_n "(cached) $ac_c" 1>&6
2358 else
2359   cat > conftest.$ac_ext <<EOF
2360 #line 2361 "configure"
2361 #include "confdefs.h"
2362 #include <sys/types.h>
2363 #include <signal.h>
2364 /* NetBSD declares sys_siglist in unistd.h.  */
2365 #ifdef HAVE_UNISTD_H
2366 #include <unistd.h>
2367 #endif
2368 int main() {
2369 char *msg = *(sys_siglist + 1);
2370 ; return 0; }
2371 EOF
2372 if { (eval echo configure:2373: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2373   rm -rf conftest*
2374   ac_cv_decl_sys_siglist=yes
2375 else
2376   echo "configure: failed program was:" >&5
2377   cat conftest.$ac_ext >&5
2378   rm -rf conftest*
2379   ac_cv_decl_sys_siglist=no
2380 fi
2381 rm -f conftest*
2382 fi
2383
2384 echo "$ac_t""$ac_cv_decl_sys_siglist" 1>&6
2385 if test $ac_cv_decl_sys_siglist = yes; then
2386   cat >> confdefs.h <<\EOF
2387 #define SYS_SIGLIST_DECLARED 1
2388 EOF
2389
2390 fi
2391
2392
2393 # File extensions
2394 manext='.1'
2395 objext='.o'
2396
2397
2398
2399 build_xm_file=
2400 build_xm_defines=
2401 build_install_headers_dir=install-headers-tar
2402 build_exeext=
2403 host_xm_file=
2404 host_xm_defines=
2405 host_xmake_file=
2406 host_truncate_target=
2407 host_exeext=
2408
2409 # Decode the host machine, then the target machine.
2410 # For the host machine, we save the xm_file variable as host_xm_file;
2411 # then we decode the target machine and forget everything else
2412 # that came from the host machine.
2413 for machine in $build $host $target; do
2414
2415         out_file=
2416         xmake_file=
2417         tmake_file=
2418         extra_headers=
2419         extra_passes=
2420         extra_parts=
2421         extra_programs=
2422         extra_objs=
2423         extra_host_objs=
2424         extra_gcc_objs=
2425         xm_defines=
2426         float_format=
2427         # Set this to force installation and use of collect2.
2428         use_collect2=
2429         # Set this to override the default target model.
2430         target_cpu_default=
2431         # Set this to control which fixincludes program to use.
2432         if test x$fast_fixinc != xyes; then
2433                 fixincludes=fixincludes
2434         else fixincludes=fixinc.sh ; fi
2435         # Set this to control how the header file directory is installed.
2436         install_headers_dir=install-headers-tar
2437         # Set this to a non-empty list of args to pass to cpp if the target
2438         # wants its .md file passed through cpp.
2439         md_cppflags=
2440         # Set this if directory names should be truncated to 14 characters.
2441         truncate_target=
2442         # Set this if gdb needs a dir command with `dirname $out_file`
2443         gdb_needs_out_file_path=
2444         # Set this if the build machine requires executables to have a
2445         # file name suffix.
2446         exeext=
2447         # Set this to control which thread package will be used.
2448         thread_file=
2449         # Reinitialize these from the flag values every loop pass, since some
2450         # configure entries modify them.
2451         gas="$gas_flag"
2452         gnu_ld="$gnu_ld_flag"
2453         enable_threads=$enable_threads_flag
2454
2455         # Set default cpu_type, tm_file and xm_file so it can be updated in
2456         # each machine entry.
2457         cpu_type=`echo $machine | sed 's/-.*$//'`
2458         case $machine in
2459         alpha*-*-*)
2460                 cpu_type=alpha
2461                 ;;
2462         arm*-*-*)
2463                 cpu_type=arm
2464                 ;;
2465         c*-convex-*)
2466                 cpu_type=convex
2467                 ;;
2468         i[34567]86-*-*)
2469                 cpu_type=i386
2470                 ;;
2471         hppa*-*-*)
2472                 cpu_type=pa
2473                 ;;
2474         m68000-*-*)
2475                 cpu_type=m68k
2476                 ;;
2477         mips*-*-*)
2478                 cpu_type=mips
2479                 ;;
2480         powerpc*-*-*)
2481                 cpu_type=rs6000
2482                 ;;
2483         pyramid-*-*)
2484                 cpu_type=pyr
2485                 ;;
2486         sparc*-*-*)
2487                 cpu_type=sparc
2488                 ;;
2489         esac
2490
2491         tm_file=${cpu_type}/${cpu_type}.h
2492         xm_file=${cpu_type}/xm-${cpu_type}.h
2493         
2494         # Set the default macros to define for GNU/Linux systems.
2495         case $machine in
2496         *-*-linux-gnu*)
2497                 xm_defines="HAVE_ATEXIT POSIX BSTRING"
2498                 ;;
2499         esac
2500
2501         case $machine in
2502         # Support site-specific machine types.
2503         *local*)
2504                 cpu_type=`echo $machine | sed -e 's/-.*//'`
2505                 rest=`echo $machine | sed -e "s/$cpu_type-//"`
2506                 xm_file=${cpu_type}/xm-$rest.h
2507                 tm_file=${cpu_type}/$rest.h
2508                 if test -f $srcdir/config/${cpu_type}/x-$rest; \
2509                 then xmake_file=${cpu_type}/x-$rest; \
2510                 else true; \
2511                 fi
2512                 if test -f $srcdir/config/${cpu_type}/t-$rest; \
2513                 then tmake_file=${cpu_type}/t-$rest; \
2514                 else true; \
2515                 fi
2516                 ;;
2517         1750a-*-*)
2518                 ;;
2519         a29k-*-bsd* | a29k-*-sym1*)
2520                 tm_file="${tm_file} a29k/unix.h"
2521                 xm_defines=USG
2522                 xmake_file=a29k/x-unix
2523                 use_collect2=yes
2524                 ;;
2525         a29k-*-udi | a29k-*-coff)
2526                 tm_file="${tm_file} dbxcoff.h a29k/udi.h"
2527                 tmake_file=a29k/t-a29kbare
2528                 ;;
2529         a29k-wrs-vxworks*)
2530                 tm_file="${tm_file} dbxcoff.h a29k/udi.h a29k/vx29k.h"
2531                 tmake_file=a29k/t-vx29k
2532                 extra_parts="crtbegin.o crtend.o"
2533                 thread_file='vxworks'
2534                 ;;
2535         a29k-*-*)                       # Default a29k environment.
2536                 use_collect2=yes
2537                 ;;
2538         alpha*-*-linux-gnuecoff*)
2539                 tm_file="${tm_file} alpha/linux-ecoff.h alpha/linux.h"
2540                 target_cpu_default="MASK_GAS"
2541                 gas=no
2542                 xmake_file=none
2543                 gas=yes gnu_ld=yes
2544                 ;;
2545         alpha*-*-linux-gnulibc1*)
2546                 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
2547                 target_cpu_default="MASK_GAS"
2548                 tmake_file="t-linux t-linux-gnulibc1 alpha/t-linux alpha/t-crtbe"
2549                 extra_parts="crtbegin.o crtend.o"
2550                 fixincludes=fixinc.wrap
2551                 xmake_file=none
2552                 gas=yes gnu_ld=yes
2553                 if test x$enable_threads = xyes; then
2554                         thread_file='posix'
2555                 fi
2556                 ;;
2557         alpha*-*-linux-gnu*)
2558                 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
2559                 target_cpu_default="MASK_GAS"
2560                 tmake_file="t-linux alpha/t-linux alpha/t-crtbe"
2561                 extra_parts="crtbegin.o crtend.o"
2562                 xmake_file=none
2563                 fixincludes=Makefile.in
2564                 gas=yes gnu_ld=yes
2565                 if test x$enable_threads = xyes; then
2566                         thread_file='posix'
2567                 fi
2568                 ;;
2569         alpha*-*-netbsd*)
2570                 tm_file="${tm_file} alpha/elf.h alpha/netbsd.h alpha/netbsdl-elf.h"
2571                 target_cpu_default="MASK_GAS"
2572                 tmake_file="alpha/t-crtbe"
2573                 extra_parts="crtbegin.o crtend.o"
2574                 xmake_file=none
2575                 fixincludes=fixinc.wrap
2576                 gas=yes gnu_ld=yes
2577                 ;;
2578                 
2579         alpha*-dec-osf*)
2580                 if test x$stabs = xyes
2581                 then
2582                         tm_file="${tm_file} dbx.h"
2583                 fi
2584                 if test x$gas != xyes
2585                 then
2586                         extra_passes="mips-tfile mips-tdump"
2587                 fi
2588                 use_collect2=yes
2589                 case $machine in
2590                   *-*-osf1*)
2591                     tm_file="${tm_file} alpha/osf.h alpha/osf12.h alpha/osf2or3.h"
2592                     ;;
2593                   *-*-osf[23]*)
2594                     tm_file="${tm_file} alpha/osf.h alpha/osf2or3.h"
2595                     ;;
2596                   *-*-osf4*)
2597                     tm_file="${tm_file} alpha/osf.h"
2598                     # Some versions of OSF4 (specifically X4.0-9 296.7) have
2599                     # a broken tar, so we use cpio instead.
2600                     install_headers_dir=install-headers-cpio
2601                     ;;
2602                 esac
2603                 case $machine in
2604                   *-*-osf4.0[b-z] | *-*-osf4.[1-9]*)
2605                     target_cpu_default=MASK_SUPPORT_ARCH
2606                     ;;
2607                 esac
2608                 ;;
2609         alpha*-*-vxworks*)
2610                 tm_file="${tm_file} dbx.h alpha/vxworks.h"
2611                 if  x$gas != xyes 
2612                 then
2613                         extra_passes="mips-tfile mips-tdump"
2614                 fi
2615                 use_collect2=yes
2616                 ;;
2617         alpha*-*-winnt*)
2618                 tm_file="${tm_file} alpha/win-nt.h"
2619                 xm_file="${xm_file} config/winnt/xm-winnt.h alpha/xm-winnt.h"
2620                 tmake_file=t-libc-ok
2621                 xmake_file=winnt/x-winnt
2622                 extra_host_objs=oldnames.o
2623                 extra_gcc_objs="spawnv.o oldnames.o"
2624                 fixincludes=fixinc.winnt
2625                 if test x$gnu_ld != xyes
2626                 then
2627                         extra_programs=ld.exe
2628                 fi
2629                 if test x$enable_threads = xyes; then
2630                         thread_file='win32'
2631                 fi
2632                 ;;
2633         alpha*-dec-vms*)
2634                 tm_file=alpha/vms.h
2635                 xm_file="${xm_file} alpha/xm-vms.h"
2636                 tmake_file=alpha/t-vms
2637                 fixincludes=Makefile.in
2638                 ;;
2639         arc-*-elf*)
2640                 extra_parts="crtinit.o crtfini.o"
2641                 ;;
2642         arm-*-coff* | armel-*-coff*)
2643                 tm_file=arm/coff.h
2644                 tmake_file=arm/t-bare
2645                 ;;
2646         arm-*-riscix1.[01]*)            # Acorn RISC machine (early versions)
2647                 tm_file=arm/riscix1-1.h
2648                 use_collect2=yes
2649                 ;;
2650         arm-*-riscix*)                  # Acorn RISC machine
2651                 if test x$gas = xyes
2652                 then
2653                     tm_file=arm/rix-gas.h
2654                 else
2655                     tm_file=arm/riscix.h
2656                 fi
2657                 xmake_file=arm/x-riscix
2658                 tmake_file=arm/t-riscix
2659                 use_collect2=yes
2660                 ;;
2661         arm-semi-aout | armel-semi-aout)
2662                 tm_file=arm/semi.h
2663                 tmake_file=arm/t-semi
2664                 fixincludes=Makefile.in # There is nothing to fix
2665                 ;;
2666         arm-semi-aof | armel-semi-aof)
2667                 tm_file=arm/semiaof.h
2668                 tmake_file=arm/t-semiaof
2669                 fixincludes=Makefile.in # There is nothing to fix
2670                 ;;
2671         arm*-*-netbsd*)
2672                 tm_file=arm/netbsd.h
2673                 xm_file="arm/xm-netbsd.h ${xm_file}"
2674                 tmake_file="t-netbsd arm/t-netbsd"
2675                 # On NetBSD, the headers are already okay, except for math.h.
2676                 fixincludes=fixinc.wrap
2677                 ;;
2678         arm-*-linux-gnuaout*)           # ARM GNU/Linux
2679                 cpu_type=arm
2680                 xmake_file=x-linux
2681                 tm_file=arm/linux-gas.h
2682                 tmake_file=arm/t-linux
2683                 fixincludes=Makefile.in
2684                 gnu_ld=yes
2685                 ;;
2686         arm-*-aout)
2687                 tm_file=arm/aout.h
2688                 tmake_file=arm/t-bare
2689                 ;;
2690         c1-convex-*)                    # Convex C1
2691                 target_cpu_default=1
2692                 use_collect2=yes
2693                 fixincludes=Makefile.in
2694                 ;;
2695         c2-convex-*)                    # Convex C2
2696                 target_cpu_default=2
2697                 use_collect2=yes
2698                 fixincludes=Makefile.in
2699                 ;;
2700         c32-convex-*)
2701                 target_cpu_default=4
2702                 use_collect2=yes
2703                 fixincludes=Makefile.in
2704                 ;;
2705         c34-convex-*)
2706                 target_cpu_default=8
2707                 use_collect2=yes
2708                 fixincludes=Makefile.in
2709                 ;;
2710         c38-convex-*)
2711                 target_cpu_default=16           
2712                 use_collect2=yes
2713                 fixincludes=Makefile.in
2714                 ;;
2715         c4x-*)
2716                 cpu_type=c4x
2717                 tmake_file=c4x/t-c4x
2718                 ;;
2719         clipper-intergraph-clix*)
2720                 tm_file="${tm_file} svr3.h clipper/clix.h"
2721                 xm_file=clipper/xm-clix.h
2722                 xmake_file=clipper/x-clix
2723                 extra_headers=va-clipper.h
2724                 extra_parts="crtbegin.o crtend.o"
2725                 install_headers_dir=install-headers-cpio
2726                 ;;
2727         dsp16xx-*)
2728                 ;;
2729         elxsi-elxsi-*)
2730                 use_collect2=yes
2731                 ;;
2732 # This hasn't been upgraded to GCC 2.
2733 #       fx80-alliant-*)                 # Alliant FX/80
2734 #               ;;
2735         h8300-*-*)
2736                 float_format=i32
2737                 ;;
2738         hppa1.1-*-pro*)
2739                 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h"
2740                 xm_file=pa/xm-papro.h
2741                 tmake_file=pa/t-pro
2742                 ;;
2743         hppa1.1-*-osf*)
2744                 target_cpu_default=1
2745                 tm_file="${tm_file} pa/pa-osf.h"
2746                 use_collect2=yes
2747                 fixincludes=Makefile.in
2748                 ;;
2749         hppa1.1-*-rtems*)
2750                 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h pa/rtems.h"
2751                 xm_file=pa/xm-papro.h
2752                 tmake_file=pa/t-pro
2753                 ;;
2754         hppa1.0-*-osf*)
2755                 tm_file="${tm_file} pa/pa-osf.h"
2756                 use_collect2=yes
2757                 fixincludes=Makefile.in
2758                 ;;
2759         hppa1.1-*-bsd*)
2760                 target_cpu_default=1
2761                 use_collect2=yes
2762                 fixincludes=Makefile.in
2763                 ;;
2764         hppa1.0-*-bsd*)
2765                 use_collect2=yes
2766                 fixincludes=Makefile.in
2767                 ;;
2768         hppa1.0-*-hpux7*)
2769                 tm_file="pa/pa-oldas.h ${tm_file} pa/pa-hpux7.h"
2770                 xm_file=pa/xm-pahpux.h
2771                 xmake_file=pa/x-pa-hpux
2772                 if test x$gas = xyes
2773                 then
2774                         tm_file="${tm_file} pa/gas.h"
2775                 fi
2776                 install_headers_dir=install-headers-cpio
2777                 use_collect2=yes
2778                 ;;
2779         hppa1.0-*-hpux8.0[0-2]*)
2780                 tm_file="${tm_file} pa/pa-hpux.h"
2781                 xm_file=pa/xm-pahpux.h
2782                 xmake_file=pa/x-pa-hpux
2783                 if test x$gas = xyes
2784                 then
2785                         tm_file="${tm_file} pa/pa-gas.h"
2786                 else
2787                         tm_file="pa/pa-oldas.h ${tm_file}"
2788                 fi
2789                 install_headers_dir=install-headers-cpio
2790                 use_collect2=yes
2791                 ;;
2792         hppa1.1-*-hpux8.0[0-2]*)
2793                 target_cpu_default=1
2794                 tm_file="${tm_file} pa/pa-hpux.h"
2795                 xm_file=pa/xm-pahpux.h
2796                 xmake_file=pa/x-pa-hpux
2797                 if test x$gas = xyes
2798                 then
2799                         tm_file="${tm_file} pa/pa-gas.h"
2800                 else
2801                         tm_file="pa/pa-oldas.h ${tm_file}"
2802                 fi
2803                 install_headers_dir=install-headers-cpio
2804                 use_collect2=yes
2805                 ;;
2806         hppa1.1-*-hpux8*)
2807                 target_cpu_default=1
2808                 tm_file="${tm_file} pa/pa-hpux.h"
2809                 xm_file=pa/xm-pahpux.h
2810                 xmake_file=pa/x-pa-hpux
2811                 if test x$gas = xyes
2812                 then
2813                         tm_file="${tm_file} pa/pa-gas.h"
2814                 fi
2815                 install_headers_dir=install-headers-cpio
2816                 use_collect2=yes
2817                 ;;
2818         hppa1.0-*-hpux8*)
2819                 tm_file="${tm_file} pa/pa-hpux.h"
2820                 xm_file=pa/xm-pahpux.h
2821                 xmake_file=pa/x-pa-hpux
2822                 if test x$gas = xyes
2823                 then
2824                         tm_file="${tm_file} pa/pa-gas.h"
2825                 fi
2826                 install_headers_dir=install-headers-cpio
2827                 use_collect2=yes
2828                 ;;
2829         hppa1.1-*-hpux10*)
2830                 target_cpu_default=1
2831                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
2832                 xm_file=pa/xm-pahpux.h
2833                 xmake_file=pa/x-pa-hpux
2834                 tmake_file=pa/t-pa
2835                 if test x$gas = xyes
2836                 then
2837                         tm_file="${tm_file} pa/pa-gas.h"
2838                 fi
2839                 if test x$enable_threads = x; then
2840                     enable_threads=$have_pthread_h
2841                 fi
2842                 if test x$enable_threads = xyes; then
2843                         thread_file='dce'
2844                         tmake_file="${tmake_file} pa/t-dce-thr"
2845                 fi
2846                 install_headers_dir=install-headers-cpio
2847                 use_collect2=yes
2848                 ;;
2849         hppa1.0-*-hpux10*)
2850                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
2851                 xm_file=pa/xm-pahpux.h
2852                 xmake_file=pa/x-pa-hpux
2853                 if test x$gas = xyes
2854                 then
2855                         tm_file="${tm_file} pa/pa-gas.h"
2856                 fi
2857                 if test x$enable_threads = x; then
2858                     enable_threads=$have_pthread_h
2859                 fi
2860                 if test x$enable_threads = xyes; then
2861                         thread_file='dce'
2862                         tmake_file="${tmake_file} pa/t-dce-thr"
2863                 fi
2864                 install_headers_dir=install-headers-cpio
2865                 use_collect2=yes
2866                 ;;
2867         hppa1.1-*-hpux*)
2868                 target_cpu_default=1
2869                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
2870                 xm_file=pa/xm-pahpux.h
2871                 xmake_file=pa/x-pa-hpux
2872                 if test x$gas = xyes
2873                 then
2874                         tm_file="${tm_file} pa/pa-gas.h"
2875                 fi
2876                 install_headers_dir=install-headers-cpio
2877                 use_collect2=yes
2878                 ;;
2879         hppa1.0-*-hpux*)
2880                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
2881                 xm_file=pa/xm-pahpux.h
2882                 xmake_file=pa/x-pa-hpux
2883                 if test x$gas = xyes
2884                 then
2885                         tm_file="${tm_file} pa/pa-gas.h"
2886                 fi
2887                 install_headers_dir=install-headers-cpio
2888                 use_collect2=yes
2889                 ;;
2890         hppa1.1-*-hiux*)
2891                 target_cpu_default=1
2892                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
2893                 xm_file=pa/xm-pahpux.h
2894                 xmake_file=pa/x-pa-hpux
2895                 if test x$gas = xyes
2896                 then
2897                         tm_file="${tm_file} pa/pa-gas.h"
2898                 fi
2899                 install_headers_dir=install-headers-cpio
2900                 use_collect2=yes
2901                 ;;
2902         hppa1.0-*-hiux*)
2903                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
2904                 xm_file=pa/xm-pahpux.h
2905                 xmake_file=pa/x-pa-hpux
2906                 if test x$gas = xyes
2907                 then
2908                         tm_file="${tm_file} pa/pa-gas.h"
2909                 fi
2910                 install_headers_dir=install-headers-cpio
2911                 use_collect2=yes
2912                 ;;
2913         hppa*-*-lites*)
2914                 target_cpu_default=1
2915                 use_collect2=yes
2916                 fixincludes=Makefile.in
2917                 ;;
2918         i370-*-mvs*)
2919                 ;;
2920         i[34567]86-ibm-aix*)            # IBM PS/2 running AIX
2921                 if test x$gas = xyes
2922                 then
2923                         tm_file=i386/aix386.h
2924                         extra_parts="crtbegin.o crtend.o"
2925                         tmake_file=i386/t-crtstuff
2926                 else
2927                         tm_file=i386/aix386ng.h
2928                         use_collect2=yes
2929                 fi
2930                 xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}"
2931                 xm_defines=USG
2932                 xmake_file=i386/x-aix
2933                 ;;
2934         i[34567]86-ncr-sysv4*)          # NCR 3000 - ix86 running system V.4
2935                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
2936                 xm_defines="USG POSIX SMALL_ARG_MAX"
2937                 xmake_file=i386/x-ncr3000
2938                 if test x$stabs = xyes -a x$gas = xyes
2939                 then
2940                         tm_file=i386/sysv4gdb.h
2941                 else
2942                         tm_file=i386/sysv4.h
2943                 fi
2944                 extra_parts="crtbegin.o crtend.o"
2945                 tmake_file=i386/t-crtpic
2946                 ;;
2947         i[34567]86-next-*)
2948                 tm_file=i386/next.h
2949                 xm_file=i386/xm-next.h
2950                 tmake_file=i386/t-next
2951                 xmake_file=i386/x-next
2952                 extra_objs=nextstep.o
2953                 extra_parts="crtbegin.o crtend.o"
2954                 if test x$enable_threads = xyes; then
2955                         thread_file='mach'
2956                 fi
2957                 ;;
2958         i[34567]86-sequent-bsd*)                # 80386 from Sequent
2959                 use_collect2=yes
2960                 if test x$gas = xyes
2961                 then
2962                         tm_file=i386/seq-gas.h
2963                 else
2964                         tm_file=i386/sequent.h
2965                 fi
2966                 ;;
2967         i[34567]86-sequent-ptx1*)
2968                 xm_defines="USG SVR3"
2969                 xmake_file=i386/x-sysv3
2970                 tm_file=i386/seq-sysv3.h
2971                 tmake_file=i386/t-crtstuff
2972                 fixincludes=fixinc.ptx
2973                 extra_parts="crtbegin.o crtend.o"
2974                 install_headers_dir=install-headers-cpio
2975                 ;;
2976         i[34567]86-sequent-ptx2* | i[34567]86-sequent-sysv3*)
2977                 xm_defines="USG SVR3"
2978                 xmake_file=i386/x-sysv3
2979                 tm_file=i386/seq2-sysv3.h
2980                 tmake_file=i386/t-crtstuff
2981                 extra_parts="crtbegin.o crtend.o"
2982                 fixincludes=fixinc.ptx
2983                 install_headers_dir=install-headers-cpio
2984                 ;;
2985         i[34567]86-sequent-ptx4* | i[34567]86-sequent-sysv4*)
2986                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
2987                 xm_defines="USG POSIX SMALL_ARG_MAX"
2988                 xmake_file=x-svr4
2989                 tm_file=i386/ptx4-i.h
2990                 tmake_file=t-svr4
2991                 extra_parts="crtbegin.o crtend.o"
2992                 fixincludes=fixinc.ptx
2993                 install_headers_dir=install-headers-cpio
2994                 ;;
2995         i386-sun-sunos*)                # Sun i386 roadrunner
2996                 xm_defines=USG
2997                 tm_file=i386/sun.h
2998                 use_collect2=yes
2999                 ;;
3000         i[34567]86-wrs-vxworks*)
3001                 tm_file=i386/vxi386.h
3002                 tmake_file=i386/t-i386bare
3003                 ;;
3004         i[34567]86-*-aout*)
3005                 tm_file=i386/i386-aout.h
3006                 tmake_file=i386/t-i386bare
3007                 ;;
3008         i[34567]86-*-bsdi* | i[34567]86-*-bsd386*)
3009                 tm_file=i386/bsd386.h
3010 #               tmake_file=t-libc-ok
3011                 ;;
3012         i[34567]86-*-bsd*)
3013                 tm_file=i386/386bsd.h
3014 #               tmake_file=t-libc-ok
3015 # Next line turned off because both 386BSD and BSD/386 use GNU ld.
3016 #               use_collect2=yes
3017                 ;;
3018         i[34567]86-*-freebsdelf*)
3019                 tm_file="i386/i386.h i386/att.h linux.h i386/freebsd-elf.h i386/perform.h"
3020                 # On FreeBSD, the headers are already ok, except for math.h.
3021                 fixincludes=fixinc.wrap
3022                 tmake_file=i386/t-freebsd
3023                 gas=yes
3024                 gnu_ld=yes
3025                 stabs=yes
3026                 ;;
3027         i[34567]86-*-freebsd*)
3028                 tm_file=i386/freebsd.h
3029                 # On FreeBSD, the headers are already ok, except for math.h.
3030                 fixincludes=fixinc.wrap
3031                 tmake_file=i386/t-freebsd
3032                 ;;
3033         # We are hoping OpenBSD is still close enough to NetBSD that we can
3034         # share the configurations.
3035         i[34567]86-*-netbsd* | i[34567]86-*-openbsd*)
3036                 tm_file=i386/netbsd.h
3037                 # On NetBSD, the headers are already okay, except for math.h.
3038                 fixincludes=fixinc.wrap
3039                 tmake_file=t-netbsd
3040                 ;;
3041         i[34567]86-*-coff*)
3042                 tm_file=i386/i386-coff.h
3043                 tmake_file=i386/t-i386bare
3044                 ;;
3045         i[34567]86-*-isc*)              # 80386 running ISC system
3046                 xm_file="${xm_file} i386/xm-isc.h"
3047                 xm_defines="USG SVR3"
3048                 case $machine in
3049                   i[34567]86-*-isc[34]*)
3050                     xmake_file=i386/x-isc3
3051                     ;;
3052                   *)
3053                     xmake_file=i386/x-isc
3054                     ;;
3055                 esac
3056                 if test x$gas = xyes -a x$stabs = xyes
3057                 then
3058                         tm_file=i386/iscdbx.h
3059                         tmake_file=i386/t-svr3dbx
3060                         extra_parts="svr3.ifile svr3z.ifile"
3061                 else
3062                         tm_file=i386/isccoff.h
3063                         tmake_file=i386/t-crtstuff
3064                         extra_parts="crtbegin.o crtend.o"
3065                 fi
3066                 install_headers_dir=install-headers-cpio
3067                 ;;
3068         i[34567]86-*-linux-gnuoldld*)   # Intel 80386's running GNU/Linux
3069                                         # pre BFD linkers
3070                 xmake_file=x-linux-aout
3071                 tmake_file="t-linux-aout i386/t-crtstuff"
3072                 tm_file=i386/linux-oldld.h
3073                 fixincludes=Makefile.in #On Linux, the headers are ok already.
3074                 gnu_ld=yes
3075                 float_format=i386
3076                 ;;
3077         i[34567]86-*-linux-gnuaout*)    # Intel 80386's running GNU/Linux
3078                 xmake_file=x-linux-aout
3079                 tmake_file="t-linux-aout i386/t-crtstuff"
3080                 tm_file=i386/linux-aout.h
3081                 fixincludes=Makefile.in #On Linux, the headers are ok already.
3082                 gnu_ld=yes
3083                 float_format=i386
3084                 ;;
3085         i[34567]86-*-linux-gnulibc1)    # Intel 80386's running GNU/Linux
3086                                         # GNU/Linux C library 5
3087                 xmake_file=x-linux      
3088                 tm_file=i386/linux.h    
3089                 tmake_file="t-linux t-linux-gnulibc1 i386/t-crtstuff"
3090                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3091                 fixincludes=Makefile.in #On Linux, the headers are ok already.
3092                 gnu_ld=yes
3093                 float_format=i386
3094                 if test x$enable_threads = xyes; then
3095                         thread_file='single'
3096                 fi
3097                 ;;
3098         i[34567]86-*-linux-gnu*)        # Intel 80386's running GNU/Linux
3099                                         # aka GNU/Linux C library 6
3100                 xmake_file=x-linux
3101                 tm_file=i386/linux.h
3102                 tmake_file="t-linux i386/t-crtstuff"
3103                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3104                 fixincludes=Makefile.in #On Linux, the headers are ok already.
3105                 gnu_ld=yes
3106                 float_format=i386
3107                 if test x$enable_threads = xyes; then
3108                         thread_file='posix'
3109                 fi
3110                 ;;
3111         i[34567]86-*-gnu*)
3112                 ;;
3113         i[34567]86-go32-msdos | i[34567]86-*-go32*)
3114                 xm_file=i386/xm-go32.h
3115                 tm_file=i386/go32.h
3116                 tmake_file=i386/t-go32
3117                 ;;
3118         i[34567]86-pc-msdosdjgpp*)
3119                 xm_file=i386/xm-go32.h
3120                 tm_file=i386/go32.h
3121                 tmake_file=i386/t-go32
3122                 gnu_ld=yes
3123                 gas=yes
3124                 ;;
3125         i[34567]86-moss-msdos* | i[34567]86-*-moss*)
3126                 tm_file=i386/moss.h
3127                 tmake_file=t-libc-ok
3128                 fixincludes=Makefile.in
3129                 gnu_ld=yes
3130                 gas=yes
3131                 ;;
3132         i[34567]86-*-lynxos*)
3133                 if test x$gas = xyes
3134                 then
3135                         tm_file=i386/lynx.h
3136                 else
3137                         tm_file=i386/lynx-ng.h
3138                 fi
3139                 xm_file=i386/xm-lynx.h
3140                 tmake_file=i386/t-i386bare
3141                 xmake_file=x-lynx
3142                 ;;
3143         i[34567]86-*-mach*)
3144                 tm_file=i386/mach.h
3145 #               tmake_file=t-libc-ok
3146                 use_collect2=yes
3147                 ;;
3148         i[34567]86-*-osfrose*)          # 386 using OSF/rose
3149                 if test x$elf = xyes
3150                 then
3151                         tm_file=i386/osfelf.h
3152                         use_collect2=
3153                 else
3154                         tm_file=i386/osfrose.h
3155                         use_collect2=yes
3156                 fi
3157                 xm_file="i386/xm-osf.h ${xm_file}"
3158                 xmake_file=i386/x-osfrose
3159                 tmake_file=i386/t-osf
3160                 extra_objs=halfpic.o
3161                 ;;
3162         i[34567]86-go32-rtems*)
3163                 cpu_type=i386
3164                 xm_file=i386/xm-go32.h
3165                 tm_file=i386/go32-rtems.h
3166                 tmake_file="i386/t-go32 t-rtems"
3167                 ;;
3168         i[34567]86-*-rtemself*)
3169                 cpu_type=i386
3170                 tm_file=i386/rtemself.h
3171                 tmake_file="i386/t-i386bare t-rtems"
3172                 ;;
3173         i[34567]86-*-rtems*)
3174                 cpu_type=i386
3175                 tm_file=i386/rtems.h
3176                 tmake_file="i386/t-i386bare t-rtems"
3177                 ;;
3178         i[34567]86-*-sco3.2v5*) # 80386 running SCO Open Server 5
3179                 xm_file="xm-siglist.h xm-alloca.h ${xm_file} i386/xm-sco5.h"
3180                 xm_defines="USG SVR3"
3181                 xmake_file=i386/x-sco5
3182                 fixincludes=fixinc.sco
3183                 install_headers_dir=install-headers-cpio
3184                 tm_file=i386/sco5.h
3185                 if test x$gas = xyes
3186                 then
3187                         tm_file="i386/sco5gas.h ${tm_file}"
3188                         tmake_file=i386/t-sco5gas
3189                 else
3190                         tmake_file=i386/t-sco5
3191                 fi
3192                 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
3193                 ;;
3194         i[34567]86-*-sco3.2v4*)         # 80386 running SCO 3.2v4 system
3195                 xm_file="${xm_file} i386/xm-sco.h"
3196                 xm_defines="USG SVR3 BROKEN_LDEXP SMALL_ARG_MAX NO_SYS_SIGLIST"
3197                 xmake_file=i386/x-sco4
3198                 fixincludes=fixinc.sco
3199                 install_headers_dir=install-headers-cpio
3200                 if test x$stabs = xyes
3201                 then
3202                         tm_file=i386/sco4dbx.h
3203                         tmake_file=i386/t-svr3dbx
3204                         extra_parts="svr3.ifile svr3z.rfile"
3205                 else
3206                         tm_file=i386/sco4.h
3207                         tmake_file=i386/t-crtstuff
3208                         extra_parts="crtbegin.o crtend.o"
3209                 fi
3210                 truncate_target=yes
3211                 ;;
3212         i[34567]86-*-sco*)              # 80386 running SCO system
3213                 xm_file=i386/xm-sco.h
3214                 xmake_file=i386/x-sco
3215                 install_headers_dir=install-headers-cpio
3216                 if test x$stabs = xyes
3217                 then
3218                         tm_file=i386/scodbx.h
3219                         tmake_file=i386/t-svr3dbx
3220                         extra_parts="svr3.ifile svr3z.rfile"
3221                 else
3222                         tm_file=i386/sco.h
3223                         extra_parts="crtbegin.o crtend.o"
3224                         tmake_file=i386/t-crtstuff
3225                 fi
3226                 truncate_target=yes
3227                 ;;
3228         i[34567]86-*-solaris2*)
3229                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
3230                 xm_defines="USG POSIX SMALL_ARG_MAX"
3231                 if test x$stabs = xyes
3232                 then
3233                         tm_file=i386/sol2dbg.h
3234                 else
3235                         tm_file=i386/sol2.h
3236                 fi
3237                 tmake_file=i386/t-sol2
3238                 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
3239                 xmake_file=x-svr4
3240                 case $machine in
3241                 *-*-solaris2.[0-4])
3242                         fixincludes=fixinc.svr4;;
3243                 *)
3244                         fixincludes=fixinc.wrap;;
3245                 esac
3246                 if test x$enable_threads = xyes; then
3247                         thread_file='solaris'
3248                 fi
3249                 ;;
3250        i[34567]86-*-sysv5*)           # Intel x86 on System V Release 5
3251                xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
3252                xm_defines="USG POSIX"
3253                tm_file=i386/sysv4.h
3254                if test x$stabs = xyes
3255                then
3256                        tm_file="${tm_file} dbx.h"
3257                fi
3258                tmake_file=i386/t-crtpic
3259                xmake_file=x-svr4
3260                extra_parts="crtbegin.o crtend.o"
3261                fixincludes=fixinc.svr4
3262                ;;
3263         i[34567]86-*-sysv4*)            # Intel 80386's running system V.4
3264                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
3265                 xm_defines="USG POSIX SMALL_ARG_MAX"
3266                 tm_file=i386/sysv4.h
3267                 if test x$stabs = xyes
3268                 then
3269                         tm_file="${tm_file} dbx.h"
3270                 fi
3271                 tmake_file=i386/t-crtpic
3272                 xmake_file=x-svr4
3273                 extra_parts="crtbegin.o crtend.o"
3274                 ;;
3275         i[34567]86-*-udk*)      # Intel x86 on SCO UW/OSR5 Dev Kit
3276                 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
3277                 xm_defines="USG POSIX"
3278                 tm_file=i386/udk.h
3279                 tmake_file="i386/t-crtpic i386/t-udk"
3280                 xmake_file=x-svr4
3281                 extra_parts="crtbegin.o crtend.o"
3282                 fixincludes="fixinc.svr4"
3283                 ;;
3284         i[34567]86-*-osf1*)             # Intel 80386's running OSF/1 1.3+
3285                 cpu_type=i386
3286                 xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h i386/xm-osf1elf.h"
3287                 xm_defines="USE_C_ALLOCA SMALL_ARG_MAX"
3288                 fixincludes=Makefile.in #Don't do it on OSF/1
3289                 if test x$stabs = xyes
3290                 then
3291                         tm_file=i386/osf1elfgdb.h
3292                 else
3293                         tm_file=i386/osf1elf.h
3294                 fi
3295                 tmake_file=i386/t-osf1elf
3296                 xmake_file=i386/x-osf1elf
3297                 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
3298                 ;;
3299         i[34567]86-*-sysv*)             # Intel 80386's running system V
3300                 xm_defines="USG SVR3"
3301                 xmake_file=i386/x-sysv3
3302                 if test x$gas = xyes
3303                 then
3304                         if test x$stabs = xyes
3305                         then
3306                                 tm_file=i386/svr3dbx.h
3307                                 tmake_file=i386/t-svr3dbx
3308                                 extra_parts="svr3.ifile svr3z.rfile"
3309                         else
3310                                 tm_file=i386/svr3gas.h
3311                                 extra_parts="crtbegin.o crtend.o"
3312                                 tmake_file=i386/t-crtstuff
3313                         fi
3314                 else
3315                         tm_file=i386/sysv3.h
3316                         extra_parts="crtbegin.o crtend.o"
3317                         tmake_file=i386/t-crtstuff
3318                 fi
3319                 ;;
3320         i386-*-vsta)                    # Intel 80386's running VSTa kernel
3321                 xm_file="${xm_file} i386/xm-vsta.h"
3322                 tm_file=i386/vsta.h
3323                 tmake_file=i386/t-vsta
3324                 xmake_file=i386/x-vsta
3325                 ;;
3326         i[34567]86-*-win32)
3327                 xm_file="${xm_file} i386/xm-cygwin32.h"
3328                 tmake_file=i386/t-cygwin32
3329                 tm_file=i386/win32.h
3330                 xmake_file=i386/x-cygwin32
3331                 extra_objs=winnt.o
3332                 fixincludes=Makefile.in
3333                 if test x$enable_threads = xyes; then
3334                         thread_file='win32'
3335                 fi
3336                 exeext=.exe
3337                 ;;
3338         i[34567]86-*-pe | i[34567]86-*-cygwin32)
3339                 xm_file="${xm_file} i386/xm-cygwin32.h"
3340                 tmake_file=i386/t-cygwin32
3341                 tm_file=i386/cygwin32.h
3342                 xmake_file=i386/x-cygwin32
3343                 extra_objs=winnt.o
3344                 fixincludes=Makefile.in
3345                 if test x$enable_threads = xyes; then
3346                         thread_file='win32'
3347                 fi
3348                 exeext=.exe
3349                 ;;
3350         i[34567]86-*-mingw32*)
3351                 tm_file=i386/mingw32.h
3352                 xm_file="${xm_file} i386/xm-mingw32.h"
3353                 tmake_file="i386/t-cygwin32 i386/t-mingw32"
3354                 extra_objs=winnt.o
3355                 xmake_file=i386/x-cygwin32
3356                 fixincludes=Makefile.in
3357                 if test x$enable_threads = xyes; then
3358                         thread_file='win32'
3359                 fi
3360                 exeext=.exe
3361                 case $machine in
3362                         *mingw32msv*)
3363                                 ;;
3364                         *minwg32crt* | *mingw32*)
3365                                 tm_file="${tm_file} i386/crtdll.h"
3366                                 ;;
3367                 esac
3368                 ;;
3369         i[34567]86-*-winnt3*)
3370                 tm_file=i386/win-nt.h
3371                 out_file=i386/i386.c
3372                 xm_file="xm-winnt.h ${xm_file}"
3373                 xmake_file=winnt/x-winnt
3374                 tmake_file=i386/t-winnt
3375                 extra_host_objs="winnt.o oldnames.o"
3376                 extra_gcc_objs="spawnv.o oldnames.o"
3377                 fixincludes=fixinc.winnt
3378                 if test x$gnu_ld != xyes
3379                 then
3380                         extra_programs=ld.exe
3381                 fi
3382                 if test x$enable_threads = xyes; then
3383                         thread_file='win32'
3384                 fi
3385                 ;;
3386         i[34567]86-dg-dgux*)
3387                 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
3388                 xm_defines="USG POSIX"
3389                 out_file=i386/dgux.c
3390                 tm_file=i386/dgux.h
3391                 tmake_file=i386/t-dgux
3392                 xmake_file=i386/x-dgux
3393                 fixincludes=fixinc.dgux
3394                 install_headers_dir=install-headers-cpio
3395               ;;
3396         i860-alliant-*)         # Alliant FX/2800
3397                 tm_file="${tm_file} svr4.h i860/sysv4.h i860/fx2800.h"
3398                 xm_file="${xm_file}"
3399                 xmake_file=i860/x-fx2800
3400                 tmake_file=i860/t-fx2800
3401                 extra_parts="crtbegin.o crtend.o"
3402                 ;;
3403         i860-*-bsd*)
3404                 tm_file="${tm_file} i860/bsd.h"
3405                 if test x$gas = xyes
3406                 then
3407                         tm_file="${tm_file} i860/bsd-gas.h"
3408                 fi
3409                 use_collect2=yes
3410                 ;;
3411         i860-*-mach*)
3412                 tm_file="${tm_file} i860/mach.h"
3413                 tmake_file=t-libc-ok
3414                 ;;
3415         i860-*-osf*)                    # Intel Paragon XP/S, OSF/1AD
3416                 tm_file="${tm_file} svr3.h i860/paragon.h"
3417                 xm_defines="USG SVR3"
3418                 tmake_file=t-osf
3419                 ;;
3420         i860-*-sysv3*)
3421                 tm_file="${tm_file} svr3.h i860/sysv3.h"
3422                 xm_defines="USG SVR3"
3423                 xmake_file=i860/x-sysv3
3424                 extra_parts="crtbegin.o crtend.o"
3425                 ;;
3426         i860-*-sysv4*)
3427                 tm_file="${tm_file} svr4.h i860/sysv4.h"
3428                 xm_defines="USG SVR3"
3429                 xmake_file=i860/x-sysv4
3430                 tmake_file=t-svr4
3431                 extra_parts="crtbegin.o crtend.o"
3432                 ;;
3433         i960-wrs-vxworks5 | i960-wrs-vxworks5.0*)
3434                 tm_file="${tm_file} i960/vx960.h"
3435                 tmake_file=i960/t-vxworks960
3436                 use_collect2=yes
3437                 thread_file='vxworks'
3438                 ;;
3439         i960-wrs-vxworks5* | i960-wrs-vxworks)
3440                 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h i960/vx960-coff.h"
3441                 tmake_file=i960/t-vxworks960
3442                 use_collect2=yes
3443                 thread_file='vxworks'
3444                 ;;
3445         i960-wrs-vxworks*)
3446                 tm_file="${tm_file} i960/vx960.h"
3447                 tmake_file=i960/t-vxworks960
3448                 use_collect2=yes
3449                 thread_file='vxworks'
3450                 ;;
3451         i960-*-coff*)
3452                 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h libgloss.h"
3453                 tmake_file=i960/t-960bare
3454                 use_collect2=yes
3455                 ;;
3456         i960-*-rtems)
3457                 tmake_file="i960/t-960bare t-rtems"
3458                 tm_file="${tm_file} dbxcoff.h i960/rtems.h"
3459                 use_collect2=yes
3460                 ;;
3461         i960-*-*)                       # Default i960 environment.
3462                 use_collect2=yes
3463                 ;;
3464         m32r-*-elf*)
3465                 extra_parts="crtinit.o crtfini.o"
3466                 ;;
3467         m68000-convergent-sysv*)
3468                 tm_file=m68k/ctix.h
3469                 xm_file="m68k/xm-3b1.h ${xm_file}"
3470                 xm_defines=USG
3471                 use_collect2=yes
3472                 extra_headers=math-68881.h
3473                 ;;
3474         m68000-hp-bsd*)                 # HP 9000/200 running BSD
3475                 tm_file=m68k/hp2bsd.h
3476                 xmake_file=m68k/x-hp2bsd
3477                 use_collect2=yes
3478                 extra_headers=math-68881.h
3479                 ;;
3480         m68000-hp-hpux*)                # HP 9000 series 300
3481                 xm_file="xm_alloca.h ${xm_file}"
3482                 xm_defines="USG NO_SYS_SIGLIST"
3483                 if test x$gas = xyes
3484                 then
3485                         xmake_file=m68k/x-hp320g
3486                         tm_file=m68k/hp310g.h
3487                 else
3488                         xmake_file=m68k/x-hp320
3489                         tm_file=m68k/hp310.h
3490                 fi
3491                 install_headers_dir=install-headers-cpio
3492                 use_collect2=yes
3493                 extra_headers=math-68881.h
3494                 ;;
3495         m68000-sun-sunos3*)
3496                 tm_file=m68k/sun2.h
3497                 use_collect2=yes
3498                 extra_headers=math-68881.h
3499                 ;;
3500         m68000-sun-sunos4*)
3501                 tm_file=m68k/sun2o4.h
3502                 use_collect2=yes
3503                 extra_headers=math-68881.h
3504                 ;;
3505         m68000-att-sysv*)
3506                 xm_file="m68k/xm-3b1.h ${xm_file}"
3507                 xm_defines=USG
3508                 if test x$gas = xyes
3509                 then
3510                         tm_file=m68k/3b1g.h
3511                 else
3512                         tm_file=m68k/3b1.h
3513                 fi
3514                 use_collect2=yes
3515                 extra_headers=math-68881.h
3516                 ;;
3517         m68k-apple-aux*)                # Apple Macintosh running A/UX
3518                 xm_defines="USG AUX"
3519                 tmake_file=m68k/t-aux
3520                 install_headers_dir=install-headers-cpio
3521                 extra_headers=math-68881.h
3522                 extra_parts="crt1.o mcrt1.o maccrt1.o crt2.o crtn.o"
3523                 tm_file=
3524                 if test "$gnu_ld" = yes
3525                 then
3526                         tm_file="${tm_file} m68k/auxgld.h"
3527                 else
3528                         tm_file="${tm_file} m68k/auxld.h"
3529                 fi
3530                 if test "$gas" = yes
3531                 then
3532                         tm_file="${tm_file} m68k/auxgas.h"
3533                 else
3534                         tm_file="${tm_file} m68k/auxas.h"
3535                 fi
3536                 tm_file="${tm_file} m68k/a-ux.h"
3537                 float_format=m68k
3538                 ;;
3539         m68k-apollo-*)
3540                 tm_file=m68k/apollo68.h
3541                 xmake_file=m68k/x-apollo68
3542                 use_collect2=yes
3543                 extra_headers=math-68881.h
3544                 float_format=m68k
3545                 ;;
3546         m68k-altos-sysv*)                  # Altos 3068
3547                 if test x$gas = xyes
3548                 then
3549                         tm_file=m68k/altos3068.h
3550                         xm_defines=USG
3551                 else
3552                         echo "The Altos is supported only with the GNU assembler" 1>&2
3553                         exit 1
3554                 fi
3555                 extra_headers=math-68881.h
3556                 ;;
3557         m68k-bull-sysv*)                # Bull DPX/2
3558                 if test x$gas = xyes
3559                 then
3560                         if test x$stabs = xyes
3561                         then
3562                                 tm_file=m68k/dpx2cdbx.h
3563                         else
3564                                 tm_file=m68k/dpx2g.h
3565                         fi
3566                 else
3567                         tm_file=m68k/dpx2.h
3568                 fi
3569                 xm_file="xm-alloca.h ${xm_file}"
3570                 xm_defines=USG
3571                 xmake_file=m68k/x-dpx2
3572                 use_collect2=yes
3573                 extra_headers=math-68881.h
3574                 ;;
3575         m68k-atari-sysv4*)              # Atari variant of V.4.
3576                 tm_file=m68k/atari.h
3577                 xm_file="xm-alloca.h ${xm_file}"
3578                 xm_defines="USG FULL_PROTOTYPES"
3579                 tmake_file=t-svr4
3580                 extra_parts="crtbegin.o crtend.o"
3581                 extra_headers=math-68881.h
3582                 float_format=m68k
3583                 ;;
3584         m68k-motorola-sysv*)
3585                 tm_file=m68k/mot3300.h
3586                 xm_file="xm-alloca.h m68k/xm-mot3300.h ${xm_file}"
3587                 xm_defines=NO_SYS_SIGLIST
3588                 if test x$gas = xyes
3589                 then
3590                         xmake_file=m68k/x-mot3300-gas
3591                         if test x$gnu_ld = xyes
3592                         then
3593                                 tmake_file=m68k/t-mot3300-gald
3594                         else
3595                                 tmake_file=m68k/t-mot3300-gas
3596                                 use_collect2=yes
3597                         fi
3598                 else
3599                         xmake_file=m68k/x-mot3300
3600                         if test x$gnu_ld = xyes
3601                         then
3602                                 tmake_file=m68k/t-mot3300-gld
3603                         else
3604                                 tmake_file=m68k/t-mot3300
3605                                 use_collect2=yes
3606                         fi
3607                 fi
3608                 gdb_needs_out_file_path=yes
3609                 extra_parts="crt0.o mcrt0.o"
3610                 extra_headers=math-68881.h
3611                 float_format=m68k
3612                 ;;
3613         m68k-ncr-sysv*)                 # NCR Tower 32 SVR3
3614                 tm_file=m68k/tower-as.h
3615                 xm_defines="USG SVR3"
3616                 xmake_file=m68k/x-tower
3617                 extra_parts="crtbegin.o crtend.o"
3618                 extra_headers=math-68881.h
3619                 ;;
3620         m68k-plexus-sysv*)
3621                 tm_file=m68k/plexus.h
3622                 xm_file="xm-alloca.h m68k/xm-plexus.h ${xm_file}"
3623                 xm_defines=USG
3624                 use_collect2=yes
3625                 extra_headers=math-68881.h
3626                 ;;
3627         m68k-tti-*)
3628                 tm_file=m68k/pbb.h
3629                 xm_file="xm-alloca.h ${xm_file}"
3630                 xm_defines=USG
3631                 extra_headers=math-68881.h
3632                 ;;
3633         m68k-crds-unos*)
3634                 xm_file="xm-alloca.h m68k/xm-crds.h ${xm_file}"
3635                 xm_defines="USG unos"
3636                 xmake_file=m68k/x-crds
3637                 tm_file=m68k/crds.h
3638                 use_collect2=yes
3639                 extra_headers=math-68881.h
3640                 ;;
3641         m68k-cbm-sysv4*)                # Commodore variant of V.4.
3642                 tm_file=m68k/amix.h
3643                 xm_file="xm-alloca.h ${xm_file}"
3644                 xm_defines="USG FULL_PROTOTYPES"
3645                 xmake_file=m68k/x-amix
3646                 tmake_file=t-svr4
3647                 extra_parts="crtbegin.o crtend.o"
3648                 extra_headers=math-68881.h
3649                 float_format=m68k
3650                 ;;
3651         m68k-ccur-rtu)
3652                 tm_file=m68k/ccur-GAS.h
3653                 xmake_file=m68k/x-ccur
3654                 extra_headers=math-68881.h
3655                 use_collect2=yes
3656                 float_format=m68k
3657                 ;;
3658         m68k-hp-bsd4.4*)                # HP 9000/3xx running 4.4bsd
3659                 tm_file=m68k/hp3bsd44.h
3660                 xmake_file=m68k/x-hp3bsd44
3661                 use_collect2=yes
3662                 extra_headers=math-68881.h
3663                 float_format=m68k
3664                 ;;
3665         m68k-hp-bsd*)                   # HP 9000/3xx running Berkeley Unix
3666                 tm_file=m68k/hp3bsd.h
3667                 use_collect2=yes
3668                 extra_headers=math-68881.h
3669                 float_format=m68k
3670                 ;;
3671         m68k-isi-bsd*)
3672                 if test x$with_fp = xno
3673                 then
3674                         tm_file=m68k/isi-nfp.h
3675                 else
3676                         tm_file=m68k/isi.h
3677                         float_format=m68k
3678                 fi
3679                 use_collect2=yes
3680                 extra_headers=math-68881.h
3681                 ;;
3682         m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7.
3683                 xm_file="xm_alloca.h ${xm_file}"
3684                 xm_defines="USG NO_SYS_SIGLIST"
3685                 if test x$gas = xyes
3686                 then
3687                         xmake_file=m68k/x-hp320g
3688                         tm_file=m68k/hp320g.h
3689                 else
3690                         xmake_file=m68k/x-hp320
3691                         tm_file=m68k/hpux7.h
3692                 fi
3693                 install_headers_dir=install-headers-cpio
3694                 use_collect2=yes
3695                 extra_headers=math-68881.h
3696                 float_format=m68k
3697                 ;;
3698         m68k-hp-hpux*)  # HP 9000 series 300
3699                 xm_file="xm_alloca.h ${xm_file}"
3700                 xm_defines="USG NO_SYS_SIGLIST"
3701                 if test x$gas = xyes
3702                 then
3703                         xmake_file=m68k/x-hp320g
3704                         tm_file=m68k/hp320g.h
3705                 else
3706                         xmake_file=m68k/x-hp320
3707                         tm_file=m68k/hp320.h
3708                 fi
3709                 install_headers_dir=install-headers-cpio
3710                 use_collect2=yes
3711                 extra_headers=math-68881.h
3712                 float_format=m68k
3713                 ;;
3714         m68k-sun-mach*)
3715                 tm_file=m68k/sun3mach.h
3716                 use_collect2=yes
3717                 extra_headers=math-68881.h
3718                 float_format=m68k
3719                 ;;
3720         m68k-sony-newsos3*)
3721                 if test x$gas = xyes
3722                 then
3723                         tm_file=m68k/news3gas.h
3724                 else
3725                         tm_file=m68k/news3.h
3726                 fi
3727                 use_collect2=yes
3728                 extra_headers=math-68881.h
3729                 float_format=m68k
3730                 ;;
3731         m68k-sony-bsd* | m68k-sony-newsos*)
3732                 if test x$gas = xyes
3733                 then
3734                         tm_file=m68k/newsgas.h
3735                 else
3736                         tm_file=m68k/news.h
3737                 fi
3738                 use_collect2=yes
3739                 extra_headers=math-68881.h
3740                 float_format=m68k
3741                 ;;
3742         m68k-next-nextstep2*)
3743                 tm_file=m68k/next21.h
3744                 xm_file="m68k/xm-next.h ${xm_file}"
3745                 tmake_file=m68k/t-next
3746                 xmake_file=m68k/x-next
3747                 extra_objs=nextstep.o
3748                 extra_headers=math-68881.h
3749                 use_collect2=yes
3750                 float_format=m68k
3751                 ;;
3752         m68k-next-nextstep3*)
3753                 tm_file=m68k/next.h
3754                 xm_file="m68k/xm-next.h ${xm_file}"
3755                 tmake_file=m68k/t-next
3756                 xmake_file=m68k/x-next
3757                 extra_objs=nextstep.o
3758                 extra_parts="crtbegin.o crtend.o"
3759                 extra_headers=math-68881.h
3760                 float_format=m68k
3761                 if test x$enable_threads = xyes; then
3762                         thread_file='mach'
3763                 fi
3764                 ;;
3765         m68k-sun-sunos3*)
3766                 if test x$with_fp = xno
3767                 then
3768                         tm_file=m68k/sun3n3.h
3769                 else
3770                         tm_file=m68k/sun3o3.h
3771                         float_format=m68k
3772                 fi
3773                 use_collect2=yes
3774                 extra_headers=math-68881.h
3775                 ;;
3776         m68k-sun-sunos*)                        # For SunOS 4 (the default).
3777                 if test x$with_fp = xno
3778                 then
3779                         tm_file=m68k/sun3n.h
3780                 else
3781                         tm_file=m68k/sun3.h
3782                         float_format=m68k
3783                 fi
3784                 use_collect2=yes
3785                 extra_headers=math-68881.h
3786                 ;;
3787         m68k-wrs-vxworks*)
3788                 tm_file=m68k/vxm68k.h
3789                 tmake_file=m68k/t-vxworks68
3790                 extra_headers=math-68881.h
3791                 thread_file='vxworks'
3792                 float_format=m68k
3793                 ;;
3794         m68k-*-aout*)
3795                 tmake_file=m68k/t-m68kbare
3796                 tm_file="m68k/m68k-aout.h libgloss.h"
3797                 extra_headers=math-68881.h
3798                 float_format=m68k
3799                 ;;
3800         m68k-*-coff*)
3801                 tmake_file=m68k/t-m68kbare
3802                 tm_file="m68k/m68k-coff.h dbx.h libgloss.h"
3803                 extra_headers=math-68881.h
3804                 float_format=m68k
3805                 ;;
3806         m68k-*-lynxos*)
3807                 if test x$gas = xyes
3808                 then
3809                         tm_file=m68k/lynx.h
3810                 else
3811                         tm_file=m68k/lynx-ng.h
3812                 fi
3813                 xm_file=m68k/xm-lynx.h
3814                 xmake_file=x-lynx
3815                 tmake_file=m68k/t-lynx
3816                 extra_headers=math-68881.h
3817                 float_format=m68k
3818                 ;;
3819         m68k*-*-netbsd*)
3820                 tm_file=m68k/netbsd.h
3821                 # On NetBSD, the headers are already okay, except for math.h.
3822                 fixincludes=fixinc.wrap
3823                 tmake_file=t-netbsd
3824                 float_format=m68k
3825                 ;;
3826         m68k-*-sysv3*)                  # Motorola m68k's running system V.3
3827                 xm_file="xm-alloca.h ${xm_file}"
3828                 xm_defines=USG
3829                 xmake_file=m68k/x-m68kv
3830                 extra_parts="crtbegin.o crtend.o"
3831                 extra_headers=math-68881.h
3832                 float_format=m68k
3833                 ;;
3834         m68k-*-sysv4*)                  # Motorola m68k's running system V.4
3835                 tm_file=m68k/m68kv4.h
3836                 xm_file="xm-alloca.h ${xm_file}"
3837                 xm_defines=USG
3838                 tmake_file=t-svr4
3839                 extra_parts="crtbegin.o crtend.o"
3840                 extra_headers=math-68881.h
3841                 float_format=m68k
3842                 ;;
3843         m68k-*-linux-gnuaout*)          # Motorola m68k's running GNU/Linux
3844                                         # with a.out format
3845                 xmake_file=x-linux
3846                 tm_file=m68k/linux-aout.h
3847                 tmake_file="t-linux-aout m68k/t-linux-aout"
3848                 fixincludes=Makefile.in # The headers are ok already.
3849                 extra_headers=math-68881.h
3850                 float_format=m68k
3851                 gnu_ld=yes
3852                 ;;
3853         m68k-*-linux-gnulibc1)          # Motorola m68k's running GNU/Linux
3854                                         # with ELF format using the
3855                                         # GNU/Linux C library 5
3856                 xmake_file=x-linux
3857                 tm_file=m68k/linux.h
3858                 tmake_file="t-linux t-linux-gnulibc1 m68k/t-linux"
3859                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3860                 fixincludes=Makefile.in # The headers are ok already.
3861                 extra_headers=math-68881.h
3862                 float_format=m68k
3863                 gnu_ld=yes
3864                 ;;
3865         m68k-*-linux-gnu*)              # Motorola m68k's running GNU/Linux
3866                                         # with ELF format using glibc 2
3867                                         # aka the GNU/Linux C library 6.
3868                 xmake_file=x-linux
3869                 tm_file=m68k/linux.h
3870                 tmake_file="t-linux m68k/t-linux"
3871                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
3872                 fixincludes=Makefile.in # The headers are ok already.
3873                 extra_headers=math-68881.h
3874                 float_format=m68k
3875                 gnu_ld=yes
3876                 if test x$enable_threads = xyes; then
3877                         thread_file='posix'
3878                 fi
3879                 ;;
3880         m68k-*-psos*)
3881                 tmake_file=m68k/t-m68kbare
3882                 tm_file=m68k/m68k-psos.h
3883                 extra_headers=math-68881.h
3884                 float_format=m68k
3885                 ;;
3886         m68k-*-rtems*)
3887                 tmake_file="m68k/t-m68kbare t-rtems"
3888                 tm_file=m68k/rtems.h
3889                 extra_headers=math-68881.h
3890                 float_format=m68k
3891                 ;;
3892
3893         m88k-dg-dgux*)
3894                 case $machine in
3895                   m88k-dg-dguxbcs*)
3896                     tm_file=m88k/dguxbcs.h
3897                     tmake_file=m88k/t-dguxbcs
3898                     ;;
3899                   *)
3900                     tm_file=m88k/dgux.h
3901                     tmake_file=m88k/t-dgux
3902                     ;;
3903                 esac
3904                 extra_parts="crtbegin.o bcscrtbegin.o crtend.o m88kdgux.ld"
3905                 xmake_file=m88k/x-dgux
3906                 if test x$gas = xyes
3907                 then
3908                         tmake_file=m88k/t-dgux-gas
3909                 fi
3910                 fixincludes=fixinc.dgux
3911                 ;;
3912         m88k-dolphin-sysv3*)
3913                 tm_file=m88k/dolph.h
3914                 extra_parts="crtbegin.o crtend.o"
3915                 xm_file="m88k/xm-sysv3.h ${xm_file}"
3916                 xmake_file=m88k/x-dolph
3917                 if test x$gas = xyes
3918                 then
3919                         tmake_file=m88k/t-m88k-gas
3920                 fi
3921                 ;;
3922         m88k-tektronix-sysv3)
3923                 tm_file=m88k/tekXD88.h
3924                 extra_parts="crtbegin.o crtend.o"
3925                 xm_file="m88k/xm-sysv3.h ${xm_file}"
3926                 xmake_file=m88k/x-tekXD88
3927                 if test x$gas = xyes
3928                 then
3929                         tmake_file=m88k/t-m88k-gas
3930                 fi
3931                 ;;
3932         m88k-*-aout*)
3933                 tm_file=m88k/m88k-aout.h
3934                 ;;
3935         m88k-*-coff*)
3936                 tm_file=m88k/m88k-coff.h
3937                 tmake_file=m88k/t-bug
3938                 ;;
3939         m88k-*-luna*)
3940                 tm_file=m88k/luna.h
3941                 extra_parts="crtbegin.o crtend.o"
3942                 if test x$gas = xyes
3943                 then
3944                         tmake_file=m88k/t-luna-gas
3945                 else
3946                         tmake_file=m88k/t-luna
3947                 fi
3948                 ;;
3949         m88k-*-sysv3*)
3950                 tm_file=m88k/sysv3.h
3951                 extra_parts="crtbegin.o crtend.o"
3952                 xm_file="m88k/xm-sysv3.h ${xm_file}"
3953                 xmake_file=m88k/x-sysv3
3954                 if test x$gas = xyes
3955                 then
3956                         tmake_file=m88k/t-m88k-gas
3957                 fi
3958                 ;;
3959         m88k-*-sysv4*)
3960                 tm_file=m88k/sysv4.h
3961                 extra_parts="crtbegin.o crtend.o"
3962                 xmake_file=m88k/x-sysv4
3963                 tmake_file=m88k/t-sysv4
3964                 ;;
3965         mips-sgi-irix6*)                # SGI System V.4., IRIX 6
3966                 tm_file=mips/iris6.h
3967                 xm_file=mips/xm-iris6.h
3968                 fixincludes=fixinc.irix
3969                 xmake_file=mips/x-iris6
3970                 tmake_file=mips/t-iris6
3971 #               if test x$enable_threads = xyes; then
3972 #                       thread_file='irix'
3973 #               fi
3974                 ;;
3975         mips-wrs-vxworks)
3976                 tm_file="mips/elf.h libgloss.h"
3977                 tmake_file=mips/t-ecoff
3978                 gas=yes
3979                 gnu_ld=yes
3980                 extra_parts="crtbegin.o crtend.o"
3981 #               thread_file='vxworks'
3982                 ;;
3983         mips-sgi-irix5cross64)          # Irix5 host, Irix 6 target, cross64
3984                 tm_file="mips/iris6.h mips/cross64.h"
3985                 xm_defines=USG
3986                 xm_file="mips/xm-iris5.h"
3987                 fixincludes=Makefile.in
3988                 xmake_file=mips/x-iris
3989                 tmake_file=mips/t-cross64
3990                 # See comment in mips/iris[56].h files.
3991                 use_collect2=yes
3992 #               if test x$enable_threads = xyes; then
3993 #                       thread_file='irix'
3994 #               fi
3995                 ;;
3996         mips-sni-sysv4)
3997                 if test x$gas = xyes
3998                 then
3999                         if test x$stabs = xyes
4000                         then
4001                                 tm_file=mips/iris5gdb.h
4002                         else
4003                                 tm_file="mips/sni-svr4.h mips/sni-gas.h"
4004                         fi
4005                 else
4006                         tm_file=mips/sni-svr4.h
4007                 fi
4008                 xm_defines=USG
4009                 xmake_file=mips/x-sni-svr4
4010                 tmake_file=mips/t-mips-gas
4011                 if test x$gnu_ld != xyes
4012                 then
4013                         use_collect2=yes
4014                 fi
4015                 ;;
4016         mips-sgi-irix5*)                # SGI System V.4., IRIX 5
4017                 if test x$gas = xyes
4018                 then
4019                         tm_file="mips/iris5.h mips/iris5gas.h"
4020                         if test x$stabs = xyes
4021                         then
4022                                 tm_file="${tm_file} dbx.h"
4023                         fi
4024                 else
4025                         tm_file=mips/iris5.h
4026                 fi
4027                 xm_defines=USG
4028                 xm_file="mips/xm-iris5.h"
4029                 fixincludes=fixinc.irix
4030                 xmake_file=mips/x-iris
4031                 # mips-tfile doesn't work yet
4032                 tmake_file=mips/t-mips-gas
4033                 # See comment in mips/iris5.h file.
4034                 use_collect2=yes
4035 #               if test x$enable_threads = xyes; then
4036 #                       thread_file='irix'
4037 #               fi
4038                 ;;
4039         mips-sgi-irix4loser*)           # Mostly like a MIPS.
4040                 tm_file="mips/iris4loser.h mips/iris3.h ${tm_file} mips/iris4.h"
4041                 if test x$stabs = xyes; then
4042                         tm_file="${tm_file} dbx.h"
4043                 fi
4044                 xm_defines=USG
4045                 xmake_file=mips/x-iris
4046                 if test x$gas = xyes
4047                 then
4048                         tmake_file=mips/t-mips-gas
4049                 else
4050                         extra_passes="mips-tfile mips-tdump"
4051                 fi
4052                 if test x$gnu_ld != xyes
4053                 then
4054                         use_collect2=yes
4055                 fi
4056 #               if test x$enable_threads = xyes; then
4057 #                       thread_file='irix'
4058 #               fi
4059                 ;;
4060         mips-sgi-irix4*)                # Mostly like a MIPS.
4061                 tm_file="mips/iris3.h ${tm_file} mips/iris4.h"
4062                 if test x$stabs = xyes; then
4063                         tm_file="${tm_file} dbx.h"
4064                 fi
4065                 xm_defines=USG
4066                 xmake_file=mips/x-iris
4067                 if test x$gas = xyes
4068                 then
4069                         tmake_file=mips/t-mips-gas
4070                 else
4071                         extra_passes="mips-tfile mips-tdump"
4072                 fi
4073                 if test x$gnu_ld != xyes
4074                 then
4075                         use_collect2=yes
4076                 fi
4077 #               if test x$enable_threads = xyes; then
4078 #                       thread_file='irix'
4079 #               fi
4080                 ;;
4081         mips-sgi-*)                     # Mostly like a MIPS.
4082                 tm_file="mips/iris3.h ${tm_file}"
4083                 if test x$stabs = xyes; then
4084                         tm_file="${tm_file} dbx.h"
4085                 fi
4086                 xm_defines=USG
4087                 xmake_file=mips/x-iris3
4088                 if test x$gas = xyes
4089                 then
4090                         tmake_file=mips/t-mips-gas
4091                 else
4092                         extra_passes="mips-tfile mips-tdump"
4093                 fi
4094                 if test x$gnu_ld != xyes
4095                 then
4096                         use_collect2=yes
4097                 fi
4098                 ;;
4099         mips-dec-osfrose*)              # Decstation running OSF/1 reference port with OSF/rose.
4100                 tm_file="mips/osfrose.h ${tm_file}"
4101                 xmake_file=mips/x-osfrose
4102                 tmake_file=mips/t-osfrose
4103                 extra_objs=halfpic.o
4104                 use_collect2=yes
4105                 ;;
4106         mips-dec-osf*)                  # Decstation running OSF/1 as shipped by DIGITAL
4107                 tm_file=mips/dec-osf1.h
4108                 if test x$stabs = xyes; then
4109                         tm_file="${tm_file} dbx.h"
4110                 fi
4111                 xmake_file=mips/x-dec-osf1
4112                 if test x$gas = xyes
4113                 then
4114                         tmake_file=mips/t-mips-gas
4115                 else
4116                         tmake_file=mips/t-ultrix
4117                         extra_passes="mips-tfile mips-tdump"
4118                 fi
4119                 if test x$gnu_ld != xyes
4120                 then
4121                         use_collect2=yes
4122                 fi
4123                 ;;
4124         mips-dec-bsd*)                  # Decstation running 4.4 BSD
4125               tm_file=mips/dec-bsd.h
4126               fixincludes=
4127               if test x$gas = xyes
4128               then
4129                         tmake_file=mips/t-mips-gas
4130               else
4131                         tmake_file=mips/t-ultrix
4132                         extra_passes="mips-tfile mips-tdump"
4133               fi
4134               if test x$gnu_ld != xyes
4135               then
4136                         use_collect2=yes
4137               fi
4138               ;;
4139         mipsel-*-netbsd* | mips-dec-netbsd*)    # Decstation running NetBSD
4140                 tm_file=mips/netbsd.h
4141                 # On NetBSD, the headers are already okay, except for math.h.
4142                 fixincludes=fixinc.wrap
4143                 tmake_file=t-netbsd
4144                 ;;
4145         mips-sony-bsd* | mips-sony-newsos*)     # Sony NEWS 3600 or risc/news.
4146                 tm_file="mips/news4.h ${tm_file}"
4147                 if test x$stabs = xyes; then
4148                         tm_file="${tm_file} dbx.h"
4149                 fi
4150                 if test x$gas = xyes
4151                 then
4152                         tmake_file=mips/t-mips-gas
4153                 else
4154                         extra_passes="mips-tfile mips-tdump"
4155                 fi
4156                 if test x$gnu_ld != xyes
4157                 then
4158                         use_collect2=yes
4159                 fi
4160                 xmake_file=mips/x-sony
4161                 ;;
4162         mips-sony-sysv*)                # Sony NEWS 3800 with NEWSOS5.0.
4163                                         # That is based on svr4.
4164                 # t-svr4 is not right because this system doesn't use ELF.
4165                 tm_file="mips/news5.h ${tm_file}"
4166                 if test x$stabs = xyes; then
4167                         tm_file="${tm_file} dbx.h"
4168                 fi
4169                 xm_file="xm-siglist.h ${xm_file}"
4170                 xm_defines=USG
4171                 if test x$gas = xyes
4172                 then
4173                         tmake_file=mips/t-mips-gas
4174                 else
4175                         extra_passes="mips-tfile mips-tdump"
4176                 fi
4177                 if test x$gnu_ld != xyes
4178                 then
4179                         use_collect2=yes
4180                 fi
4181                 ;;
4182         mips-tandem-sysv4*)             # Tandem S2 running NonStop UX
4183                 tm_file="mips/svr4-5.h mips/svr4-t.h"
4184                 if test x$stabs = xyes; then
4185                         tm_file="${tm_file} dbx.h"
4186                 fi
4187                 xm_file="xm-siglist.h ${xm_file}"
4188                 xm_defines=USG
4189                 xmake_file=mips/x-sysv
4190                 if test x$gas = xyes
4191                 then
4192                         tmake_file=mips/t-mips-gas
4193                         extra_parts="crtbegin.o crtend.o"
4194                 else
4195                         tmake_file=mips/t-mips
4196                         extra_passes="mips-tfile mips-tdump"
4197                 fi
4198                 if test x$gnu_ld != xyes
4199                 then
4200                         use_collect2=yes
4201                 fi
4202                 ;;
4203         mips-*-ultrix* | mips-dec-mach3)        # Decstation.
4204                 tm_file="mips/ultrix.h ${tm_file}"
4205                 if test x$stabs = xyes; then
4206                         tm_file="${tm_file} dbx.h"
4207                 fi
4208                 xmake_file=mips/x-ultrix
4209                 if test x$gas = xyes
4210                 then
4211                         tmake_file=mips/t-mips-gas
4212                 else
4213                         tmake_file=mips/t-ultrix
4214                         extra_passes="mips-tfile mips-tdump"
4215                 fi
4216                 if test x$gnu_ld != xyes
4217                 then
4218                         use_collect2=yes
4219                 fi
4220                 ;;
4221         mips-*-riscos[56789]bsd*)
4222                 tm_file=mips/bsd-5.h    # MIPS BSD 4.3, RISC-OS 5.0
4223                 if test x$stabs = xyes; then
4224                         tm_file="${tm_file} dbx.h"
4225                 fi
4226                 if test x$gas = xyes
4227                 then
4228                         tmake_file=mips/t-bsd-gas
4229                 else
4230                         tmake_file=mips/t-bsd
4231                         extra_passes="mips-tfile mips-tdump"
4232                 fi
4233                 if test x$gnu_ld != xyes
4234                 then
4235                         use_collect2=yes
4236                 fi
4237                 ;;
4238         mips-*-bsd* | mips-*-riscosbsd* | mips-*-riscos[1234]bsd*)
4239                 tm_file="mips/bsd-4.h ${tm_file}" # MIPS BSD 4.3, RISC-OS 4.0
4240                 if test x$stabs = xyes; then
4241                         tm_file="${tm_file} dbx.h"
4242                 fi
4243                 if test x$gas = xyes
4244                 then
4245                         tmake_file=mips/t-bsd-gas
4246                 else
4247                         tmake_file=mips/t-bsd
4248                         extra_passes="mips-tfile mips-tdump"
4249                 fi
4250                 if test x$gnu_ld != xyes
4251                 then
4252                         use_collect2=yes
4253                 fi
4254                 ;;
4255         mips-*-riscos[56789]sysv4*)
4256                 tm_file=mips/svr4-5.h   # MIPS System V.4., RISC-OS 5.0
4257                 if test x$stabs = xyes; then
4258                         tm_file="${tm_file} dbx.h"
4259                 fi
4260                 xm_file="xm-siglist.h ${xm_file}"
4261                 xmake_file=mips/x-sysv
4262                 if test x$gas = xyes
4263                 then
4264                         tmake_file=mips/t-svr4-gas
4265                 else
4266                         tmake_file=mips/t-svr4
4267                         extra_passes="mips-tfile mips-tdump"
4268                 fi
4269                 if test x$gnu_ld != xyes
4270                 then
4271                         use_collect2=yes
4272                 fi
4273                 ;;
4274         mips-*-sysv4* | mips-*-riscos[1234]sysv4* | mips-*-riscossysv4*)
4275                 tm_file="mips/svr4-4.h ${tm_file}"
4276                 if test x$stabs = xyes; then
4277                         tm_file="${tm_file} dbx.h"
4278                 fi
4279                 xm_defines=USG
4280                 xmake_file=mips/x-sysv
4281                 if test x$gas = xyes
4282                 then
4283                         tmake_file=mips/t-svr4-gas
4284                 else
4285                         tmake_file=mips/t-svr4
4286                         extra_passes="mips-tfile mips-tdump"
4287                 fi
4288                 if test x$gnu_ld != xyes
4289                 then
4290                         use_collect2=yes
4291                 fi
4292                 ;;
4293         mips-*-riscos[56789]sysv*)
4294                 tm_file=mips/svr3-5.h   # MIPS System V.3, RISC-OS 5.0
4295                 if test x$stabs = xyes; then
4296                         tm_file="${tm_file} dbx.h"
4297                 fi
4298                 xm_defines=USG
4299                 xmake_file=mips/x-sysv
4300                 if test x$gas = xyes
4301                 then
4302                         tmake_file=mips/t-svr3-gas
4303                 else
4304                         tmake_file=mips/t-svr3
4305                         extra_passes="mips-tfile mips-tdump"
4306                 fi
4307                 if test x$gnu_ld != xyes
4308                 then
4309                         use_collect2=yes
4310                 fi
4311                 ;;
4312         mips-*-sysv* | mips-*-riscos*sysv*)
4313                 tm_file="mips/svr3-4.h ${tm_file}"
4314                 if test x$stabs = xyes; then
4315                         tm_file="${tm_file} dbx.h"
4316                 fi
4317                 xm_defines=USG
4318                 xmake_file=mips/x-sysv
4319                 if test x$gas = xyes
4320                 then
4321                         tmake_file=mips/t-svr3-gas
4322                 else
4323                         tmake_file=mips/t-svr3
4324                         extra_passes="mips-tfile mips-tdump"
4325                 fi
4326                 if test x$gnu_ld != xyes
4327                 then
4328                         use_collect2=yes
4329                 fi
4330                 ;;
4331         mips-*-riscos[56789]*)          # Default MIPS RISC-OS 5.0.
4332                 tm_file=mips/mips-5.h
4333                 if test x$stabs = xyes; then
4334                         tm_file="${tm_file} dbx.h"
4335                 fi
4336                 if test x$gas = xyes
4337                 then
4338                         tmake_file=mips/t-mips-gas
4339                 else
4340                         extra_passes="mips-tfile mips-tdump"
4341                 fi
4342                 if test x$gnu_ld != xyes
4343                 then
4344                         use_collect2=yes
4345                 fi
4346                 ;;
4347         mips-*-gnu*)
4348                 ;;
4349         mipsel-*-ecoff*)
4350                 tm_file=mips/ecoffl.h
4351                 if test x$stabs = xyes; then
4352                         tm_file="${tm_file} dbx.h"
4353                 fi
4354                 tmake_file=mips/t-ecoff
4355                 ;;
4356         mips-*-ecoff*)
4357                 tm_file="gofast.h mips/ecoff.h"
4358                 if test x$stabs = xyes; then
4359                         tm_file="${tm_file} dbx.h"
4360                 fi
4361                 tmake_file=mips/t-ecoff
4362                 ;;
4363         mipsel-*-elf*)
4364                 tm_file="mips/elfl.h libgloss.h"
4365                 tmake_file=mips/t-ecoff
4366                 ;;
4367         mips-*-elf*)
4368                 tm_file="mips/elf.h libgloss.h"
4369                 tmake_file=mips/t-ecoff
4370                 ;;
4371         mips64el-*-elf*)
4372                 tm_file="mips/elfl64.h libgloss.h"
4373                 tmake_file=mips/t-ecoff
4374                 ;;
4375         mips64orionel-*-elf*)
4376                 tm_file="mips/elforion.h mips/elfl64.h libgloss.h"
4377                 tmake_file=mips/t-ecoff
4378                 ;;
4379         mips64-*-elf*)
4380                 tm_file="mips/elf64.h libgloss.h"
4381                 tmake_file=mips/t-ecoff
4382                 ;;
4383         mips64orion-*-elf*)
4384                 tm_file="mips/elforion.h mips/elf64.h libgloss.h"
4385                 tmake_file=mips/t-ecoff
4386                 ;;
4387         mips64orion-*-rtems*)
4388                 tm_file="mips/elforion.h mips/elf64.h mips/rtems64.h"
4389                 tmake_file="mips/t-ecoff t-rtems"
4390                 ;;
4391         mipstx39el-*-elf*)
4392                 tm_file="mips/r3900.h mips/elfl.h mips/abi64.h libgloss.h"
4393                 tmake_file=mips/t-r3900
4394                 ;;
4395         mipstx39-*-elf*)
4396                 tm_file="mips/r3900.h mips/elf.h mips/abi64.h libgloss.h"
4397                 tmake_file=mips/t-r3900
4398                 # FIXME mips-elf should be fixed to use crtstuff.
4399                 use_collect2=yes
4400                 ;;
4401         mips-*-*)                               # Default MIPS RISC-OS 4.0.
4402                 if test x$stabs = xyes; then
4403                         tm_file="${tm_file} dbx.h"
4404                 fi
4405                 if test x$gas = xyes
4406                 then
4407                         tmake_file=mips/t-mips-gas
4408                 else
4409                         extra_passes="mips-tfile mips-tdump"
4410                 fi
4411                 if test x$gnu_ld != xyes
4412                 then
4413                         use_collect2=yes
4414                 fi
4415                 ;;
4416         mn10200-*-*)
4417                 cpu_type=mn10200
4418                 tm_file="mn10200/mn10200.h"
4419                 if test x$stabs = xyes
4420                 then
4421                         tm_file="${tm_file} dbx.h"
4422                 fi
4423                 use_collect2=no
4424                 ;;
4425         mn10300-*-*)
4426                 cpu_type=mn10300
4427                 tm_file="mn10300/mn10300.h"
4428                 if test x$stabs = xyes
4429                 then
4430                         tm_file="${tm_file} dbx.h"
4431                 fi
4432                 use_collect2=no
4433                 ;;
4434         ns32k-encore-bsd*)
4435                 tm_file=ns32k/encore.h
4436                 use_collect2=yes
4437                 ;;
4438         ns32k-sequent-bsd*)
4439                 tm_file=ns32k/sequent.h
4440                 use_collect2=yes
4441                 ;;
4442         ns32k-tek6100-bsd*)
4443                 tm_file=ns32k/tek6100.h
4444                 use_collect2=yes
4445                 ;;
4446         ns32k-tek6200-bsd*)
4447                 tm_file=ns32k/tek6200.h
4448                 use_collect2=yes
4449                 ;;
4450 # This has not been updated to GCC 2.
4451 #       ns32k-ns-genix*)
4452 #               xm_defines=USG
4453 #               xmake_file=ns32k/x-genix
4454 #               tm_file=ns32k/genix.h
4455 #               use_collect2=yes
4456 #               ;;
4457         ns32k-merlin-*)
4458                 tm_file=ns32k/merlin.h
4459                 use_collect2=yes
4460                 ;;
4461         ns32k-pc532-mach*)
4462                 tm_file=ns32k/pc532-mach.h
4463                 use_collect2=yes
4464                 ;;
4465         ns32k-pc532-minix*)
4466                 tm_file=ns32k/pc532-min.h
4467                 xm_file="ns32k/xm-pc532-min.h ${xm-file}"
4468                 xm_defines=USG
4469                 use_collect2=yes
4470                 ;;
4471         ns32k-*-netbsd*)
4472                 tm_file=ns32k/netbsd.h
4473                 xm_file="ns32k/xm-netbsd.h ${xm_file}"
4474                 # On NetBSD, the headers are already okay, except for math.h.
4475                 fixincludes=fixinc.wrap
4476                 tmake_file=t-netbsd
4477                 ;;
4478         pdp11-*-bsd)
4479                 tm_file="${tm_file} pdp11/2bsd.h"
4480                 ;;
4481         pdp11-*-*)
4482                 ;;
4483         pyramid-*-*)
4484                 cpu_type=pyr
4485                 xmake_file=pyr/x-pyr
4486                 use_collect2=yes
4487                 ;;
4488         romp-*-aos*)
4489                 use_collect2=yes
4490                 ;;
4491         romp-*-mach*)
4492                 xmake_file=romp/x-mach
4493                 use_collect2=yes
4494                 ;;
4495         powerpc-*-beos*)
4496                 cpu_type=rs6000
4497                 tm_file=rs6000/beos.h
4498                 xm_file=rs6000/xm-beos.h
4499                 tmake_file=rs6000/t-beos
4500                 xmake_file=rs6000/x-beos
4501                 ;;
4502         powerpc-*-sysv* | powerpc-*-elf*)
4503                 tm_file=rs6000/sysv4.h
4504                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
4505                 xm_defines="USG POSIX"
4506                 extra_headers=ppc-asm.h
4507                 if test x$gas = xyes
4508                 then
4509                         tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
4510                 else
4511                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
4512                 fi
4513                 xmake_file=rs6000/x-sysv4
4514                 ;;
4515         powerpc-*-eabiaix*)
4516                 tm_file=rs6000/eabiaix.h
4517                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
4518                 fixincludes=Makefile.in
4519                 extra_headers=ppc-asm.h
4520                 ;;
4521         powerpc-*-eabisim*)
4522                 tm_file=rs6000/eabisim.h
4523                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
4524                 fixincludes=Makefile.in
4525                 extra_headers=ppc-asm.h
4526                 ;;
4527         powerpc-*-eabi*)
4528                 tm_file=rs6000/eabi.h
4529                 if test x$gas = xyes
4530                 then
4531                         tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
4532                 else
4533                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
4534                 fi
4535                 fixincludes=Makefile.in
4536                 extra_headers=ppc-asm.h
4537                 ;;
4538         powerpc-*-rtems*)
4539                 tm_file=rs6000/rtems.h
4540                 if test x$gas = xyes
4541                 then
4542                      tmake_file="rs6000/t-ppcgas t-rtems rs6000/t-ppccomm"
4543                 else
4544                      tmake_file="rs6000/t-ppc t-rtems rs6000/t-ppccomm"
4545                 fi
4546                 fixincludes=Makefile.in
4547                 extra_headers=ppc-asm.h
4548                 ;;
4549         powerpc-*-linux-gnulibc1)
4550                 tm_file=rs6000/linux.h
4551                 xm_file=rs6000/xm-sysv4.h
4552                 out_file=rs6000/rs6000.c
4553                 if test x$gas = xyes
4554                 then
4555                         tmake_file="rs6000/t-ppcos t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
4556                 else
4557                         tmake_file="rs6000/t-ppc t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
4558                 fi
4559                 xmake_file=x-linux
4560                 fixincludes=Makefile.in
4561                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
4562                 extra_headers=ppc-asm.h
4563                 if test x$enable_threads = xyes; then
4564                         thread_file='posix'
4565                 fi
4566                 ;;
4567         powerpc-*-linux-gnu*)
4568                 tm_file=rs6000/linux.h
4569                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
4570                 xm_defines="USG ${xm_defines}"
4571                 out_file=rs6000/rs6000.c
4572                 if test x$gas = xyes
4573                 then
4574                         tmake_file="rs6000/t-ppcos t-linux rs6000/t-ppccomm"
4575                 else
4576                         tmake_file="rs6000/t-ppc t-linux rs6000/t-ppccomm"
4577                 fi
4578                 xmake_file=x-linux
4579                 fixincludes=Makefile.in
4580                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
4581                 extra_headers=ppc-asm.h
4582                 if test x$enable_threads = xyes; then
4583                         thread_file='posix'
4584                 fi
4585                 ;;
4586         powerpc-wrs-vxworks*)
4587                 cpu_type=rs6000
4588                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
4589                 xm_defines="USG POSIX"
4590                 tm_file=rs6000/vxppc.h
4591                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
4592                 extra_headers=ppc-asm.h
4593                 thread_file='vxworks'
4594                 ;;
4595         powerpcle-*-sysv* | powerpcle-*-elf*)
4596                 tm_file=rs6000/sysv4le.h
4597                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
4598                 xm_defines="USG POSIX"
4599                 if test x$gas = xyes
4600                 then
4601                         tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
4602                 else
4603                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
4604                 fi
4605                 xmake_file=rs6000/x-sysv4
4606                 extra_headers=ppc-asm.h
4607                 ;;
4608         powerpcle-*-eabisim*)
4609                 tm_file=rs6000/eabilesim.h
4610                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
4611                 fixincludes=Makefile.in
4612                 extra_headers=ppc-asm.h
4613                 ;;
4614         powerpcle-*-eabi*)
4615                 tm_file=rs6000/eabile.h
4616                 if test x$gas = xyes
4617                 then
4618                         tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
4619                 else
4620                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
4621                 fi
4622                 fixincludes=Makefile.in
4623                 extra_headers=ppc-asm.h
4624                 ;;
4625         powerpcle-*-winnt* )
4626                 tm_file=rs6000/win-nt.h
4627                 tmake_file=rs6000/t-winnt
4628 #               extra_objs=pe.o
4629                 fixincludes=Makefile.in
4630                 if test x$enable_threads = xyes; then
4631                         thread_file='win32'
4632                 fi
4633                 extra_headers=ppc-asm.h
4634                 ;;
4635         powerpcle-*-pe | powerpcle-*-cygwin32)
4636                 tm_file=rs6000/cygwin32.h
4637                 xm_file="rs6000/xm-cygwin32.h ${xm_file}"
4638                 tmake_file=rs6000/t-winnt
4639                 xmake_file=rs6000/x-cygwin32
4640 #               extra_objs=pe.o
4641                 fixincludes=Makefile.in
4642                 if test x$enable_threads = xyes; then
4643                         thread_file='win32'
4644                 fi
4645                 exeext=.exe
4646                 extra_headers=ppc-asm.h
4647                 ;;
4648         powerpcle-*-solaris2*)
4649                 tm_file=rs6000/sol2.h
4650                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
4651                 xm_defines="USG POSIX"
4652                 if test x$gas = xyes
4653                 then
4654                         tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
4655                 else
4656                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
4657                 fi
4658                 xmake_file=rs6000/x-sysv4
4659                 case $machine in
4660                 *-*-solaris2.[0-4])
4661                         fixincludes=fixinc.svr4;;
4662                 *)
4663                         fixincludes=fixinc.wrap;;
4664                 esac
4665                 extra_headers=ppc-asm.h
4666                 ;;
4667         rs6000-ibm-aix3.[01]*)
4668                 tm_file=rs6000/aix31.h
4669                 xmake_file=rs6000/x-aix31
4670                 use_collect2=yes
4671                 ;;
4672         rs6000-ibm-aix3.2.[456789]* | powerpc-ibm-aix3.2.[456789]*)
4673                 tm_file=rs6000/aix3newas.h
4674                 if test x$host != x$target
4675                 then
4676                         tmake_file=rs6000/t-xnewas
4677                 else
4678                         tmake_file=rs6000/t-newas
4679                 fi
4680                 use_collect2=yes
4681                 ;;
4682         rs6000-ibm-aix4.[12]* | powerpc-ibm-aix4.[12]*)
4683                 tm_file=rs6000/aix41.h
4684                 if test x$host != x$target
4685                 then
4686                         tmake_file=rs6000/t-xnewas
4687                 else
4688                         tmake_file=rs6000/t-newas
4689                 fi
4690                 xmake_file=rs6000/x-aix41
4691                 use_collect2=yes
4692                 ;;
4693         rs6000-ibm-aix4.[3456789].* | powerpc-ibm-aix4.[3456789].*)
4694                 tm_file=rs6000/aix43.h
4695                 if test x$host != x$target
4696                 then
4697                         tmake_file=rs6000/t-xaix43
4698                 else
4699                         tmake_file=rs6000/t-aix43
4700                 fi
4701                 xmake_file=rs6000/x-aix43
4702                 use_collect2=yes
4703                 ;;
4704         rs6000-ibm-aix[56789].* | powerpc-ibm-aix[56789].*)
4705                 tm_file=rs6000/aix43.h
4706                 if test x$host != x$target
4707                 then
4708                         tmake_file=rs6000/t-xaix43
4709                 else
4710                         tmake_file=rs6000/t-aix43
4711                 fi
4712                 xmake_file=rs6000/x-aix43
4713                 use_collect2=yes
4714                 ;;
4715         rs6000-ibm-aix*)
4716                 use_collect2=yes
4717                 ;;
4718         rs6000-bull-bosx)
4719                 use_collect2=yes
4720                 ;;
4721         rs6000-*-mach*)
4722                 tm_file=rs6000/mach.h
4723                 xm_file="${xm_file} rs6000/xm-mach.h"
4724                 xmake_file=rs6000/x-mach
4725                 use_collect2=yes
4726                 ;;
4727         rs6000-*-lynxos*)
4728                 tm_file=rs6000/lynx.h
4729                 xm_file=rs6000/xm-lynx.h
4730                 tmake_file=rs6000/t-rs6000
4731                 xmake_file=rs6000/x-lynx
4732                 use_collect2=yes
4733                 ;;
4734         sh-*-elf*)
4735                 tm_file=sh/elf.h
4736                 float_format=sh
4737                 ;;
4738         sh-*-rtemself*)
4739                 tmake_file="sh/t-sh t-rtems"
4740                 tm_file=sh/rtemself.h
4741                 float_format=sh
4742                 ;;
4743         sh-*-rtems*)
4744                 tmake_file="sh/t-sh t-rtems"
4745                 tm_file=sh/rtems.h
4746                 float_format=sh
4747                 ;;
4748         sh-*-*)
4749                 float_format=sh
4750                 ;;
4751         sparc-tti-*)
4752                 tm_file=sparc/pbd.h
4753                 xm_file="xm-alloca.h ${xm_file}"
4754                 xm_defines=USG
4755                 ;;
4756         sparc-wrs-vxworks* | sparclite-wrs-vxworks*)
4757                 tm_file=sparc/vxsparc.h
4758                 tmake_file=sparc/t-vxsparc
4759                 use_collect2=yes
4760                 thread_file='vxworks'
4761                 ;;
4762         sparc-*-aout*)
4763                 tmake_file=sparc/t-sparcbare
4764                 tm_file="sparc/aout.h libgloss.h"
4765                 ;;
4766         sparc-*-netbsd*)
4767                 tm_file=sparc/netbsd.h
4768                 # On NetBSD, the headers are already okay, except for math.h.
4769                 fixincludes=fixinc.wrap
4770                 tmake_file=t-netbsd
4771                 ;;
4772         sparc-*-bsd*)
4773                 tm_file=sparc/bsd.h
4774                 ;;
4775         sparc-*-elf*)
4776                 tm_file=sparc/elf.h
4777                 tmake_file=sparc/t-elf
4778                 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
4779                 #float_format=i128
4780                 float_format=i64
4781                 ;;
4782         sparc-*-linux-gnuaout*)         # Sparc's running GNU/Linux, a.out
4783                 xm_file="${xm_file} sparc/xm-linux.h"
4784                 tm_file=sparc/linux-aout.h
4785                 xmake_file=x-linux
4786                 fixincludes=Makefile.in #On Linux, the headers are ok already.
4787                 gnu_ld=yes
4788                 ;;
4789         sparc-*-linux-gnulibc1*)        # Sparc's running GNU/Linux, libc5
4790                 xm_file="${xm_file} sparc/xm-linux.h"
4791                 xmake_file=x-linux
4792                 tm_file=sparc/linux.h
4793                 tmake_file="t-linux t-linux-gnulibc1"
4794                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
4795                 fixincludes=Makefile.in #On Linux, the headers are ok already.
4796                 gnu_ld=yes
4797                 ;;
4798         sparc-*-linux-gnu*)             # Sparc's running GNU/Linux, libc6
4799                 xm_file="${xm_file} sparc/xm-linux.h"
4800                 xmake_file=x-linux
4801                 tm_file=sparc/linux.h
4802                 tmake_file="t-linux"
4803                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
4804                 fixincludes=Makefile.in #On Linux, the headers are ok already.
4805                 gnu_ld=yes
4806                 if test x$enable_threads = xyes; then
4807                         thread_file='posix'
4808                 fi
4809                 ;;
4810         sparc-*-lynxos*)
4811                 if test x$gas = xyes
4812                 then
4813                         tm_file=sparc/lynx.h
4814                 else
4815                         tm_file=sparc/lynx-ng.h
4816                 fi
4817                 xm_file=sparc/xm-lynx.h
4818                 tmake_file=sparc/t-sunos41
4819                 xmake_file=x-lynx
4820                 ;;
4821         sparc-*-rtems*)
4822                 tmake_file="sparc/t-sparcbare t-rtems"
4823                 tm_file=sparc/rtems.h
4824                 ;;
4825         sparcv9-*-solaris2*)
4826                 tm_file=sparc/sol2-sld-64.h
4827                 xm_file="sparc/xm-sysv4-64.h sparc/xm-sol2.h"
4828                 xm_defines="USG POSIX"
4829                 tmake_file="sparc/t-sol2 sparc/t-sol2-64"
4830                 xmake_file=sparc/x-sysv4
4831                 extra_parts="crt1.o crti.o crtn.o gcrt1.o crtbegin.o crtend.o"
4832                 fixincludes=fixinc.wrap
4833                 float_format=i128
4834                 if test x${enable_threads} = x ; then
4835                     enable_threads=$have_pthread_h
4836                     if test x${enable_threads} = x ; then
4837                         enable_threads=$have_thread_h
4838                     fi
4839                 fi
4840                 if test x${enable_threads} = xyes ; then
4841                     if test x${have_pthread_h} = xyes ; then
4842                         thread_file='posix'
4843                     else
4844                         thread_file='solaris'
4845                     fi
4846                 fi
4847                 ;;
4848         sparc-*-solaris2*)
4849                 if test x$gnu_ld = xyes
4850                 then
4851                         tm_file=sparc/sol2.h
4852                 else
4853                         tm_file=sparc/sol2-sld.h
4854                 fi
4855                 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
4856                 xm_defines="USG POSIX"
4857                 tmake_file=sparc/t-sol2
4858                 xmake_file=sparc/x-sysv4
4859                 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
4860                 case $machine in
4861                 *-*-solaris2.[0-4])
4862                         fixincludes=fixinc.svr4;;
4863                 *)
4864                         fixincludes=fixinc.wrap;;
4865                 esac
4866                 float_format=i128
4867                 if test x${enable_threads} = x; then
4868                     enable_threads=$have_pthread_h
4869                     if test x${enable_threads} = x; then
4870                         enable_threads=$have_thread_h
4871                     fi
4872                 fi
4873                 if test x${enable_threads} = xyes; then
4874                     if test x${have_pthread_h} = xyes; then
4875                         thread_file='posix'
4876                     else
4877                         thread_file='solaris'
4878                     fi
4879                 fi
4880                 ;;
4881         sparc-*-sunos4.0*)
4882                 tm_file=sparc/sunos4.h
4883                 tmake_file=sparc/t-sunos40
4884                 use_collect2=yes
4885                 ;;
4886         sparc-*-sunos4*)
4887                 tm_file=sparc/sunos4.h
4888                 tmake_file=sparc/t-sunos41
4889                 use_collect2=yes
4890                 if test x$gas = xyes; then
4891                         tm_file="${tm_file} sparc/sun4gas.h"
4892                 fi
4893                 ;;
4894         sparc-*-sunos3*)
4895                 tm_file=sparc/sun4o3.h
4896                 use_collect2=yes
4897                 ;;
4898         sparc-*-sysv4*)
4899                 tm_file=sparc/sysv4.h
4900                 xm_file="xm-siglist.h sparc/xm-sysv4.h"
4901                 xm_defines="USG POSIX"
4902                 tmake_file=t-svr4
4903                 xmake_file=sparc/x-sysv4
4904                 extra_parts="crtbegin.o crtend.o"
4905                 ;;
4906         sparc-*-vxsim*)
4907                 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
4908                 xm_defines="USG POSIX"
4909                 tm_file=sparc/vxsim.h
4910                 tmake_file=sparc/t-vxsparc
4911                 xmake_file=sparc/x-sysv4
4912                 ;;
4913         sparclet-*-aout*)
4914                 tm_file="sparc/splet.h libgloss.h"
4915                 tmake_file=sparc/t-splet
4916                 ;;
4917         sparclite-*-coff*)
4918                 tm_file="sparc/litecoff.h libgloss.h"
4919                 tmake_file=sparc/t-sparclite
4920                 ;;
4921         sparclite-*-aout*)
4922                 tm_file="sparc/lite.h aoutos.h libgloss.h"
4923                 tmake_file=sparc/t-sparclite
4924                 ;;
4925         sparc64-*-aout*)
4926                 tmake_file=sparc/t-sp64
4927                 tm_file=sparc/sp64-aout.h
4928                 ;;
4929         sparc64-*-elf*)
4930                 tmake_file=sparc/t-sp64
4931                 tm_file=sparc/sp64-elf.h
4932                 extra_parts="crtbegin.o crtend.o"
4933                 ;;
4934         sparc64-*-linux*)               # 64-bit Sparc's running GNU/Linux
4935                 tmake_file="t-linux sparc/t-linux64"
4936                 xm_file="sparc/xm-sp64.h sparc/xm-linux.h"
4937                 tm_file=sparc/linux64.h
4938                 xmake_file=x-linux
4939                 fixincludes=Makefile.in # The headers are ok already.
4940                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
4941                 gnu_ld=yes
4942                 ;;
4943 # This hasn't been upgraded to GCC 2.
4944 #       tahoe-harris-*)                 # Harris tahoe, using COFF.
4945 #               tm_file=tahoe/harris.h
4946 #               ;;
4947 #       tahoe-*-bsd*)                   # tahoe running BSD
4948 #               ;;
4949         thumb-*-coff* | thumbel-*-coff*)
4950                 tm_file=arm/tcoff.h
4951                 out_file=arm/thumb.c
4952                 xm_file=arm/xm-thumb.h
4953                 md_file=arm/thumb.md
4954                 tmake_file=arm/t-thumb
4955                 fixincludes=Makefile.in # There is nothing to fix
4956                 ;;
4957 # This hasn't been upgraded to GCC 2.
4958 #       tron-*-*)
4959 #               cpu_type=gmicro
4960 #               use_collect2=yes
4961 #               ;;
4962         v850-*-*)
4963                 cpu_type=v850
4964                 tm_file="v850/v850.h"
4965                 xm_file="v850/xm-v850.h"
4966                 tmake_file=v850/t-v850
4967                 if test x$stabs = xyes
4968                 then
4969                         tm_file="${tm_file} dbx.h"
4970                 fi
4971                 use_collect2=no
4972                 ;;
4973         vax-*-bsd*)                     # vaxen running BSD
4974                 use_collect2=yes
4975                 float_format=vax
4976                 ;;
4977         vax-*-sysv*)                    # vaxen running system V
4978                 tm_file="${tm_file} vax/vaxv.h"
4979                 xm_defines=USG
4980                 float_format=vax
4981                 ;;
4982         vax-*-netbsd*)
4983                 tm_file="${tm_file} netbsd.h vax/netbsd.h"
4984                 # On NetBSD, the headers are already okay, except for math.h.
4985                 fixincludes=fixinc.wrap
4986                 tmake_file=t-netbsd
4987                 float_format=vax
4988                 ;;
4989         vax-*-ultrix*)                  # vaxen running ultrix
4990                 tm_file="${tm_file} vax/ultrix.h"
4991                 use_collect2=yes
4992                 float_format=vax
4993                 ;;
4994         vax-*-vms*)                     # vaxen running VMS
4995                 xm_file=vax/xm-vms.h
4996                 tm_file=vax/vms.h
4997                 float_format=vax
4998                 ;;
4999         vax-*-*)                        # vax default entry
5000                 float_format=vax
5001                 ;;
5002         we32k-att-sysv*)
5003                 xm_file="${xm_file} xm-svr3"
5004                 use_collect2=yes
5005                 ;;
5006         *)
5007                 echo "Configuration $machine not supported" 1>&2
5008                 exit 1
5009                 ;;
5010         esac
5011
5012         case $machine in
5013         *-*-linux-gnu*)
5014                 ;; # Existing GNU/Linux systems do not use the GNU setup.
5015         *-*-gnu*)
5016                 # On the GNU system, the setup is just about the same on
5017                 # each different CPU.  The specific machines that GNU
5018                 # supports are matched above and just set $cpu_type.
5019                 xm_file="xm-gnu.h ${xm_file}"
5020                 tm_file=${cpu_type}/gnu.h
5021                 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
5022                 # GNU always uses ELF.
5023                 elf=yes
5024                 # GNU tools are the only tools.
5025                 gnu_ld=yes
5026                 gas=yes
5027                 # On GNU, the headers are already okay.
5028                 fixincludes=Makefile.in
5029                 xmake_file=x-linux      # These details are the same as Linux.
5030                 tmake_file=t-gnu        # These are not.
5031                 ;;
5032         *-*-sysv4*)
5033                 fixincludes=fixinc.svr4
5034                 xmake_try_sysv=x-sysv
5035                 install_headers_dir=install-headers-cpio
5036                 ;;
5037         *-*-sysv*)
5038                 install_headers_dir=install-headers-cpio
5039                 ;;
5040         esac
5041
5042         # Distinguish i[34567]86
5043         # Also, do not run mips-tfile on MIPS if using gas.
5044         # Process --with-cpu= for PowerPC/rs6000
5045         target_cpu_default2=
5046         case $machine in
5047         i486-*-*)
5048                 target_cpu_default2=1
5049                 ;;
5050         i586-*-*)
5051                 target_cpu_default2=2
5052                 ;;
5053         i686-*-* | i786-*-*)
5054                 target_cpu_default2=3
5055                 ;;
5056         alpha*-*-*)
5057                 case $machine in
5058                         alphaev6*)
5059                                 target_cpu_default2="MASK_CPU_EV6|MASK_BXW|MASK_CIX|MASK_MAX"
5060                                 ;;
5061                         alphapca56*)
5062                                 target_cpu_default2="MASK_CPU_EV5|MASK_BWX|MASK_MAX"
5063                                 ;;
5064                         alphaev56*)
5065                                 target_cpu_default2="MASK_CPU_EV5|MASK_BWX"
5066                                 ;;
5067                         alphaev5*)
5068                                 target_cpu_default2="MASK_CPU_EV5"
5069                                 ;;
5070                 esac
5071                                 
5072                 if test x$gas = xyes
5073                 then
5074                         if test "$target_cpu_default2" = ""
5075                         then
5076                                 target_cpu_default2="MASK_GAS"
5077                         else
5078                                 target_cpu_default2="${target_cpu_default2}|MASK_GAS"
5079                         fi
5080                 fi
5081                 ;;
5082         arm*-*-*)
5083                 case "x$with_cpu" in
5084                         x)
5085                                 # The most generic
5086                                 target_cpu_default2="TARGET_CPU_generic"
5087                                 ;;
5088
5089                         # Distinguish cores, and major variants
5090                         # arm7m doesn't exist, but D & I don't affect code
5091                         xarm23678 | xarm250 | xarm67010 \
5092                         | xarm7m | xarm7dm | xarm7dmi | xarm7tdmi \
5093                         | xarm7100 | xarm7500 | xarm7500fe | xarm810 \
5094                         | xstrongarm | xstrongarm110)
5095                                 target_cpu_default2="TARGET_CPU_$with_cpu"
5096                                 ;;
5097
5098                         xyes | xno)
5099                                 echo "--with-cpu must be passed a value" 1>&2
5100                                 exit 1
5101                                 ;;
5102
5103                         *)
5104                                 if test x$pass2done = xyes
5105                                 then
5106                                         echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
5107                                         exit 1
5108                                 fi
5109                                 ;;
5110                 esac
5111                 ;;
5112
5113         mips*-*-ecoff* | mips*-*-elf*)
5114                 if test x$gas = xyes
5115                 then
5116                         if test x$gnu_ld = xyes
5117                         then
5118                                 target_cpu_default2=20
5119                         else
5120                                 target_cpu_default2=16
5121                         fi
5122                 fi
5123                 ;;
5124         mips*-*-*)
5125                 if test x$gas = xyes
5126                 then
5127                         target_cpu_default2=16
5128                 fi
5129                 ;;
5130         powerpc*-*-* | rs6000-*-*)
5131                 case "x$with_cpu" in
5132                         x)
5133                                 ;;
5134
5135                         xcommon | xpower | xpower2 | xpowerpc | xrios \
5136                           | xrios1 | xrios2 | xrsc | xrsc1 \
5137                           | x601 | x602 | x603 | x603e | x604 | x604e | x620 \
5138                           | x403 | x505 | x801 | x821 | x823 | x860)
5139                                 target_cpu_default2="\"$with_cpu\""
5140                                 ;;
5141
5142                         xyes | xno)
5143                                 echo "--with-cpu must be passed a value" 1>&2
5144                                 exit 1
5145                                 ;;
5146
5147                         *)
5148                                 if test x$pass2done = xyes
5149                                 then
5150                                         echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
5151                                         exit 1
5152                                 fi
5153                                 ;;
5154                 esac
5155                 ;;
5156         sparc*-*-*)
5157                 case ".$with_cpu" in
5158                         .)
5159                                 target_cpu_default2=TARGET_CPU_"`echo $machine | sed 's/-.*$//'`"
5160                                 ;;
5161                         .supersparc | .ultrasparc | .v7 | .v8 | .v9)
5162                                 target_cpu_default2="TARGET_CPU_$with_cpu"
5163                                 ;;
5164                         *)
5165                                 if test x$pass2done = xyes
5166                                 then
5167                                         echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
5168                                         exit 1
5169                                 fi
5170                                 ;;
5171                 esac
5172                 ;;
5173         esac
5174
5175         if test "$target_cpu_default2" != ""
5176         then
5177                 if test "$target_cpu_default" != ""
5178                 then
5179                         target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
5180                 else
5181                         target_cpu_default=$target_cpu_default2
5182                 fi
5183         fi
5184
5185         # No need for collect2 if we have the GNU linker.
5186         # Actually, there is now; GNU ld doesn't handle the EH info or
5187         # collecting for shared libraries.
5188         #case x$gnu_ld in
5189         #xyes)
5190         #       use_collect2=
5191         #       ;;
5192         #esac
5193
5194 # Save data on machine being used to compile GCC in build_xm_file.
5195 # Save data on host machine in vars host_xm_file and host_xmake_file.
5196         if test x$pass1done = x
5197         then
5198                 if test x"$xm_file" = x
5199                 then build_xm_file=$cpu_type/xm-$cpu_type.h
5200                 else build_xm_file=$xm_file
5201                 fi
5202                 build_xm_defines=$xm_defines
5203                 build_install_headers_dir=$install_headers_dir
5204                 build_exeext=$exeext
5205                 pass1done=yes
5206         else
5207                 if test x$pass2done = x
5208                 then
5209                         if test x"$xm_file" = x
5210                         then host_xm_file=$cpu_type/xm-$cpu_type.h
5211                         else host_xm_file=$xm_file
5212                         fi
5213                         host_xm_defines=$xm_defines
5214                         if test x"$xmake_file" = x
5215                         then xmake_file=$cpu_type/x-$cpu_type
5216                         fi
5217                         host_xmake_file="$xmake_file"
5218                         host_truncate_target=$truncate_target
5219                         host_extra_gcc_objs=$extra_gcc_objs
5220                         host_extra_objs=$extra_host_objs
5221                         host_exeext=$exeext
5222                         pass2done=yes
5223                 fi
5224         fi
5225 done
5226
5227 extra_objs="${host_extra_objs} ${extra_objs}"
5228
5229 # Default the target-machine variables that were not explicitly set.
5230 if test x"$tm_file" = x
5231 then tm_file=$cpu_type/$cpu_type.h; fi
5232
5233 if test x$extra_headers = x
5234 then extra_headers=; fi
5235
5236 if test x"$xm_file" = x
5237 then xm_file=$cpu_type/xm-$cpu_type.h; fi
5238
5239 if test x$md_file = x
5240 then md_file=$cpu_type/$cpu_type.md; fi
5241
5242 if test x$out_file = x
5243 then out_file=$cpu_type/$cpu_type.c; fi
5244
5245 if test x"$tmake_file" = x
5246 then tmake_file=$cpu_type/t-$cpu_type
5247 fi
5248
5249 if test x$float_format = x
5250 then float_format=i64
5251 fi
5252
5253 if test x$enable_haifa = x
5254 then
5255   case $target in
5256     alpha*-* | hppa1.?-* | powerpc*-* | rs6000-* | *sparc*-* | m32r*-*)
5257       enable_haifa=yes;;
5258   esac
5259 fi
5260
5261 # Say what files are being used for the output code and MD file.
5262 echo "Using \`$srcdir/config/$out_file' to output insns."
5263 echo "Using \`$srcdir/config/$md_file' as machine description file."
5264
5265 count=a
5266 for f in $tm_file; do
5267         count=${count}x
5268 done
5269 if test $count = ax; then
5270         echo "Using \`$srcdir/config/$tm_file' as target machine macro file."
5271 else
5272         echo "Using the following target machine macro files:"
5273         for f in $tm_file; do
5274                 echo "  $srcdir/config/$f"
5275         done
5276 fi
5277
5278 count=a
5279 for f in $host_xm_file; do
5280         count=${count}x
5281 done
5282 if test $count = ax; then
5283         echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file."
5284 else
5285         echo "Using the following host machine macro files:"
5286         for f in $host_xm_file; do
5287                 echo "  $srcdir/config/$f"
5288         done
5289 fi
5290
5291 if test "$host_xm_file" != "$build_xm_file"; then
5292         count=a
5293         for f in $build_xm_file; do
5294                 count=${count}x
5295         done
5296         if test $count = ax; then
5297                 echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file."
5298         else
5299                 echo "Using the following build machine macro files:"
5300                 for f in $build_xm_file; do
5301                         echo "  $srcdir/config/$f"
5302                 done
5303         fi
5304 fi
5305
5306 if test x$thread_file = x; then
5307         if test x$target_thread_file != x; then
5308                 thread_file=$target_thread_file
5309         else
5310                 thread_file='single'
5311         fi
5312 fi
5313
5314 # Set up the header files.
5315 # $links is the list of header files to create.
5316 # $vars is the list of shell variables with file names to include.
5317 # auto-host.h is the file containing items generated by autoconf and is
5318 # the first file included by config.h.
5319 null_defines=
5320 host_xm_file="auto-host.h ${host_xm_file}"
5321
5322 # If host=build, it is correct to have hconfig include auto-host.h
5323 # as well.  If host!=build, we are in error and need to do more 
5324 # work to find out the build config parameters.
5325 if test x$host = x$build
5326 then
5327         build_xm_file="auto-host.h ${build_xm_file}"
5328 else
5329         # We create a subdir, then run autoconf in the subdir.
5330         # To prevent recursion we set host and build for the new
5331         # invocation of configure to the build for this invocation
5332         # of configure. 
5333         tempdir=build.$$
5334         rm -rf $tempdir
5335         mkdir $tempdir
5336         cd $tempdir
5337         case ${srcdir} in
5338         /*) realsrcdir=${srcdir};;
5339         *) realsrcdir=../${srcdir};;
5340         esac
5341         CC=${CC_FOR_BUILD} ${realsrcdir}/configure \
5342                 --target=$target --host=$build --build=$build
5343
5344         # We just finished tests for the build machine, so rename
5345         # the file auto-build.h in the gcc directory.
5346         mv auto-host.h ../auto-build.h
5347         cd ..
5348         rm -rf $tempdir
5349         build_xm_file="auto-build.h ${build_xm_file}"
5350 fi
5351
5352 vars="host_xm_file tm_file xm_file build_xm_file"
5353 links="config.h tm.h tconfig.h hconfig.h"
5354 defines="host_xm_defines null_defines xm_defines build_xm_defines"
5355
5356 rm -f config.bak
5357 if test -f config.status; then mv -f config.status config.bak; fi
5358
5359 # Make the links.
5360 while test -n "$vars"
5361 do
5362         set $vars; var=$1; shift; vars=$*
5363         set $links; link=$1; shift; links=$*
5364         set $defines; define=$1; shift; defines=$*
5365
5366         rm -f $link
5367
5368         # Define TARGET_CPU_DEFAULT if the system wants one.
5369         # This substitutes for lots of *.h files.
5370         if test "$target_cpu_default" != "" -a $link = tm.h
5371         then
5372                 echo "#define TARGET_CPU_DEFAULT ($target_cpu_default)" >>$link
5373         fi
5374
5375         for file in `eval echo '$'$var`; do
5376                 echo "#include \"$file\"" >>$link
5377         done
5378
5379         for def in `eval echo '$'$define`; do
5380                 echo "#ifndef $def" >>$link
5381                 echo "#define $def" >>$link
5382                 echo "#endif" >>$link
5383         done
5384 done
5385
5386 # Truncate the target if necessary
5387 if test x$host_truncate_target != x; then
5388         target=`echo $target | sed -e 's/\(..............\).*/\1/'`
5389 fi
5390
5391 # Get the version trigger filename from the toplevel
5392 if test "${with_gcc_version_trigger+set}" = set; then
5393         gcc_version_trigger=$with_gcc_version_trigger
5394 else
5395         gcc_version_trigger=${srcdir}/version.c
5396 fi
5397 gcc_version=`sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/' < ${gcc_version_trigger}`
5398
5399 # Get an absolute path to the GCC top-level source directory
5400 holddir=`pwd`
5401 cd $srcdir
5402 topdir=`pwd`
5403 cd $holddir
5404
5405 # Conditionalize the makefile for this host machine.
5406 # Make-host contains the concatenation of all host makefile fragments
5407 # [there can be more than one].  This file is built by configure.frag.
5408 host_overrides=Make-host
5409 dep_host_xmake_file=
5410 for f in .. ${host_xmake_file}
5411 do
5412         if test -f ${srcdir}/config/$f
5413         then
5414                 dep_host_xmake_file="${dep_host_xmake_file} ${srcdir}/config/$f"
5415         fi
5416 done
5417
5418 # Conditionalize the makefile for this target machine.
5419 # Make-target contains the concatenation of all host makefile fragments
5420 # [there can be more than one].  This file is built by configure.frag.
5421 target_overrides=Make-target
5422 dep_tmake_file=
5423 for f in .. ${tmake_file}
5424 do
5425         if test -f ${srcdir}/config/$f
5426         then
5427                 dep_tmake_file="${dep_tmake_file} ${srcdir}/config/$f"
5428         fi
5429 done
5430
5431 # If the host doesn't support symlinks, modify CC in
5432 # FLAGS_TO_PASS so CC="stage1/xgcc -Bstage1/" works.
5433 # Otherwise, we can use "CC=$(CC)".
5434 rm -f symtest.tem
5435 if $symbolic_link $srcdir/gcc.c symtest.tem 2>/dev/null
5436 then
5437         cc_set_by_configure="\$(CC)"
5438         stage_prefix_set_by_configure="\$(STAGE_PREFIX)"
5439 else
5440         rm -f symtest.tem
5441         if cp -p $srcdir/gcc.c symtest.tem 2>/dev/null
5442         then
5443                 symbolic_link="cp -p"
5444         else
5445                 symbolic_link="cp"
5446         fi
5447         cc_set_by_configure="\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`"
5448         stage_prefix_set_by_configure="\`case '\$(STAGE_PREFIX)' in stage*) echo '\$(STAGE_PREFIX)' | sed -e 's|stage|../stage|g';; *) echo '\$(STAGE_PREFIX)';; esac\`"
5449 fi
5450 rm -f symtest.tem
5451
5452 out_object_file=`basename $out_file .c`.o
5453
5454 tm_file_list=
5455 for f in $tm_file; do
5456         tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
5457 done
5458
5459 host_xm_file_list=
5460 for f in $host_xm_file; do
5461         if test $f != "auto-host.h"; then
5462                 host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f"
5463         else
5464                 host_xm_file_list="${host_xm_file_list} auto-host.h"
5465         fi
5466 done
5467
5468 build_xm_file_list=
5469 for f in $build_xm_file; do
5470         if test $f != "auto-build.h"; then
5471                 if test $f != "auto-host.h"; then
5472                         build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f"
5473                 else
5474                         build_xm_file_list="${build_xm_file_list} auto-host.h"
5475                 fi
5476         else
5477                 build_xm_file_list="${build_xm_file_list} auto-build.h"
5478         fi
5479 done
5480
5481 # Define macro CROSS_COMPILE in compilation
5482 # if this is a cross-compiler.
5483 # Also use all.cross instead of all.internal
5484 # and add cross-make to Makefile.
5485 cross_overrides="/dev/null"
5486 if test x$host != x$target
5487 then
5488         cross_defines="CROSS=-DCROSS_COMPILE"
5489         cross_overrides="${topdir}/cross-make"
5490 fi
5491
5492 # When building gcc with a cross-compiler, we need to fix a few things.
5493 # This must come after cross-make as we want all.build to override
5494 # all.cross.
5495 build_overrides="/dev/null"
5496 if test x$build != x$host
5497 then
5498         build_overrides="${topdir}/build-make"
5499 fi
5500
5501 # Expand extra_headers to include complete path.
5502 # This substitutes for lots of t-* files.
5503 extra_headers_list=
5504 if test "x$extra_headers" = x
5505 then true
5506 else
5507         # Prepend ${srcdir}/ginclude/ to every entry in extra_headers.
5508         for file in $extra_headers;
5509         do
5510                 extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/${file}"
5511         done
5512 fi
5513
5514 if test x$use_collect2 = xno; then
5515         use_collect2=
5516 fi
5517
5518 # Add a definition of USE_COLLECT2 if system wants one.
5519 # Also tell toplev.c what to do.
5520 # This substitutes for lots of t-* files.
5521 if test x$use_collect2 = x
5522 then
5523         will_use_collect2=
5524         maybe_use_collect2=
5525 else
5526         will_use_collect2="collect2"
5527         maybe_use_collect2="-DUSE_COLLECT2"
5528 fi
5529
5530 # NEED TO CONVERT
5531 # Set MD_DEPS if the real md file is in md.pre-cpp.
5532 # Set MD_CPP to the cpp to pass the md file through.  Md files use ';'
5533 # for line oriented comments, so we must always use a GNU cpp.  If
5534 # building gcc with a cross compiler, use the cross compiler just
5535 # built.  Otherwise, we can use the cpp just built.
5536 md_file_sub=
5537 if test "x$md_cppflags" = x
5538 then
5539         md_file_sub=$srcdir/config/$md_file
5540 else
5541         md_file=md
5542 fi
5543
5544 # If we have gas in the build tree, make a link to it.
5545 if test -f ../gas/Makefile; then
5546         rm -f as; $symbolic_link ../gas/as-new$host_exeext as$host_exeext 2>/dev/null
5547 fi
5548
5549 # If we have nm in the build tree, make a link to it.
5550 if test -f ../binutils/Makefile; then
5551         rm -f nm; $symbolic_link ../binutils/nm-new$host_exeext nm$host_exeext 2>/dev/null
5552 fi
5553
5554 # If we have ld in the build tree, make a link to it.
5555 if test -f ../ld/Makefile; then
5556 #       if test x$use_collect2 = x; then
5557 #               rm -f ld; $symbolic_link ../ld/ld-new$host_exeext ld$host_exeext 2>/dev/null
5558 #       else
5559                 rm -f collect-ld; $symbolic_link ../ld/ld-new$host_exeext collect-ld$host_exeext 2>/dev/null
5560 #       fi
5561 fi
5562
5563 # Figure out what assembler alignment features are present.
5564 echo $ac_n "checking assembler alignment features""... $ac_c" 1>&6
5565 echo "configure:5566: checking assembler alignment features" >&5
5566 gcc_cv_as=
5567 gcc_cv_as_alignment_features=
5568 gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/gas
5569 if test -x "$AS"; then
5570         gcc_cv_as=$AS
5571 elif test -x as$host_exeext; then
5572         # Build using assembler in the current directory.
5573         gcc_cv_as=./as$host_exeext
5574 elif test -f $gcc_cv_as_gas_srcdir/configure.in; then
5575         # Single tree build which includes gas.
5576         for f in $gcc_cv_as_gas_srcdir/configure $gcc_cv_as_gas_srcdir/configure.in $gcc_cv_as_gas_srcdir/Makefile.in
5577         do
5578                 gcc_cv_gas_version=`grep '^VERSION=[0-9]*\.[0-9]*' $f`
5579                 if test x$gcc_cv_gas_version != x; then
5580                         break
5581                 fi
5582         done
5583         gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"`
5584         gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
5585         if test x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x; then
5586                 # Gas version 2.6 and later support for .balign and .p2align.
5587                 # bytes to skip when using .p2align.
5588                 if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 6 -o "$gcc_cv_gas_major_version" -gt 2; then
5589                         gcc_cv_as_alignment_features=".balign and .p2align"
5590                         cat >> confdefs.h <<\EOF
5591 #define HAVE_GAS_BALIGN_AND_P2ALIGN 1
5592 EOF
5593
5594                 fi
5595                 # Gas version 2.8 and later support specifying the maximum
5596                 # bytes to skip when using .p2align.
5597                 if test "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 8 -o "$gcc_cv_gas_major_version" -gt 2; then
5598                         gcc_cv_as_alignment_features=".p2align including maximum skip"
5599                         cat >> confdefs.h <<\EOF
5600 #define HAVE_GAS_MAX_SKIP_P2ALIGN 1
5601 EOF
5602
5603                 fi
5604         fi
5605 elif test x$host = x$target; then
5606         # Native build.
5607         gcc_cv_as=as$host_exeext
5608 fi
5609 if test x$gcc_cv_as != x; then
5610         # Check if we have .balign and .p2align
5611         echo ".balign  4" > conftest.s
5612         echo ".p2align  2" >> conftest.s
5613         if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
5614                 gcc_cv_as_alignment_features=".balign and .p2align"
5615                 cat >> confdefs.h <<\EOF
5616 #define HAVE_GAS_BALIGN_AND_P2ALIGN 1
5617 EOF
5618
5619         fi
5620         rm -f conftest.s conftest.o
5621         # Check if specifying the maximum bytes to skip when
5622         # using .p2align is supported.
5623         echo ".p2align 4,,7" > conftest.s
5624         if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
5625                 gcc_cv_as_alignment_features=".p2align including maximum skip"
5626                 cat >> confdefs.h <<\EOF
5627 #define HAVE_GAS_MAX_SKIP_P2ALIGN 1
5628 EOF
5629
5630         fi
5631         rm -f conftest.s conftest.o
5632 fi
5633 echo "$ac_t""$gcc_cv_as_alignment_features" 1>&6
5634
5635 echo $ac_n "checking assembler subsection support""... $ac_c" 1>&6
5636 echo "configure:5637: checking assembler subsection support" >&5
5637 gcc_cv_as_subsections=
5638 if test x$gcc_cv_as != x; then
5639         # Check if we have .subsection
5640         echo ".subsection 1" > conftest.s
5641         if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
5642                 gcc_cv_as_subsections=".subsection"
5643                 if test -x nm$host_exeext; then
5644                         gcc_cv_nm=./nm$host_exeext
5645                 elif test x$host = x$target; then
5646                         # Native build.
5647                         gcc_cv_nm=nm$host_exeext
5648                 fi
5649                 if test x$gcc_cv_nm != x; then
5650                         cat > conftest.s <<EOF
5651 conftest_label1: .word 0
5652 .subsection -1
5653 conftest_label2: .word 0
5654 .previous
5655 EOF
5656                         if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
5657                                 $gcc_cv_nm conftest.o | grep conftest_label1 > conftest.nm1
5658                                 $gcc_cv_nm conftest.o | grep conftest_label2 | sed -e 's/label2/label1/' > conftest.nm2
5659                                 if cmp conftest.nm1 conftest.nm2 > /dev/null 2>&1; then
5660                                         :
5661                                 else
5662                                         gcc_cv_as_subsections="working .subsection -1"
5663                                         cat >> confdefs.h <<\EOF
5664 #define HAVE_GAS_SUBSECTION_ORDERING 1
5665 EOF
5666
5667                                 fi
5668                         fi
5669                 fi
5670         fi
5671         rm -f conftest.s conftest.o conftest.nm1 conftest.nm2
5672 fi
5673 echo "$ac_t""$gcc_cv_as_subsections" 1>&6
5674
5675 # Figure out what language subdirectories are present.
5676 subdirs=
5677 for lang in ${srcdir}/*/config-lang.in ..
5678 do
5679         case $lang in
5680         ..) ;;
5681         # The odd quoting in the next line works around
5682         # an apparent bug in bash 1.12 on linux.
5683         ${srcdir}/ada/config-lang.in)
5684           if test x$gnat = xyes ; then
5685                 subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`"
5686           fi
5687         ;;
5688         ${srcdir}/[*]/config-lang.in) ;;
5689         *) subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`" ;;
5690         esac
5691 done
5692
5693 # Make gthr-default.h if we have a thread file.
5694 gthread_flags=
5695 if test $thread_file != single; then
5696     rm -f gthr-default.h
5697     echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h
5698     gthread_flags=-DHAVE_GTHR_DEFAULT
5699 fi
5700
5701
5702 # Make empty files to contain the specs and options for each language.
5703 # Then add #include lines to for a compiler that has specs and/or options.
5704
5705 lang_specs_files=
5706 lang_options_files=
5707 lang_tree_files=
5708 rm -f specs.h options.h gencheck.h
5709 touch specs.h options.h gencheck.h
5710 for subdir in . $subdirs
5711 do
5712         if test -f $srcdir/$subdir/lang-specs.h; then
5713                 echo "#include \"$subdir/lang-specs.h\"" >>specs.h
5714                 lang_specs_files="$lang_specs_files $srcdir/$subdir/lang-specs.h"
5715         fi
5716         if test -f $srcdir/$subdir/lang-options.h; then
5717                 echo "#include \"$subdir/lang-options.h\"" >>options.h
5718                 lang_options_files="$lang_options_files $srcdir/$subdir/lang-options.h"
5719         fi
5720         if test -f $srcdir/$subdir/$subdir-tree.def; then
5721                 echo "#include \"$subdir/$subdir-tree.def\"" >>gencheck.h
5722                 lang_tree_files="$lang_tree_files $srcdir/$subdir/$subdir-tree.def"
5723         fi
5724 done
5725
5726 # These (without "all_") are set in each config-lang.in.
5727 # `language' must be a single word so is spelled singularly.
5728 all_languages=
5729 all_boot_languages=
5730 all_compilers=
5731 all_stagestuff=
5732 all_diff_excludes=
5733 all_outputs=Makefile
5734 # List of language makefile fragments.
5735 all_lang_makefiles=
5736 all_headers=
5737 all_lib2funcs=
5738
5739 # Add the language fragments.
5740 # Languages are added via two mechanisms.  Some information must be
5741 # recorded in makefile variables, these are defined in config-lang.in.
5742 # We accumulate them and plug them into the main Makefile.
5743 # The other mechanism is a set of hooks for each of the main targets
5744 # like `clean', `install', etc.
5745
5746 language_fragments="Make-lang"
5747 language_hooks="Make-hooks"
5748 oldstyle_subdirs=
5749
5750 for s in .. $subdirs
5751 do
5752         if test $s != ".."
5753         then
5754                 language=
5755                 boot_language=
5756                 compilers=
5757                 stagestuff=
5758                 diff_excludes=
5759                 headers=
5760                 outputs=
5761                 lib2funcs=
5762                 . ${srcdir}/$s/config-lang.in
5763                 if test "x$language" = x
5764                 then
5765                         echo "${srcdir}/$s/config-lang.in doesn't set \$language." 1>&2
5766                         exit 1
5767                 fi
5768                 all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Make-lang.in ${srcdir}/$s/Makefile.in"
5769                 all_languages="$all_languages $language"
5770                 if test "x$boot_language" = xyes
5771                 then
5772                         all_boot_languages="$all_boot_languages $language"
5773                 fi
5774                 all_compilers="$all_compilers $compilers"
5775                 all_stagestuff="$all_stagestuff $stagestuff"
5776                 all_diff_excludes="$all_diff_excludes $diff_excludes"
5777                 all_headers="$all_headers $headers"
5778                 all_outputs="$all_outputs $outputs"
5779                 if test x$outputs = x
5780                 then
5781                         oldstyle_subdirs="$oldstyle_subdirs $s"
5782                 fi
5783                 all_lib2funcs="$all_lib2funcs $lib2funcs"
5784         fi
5785 done
5786
5787 # Since we can't use `::' targets, we link each language in
5788 # with a set of hooks, reached indirectly via lang.${target}.
5789
5790 rm -f Make-hooks
5791 touch Make-hooks
5792 target_list="all.build all.cross start.encap rest.encap \
5793         info dvi \
5794         install-normal install-common install-info install-man \
5795         uninstall distdir \
5796         mostlyclean clean distclean extraclean maintainer-clean \
5797         stage1 stage2 stage3 stage4"
5798 for t in $target_list
5799 do
5800         x=
5801         for l in .. $all_languages
5802         do
5803                 if test $l != ".."; then
5804                         x="$x $l.$t"
5805                 fi
5806         done
5807         echo "lang.$t: $x" >> Make-hooks
5808 done
5809
5810 # If we're not building in srcdir, create .gdbinit.
5811
5812 if test ! -f Makefile.in; then
5813         echo "dir ." > .gdbinit
5814         echo "dir ${srcdir}" >> .gdbinit
5815         if test x$gdb_needs_out_file_path = xyes
5816         then
5817                 echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
5818         fi
5819         if test "x$subdirs" != x; then
5820                 for s in $subdirs
5821                 do
5822                         echo "dir ${srcdir}/$s" >> .gdbinit
5823                 done
5824         fi
5825         echo "source ${srcdir}/.gdbinit" >> .gdbinit
5826 fi
5827
5828 # Define variables host_canonical and build_canonical
5829 # because some Cygnus local changes in the Makefile depend on them.
5830 build_canonical=${build}
5831 host_canonical=${host}
5832 target_subdir=
5833 if test "${host}" != "${target}" ; then
5834     target_subdir=${target}/
5835 fi
5836
5837
5838
5839         
5840 # If this is using newlib, then define inhibit_libc in
5841 # LIBGCC2_CFLAGS.  This will cause __eprintf to be left out of
5842 # libgcc.a, but that's OK because newib should have its own version of
5843 # assert.h.
5844 inhibit_libc=
5845 if test x$with_newlib = xyes; then
5846         inhibit_libc=-Dinhibit_libc
5847 fi
5848
5849
5850 # Override SCHED_OBJ and SCHED_CFLAGS to enable the Haifa scheduler.
5851 sched_prefix=
5852 sched_cflags=
5853 if test x$enable_haifa = xyes; then
5854     echo "Using the Haifa scheduler."
5855     sched_prefix=haifa-
5856     sched_cflags=-DHAIFA
5857 fi
5858
5859
5860 if test x$enable_haifa != x; then
5861     # Explicitly remove files that need to be recompiled for the Haifa scheduler.
5862     for x in genattrtab.o toplev.o loop.o unroll.o *sched.o; do
5863         if test -f $x; then
5864             echo "Removing $x"
5865             rm -f $x
5866         fi
5867     done
5868 fi
5869
5870 # Warn if using init_priority.
5871 echo $ac_n "checking whether to enable init_priority by default""... $ac_c" 1>&6
5872 echo "configure:5873: checking whether to enable init_priority by default" >&5
5873 if test x$enable_init_priority != xyes; then
5874   enable_init_priority=no
5875 fi
5876 echo "$ac_t""$enable_init_priority" 1>&6
5877
5878 # Nothing to do for FLOAT_H, float_format already handled.
5879 objdir=`pwd`
5880
5881
5882 # Process the language and host/target makefile fragments.
5883 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
5884
5885 # Substitute configuration variables
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900
5901
5902
5903
5904
5905
5906
5907
5908
5909
5910
5911
5912
5913
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943 # Echo that links are built
5944 if test x$host = x$target
5945 then
5946         str1="native "
5947 else
5948         str1="cross-"
5949         str2=" from $host"
5950 fi
5951
5952 if test x$host != x$build
5953 then
5954         str3=" on a $build system"
5955 fi
5956
5957 if test "x$str2" != x || test "x$str3" != x
5958 then
5959         str4=
5960 fi
5961
5962 echo "Links are now set up to build a ${str1}compiler for ${target}$str4" 1>&2
5963
5964 if test "x$str2" != x || test "x$str3" != x
5965 then
5966         echo " ${str2}${str3}." 1>&2
5967 fi
5968
5969 # Truncate the target if necessary
5970 if test x$host_truncate_target != x; then
5971         target=`echo $target | sed -e 's/\(..............\).*/\1/'`
5972 fi
5973
5974 # Configure the subdirectories
5975 # AC_CONFIG_SUBDIRS($subdirs)
5976
5977 # Create the Makefile
5978 # and configure language subdirectories
5979 trap '' 1 2 15
5980 cat > confcache <<\EOF
5981 # This file is a shell script that caches the results of configure
5982 # tests run on this system so they can be shared between configure
5983 # scripts and configure runs.  It is not useful on other systems.
5984 # If it contains results you don't want to keep, you may remove or edit it.
5985 #
5986 # By default, configure uses ./config.cache as the cache file,
5987 # creating it if it does not exist already.  You can give configure
5988 # the --cache-file=FILE option to use a different cache file; that is
5989 # what configure does when it calls configure scripts in
5990 # subdirectories, so they share the cache.
5991 # Giving --cache-file=/dev/null disables caching, for debugging configure.
5992 # config.status only pays attention to the cache file if you give it the
5993 # --recheck option to rerun configure.
5994 #
5995 EOF
5996 # The following way of writing the cache mishandles newlines in values,
5997 # but we know of no workaround that is simple, portable, and efficient.
5998 # So, don't put newlines in cache variables' values.
5999 # Ultrix sh set writes to stderr and can't be redirected directly,
6000 # and sets the high bit in the cache file unless we assign to the vars.
6001 (set) 2>&1 |
6002   case `(ac_space=' '; set) 2>&1 | grep ac_space` in
6003   *ac_space=\ *)
6004     # `set' does not quote correctly, so add quotes (double-quote substitution
6005     # turns \\\\ into \\, and sed turns \\ into \).
6006     sed -n \
6007       -e "s/'/'\\\\''/g" \
6008       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
6009     ;;
6010   *)
6011     # `set' quotes correctly as required by POSIX, so do not add quotes.
6012     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
6013     ;;
6014   esac >> confcache
6015 if cmp -s $cache_file confcache; then
6016   :
6017 else
6018   if test -w $cache_file; then
6019     echo "updating cache $cache_file"
6020     cat confcache > $cache_file
6021   else
6022     echo "not updating unwritable cache $cache_file"
6023   fi
6024 fi
6025 rm -f confcache
6026
6027 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
6028
6029 test "x$prefix" = xNONE && prefix=$ac_default_prefix
6030 # Let make expand exec_prefix.
6031 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
6032
6033 # Any assignment to VPATH causes Sun make to only execute
6034 # the first set of double-colon rules, so remove it if not needed.
6035 # If there is a colon in the path, we need to keep it.
6036 if test "x$srcdir" = x.; then
6037   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
6038 fi
6039
6040 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
6041
6042 DEFS=-DHAVE_CONFIG_H
6043
6044 # Without the "./", some shells look in PATH for config.status.
6045 : ${CONFIG_STATUS=./config.status}
6046
6047 echo creating $CONFIG_STATUS
6048 rm -f $CONFIG_STATUS
6049 cat > $CONFIG_STATUS <<EOF
6050 #! /bin/sh
6051 # Generated automatically by configure.
6052 # Run this file to recreate the current configuration.
6053 # This directory was configured as follows,
6054 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
6055 #
6056 # $0 $ac_configure_args
6057 #
6058 # Compiler output produced by configure, useful for debugging
6059 # configure, is in ./config.log if it exists.
6060
6061 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
6062 for ac_option
6063 do
6064   case "\$ac_option" in
6065   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
6066     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
6067     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
6068   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
6069     echo "$CONFIG_STATUS generated by autoconf version 2.12.1"
6070     exit 0 ;;
6071   -help | --help | --hel | --he | --h)
6072     echo "\$ac_cs_usage"; exit 0 ;;
6073   *) echo "\$ac_cs_usage"; exit 1 ;;
6074   esac
6075 done
6076
6077 ac_given_srcdir=$srcdir
6078
6079 trap 'rm -fr `echo "$all_outputs auto-host.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
6080 EOF
6081 cat >> $CONFIG_STATUS <<EOF
6082
6083 # Protect against being on the right side of a sed subst in config.status.
6084 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
6085  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
6086 $ac_vpsub
6087 $extrasub
6088 s%@SHELL@%$SHELL%g
6089 s%@CFLAGS@%$CFLAGS%g
6090 s%@CPPFLAGS@%$CPPFLAGS%g
6091 s%@CXXFLAGS@%$CXXFLAGS%g
6092 s%@DEFS@%$DEFS%g
6093 s%@LDFLAGS@%$LDFLAGS%g
6094 s%@LIBS@%$LIBS%g
6095 s%@exec_prefix@%$exec_prefix%g
6096 s%@prefix@%$prefix%g
6097 s%@program_transform_name@%$program_transform_name%g
6098 s%@bindir@%$bindir%g
6099 s%@sbindir@%$sbindir%g
6100 s%@libexecdir@%$libexecdir%g
6101 s%@datadir@%$datadir%g
6102 s%@sysconfdir@%$sysconfdir%g
6103 s%@sharedstatedir@%$sharedstatedir%g
6104 s%@localstatedir@%$localstatedir%g
6105 s%@libdir@%$libdir%g
6106 s%@includedir@%$includedir%g
6107 s%@oldincludedir@%$oldincludedir%g
6108 s%@infodir@%$infodir%g
6109 s%@mandir@%$mandir%g
6110 s%@host@%$host%g
6111 s%@host_alias@%$host_alias%g
6112 s%@host_cpu@%$host_cpu%g
6113 s%@host_vendor@%$host_vendor%g
6114 s%@host_os@%$host_os%g
6115 s%@target@%$target%g
6116 s%@target_alias@%$target_alias%g
6117 s%@target_cpu@%$target_cpu%g
6118 s%@target_vendor@%$target_vendor%g
6119 s%@target_os@%$target_os%g
6120 s%@build@%$build%g
6121 s%@build_alias@%$build_alias%g
6122 s%@build_cpu@%$build_cpu%g
6123 s%@build_vendor@%$build_vendor%g
6124 s%@build_os@%$build_os%g
6125 s%@CC@%$CC%g
6126 s%@stage1_warn_cflags@%$stage1_warn_cflags%g
6127 s%@SET_MAKE@%$SET_MAKE%g
6128 s%@AWK@%$AWK%g
6129 s%@LEX@%$LEX%g
6130 s%@LEXLIB@%$LEXLIB%g
6131 s%@LN@%$LN%g
6132 s%@LN_S@%$LN_S%g
6133 s%@RANLIB@%$RANLIB%g
6134 s%@YACC@%$YACC%g
6135 s%@INSTALL@%$INSTALL%g
6136 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
6137 s%@INSTALL_DATA@%$INSTALL_DATA%g
6138 s%@CPP@%$CPP%g
6139 s%@gnat@%$gnat%g
6140 s%@vfprintf@%$vfprintf%g
6141 s%@doprint@%$doprint%g
6142 s%@manext@%$manext%g
6143 s%@objext@%$objext%g
6144 s%@gthread_flags@%$gthread_flags%g
6145 s%@build_canonical@%$build_canonical%g
6146 s%@host_canonical@%$host_canonical%g
6147 s%@target_subdir@%$target_subdir%g
6148 s%@inhibit_libc@%$inhibit_libc%g
6149 s%@sched_prefix@%$sched_prefix%g
6150 s%@sched_cflags@%$sched_cflags%g
6151 s%@objdir@%$objdir%g
6152 s%@subdirs@%$subdirs%g
6153 s%@all_languages@%$all_languages%g
6154 s%@all_boot_languages@%$all_boot_languages%g
6155 s%@all_compilers@%$all_compilers%g
6156 s%@all_lang_makefiles@%$all_lang_makefiles%g
6157 s%@all_stagestuff@%$all_stagestuff%g
6158 s%@all_diff_excludes@%$all_diff_excludes%g
6159 s%@all_lib2funcs@%$all_lib2funcs%g
6160 s%@all_headers@%$all_headers%g
6161 s%@cpp_main@%$cpp_main%g
6162 s%@extra_passes@%$extra_passes%g
6163 s%@extra_programs@%$extra_programs%g
6164 s%@extra_parts@%$extra_parts%g
6165 s%@extra_c_objs@%$extra_c_objs%g
6166 s%@extra_cxx_objs@%$extra_cxx_objs%g
6167 s%@extra_cpp_objs@%$extra_cpp_objs%g
6168 s%@extra_c_flags@%$extra_c_flags%g
6169 s%@extra_objs@%$extra_objs%g
6170 s%@host_extra_gcc_objs@%$host_extra_gcc_objs%g
6171 s%@extra_headers_list@%$extra_headers_list%g
6172 s%@dep_host_xmake_file@%$dep_host_xmake_file%g
6173 s%@dep_tmake_file@%$dep_tmake_file%g
6174 s%@out_file@%$out_file%g
6175 s%@out_object_file@%$out_object_file%g
6176 s%@md_file@%$md_file%g
6177 s%@tm_file_list@%$tm_file_list%g
6178 s%@build_xm_file_list@%$build_xm_file_list%g
6179 s%@host_xm_file_list@%$host_xm_file_list%g
6180 s%@lang_specs_files@%$lang_specs_files%g
6181 s%@lang_options_files@%$lang_options_files%g
6182 s%@lang_tree_files@%$lang_tree_files%g
6183 s%@thread_file@%$thread_file%g
6184 s%@objc_boehm_gc@%$objc_boehm_gc%g
6185 s%@gcc_version@%$gcc_version%g
6186 s%@gcc_version_trigger@%$gcc_version_trigger%g
6187 s%@local_prefix@%$local_prefix%g
6188 s%@gxx_include_dir@%$gxx_include_dir%g
6189 s%@fixincludes@%$fixincludes%g
6190 s%@build_install_headers_dir@%$build_install_headers_dir%g
6191 s%@build_exeext@%$build_exeext%g
6192 s%@host_exeext@%$host_exeext%g
6193 s%@float_format@%$float_format%g
6194 s%@will_use_collect2@%$will_use_collect2%g
6195 s%@maybe_use_collect2@%$maybe_use_collect2%g
6196 s%@cc_set_by_configure@%$cc_set_by_configure%g
6197 s%@stage_prefix_set_by_configure@%$stage_prefix_set_by_configure%g
6198 s%@install@%$install%g
6199 s%@symbolic_link@%$symbolic_link%g
6200 /@target_overrides@/r $target_overrides
6201 s%@target_overrides@%%g
6202 /@host_overrides@/r $host_overrides
6203 s%@host_overrides@%%g
6204 s%@cross_defines@%$cross_defines%g
6205 /@cross_overrides@/r $cross_overrides
6206 s%@cross_overrides@%%g
6207 /@build_overrides@/r $build_overrides
6208 s%@build_overrides@%%g
6209 /@language_fragments@/r $language_fragments
6210 s%@language_fragments@%%g
6211 /@language_hooks@/r $language_hooks
6212 s%@language_hooks@%%g
6213
6214 CEOF
6215 EOF
6216
6217 cat >> $CONFIG_STATUS <<\EOF
6218
6219 # Split the substitutions into bite-sized pieces for seds with
6220 # small command number limits, like on Digital OSF/1 and HP-UX.
6221 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
6222 ac_file=1 # Number of current file.
6223 ac_beg=1 # First line for current file.
6224 ac_end=$ac_max_sed_cmds # Line after last line for current file.
6225 ac_more_lines=:
6226 ac_sed_cmds=""
6227 while $ac_more_lines; do
6228   if test $ac_beg -gt 1; then
6229     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
6230   else
6231     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
6232   fi
6233   if test ! -s conftest.s$ac_file; then
6234     ac_more_lines=false
6235     rm -f conftest.s$ac_file
6236   else
6237     if test -z "$ac_sed_cmds"; then
6238       ac_sed_cmds="sed -f conftest.s$ac_file"
6239     else
6240       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
6241     fi
6242     ac_file=`expr $ac_file + 1`
6243     ac_beg=$ac_end
6244     ac_end=`expr $ac_end + $ac_max_sed_cmds`
6245   fi
6246 done
6247 if test -z "$ac_sed_cmds"; then
6248   ac_sed_cmds=cat
6249 fi
6250 EOF
6251
6252 cat >> $CONFIG_STATUS <<EOF
6253
6254 CONFIG_FILES=\${CONFIG_FILES-"$all_outputs"}
6255 EOF
6256 cat >> $CONFIG_STATUS <<\EOF
6257 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
6258   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6259   case "$ac_file" in
6260   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6261        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6262   *) ac_file_in="${ac_file}.in" ;;
6263   esac
6264
6265   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
6266
6267   # Remove last slash and all that follows it.  Not all systems have dirname.
6268   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6269   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6270     # The file is in a subdirectory.
6271     test ! -d "$ac_dir" && mkdir "$ac_dir"
6272     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
6273     # A "../" for each directory in $ac_dir_suffix.
6274     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
6275   else
6276     ac_dir_suffix= ac_dots=
6277   fi
6278
6279   case "$ac_given_srcdir" in
6280   .)  srcdir=.
6281       if test -z "$ac_dots"; then top_srcdir=.
6282       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
6283   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
6284   *) # Relative path.
6285     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
6286     top_srcdir="$ac_dots$ac_given_srcdir" ;;
6287   esac
6288
6289
6290   echo creating "$ac_file"
6291   rm -f "$ac_file"
6292   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
6293   case "$ac_file" in
6294   *Makefile*) ac_comsub="1i\\
6295 # $configure_input" ;;
6296   *) ac_comsub= ;;
6297   esac
6298
6299   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6300   sed -e "$ac_comsub
6301 s%@configure_input@%$configure_input%g
6302 s%@srcdir@%$srcdir%g
6303 s%@top_srcdir@%$top_srcdir%g
6304 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
6305 fi; done
6306 rm -f conftest.s*
6307
6308 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
6309 # NAME is the cpp macro being defined and VALUE is the value it is being given.
6310 #
6311 # ac_d sets the value in "#define NAME VALUE" lines.
6312 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
6313 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
6314 ac_dC='\3'
6315 ac_dD='%g'
6316 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
6317 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6318 ac_uB='\([      ]\)%\1#\2define\3'
6319 ac_uC=' '
6320 ac_uD='\4%g'
6321 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
6322 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6323 ac_eB='$%\1#\2define\3'
6324 ac_eC=' '
6325 ac_eD='%g'
6326
6327 if test "${CONFIG_HEADERS+set}" != set; then
6328 EOF
6329 cat >> $CONFIG_STATUS <<EOF
6330   CONFIG_HEADERS="auto-host.h:config.in"
6331 EOF
6332 cat >> $CONFIG_STATUS <<\EOF
6333 fi
6334 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
6335   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6336   case "$ac_file" in
6337   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6338        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6339   *) ac_file_in="${ac_file}.in" ;;
6340   esac
6341
6342   echo creating $ac_file
6343
6344   rm -f conftest.frag conftest.in conftest.out
6345   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6346   cat $ac_file_inputs > conftest.in
6347
6348 EOF
6349
6350 # Transform confdefs.h into a sed script conftest.vals that substitutes
6351 # the proper values into config.h.in to produce config.h.  And first:
6352 # Protect against being on the right side of a sed subst in config.status.
6353 # Protect against being in an unquoted here document in config.status.
6354 rm -f conftest.vals
6355 cat > conftest.hdr <<\EOF
6356 s/[\\&%]/\\&/g
6357 s%[\\$`]%\\&%g
6358 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
6359 s%ac_d%ac_u%gp
6360 s%ac_u%ac_e%gp
6361 EOF
6362 sed -n -f conftest.hdr confdefs.h > conftest.vals
6363 rm -f conftest.hdr
6364
6365 # This sed command replaces #undef with comments.  This is necessary, for
6366 # example, in the case of _POSIX_SOURCE, which is predefined and required
6367 # on some systems where configure will not decide to define it.
6368 cat >> conftest.vals <<\EOF
6369 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
6370 EOF
6371
6372 # Break up conftest.vals because some shells have a limit on
6373 # the size of here documents, and old seds have small limits too.
6374
6375 rm -f conftest.tail
6376 while :
6377 do
6378   ac_lines=`grep -c . conftest.vals`
6379   # grep -c gives empty output for an empty file on some AIX systems.
6380   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
6381   # Write a limited-size here document to conftest.frag.
6382   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
6383   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
6384   echo 'CEOF
6385   sed -f conftest.frag conftest.in > conftest.out
6386   rm -f conftest.in
6387   mv conftest.out conftest.in
6388 ' >> $CONFIG_STATUS
6389   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
6390   rm -f conftest.vals
6391   mv conftest.tail conftest.vals
6392 done
6393 rm -f conftest.vals
6394
6395 cat >> $CONFIG_STATUS <<\EOF
6396   rm -f conftest.frag conftest.h
6397   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
6398   cat conftest.in >> conftest.h
6399   rm -f conftest.in
6400   if cmp -s $ac_file conftest.h 2>/dev/null; then
6401     echo "$ac_file is unchanged"
6402     rm -f conftest.h
6403   else
6404     # Remove last slash and all that follows it.  Not all systems have dirname.
6405       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6406       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6407       # The file is in a subdirectory.
6408       test ! -d "$ac_dir" && mkdir "$ac_dir"
6409     fi
6410     rm -f $ac_file
6411     mv conftest.h $ac_file
6412   fi
6413 fi; done
6414
6415 EOF
6416 cat >> $CONFIG_STATUS <<EOF
6417
6418 host='${host}'
6419 build='${build}'
6420 target='${target}'
6421 target_alias='${target_alias}'
6422 srcdir='${srcdir}'
6423 subdirs='${subdirs}'
6424 oldstyle_subdirs='${oldstyle_subdirs}'
6425 symbolic_link='${symbolic_link}'
6426 program_transform_set='${program_transform_set}'
6427 program_transform_name='${program_transform_name}'
6428 dep_host_xmake_file='${dep_host_xmake_file}'
6429 host_xmake_file='${host_xmake_file}'
6430 dep_tmake_file='${dep_tmake_file}'
6431 tmake_file='${tmake_file}'
6432 thread_file='${thread_file}'
6433 gcc_version='${gcc_version}'
6434 gcc_version_trigger='${gcc_version_trigger}'
6435 local_prefix='${local_prefix}'
6436 build_install_headers_dir='${build_install_headers_dir}'
6437 build_exeext='${build_exeext}'
6438 host_exeext='${host_exeext}'
6439 out_file='${out_file}'
6440 gdb_needs_out_file_path='${gdb_needs_out_file_path}'
6441 SET_MAKE='${SET_MAKE}'
6442 target_list='${target_list}'
6443 target_overrides='${target_overrides}'
6444 host_overrides='${host_overrides}'
6445 cross_defines='${cross_defines}'
6446 cross_overrides='${cross_overrides}'
6447 build_overrides='${build_overrides}'
6448
6449 EOF
6450 cat >> $CONFIG_STATUS <<\EOF
6451
6452 . $srcdir/configure.lang
6453 case x$CONFIG_HEADERS in
6454 xauto-host.h:config.in)
6455 echo > cstamp-h ;;
6456 esac
6457 # If the host supports symlinks, point stage[1234] at ../stage[1234] so
6458 # bootstrapping and the installation procedure can still use
6459 # CC="stage1/xgcc -Bstage1/".  If the host doesn't support symlinks,
6460 # FLAGS_TO_PASS has been modified to solve the problem there.
6461 # This is virtually a duplicate of what happens in configure.lang; we do
6462 # an extra check to make sure this only happens if ln -s can be used.
6463 if test "$symbolic_link" = "ln -s"; then
6464  for d in .. ${subdirs} ; do
6465    if test $d != ..; then
6466         STARTDIR=`pwd`
6467         cd $d
6468         for t in stage1 stage2 stage3 stage4 include
6469         do
6470                 rm -f $t
6471                 $symbolic_link ../$t $t 2>/dev/null
6472         done
6473         cd $STARTDIR
6474    fi
6475  done
6476 else true ; fi
6477
6478 exit 0
6479 EOF
6480 chmod +x $CONFIG_STATUS
6481 rm -fr confdefs* $ac_clean_files
6482 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
6483