OSDN Git Service

configure.in: Added i[34567]86-*-win32.
[pf3gnuchains/gcc-fork.git] / gcc / configure.in
1 # configure.in for GNU CC
2 # Process this file with autoconf to generate a configuration script.
3
4 # Copyright (C) 1997, 1998 Free Software Foundation, Inc.
5
6 #This file is part of GNU CC.
7
8 #GNU CC is free software; you can redistribute it and/or modify
9 #it under the terms of the GNU General Public License as published by
10 #the Free Software Foundation; either version 2, or (at your option)
11 #any later version.
12
13 #GNU CC is distributed in the hope that it will be useful,
14 #but WITHOUT ANY WARRANTY; without even the implied warranty of
15 #MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 #GNU General Public License for more details.
17
18 #You should have received a copy of the GNU General Public License
19 #along with GNU CC; see the file COPYING.  If not, write to
20 #the Free Software Foundation, 59 Temple Place - Suite 330,
21 #Boston, MA 02111-1307, USA.
22
23 # Initialization and defaults
24 AC_INIT(tree.c)
25 AC_CONFIG_HEADER(auto-host.h:config.in)
26
27 remove=rm
28 hard_link=ln
29 symbolic_link='ln -s'
30 copy=cp
31
32 # Check for additional parameters
33
34 # With GNU ld
35 AC_ARG_WITH(gnu-ld,
36 [  --with-gnu-ld           arrange to work with GNU ld.],
37 gnu_ld_flag="$with_gnu_ld",
38 gnu_ld_flag=no)
39
40 # With GNU as
41 AC_ARG_WITH(gnu-as,
42 [  --with-gnu-as           arrange to work with GNU as.],
43 gas_flag="$with_gnu_as",
44 gas_flag=no)
45
46 # With stabs
47 AC_ARG_WITH(stabs,
48 [  --with-stabs            arrange to use stabs instead of host debug format.],
49 stabs="$with_stabs",
50 stabs=no)
51
52 # With ELF
53 AC_ARG_WITH(elf,
54 [  --with-elf              arrange to use ELF instead of host debug format.],
55 elf="$with_elf",
56 elf=no)
57
58 # Specify the local prefix
59 AC_ARG_WITH(local-prefix,
60 [  --with-local-prefix=DIR specifies directory to put local include.],
61 local_prefix=$with_local_prefix,
62 local_prefix=/usr/local)
63
64 # Default local prefix if it is empty
65 if [[ x$local_prefix = x ]]; then
66         local_prefix=/usr/local
67 fi
68
69 # Specify the g++ header file directory
70 AC_ARG_WITH(gxx-include-dir,
71 [  --with-gxx-include-dir=DIR
72                           specifies directory to put g++ header files.],
73 gxx_include_dir=$with_gxx_include_dir,
74 if test x${enable_version_specific_runtime_libs} = xyes; then
75 gxx_include_dir='${libsubdir}/include/g++'
76 else gxx_include_dir='${prefix}/include/g++'; fi)
77
78 # Enable expensive internal checks
79 AC_ARG_ENABLE(checking,
80 [  --enable-checking       enable expensive run-time checks.],
81 AC_DEFINE(ENABLE_CHECKING)  
82 )
83
84 # Enable use of cpplib for C.
85 cpp_main=cccp
86 AC_ARG_ENABLE(c-cpplib,
87 [  --enable-c-cpplib       Use cpplib for C and C++.],
88 if [[[ x$enable_c_cpplib != xno ]]]; then
89   extra_c_objs="${extra_c_objs} cpplib.o cppexp.o cpphash.o cpperror.o"
90   extra_c_objs="${extra_c_objs} prefix.o"
91   extra_cxx_objs="${extra_cxx_objs} ../cpplib.o ../cppexp.o ../cpphash.o ../cpperror.o ../prefix.o"
92   extra_c_flags=-DUSE_CPPLIB=1
93   cpp_main=cppmain
94 fi)
95   
96 # Enable Multibyte Characters for C/C++
97 AC_ARG_ENABLE(c-mbchar,
98 [  --enable-c-mbchar       Enable multibyte characters for C and C++.],
99 if [[[ x$enable_c_mbchar != xno ]]]; then
100   extra_c_flags=-DMULTIBYTE_CHARS=1
101 fi)
102   
103 # Enable Haifa scheduler.
104 AC_ARG_ENABLE(haifa,
105 [  --enable-haifa          Use the experimental scheduler.
106   --disable-haifa         Don't use the experimental scheduler for the
107                           targets which normally enable it.])
108 # Fast fixincludes
109 #
110 # This is a work in progress...
111 AC_ARG_WITH(fast-fixincludes,
112 [  --with-fast-fixincludes    Use a faster fixinclude program.  Experimental],
113 fast_fixinc="$with_fast_fixincludes",
114 fast_fixinc=no)
115
116 # Enable threads
117 # Pass with no value to take the default
118 # Pass with a value to specify a thread package
119 AC_ARG_ENABLE(threads,
120 [  --enable-threads        enable thread usage for target GCC.
121   --enable-threads=LIB    use LIB thread package for target GCC.],
122 if [[[ x$enable_threads = xno ]]]; then
123         enable_threads=''
124 fi,
125 enable_threads='')
126
127 enable_threads_flag=$enable_threads
128 # Check if a valid thread package
129 case x${enable_threads_flag} in
130         x | xno)
131                 # No threads
132                 target_thread_file='single'
133                 ;;
134         xyes)
135                 # default
136                 target_thread_file=''
137                 ;;
138         xdecosf1 | xirix | xmach | xos2 | xposix | xpthreads | xsingle | \
139         xsolaris | xwin32 | xdce | xvxworks)
140                 target_thread_file=$enable_threads_flag
141                 ;;
142         *)
143                 echo "$enable_threads is an unknown thread package" 1>&2
144                 exit 1
145                 ;;
146 esac
147
148 # Determine the host, build, and target systems
149 AC_CANONICAL_SYSTEM
150
151 # Find the native compiler
152 AC_PROG_CC
153 AC_PROG_MAKE_SET
154
155 # Find some useful tools
156 AC_PROG_AWK
157 AC_PROG_LEX
158 GCC_PROG_LN
159 GCC_PROG_LN_S
160 GCC_C_VOLATILE
161 AC_PROG_RANLIB
162 AC_PROG_YACC
163 EGCS_PROG_INSTALL
164
165 AC_HEADER_STDC
166 AC_HEADER_TIME
167 AC_CHECK_HEADERS(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)
168
169 # Check for thread headers.
170 AC_CHECK_HEADER(thread.h, [have_thread_h=yes], [have_thread_h=])
171 AC_CHECK_HEADER(pthread.h, [have_pthread_h=yes], [have_pthread_h=])
172
173 # See if the system preprocessor understands the ANSI C preprocessor
174 # stringification operator.
175 AC_MSG_CHECKING(whether cpp understands the stringify operator)
176 AC_CACHE_VAL(gcc_cv_c_have_stringify,
177 [AC_TRY_COMPILE(,
178 [#define S(x)   #x
179 char *test = S(foo);],
180 gcc_cv_c_have_stringify=yes, gcc_cv_c_have_stringify=no)])
181 AC_MSG_RESULT($gcc_cv_c_have_stringify)
182 if test $gcc_cv_c_have_stringify = yes; then
183   AC_DEFINE(HAVE_CPP_STRINGIFY)
184 fi
185
186 # Use <inttypes.h> only if it exists,
187 # doesn't clash with <sys/types.h>, and declares intmax_t.
188 AC_MSG_CHECKING(for inttypes.h)
189 AC_CACHE_VAL(gcc_cv_header_inttypes_h,
190 [AC_TRY_COMPILE(
191   [#include <sys/types.h>
192 #include <inttypes.h>],
193   [intmax_t i = -1;],
194   [AC_DEFINE_UNQUOTED(HAVE_INTTYPES_H)
195    gcc_cv_header_inttypes_h=yes],
196   gcc_cv_header_inttypes_h=no)])
197 AC_MSG_RESULT($gcc_cv_header_inttypes_h)
198
199 AC_CHECK_FUNCS(strtoul bsearch strerror putenv popen bcopy bzero bcmp \
200         index rindex strchr strrchr kill getrlimit setrlimit atoll atoq \
201         sysconf isascii gettimeofday)
202
203 # Make sure wchar_t is available
204 #AC_CHECK_TYPE(wchar_t, unsigned int)
205
206 GCC_FUNC_VFPRINTF_DOPRNT
207 GCC_FUNC_PRINTF_PTR
208
209 GCC_NEED_DECLARATIONS(malloc realloc calloc free bcopy bzero bcmp \
210         index rindex getenv atol sbrk abort atof strerror getcwd getwd)
211
212 GCC_NEED_DECLARATIONS(getrlimit setrlimit, [
213 #include <sys/types.h>
214 #ifdef HAVE_SYS_RESOURCE_H
215 #include <sys/resource.h>
216 #endif
217 ])
218
219 AC_DECL_SYS_SIGLIST
220
221 # File extensions
222 manext='.1'
223 objext='.o'
224 AC_SUBST(manext)
225 AC_SUBST(objext)
226
227 build_xm_file=
228 build_xm_defines=
229 build_install_headers_dir=install-headers-tar
230 build_exeext=
231 host_xm_file=
232 host_xm_defines=
233 host_xmake_file=
234 host_truncate_target=
235 host_exeext=
236
237 # Decode the host machine, then the target machine.
238 # For the host machine, we save the xm_file variable as host_xm_file;
239 # then we decode the target machine and forget everything else
240 # that came from the host machine.
241 for machine in $build $host $target; do
242
243         out_file=
244         xmake_file=
245         tmake_file=
246         extra_headers=
247         extra_passes=
248         extra_parts=
249         extra_programs=
250         extra_objs=
251         extra_host_objs=
252         extra_gcc_objs=
253         xm_defines=
254         float_format=
255         # Set this to force installation and use of collect2.
256         use_collect2=
257         # Set this to override the default target model.
258         target_cpu_default=
259         # Set this to control which fixincludes program to use.
260         if [[ x$fast_fixinc != xyes ]] ; then
261                 fixincludes=fixincludes
262         else fixincludes=fixinc.sh ; fi
263         # Set this to control how the header file directory is installed.
264         install_headers_dir=install-headers-tar
265         # Set this to a non-empty list of args to pass to cpp if the target
266         # wants its .md file passed through cpp.
267         md_cppflags=
268         # Set this if directory names should be truncated to 14 characters.
269         truncate_target=
270         # Set this if gdb needs a dir command with `dirname $out_file`
271         gdb_needs_out_file_path=
272         # Set this if the build machine requires executables to have a
273         # file name suffix.
274         exeext=
275         # Set this to control which thread package will be used.
276         thread_file=
277         # Reinitialize these from the flag values every loop pass, since some
278         # configure entries modify them.
279         gas="$gas_flag"
280         gnu_ld="$gnu_ld_flag"
281         enable_threads=$enable_threads_flag
282
283         # Set default cpu_type, tm_file and xm_file so it can be updated in
284         # each machine entry.
285         cpu_type=`echo $machine | sed 's/-.*$//'`
286         case $machine in
287         alpha*-*-*)
288                 cpu_type=alpha
289                 ;;
290         arm*-*-*)
291                 cpu_type=arm
292                 ;;
293         c*-convex-*)
294                 cpu_type=convex
295                 ;;
296         i[[34567]]86-*-*)
297                 cpu_type=i386
298                 ;;
299         hppa*-*-*)
300                 cpu_type=pa
301                 ;;
302         m68000-*-*)
303                 cpu_type=m68k
304                 ;;
305         mips*-*-*)
306                 cpu_type=mips
307                 ;;
308         powerpc*-*-*)
309                 cpu_type=rs6000
310                 ;;
311         pyramid-*-*)
312                 cpu_type=pyr
313                 ;;
314         sparc*-*-*)
315                 cpu_type=sparc
316                 ;;
317         esac
318
319         tm_file=${cpu_type}/${cpu_type}.h
320         xm_file=${cpu_type}/xm-${cpu_type}.h
321         
322         # Set the default macros to define for GNU/Linux systems.
323         case $machine in
324         *-*-linux-gnu*)
325                 xm_defines="HAVE_ATEXIT POSIX BSTRING"
326                 ;;
327         esac
328
329         case $machine in
330         # Support site-specific machine types.
331         *local*)
332                 cpu_type=`echo $machine | sed -e 's/-.*//'`
333                 rest=`echo $machine | sed -e "s/$cpu_type-//"`
334                 xm_file=${cpu_type}/xm-$rest.h
335                 tm_file=${cpu_type}/$rest.h
336                 if [[ -f $srcdir/config/${cpu_type}/x-$rest ]] ; \
337                 then xmake_file=${cpu_type}/x-$rest; \
338                 else true; \
339                 fi
340                 if [[ -f $srcdir/config/${cpu_type}/t-$rest ]] ; \
341                 then tmake_file=${cpu_type}/t-$rest; \
342                 else true; \
343                 fi
344                 ;;
345         1750a-*-*)
346                 ;;
347         a29k-*-bsd* | a29k-*-sym1*)
348                 tm_file="${tm_file} a29k/unix.h"
349                 xm_defines=USG
350                 xmake_file=a29k/x-unix
351                 use_collect2=yes
352                 ;;
353         a29k-*-udi | a29k-*-coff)
354                 tm_file="${tm_file} dbxcoff.h a29k/udi.h"
355                 tmake_file=a29k/t-a29kbare
356                 ;;
357         a29k-wrs-vxworks*)
358                 tm_file="${tm_file} dbxcoff.h a29k/udi.h a29k/vx29k.h"
359                 tmake_file=a29k/t-vx29k
360                 extra_parts="crtbegin.o crtend.o"
361                 thread_file='vxworks'
362                 ;;
363         a29k-*-*)                       # Default a29k environment.
364                 use_collect2=yes
365                 ;;
366         alpha*-*-linux-gnuecoff*)
367                 tm_file="${tm_file} alpha/linux-ecoff.h alpha/linux.h"
368                 target_cpu_default="MASK_GAS"
369                 gas=no
370                 xmake_file=none
371                 gas=yes gnu_ld=yes
372                 ;;
373         alpha*-*-linux-gnulibc1*)
374                 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
375                 target_cpu_default="MASK_GAS"
376                 tmake_file="t-linux t-linux-gnulibc1 alpha/t-linux alpha/t-crtbe"
377                 extra_parts="crtbegin.o crtend.o"
378                 fixincludes=fixinc.wrap
379                 xmake_file=none
380                 gas=yes gnu_ld=yes
381                 if [[ x$enable_threads = xyes ]]; then
382                         thread_file='posix'
383                 fi
384                 ;;
385         alpha*-*-linux-gnu*)
386                 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
387                 target_cpu_default="MASK_GAS"
388                 tmake_file="t-linux alpha/t-linux alpha/t-crtbe"
389                 extra_parts="crtbegin.o crtend.o"
390                 xmake_file=none
391                 fixincludes=Makefile.in
392                 gas=yes gnu_ld=yes
393                 if [[ x$enable_threads = xyes ]]; then
394                         thread_file='posix'
395                 fi
396                 ;;
397         alpha*-*-netbsd*)
398                 tm_file="${tm_file} alpha/elf.h alpha/netbsd.h alpha/netbsdl-elf.h"
399                 target_cpu_default="MASK_GAS"
400                 tmake_file="alpha/t-crtbe"
401                 extra_parts="crtbegin.o crtend.o"
402                 xmake_file=none
403                 fixincludes=fixinc.wrap
404                 gas=yes gnu_ld=yes
405                 ;;
406                 
407         alpha*-dec-osf*)
408                 if [[ x$stabs = xyes ]]
409                 then
410                         tm_file="${tm_file} dbx.h"
411                 fi
412                 if [[ x$gas != xyes ]]
413                 then
414                         extra_passes="mips-tfile mips-tdump"
415                 fi
416                 use_collect2=yes
417                 case $machine in
418                   *-*-osf1*)
419                     tm_file="${tm_file} alpha/osf.h alpha/osf12.h alpha/osf2or3.h"
420                     ;;
421                   *-*-osf[[23]]*)
422                     tm_file="${tm_file} alpha/osf.h alpha/osf2or3.h"
423                     ;;
424                   *-*-osf4*)
425                     tm_file="${tm_file} alpha/osf.h"
426                     # Some versions of OSF4 (specifically X4.0-9 296.7) have
427                     # a broken tar, so we use cpio instead.
428                     install_headers_dir=install-headers-cpio
429                     ;;
430                 esac
431                 case $machine in
432                   *-*-osf4.0[[b-z]] | *-*-osf4.[[1-9]]*)
433                     target_cpu_default=MASK_SUPPORT_ARCH
434                     ;;
435                 esac
436                 ;;
437         alpha*-*-vxworks*)
438                 tm_file="${tm_file} dbx.h alpha/vxworks.h"
439                 if [ x$gas != xyes ]
440                 then
441                         extra_passes="mips-tfile mips-tdump"
442                 fi
443                 use_collect2=yes
444                 ;;
445         alpha*-*-winnt*)
446                 tm_file="${tm_file} alpha/win-nt.h"
447                 xm_file="${xm_file} config/winnt/xm-winnt.h alpha/xm-winnt.h"
448                 tmake_file=t-libc-ok
449                 xmake_file=winnt/x-winnt
450                 extra_host_objs=oldnames.o
451                 extra_gcc_objs="spawnv.o oldnames.o"
452                 fixincludes=fixinc.winnt
453                 if [[ x$gnu_ld != xyes ]]
454                 then
455                         extra_programs=ld.exe
456                 fi
457                 if [[ x$enable_threads = xyes ]]; then
458                         thread_file='win32'
459                 fi
460                 ;;
461         alpha*-dec-vms*)
462                 tm_file=alpha/vms.h
463                 xm_file="${xm_file} alpha/xm-vms.h"
464                 tmake_file=alpha/t-vms
465                 fixincludes=Makefile.in
466                 ;;
467         arc-*-elf*)
468                 extra_parts="crtinit.o crtfini.o"
469                 ;;
470         arm-*-coff* | armel-*-coff*)
471                 tm_file=arm/coff.h
472                 tmake_file=arm/t-bare
473                 ;;
474         arm-*-riscix1.[[01]]*)          # Acorn RISC machine (early versions)
475                 tm_file=arm/riscix1-1.h
476                 use_collect2=yes
477                 ;;
478         arm-*-riscix*)                  # Acorn RISC machine
479                 if [[ x$gas = xyes ]]
480                 then
481                     tm_file=arm/rix-gas.h
482                 else
483                     tm_file=arm/riscix.h
484                 fi
485                 xmake_file=arm/x-riscix
486                 tmake_file=arm/t-riscix
487                 use_collect2=yes
488                 ;;
489         arm-semi-aout | armel-semi-aout)
490                 tm_file=arm/semi.h
491                 tmake_file=arm/t-semi
492                 fixincludes=Makefile.in # There is nothing to fix
493                 ;;
494         arm-semi-aof | armel-semi-aof)
495                 tm_file=arm/semiaof.h
496                 tmake_file=arm/t-semiaof
497                 fixincludes=Makefile.in # There is nothing to fix
498                 ;;
499         arm-*-netbsd*)
500                 tm_file=arm/netbsd.h
501                 xm_file="xm-siglist.h ${xm_file}"
502                 tmake_file="t-netbsd arm/t-netbsd"
503                 # On NetBSD, the headers are already okay, except for math.h.
504                 fixincludes=fixinc.wrap
505                 ;;
506         arm-*-linux-gnuaout*)           # ARM GNU/Linux
507                 cpu_type=arm
508                 xmake_file=x-linux
509                 tm_file=arm/linux-gas.h
510                 tmake_file=arm/t-linux
511                 fixincludes=Makefile.in
512                 gnu_ld=yes
513                 ;;
514         arm-*-aout)
515                 tm_file=arm/aout.h
516                 tmake_file=arm/t-bare
517                 ;;
518         c1-convex-*)                    # Convex C1
519                 target_cpu_default=1
520                 use_collect2=yes
521                 fixincludes=Makefile.in
522                 ;;
523         c2-convex-*)                    # Convex C2
524                 target_cpu_default=2
525                 use_collect2=yes
526                 fixincludes=Makefile.in
527                 ;;
528         c32-convex-*)
529                 target_cpu_default=4
530                 use_collect2=yes
531                 fixincludes=Makefile.in
532                 ;;
533         c34-convex-*)
534                 target_cpu_default=8
535                 use_collect2=yes
536                 fixincludes=Makefile.in
537                 ;;
538         c38-convex-*)
539                 target_cpu_default=16           
540                 use_collect2=yes
541                 fixincludes=Makefile.in
542                 ;;
543         clipper-intergraph-clix*)
544                 tm_file="${tm_file} svr3.h clipper/clix.h"
545                 xm_file=clipper/xm-clix.h
546                 xmake_file=clipper/x-clix
547                 extra_headers=va-clipper.h
548                 extra_parts="crtbegin.o crtend.o"
549                 install_headers_dir=install-headers-cpio
550                 ;;
551         dsp16xx-*)
552                 ;;
553         elxsi-elxsi-*)
554                 use_collect2=yes
555                 ;;
556 # This hasn't been upgraded to GCC 2.
557 #       fx80-alliant-*)                 # Alliant FX/80
558 #               ;;
559         h8300-*-*)
560                 float_format=i32
561                 ;;
562         hppa1.1-*-pro*)
563                 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h"
564                 xm_file=pa/xm-papro.h
565                 tmake_file=pa/t-pro
566                 ;;
567         hppa1.1-*-osf*)
568                 target_cpu_default=1
569                 tm_file="${tm_file} pa/pa-osf.h"
570                 use_collect2=yes
571                 fixincludes=Makefile.in
572                 ;;
573         hppa1.1-*-rtems*)
574                 tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h pa/rtems.h"
575                 xm_file=pa/xm-papro.h
576                 tmake_file=pa/t-pro
577                 ;;
578         hppa1.0-*-osf*)
579                 tm_file="${tm_file} pa/pa-osf.h"
580                 use_collect2=yes
581                 fixincludes=Makefile.in
582                 ;;
583         hppa1.1-*-bsd*)
584                 target_cpu_default=1
585                 use_collect2=yes
586                 fixincludes=Makefile.in
587                 ;;
588         hppa1.0-*-bsd*)
589                 use_collect2=yes
590                 fixincludes=Makefile.in
591                 ;;
592         hppa1.0-*-hpux7*)
593                 tm_file="pa/pa-oldas.h ${tm_file} pa/pa-hpux7.h"
594                 xm_file=pa/xm-pahpux.h
595                 xmake_file=pa/x-pa-hpux
596                 if [[ x$gas = xyes ]]
597                 then
598                         tm_file="${tm_file} pa/gas.h"
599                 fi
600                 install_headers_dir=install-headers-cpio
601                 use_collect2=yes
602                 ;;
603         hppa1.0-*-hpux8.0[[0-2]]*)
604                 tm_file="${tm_file} pa/pa-hpux.h"
605                 xm_file=pa/xm-pahpux.h
606                 xmake_file=pa/x-pa-hpux
607                 if [[ x$gas = xyes ]]
608                 then
609                         tm_file="${tm_file} pa/pa-gas.h"
610                 else
611                         tm_file="pa/pa-oldas.h ${tm_file}"
612                 fi
613                 install_headers_dir=install-headers-cpio
614                 use_collect2=yes
615                 ;;
616         hppa1.1-*-hpux8.0[[0-2]]*)
617                 target_cpu_default=1
618                 tm_file="${tm_file} pa/pa-hpux.h"
619                 xm_file=pa/xm-pahpux.h
620                 xmake_file=pa/x-pa-hpux
621                 if [[ x$gas = xyes ]]
622                 then
623                         tm_file="${tm_file} pa/pa-gas.h"
624                 else
625                         tm_file="pa/pa-oldas.h ${tm_file}"
626                 fi
627                 install_headers_dir=install-headers-cpio
628                 use_collect2=yes
629                 ;;
630         hppa1.1-*-hpux8*)
631                 target_cpu_default=1
632                 tm_file="${tm_file} pa/pa-hpux.h"
633                 xm_file=pa/xm-pahpux.h
634                 xmake_file=pa/x-pa-hpux
635                 if [[ x$gas = xyes ]]
636                 then
637                         tm_file="${tm_file} pa/pa-gas.h"
638                 fi
639                 install_headers_dir=install-headers-cpio
640                 use_collect2=yes
641                 ;;
642         hppa1.0-*-hpux8*)
643                 tm_file="${tm_file} pa/pa-hpux.h"
644                 xm_file=pa/xm-pahpux.h
645                 xmake_file=pa/x-pa-hpux
646                 if [[ x$gas = xyes ]]
647                 then
648                         tm_file="${tm_file} pa/pa-gas.h"
649                 fi
650                 install_headers_dir=install-headers-cpio
651                 use_collect2=yes
652                 ;;
653         hppa1.1-*-hpux10*)
654                 target_cpu_default=1
655                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
656                 xm_file=pa/xm-pahpux.h
657                 xmake_file=pa/x-pa-hpux
658                 tmake_file=pa/t-pa
659                 if [[ x$gas = xyes ]]
660                 then
661                         tm_file="${tm_file} pa/pa-gas.h"
662                 fi
663                 if [[ x$enable_threads = x ]]; then
664                     enable_threads=$have_pthread_h
665                 fi
666                 if [[ x$enable_threads = xyes ]]; then
667                         thread_file='dce'
668                         tmake_file="${tmake_file} pa/t-dce-thr"
669                 fi
670                 install_headers_dir=install-headers-cpio
671                 use_collect2=yes
672                 ;;
673         hppa1.0-*-hpux10*)
674                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux10.h"
675                 xm_file=pa/xm-pahpux.h
676                 xmake_file=pa/x-pa-hpux
677                 if [[ x$gas = xyes ]]
678                 then
679                         tm_file="${tm_file} pa/pa-gas.h"
680                 fi
681                 if [[ x$enable_threads = x ]]; then
682                     enable_threads=$have_pthread_h
683                 fi
684                 if [[ x$enable_threads = xyes ]]; then
685                         thread_file='dce'
686                         tmake_file="${tmake_file} pa/t-dce-thr"
687                 fi
688                 install_headers_dir=install-headers-cpio
689                 use_collect2=yes
690                 ;;
691         hppa1.1-*-hpux*)
692                 target_cpu_default=1
693                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
694                 xm_file=pa/xm-pahpux.h
695                 xmake_file=pa/x-pa-hpux
696                 if [[ x$gas = xyes ]]
697                 then
698                         tm_file="${tm_file} pa/pa-gas.h"
699                 fi
700                 install_headers_dir=install-headers-cpio
701                 use_collect2=yes
702                 ;;
703         hppa1.0-*-hpux*)
704                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hpux9.h"
705                 xm_file=pa/xm-pahpux.h
706                 xmake_file=pa/x-pa-hpux
707                 if [[ x$gas = xyes ]]
708                 then
709                         tm_file="${tm_file} pa/pa-gas.h"
710                 fi
711                 install_headers_dir=install-headers-cpio
712                 use_collect2=yes
713                 ;;
714         hppa1.1-*-hiux*)
715                 target_cpu_default=1
716                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
717                 xm_file=pa/xm-pahpux.h
718                 xmake_file=pa/x-pa-hpux
719                 if [[ x$gas = xyes ]]
720                 then
721                         tm_file="${tm_file} pa/pa-gas.h"
722                 fi
723                 install_headers_dir=install-headers-cpio
724                 use_collect2=yes
725                 ;;
726         hppa1.0-*-hiux*)
727                 tm_file="${tm_file} pa/pa-hpux.h pa/pa-hiux.h"
728                 xm_file=pa/xm-pahpux.h
729                 xmake_file=pa/x-pa-hpux
730                 if [[ x$gas = xyes ]]
731                 then
732                         tm_file="${tm_file} pa/pa-gas.h"
733                 fi
734                 install_headers_dir=install-headers-cpio
735                 use_collect2=yes
736                 ;;
737         hppa*-*-lites*)
738                 target_cpu_default=1
739                 use_collect2=yes
740                 fixincludes=Makefile.in
741                 ;;
742         i370-*-mvs*)
743                 ;;
744         i[[34567]]86-ibm-aix*)          # IBM PS/2 running AIX
745                 if [[ x$gas = xyes ]]
746                 then
747                         tm_file=i386/aix386.h
748                         extra_parts="crtbegin.o crtend.o"
749                         tmake_file=i386/t-crtstuff
750                 else
751                         tm_file=i386/aix386ng.h
752                         use_collect2=yes
753                 fi
754                 xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}"
755                 xm_defines=USG
756                 xmake_file=i386/x-aix
757                 ;;
758         i[[34567]]86-ncr-sysv4*)        # NCR 3000 - ix86 running system V.4
759                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
760                 xm_defines="USG POSIX SMALL_ARG_MAX"
761                 xmake_file=i386/x-ncr3000
762                 if [[ x$stabs = xyes -a x$gas = xyes ]]
763                 then
764                         tm_file=i386/sysv4gdb.h
765                 else
766                         tm_file=i386/sysv4.h
767                 fi
768                 extra_parts="crtbegin.o crtend.o"
769                 tmake_file=i386/t-crtpic
770                 ;;
771         i[[34567]]86-next-*)
772                 tm_file=i386/next.h
773                 xm_file=i386/xm-next.h
774                 tmake_file=i386/t-next
775                 xmake_file=i386/x-next
776                 extra_objs=nextstep.o
777                 if [[ x$enable_threads = xyes ]]; then
778                         thread_file='mach'
779                 fi
780                 ;;
781         i[[34567]]86-sequent-bsd*)              # 80386 from Sequent
782                 use_collect2=yes
783                 if [[ x$gas = xyes ]]
784                 then
785                         tm_file=i386/seq-gas.h
786                 else
787                         tm_file=i386/sequent.h
788                 fi
789                 ;;
790         i[[34567]]86-sequent-ptx1*)
791                 xm_defines="USG SVR3"
792                 xmake_file=i386/x-sysv3
793                 tm_file=i386/seq-sysv3.h
794                 tmake_file=i386/t-crtstuff
795                 fixincludes=fixinc.ptx
796                 extra_parts="crtbegin.o crtend.o"
797                 install_headers_dir=install-headers-cpio
798                 ;;
799         i[[34567]]86-sequent-ptx2* | i[[34567]]86-sequent-sysv3*)
800                 xm_defines="USG SVR3"
801                 xmake_file=i386/x-sysv3
802                 tm_file=i386/seq2-sysv3.h
803                 tmake_file=i386/t-crtstuff
804                 extra_parts="crtbegin.o crtend.o"
805                 fixincludes=fixinc.ptx
806                 install_headers_dir=install-headers-cpio
807                 ;;
808         i[[34567]]86-sequent-ptx4* | i[[34567]]86-sequent-sysv4*)
809                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
810                 xm_defines="USG POSIX SMALL_ARG_MAX"
811                 xmake_file=x-svr4
812                 tm_file=i386/ptx4-i.h
813                 tmake_file=t-svr4
814                 extra_parts="crtbegin.o crtend.o"
815                 fixincludes=fixinc.ptx
816                 install_headers_dir=install-headers-cpio
817                 ;;
818         i386-sun-sunos*)                # Sun i386 roadrunner
819                 xm_defines=USG
820                 tm_file=i386/sun.h
821                 use_collect2=yes
822                 ;;
823         i[[34567]]86-wrs-vxworks*)
824                 tm_file=i386/vxi386.h
825                 tmake_file=i386/t-i386bare
826                 ;;
827         i[[34567]]86-*-aout*)
828                 tm_file=i386/i386-aout.h
829                 tmake_file=i386/t-i386bare
830                 ;;
831         i[[34567]]86-*-bsdi* | i[[34567]]86-*-bsd386*)
832                 tm_file=i386/bsd386.h
833 #               tmake_file=t-libc-ok
834                 ;;
835         i[[34567]]86-*-bsd*)
836                 tm_file=i386/386bsd.h
837 #               tmake_file=t-libc-ok
838 # Next line turned off because both 386BSD and BSD/386 use GNU ld.
839 #               use_collect2=yes
840                 ;;
841         i[[34567]]86-*-freebsdelf*)
842                 tm_file="i386/i386.h i386/att.h linux.h i386/freebsd-elf.h i386/perform.h"
843                 # On FreeBSD, the headers are already ok, except for math.h.
844                 fixincludes=fixinc.wrap
845                 tmake_file=i386/t-freebsd
846                 gas=yes
847                 gnu_ld=yes
848                 stabs=yes
849                 ;;
850         i[[34567]]86-*-freebsd*)
851                 tm_file=i386/freebsd.h
852                 # On FreeBSD, the headers are already ok, except for math.h.
853                 fixincludes=fixinc.wrap
854                 tmake_file=i386/t-freebsd
855                 ;;
856         i[[34567]]86-*-netbsd*)
857                 tm_file=i386/netbsd.h
858                 # On NetBSD, the headers are already okay, except for math.h.
859                 fixincludes=fixinc.wrap
860                 tmake_file=t-netbsd
861                 ;;
862         i[[34567]]86-*-coff*)
863                 tm_file=i386/i386-coff.h
864                 tmake_file=i386/t-i386bare
865                 ;;
866         i[[34567]]86-*-isc*)            # 80386 running ISC system
867                 xm_file="${xm_file} i386/xm-isc.h"
868                 xm_defines="USG SVR3"
869                 case $machine in
870                   i[[34567]]86-*-isc[[34]]*)
871                     xmake_file=i386/x-isc3
872                     ;;
873                   *)
874                     xmake_file=i386/x-isc
875                     ;;
876                 esac
877                 if [[ x$gas = xyes -a x$stabs = xyes ]]
878                 then
879                         tm_file=i386/iscdbx.h
880                         tmake_file=i386/t-svr3dbx
881                         extra_parts="svr3.ifile svr3z.ifile"
882                 else
883                         tm_file=i386/isccoff.h
884                         tmake_file=i386/t-crtstuff
885                         extra_parts="crtbegin.o crtend.o"
886                 fi
887                 install_headers_dir=install-headers-cpio
888                 ;;
889         i[[34567]]86-*-linux-gnuoldld*) # Intel 80386's running GNU/Linux
890                                         # with a.out format using
891                                         # pre BFD linkers
892                 xmake_file=x-linux-aout
893                 tmake_file="t-linux-aout i386/t-crtstuff"
894                 tm_file=i386/linux-oldld.h
895                 fixincludes=Makefile.in #On Linux, the headers are ok already.
896                 gnu_ld=yes
897                 float_format=i386
898                 ;;
899         i[[34567]]86-*-linux-gnuaout*)  # Intel 80386's running GNU/Linux
900                                         # with a.out format
901                 xmake_file=x-linux-aout
902                 tmake_file="t-linux-aout i386/t-crtstuff"
903                 tm_file=i386/linux-aout.h
904                 fixincludes=Makefile.in #On Linux, the headers are ok already.
905                 gnu_ld=yes
906                 float_format=i386
907                 ;;
908         i[[34567]]86-*-linux-gnulibc1)  # Intel 80386's running GNU/Linux
909                                         # with ELF format using the
910                                         # GNU/Linux C library 5
911                 xmake_file=x-linux      
912                 tm_file=i386/linux.h    
913                 tmake_file="t-linux t-linux-gnulibc1 i386/t-crtstuff"
914                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
915                 fixincludes=Makefile.in #On Linux, the headers are ok already.
916                 gnu_ld=yes
917                 float_format=i386
918                 if [[ x$enable_threads = xyes ]]; then
919                         thread_file='single'
920                 fi
921                 ;;
922         i[[34567]]86-*-linux-gnu*)      # Intel 80386's running GNU/Linux
923                                         # with ELF format using glibc 2
924                                         # aka GNU/Linux C library 6
925                 xmake_file=x-linux
926                 tm_file=i386/linux.h
927                 tmake_file="t-linux i386/t-crtstuff"
928                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
929                 fixincludes=Makefile.in #On Linux, the headers are ok already.
930                 gnu_ld=yes
931                 float_format=i386
932                 if [[ x$enable_threads = xyes ]]; then
933                         thread_file='posix'
934                 fi
935                 ;;
936         i[[34567]]86-*-gnu*)
937                 ;;
938         i[[34567]]86-go32-msdos | i[[34567]]86-*-go32*)
939                 xm_file=i386/xm-go32.h
940                 tm_file=i386/go32.h
941                 tmake_file=i386/t-go32
942                 ;;
943         i[[34567]]86-pc-msdosdjgpp*)
944                 xm_file=i386/xm-go32.h
945                 tm_file=i386/go32.h
946                 tmake_file=i386/t-go32
947                 gnu_ld=yes
948                 gas=yes
949                 ;;
950         i[[34567]]86-moss-msdos* | i[[34567]]86-*-moss*)
951                 tm_file=i386/moss.h
952                 tmake_file=t-libc-ok
953                 fixincludes=Makefile.in
954                 gnu_ld=yes
955                 gas=yes
956                 ;;
957         i[[34567]]86-*-lynxos*)
958                 if [[ x$gas = xyes ]]
959                 then
960                         tm_file=i386/lynx.h
961                 else
962                         tm_file=i386/lynx-ng.h
963                 fi
964                 xm_file=i386/xm-lynx.h
965                 tmake_file=i386/t-i386bare
966                 xmake_file=x-lynx
967                 ;;
968         i[[34567]]86-*-mach*)
969                 tm_file=i386/mach.h
970 #               tmake_file=t-libc-ok
971                 use_collect2=yes
972                 ;;
973         i[[34567]]86-*-osfrose*)                # 386 using OSF/rose
974                 if [[ x$elf = xyes ]]
975                 then
976                         tm_file=i386/osfelf.h
977                         use_collect2=
978                 else
979                         tm_file=i386/osfrose.h
980                         use_collect2=yes
981                 fi
982                 xm_file="i386/xm-osf.h ${xm_file}"
983                 xmake_file=i386/x-osfrose
984                 tmake_file=i386/t-osf
985                 extra_objs=halfpic.o
986                 ;;
987         i[[34567]]86-go32-rtems*)
988                 cpu_type=i386
989                 xm_file=i386/xm-go32.h
990                 tm_file=i386/go32-rtems.h
991                 tmake_file="i386/t-go32 t-rtems"
992                 ;;
993         i[[34567]]86-*-rtemself*)
994                 cpu_type=i386
995                 tm_file=i386/rtemself.h
996                 tmake_file="i386/t-i386bare t-rtems"
997                 ;;
998         i[[34567]]86-*-rtems*)
999                 cpu_type=i386
1000                 tm_file=i386/rtems.h
1001                 tmake_file="i386/t-i386bare t-rtems"
1002                 ;;
1003         i[[34567]]86-*-sco3.2v5*)       # 80386 running SCO Open Server 5
1004                 xm_file="xm-siglist.h xm-alloca.h ${xm_file} i386/xm-sco5.h"
1005                 xm_defines="USG SVR3"
1006                 xmake_file=i386/x-sco5
1007                 fixincludes=fixinc.sco
1008                 install_headers_dir=install-headers-cpio
1009                 tm_file=i386/sco5.h
1010                 if [[ x$gas = xyes ]]
1011                 then
1012                         tm_file="i386/sco5gas.h ${tm_file}"
1013                         tmake_file=i386/t-sco5gas
1014                 else
1015                         tmake_file=i386/t-sco5
1016                 fi
1017                 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
1018                 ;;
1019         i[[34567]]86-*-sco3.2v4*)       # 80386 running SCO 3.2v4 system
1020                 xm_file="${xm_file} i386/xm-sco.h"
1021                 xm_defines="USG SVR3 BROKEN_LDEXP SMALL_ARG_MAX NO_SYS_SIGLIST"
1022                 xmake_file=i386/x-sco4
1023                 fixincludes=fixinc.sco
1024                 install_headers_dir=install-headers-cpio
1025                 if [[ x$stabs = xyes ]]
1026                 then
1027                         tm_file=i386/sco4dbx.h
1028                         tmake_file=i386/t-svr3dbx
1029                         extra_parts="svr3.ifile svr3z.rfile"
1030                 else
1031                         tm_file=i386/sco4.h
1032                         tmake_file=i386/t-crtstuff
1033                         extra_parts="crtbegin.o crtend.o"
1034                 fi
1035                 truncate_target=yes
1036                 ;;
1037         i[[34567]]86-*-sco*)            # 80386 running SCO system
1038                 xm_file=i386/xm-sco.h
1039                 xmake_file=i386/x-sco
1040                 install_headers_dir=install-headers-cpio
1041                 if [[ x$stabs = xyes ]]
1042                 then
1043                         tm_file=i386/scodbx.h
1044                         tmake_file=i386/t-svr3dbx
1045                         extra_parts="svr3.ifile svr3z.rfile"
1046                 else
1047                         tm_file=i386/sco.h
1048                         extra_parts="crtbegin.o crtend.o"
1049                         tmake_file=i386/t-crtstuff
1050                 fi
1051                 truncate_target=yes
1052                 ;;
1053         i[[34567]]86-*-solaris2*)
1054                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
1055                 xm_defines="USG POSIX SMALL_ARG_MAX"
1056                 if [[ x$stabs = xyes ]]
1057                 then
1058                         tm_file=i386/sol2dbg.h
1059                 else
1060                         tm_file=i386/sol2.h
1061                 fi
1062                 tmake_file=i386/t-sol2
1063                 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
1064                 xmake_file=x-svr4
1065                 case $machine in
1066                 *-*-solaris2.[[0-4]])
1067                         fixincludes=fixinc.svr4;;
1068                 *)
1069                         fixincludes=fixinc.wrap;;
1070                 esac
1071                 if [[ x$enable_threads = xyes ]]; then
1072                         thread_file='solaris'
1073                 fi
1074                 ;;
1075        i[[34567]]86-*-sysv5*)           # Intel x86 on System V Release 5
1076                xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
1077                xm_defines="USG POSIX"
1078                tm_file=i386/sysv4.h
1079                if [[ x$stabs = xyes ]]
1080                then
1081                        tm_file="${tm_file} dbx.h"
1082                fi
1083                tmake_file=i386/t-crtpic
1084                xmake_file=x-svr4
1085                extra_parts="crtbegin.o crtend.o"
1086                fixincludes=Makefile.in # The headers are just fine, thank you.
1087                ;;
1088         i[[34567]]86-*-sysv4*)          # Intel 80386's running system V.4
1089                 xm_file="xm-siglist.h xm-alloca.h ${xm_file}"
1090                 xm_defines="USG POSIX SMALL_ARG_MAX"
1091                 tm_file=i386/sysv4.h
1092                 if [[ x$stabs = xyes ]]
1093                 then
1094                         tm_file="${tm_file} dbx.h"
1095                 fi
1096                 tmake_file=i386/t-crtpic
1097                 xmake_file=x-svr4
1098                 extra_parts="crtbegin.o crtend.o"
1099                 ;;
1100         i[[34567]]86-*-osf1*)           # Intel 80386's running OSF/1 1.3+
1101                 cpu_type=i386
1102                 xm_file="${xm_file} xm-svr4.h i386/xm-sysv4.h i386/xm-osf1elf.h"
1103                 xm_defines="USE_C_ALLOCA SMALL_ARG_MAX"
1104                 fixincludes=Makefile.in #Don't do it on OSF/1
1105                 if [[ x$stabs = xyes ]]
1106                 then
1107                         tm_file=i386/osf1elfgdb.h
1108                 else
1109                         tm_file=i386/osf1elf.h
1110                 fi
1111                 tmake_file=i386/t-osf1elf
1112                 xmake_file=i386/x-osf1elf
1113                 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
1114                 ;;
1115         i[[34567]]86-*-sysv*)           # Intel 80386's running system V
1116                 xm_defines="USG SVR3"
1117                 xmake_file=i386/x-sysv3
1118                 if [[ x$gas = xyes ]]
1119                 then
1120                         if [[ x$stabs = xyes ]]
1121                         then
1122                                 tm_file=i386/svr3dbx.h
1123                                 tmake_file=i386/t-svr3dbx
1124                                 extra_parts="svr3.ifile svr3z.rfile"
1125                         else
1126                                 tm_file=i386/svr3gas.h
1127                                 extra_parts="crtbegin.o crtend.o"
1128                                 tmake_file=i386/t-crtstuff
1129                         fi
1130                 else
1131                         tm_file=i386/sysv3.h
1132                         extra_parts="crtbegin.o crtend.o"
1133                         tmake_file=i386/t-crtstuff
1134                 fi
1135                 ;;
1136         i386-*-vsta)                    # Intel 80386's running VSTa kernel
1137                 xm_file="${xm_file} i386/xm-vsta.h"
1138                 tm_file=i386/vsta.h
1139                 tmake_file=i386/t-vsta
1140                 xmake_file=i386/x-vsta
1141                 ;;
1142         i[[34567]]86-*-win32)
1143                 xm_file="${xm_file} i386/xm-cygwin32.h"
1144                 tmake_file=i386/t-cygwin32
1145                 tm_file=i386/win32.h
1146                 xmake_file=i386/x-cygwin32
1147                 extra_objs=winnt.o
1148                 fixincludes=Makefile.in
1149                 if [[ x$enable_threads = xyes ]]; then
1150                         thread_file='win32'
1151                 fi
1152                 exeext=.exe
1153                 ;;
1154         i[[34567]]86-*-pe | i[[34567]]86-*-cygwin32)
1155                 xm_file="${xm_file} i386/xm-cygwin32.h"
1156                 tmake_file=i386/t-cygwin32
1157                 tm_file=i386/cygwin32.h
1158                 xmake_file=i386/x-cygwin32
1159                 extra_objs=winnt.o
1160                 fixincludes=Makefile.in
1161                 if [[ x$enable_threads = xyes ]]; then
1162                         thread_file='win32'
1163                 fi
1164                 exeext=.exe
1165                 ;;
1166         i[[34567]]86-*-mingw32*)
1167                 tm_file=i386/mingw32.h
1168                 xm_file="${xm_file} i386/xm-mingw32.h"
1169                 tmake_file="i386/t-cygwin32 i386/t-mingw32"
1170                 extra_objs=winnt.o
1171                 xmake_file=i386/x-cygwin32
1172                 fixincludes=Makefile.in
1173                 if [[ x$enable_threads = xyes ]]; then
1174                         thread_file='win32'
1175                 fi
1176                 exeext=.exe
1177                 case $machine in
1178                         *mingw32msv*)
1179                                 ;;
1180                         *minwg32crt* | *mingw32*)
1181                                 tm_file="${tm_file} i386/crtdll.h"
1182                                 ;;
1183                 esac
1184                 ;;
1185         i[[34567]]86-*-winnt3*)
1186                 tm_file=i386/win-nt.h
1187                 out_file=i386/i386.c
1188                 xm_file="xm-winnt.h ${xm_file}"
1189                 xmake_file=winnt/x-winnt
1190                 tmake_file=i386/t-winnt
1191                 extra_host_objs="winnt.o oldnames.o"
1192                 extra_gcc_objs="spawnv.o oldnames.o"
1193                 fixincludes=fixinc.winnt
1194                 if [[ x$gnu_ld != xyes ]]
1195                 then
1196                         extra_programs=ld.exe
1197                 fi
1198                 if [[ x$enable_threads = xyes ]]; then
1199                         thread_file='win32'
1200                 fi
1201                 ;;
1202         i[[34567]]86-dg-dgux*)
1203                 xm_file="xm-alloca.h xm-siglist.h ${xm_file}"
1204                 xm_defines="USG POSIX"
1205                 out_file=i386/dgux.c
1206                 tm_file=i386/dgux.h
1207                 tmake_file=i386/t-dgux
1208                 xmake_file=i386/x-dgux
1209                 fixincludes=fixinc.dgux
1210                 install_headers_dir=install-headers-cpio
1211               ;;
1212         i860-alliant-*)         # Alliant FX/2800
1213                 tm_file="${tm_file} svr4.h i860/sysv4.h i860/fx2800.h"
1214                 xm_file="${xm_file}"
1215                 xmake_file=i860/x-fx2800
1216                 tmake_file=i860/t-fx2800
1217                 extra_parts="crtbegin.o crtend.o"
1218                 ;;
1219         i860-*-bsd*)
1220                 tm_file="${tm_file} i860/bsd.h"
1221                 if [[ x$gas = xyes ]]
1222                 then
1223                         tm_file="${tm_file} i860/bsd-gas.h"
1224                 fi
1225                 use_collect2=yes
1226                 ;;
1227         i860-*-mach*)
1228                 tm_file="${tm_file} i860/mach.h"
1229                 tmake_file=t-libc-ok
1230                 ;;
1231         i860-*-osf*)                    # Intel Paragon XP/S, OSF/1AD
1232                 tm_file="${tm_file} svr3.h i860/paragon.h"
1233                 xm_defines="USG SVR3"
1234                 tmake_file=t-osf
1235                 ;;
1236         i860-*-sysv3*)
1237                 tm_file="${tm_file} svr3.h i860/sysv3.h"
1238                 xm_defines="USG SVR3"
1239                 xmake_file=i860/x-sysv3
1240                 extra_parts="crtbegin.o crtend.o"
1241                 ;;
1242         i860-*-sysv4*)
1243                 tm_file="${tm_file} svr4.h i860/sysv4.h"
1244                 xm_defines="USG SVR3"
1245                 xmake_file=i860/x-sysv4
1246                 tmake_file=t-svr4
1247                 extra_parts="crtbegin.o crtend.o"
1248                 ;;
1249         i960-wrs-vxworks5 | i960-wrs-vxworks5.0*)
1250                 tm_file="${tm_file} i960/vx960.h"
1251                 tmake_file=i960/t-vxworks960
1252                 use_collect2=yes
1253                 thread_file='vxworks'
1254                 ;;
1255         i960-wrs-vxworks5* | i960-wrs-vxworks)
1256                 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h i960/vx960-coff.h"
1257                 tmake_file=i960/t-vxworks960
1258                 use_collect2=yes
1259                 thread_file='vxworks'
1260                 ;;
1261         i960-wrs-vxworks*)
1262                 tm_file="${tm_file} i960/vx960.h"
1263                 tmake_file=i960/t-vxworks960
1264                 use_collect2=yes
1265                 thread_file='vxworks'
1266                 ;;
1267         i960-*-coff*)
1268                 tm_file="${tm_file} dbxcoff.h i960/i960-coff.h libgloss.h"
1269                 tmake_file=i960/t-960bare
1270                 use_collect2=yes
1271                 ;;
1272         i960-*-rtems)
1273                 tmake_file="i960/t-960bare t-rtems"
1274                 tm_file="${tm_file} dbxcoff.h i960/rtems.h"
1275                 use_collect2=yes
1276                 ;;
1277         i960-*-*)                       # Default i960 environment.
1278                 use_collect2=yes
1279                 ;;
1280         m32r-*-elf*)
1281                 extra_parts="crtinit.o crtfini.o"
1282                 ;;
1283         m68000-convergent-sysv*)
1284                 tm_file=m68k/ctix.h
1285                 xm_file="m68k/xm-3b1.h ${xm_file}"
1286                 xm_defines=USG
1287                 use_collect2=yes
1288                 extra_headers=math-68881.h
1289                 ;;
1290         m68000-hp-bsd*)                 # HP 9000/200 running BSD
1291                 tm_file=m68k/hp2bsd.h
1292                 xmake_file=m68k/x-hp2bsd
1293                 use_collect2=yes
1294                 extra_headers=math-68881.h
1295                 ;;
1296         m68000-hp-hpux*)                # HP 9000 series 300
1297                 xm_file="xm_alloca.h ${xm_file}"
1298                 xm_defines="USG NO_SYS_SIGLIST"
1299                 if [[ x$gas = xyes ]]
1300                 then
1301                         xmake_file=m68k/x-hp320g
1302                         tm_file=m68k/hp310g.h
1303                 else
1304                         xmake_file=m68k/x-hp320
1305                         tm_file=m68k/hp310.h
1306                 fi
1307                 install_headers_dir=install-headers-cpio
1308                 use_collect2=yes
1309                 extra_headers=math-68881.h
1310                 ;;
1311         m68000-sun-sunos3*)
1312                 tm_file=m68k/sun2.h
1313                 use_collect2=yes
1314                 extra_headers=math-68881.h
1315                 ;;
1316         m68000-sun-sunos4*)
1317                 tm_file=m68k/sun2o4.h
1318                 use_collect2=yes
1319                 extra_headers=math-68881.h
1320                 ;;
1321         m68000-att-sysv*)
1322                 xm_file="m68k/xm-3b1.h ${xm_file}"
1323                 xm_defines=USG
1324                 if [[ x$gas = xyes ]]
1325                 then
1326                         tm_file=m68k/3b1g.h
1327                 else
1328                         tm_file=m68k/3b1.h
1329                 fi
1330                 use_collect2=yes
1331                 extra_headers=math-68881.h
1332                 ;;
1333         m68k-apple-aux*)                # Apple Macintosh running A/UX
1334                 xm_defines="USG AUX"
1335                 tmake_file=m68k/t-aux
1336                 install_headers_dir=install-headers-cpio
1337                 extra_headers=math-68881.h
1338                 extra_parts="crt1.o mcrt1.o maccrt1.o crt2.o crtn.o"
1339                 tm_file=
1340                 if [[ "$gnu_ld" = yes ]]
1341                 then
1342                         tm_file="${tm_file} m68k/auxgld.h"
1343                 else
1344                         tm_file="${tm_file} m68k/auxld.h"
1345                 fi
1346                 if [[ "$gas" = yes ]]
1347                 then
1348                         tm_file="${tm_file} m68k/auxgas.h"
1349                 else
1350                         tm_file="${tm_file} m68k/auxas.h"
1351                 fi
1352                 tm_file="${tm_file} m68k/a-ux.h"
1353                 float_format=m68k
1354                 ;;
1355         m68k-apollo-*)
1356                 tm_file=m68k/apollo68.h
1357                 xmake_file=m68k/x-apollo68
1358                 use_collect2=yes
1359                 extra_headers=math-68881.h
1360                 float_format=m68k
1361                 ;;
1362         m68k-altos-sysv*)                  # Altos 3068
1363                 if [[ x$gas = xyes ]]
1364                 then
1365                         tm_file=m68k/altos3068.h
1366                         xm_defines=USG
1367                 else
1368                         echo "The Altos is supported only with the GNU assembler" 1>&2
1369                         exit 1
1370                 fi
1371                 extra_headers=math-68881.h
1372                 ;;
1373         m68k-bull-sysv*)                # Bull DPX/2
1374                 if [[ x$gas = xyes ]]
1375                 then
1376                         if [[ x$stabs = xyes ]]
1377                         then
1378                                 tm_file=m68k/dpx2cdbx.h
1379                         else
1380                                 tm_file=m68k/dpx2g.h
1381                         fi
1382                 else
1383                         tm_file=m68k/dpx2.h
1384                 fi
1385                 xm_file="xm-alloca.h ${xm_file}"
1386                 xm_defines=USG
1387                 xmake_file=m68k/x-dpx2
1388                 use_collect2=yes
1389                 extra_headers=math-68881.h
1390                 ;;
1391         m68k-atari-sysv4*)              # Atari variant of V.4.
1392                 tm_file=m68k/atari.h
1393                 xm_file="xm-alloca.h ${xm_file}"
1394                 xm_defines="USG FULL_PROTOTYPES"
1395                 tmake_file=t-svr4
1396                 extra_parts="crtbegin.o crtend.o"
1397                 extra_headers=math-68881.h
1398                 float_format=m68k
1399                 ;;
1400         m68k-motorola-sysv*)
1401                 tm_file=m68k/mot3300.h
1402                 xm_file="xm-alloca.h m68k/xm-mot3300.h ${xm_file}"
1403                 xm_defines=NO_SYS_SIGLIST
1404                 if [[ x$gas = xyes ]]
1405                 then
1406                         xmake_file=m68k/x-mot3300-gas
1407                         if [[ x$gnu_ld = xyes ]]
1408                         then
1409                                 tmake_file=m68k/t-mot3300-gald
1410                         else
1411                                 tmake_file=m68k/t-mot3300-gas
1412                                 use_collect2=yes
1413                         fi
1414                 else
1415                         xmake_file=m68k/x-mot3300
1416                         if [[ x$gnu_ld = xyes ]]
1417                         then
1418                                 tmake_file=m68k/t-mot3300-gld
1419                         else
1420                                 tmake_file=m68k/t-mot3300
1421                                 use_collect2=yes
1422                         fi
1423                 fi
1424                 gdb_needs_out_file_path=yes
1425                 extra_parts="crt0.o mcrt0.o"
1426                 extra_headers=math-68881.h
1427                 float_format=m68k
1428                 ;;
1429         m68k-ncr-sysv*)                 # NCR Tower 32 SVR3
1430                 tm_file=m68k/tower-as.h
1431                 xm_defines="USG SVR3"
1432                 xmake_file=m68k/x-tower
1433                 extra_parts="crtbegin.o crtend.o"
1434                 extra_headers=math-68881.h
1435                 ;;
1436         m68k-plexus-sysv*)
1437                 tm_file=m68k/plexus.h
1438                 xm_file="xm-alloca.h m68k/xm-plexus.h ${xm_file}"
1439                 xm_defines=USG
1440                 use_collect2=yes
1441                 extra_headers=math-68881.h
1442                 ;;
1443         m68k-tti-*)
1444                 tm_file=m68k/pbb.h
1445                 xm_file="xm-alloca.h ${xm_file}"
1446                 xm_defines=USG
1447                 extra_headers=math-68881.h
1448                 ;;
1449         m68k-crds-unos*)
1450                 xm_file="xm-alloca.h m68k/xm-crds.h ${xm_file}"
1451                 xm_defines="USG unos"
1452                 xmake_file=m68k/x-crds
1453                 tm_file=m68k/crds.h
1454                 use_collect2=yes
1455                 extra_headers=math-68881.h
1456                 ;;
1457         m68k-cbm-sysv4*)                # Commodore variant of V.4.
1458                 tm_file=m68k/amix.h
1459                 xm_file="xm-alloca.h ${xm_file}"
1460                 xm_defines="USG FULL_PROTOTYPES"
1461                 xmake_file=m68k/x-amix
1462                 tmake_file=t-svr4
1463                 extra_parts="crtbegin.o crtend.o"
1464                 extra_headers=math-68881.h
1465                 float_format=m68k
1466                 ;;
1467         m68k-ccur-rtu)
1468                 tm_file=m68k/ccur-GAS.h
1469                 xmake_file=m68k/x-ccur
1470                 extra_headers=math-68881.h
1471                 use_collect2=yes
1472                 float_format=m68k
1473                 ;;
1474         m68k-hp-bsd4.4*)                # HP 9000/3xx running 4.4bsd
1475                 tm_file=m68k/hp3bsd44.h
1476                 xmake_file=m68k/x-hp3bsd44
1477                 use_collect2=yes
1478                 extra_headers=math-68881.h
1479                 float_format=m68k
1480                 ;;
1481         m68k-hp-bsd*)                   # HP 9000/3xx running Berkeley Unix
1482                 tm_file=m68k/hp3bsd.h
1483                 use_collect2=yes
1484                 extra_headers=math-68881.h
1485                 float_format=m68k
1486                 ;;
1487         m68k-isi-bsd*)
1488                 if [[ x$with_fp = xno ]]
1489                 then
1490                         tm_file=m68k/isi-nfp.h
1491                 else
1492                         tm_file=m68k/isi.h
1493                         float_format=m68k
1494                 fi
1495                 use_collect2=yes
1496                 extra_headers=math-68881.h
1497                 ;;
1498         m68k-hp-hpux7*) # HP 9000 series 300 running HPUX version 7.
1499                 xm_file="xm_alloca.h ${xm_file}"
1500                 xm_defines="USG NO_SYS_SIGLIST"
1501                 if [[ x$gas = xyes ]]
1502                 then
1503                         xmake_file=m68k/x-hp320g
1504                         tm_file=m68k/hp320g.h
1505                 else
1506                         xmake_file=m68k/x-hp320
1507                         tm_file=m68k/hpux7.h
1508                 fi
1509                 install_headers_dir=install-headers-cpio
1510                 use_collect2=yes
1511                 extra_headers=math-68881.h
1512                 float_format=m68k
1513                 ;;
1514         m68k-hp-hpux*)  # HP 9000 series 300
1515                 xm_file="xm_alloca.h ${xm_file}"
1516                 xm_defines="USG NO_SYS_SIGLIST"
1517                 if [[ x$gas = xyes ]]
1518                 then
1519                         xmake_file=m68k/x-hp320g
1520                         tm_file=m68k/hp320g.h
1521                 else
1522                         xmake_file=m68k/x-hp320
1523                         tm_file=m68k/hp320.h
1524                 fi
1525                 install_headers_dir=install-headers-cpio
1526                 use_collect2=yes
1527                 extra_headers=math-68881.h
1528                 float_format=m68k
1529                 ;;
1530         m68k-sun-mach*)
1531                 tm_file=m68k/sun3mach.h
1532                 use_collect2=yes
1533                 extra_headers=math-68881.h
1534                 float_format=m68k
1535                 ;;
1536         m68k-sony-newsos3*)
1537                 if [[ x$gas = xyes ]]
1538                 then
1539                         tm_file=m68k/news3gas.h
1540                 else
1541                         tm_file=m68k/news3.h
1542                 fi
1543                 use_collect2=yes
1544                 extra_headers=math-68881.h
1545                 float_format=m68k
1546                 ;;
1547         m68k-sony-bsd* | m68k-sony-newsos*)
1548                 if [[ x$gas = xyes ]]
1549                 then
1550                         tm_file=m68k/newsgas.h
1551                 else
1552                         tm_file=m68k/news.h
1553                 fi
1554                 use_collect2=yes
1555                 extra_headers=math-68881.h
1556                 float_format=m68k
1557                 ;;
1558         m68k-next-nextstep2*)
1559                 tm_file=m68k/next21.h
1560                 xm_file="m68k/xm-next.h ${xm_file}"
1561                 tmake_file=m68k/t-next
1562                 xmake_file=m68k/x-next
1563                 extra_objs=nextstep.o
1564                 extra_headers=math-68881.h
1565                 use_collect2=yes
1566                 float_format=m68k
1567                 ;;
1568         m68k-next-nextstep3*)
1569                 tm_file=m68k/next.h
1570                 xm_file="m68k/xm-next.h ${xm_file}"
1571                 tmake_file=m68k/t-next
1572                 xmake_file=m68k/x-next
1573                 extra_objs=nextstep.o
1574                 extra_headers=math-68881.h
1575                 float_format=m68k
1576                 if [[ x$enable_threads = xyes ]]; then
1577                         thread_file='mach'
1578                 fi
1579                 ;;
1580         m68k-sun-sunos3*)
1581                 if [[ x$with_fp = xno ]]
1582                 then
1583                         tm_file=m68k/sun3n3.h
1584                 else
1585                         tm_file=m68k/sun3o3.h
1586                         float_format=m68k
1587                 fi
1588                 use_collect2=yes
1589                 extra_headers=math-68881.h
1590                 ;;
1591         m68k-sun-sunos*)                        # For SunOS 4 (the default).
1592                 if [[ x$with_fp = xno ]]
1593                 then
1594                         tm_file=m68k/sun3n.h
1595                 else
1596                         tm_file=m68k/sun3.h
1597                         float_format=m68k
1598                 fi
1599                 use_collect2=yes
1600                 extra_headers=math-68881.h
1601                 ;;
1602         m68k-wrs-vxworks*)
1603                 tm_file=m68k/vxm68k.h
1604                 tmake_file=m68k/t-vxworks68
1605                 extra_headers=math-68881.h
1606                 thread_file='vxworks'
1607                 float_format=m68k
1608                 ;;
1609         m68k-*-aout*)
1610                 tmake_file=m68k/t-m68kbare
1611                 tm_file="m68k/m68k-aout.h libgloss.h"
1612                 extra_headers=math-68881.h
1613                 float_format=m68k
1614                 ;;
1615         m68k-*-coff*)
1616                 tmake_file=m68k/t-m68kbare
1617                 tm_file="m68k/m68k-coff.h dbx.h libgloss.h"
1618                 extra_headers=math-68881.h
1619                 float_format=m68k
1620                 ;;
1621         m68k-*-lynxos*)
1622                 if [[ x$gas = xyes ]]
1623                 then
1624                         tm_file=m68k/lynx.h
1625                 else
1626                         tm_file=m68k/lynx-ng.h
1627                 fi
1628                 xm_file=m68k/xm-lynx.h
1629                 xmake_file=x-lynx
1630                 tmake_file=m68k/t-lynx
1631                 extra_headers=math-68881.h
1632                 float_format=m68k
1633                 ;;
1634         m68k-*-netbsd*)
1635                 tm_file=m68k/netbsd.h
1636                 # On NetBSD, the headers are already okay, except for math.h.
1637                 fixincludes=fixinc.wrap
1638                 tmake_file=t-netbsd
1639                 float_format=m68k
1640                 ;;
1641         m68k-*-sysv3*)                  # Motorola m68k's running system V.3
1642                 xm_file="xm-alloca.h ${xm_file}"
1643                 xm_defines=USG
1644                 xmake_file=m68k/x-m68kv
1645                 extra_parts="crtbegin.o crtend.o"
1646                 extra_headers=math-68881.h
1647                 float_format=m68k
1648                 ;;
1649         m68k-*-sysv4*)                  # Motorola m68k's running system V.4
1650                 tm_file=m68k/m68kv4.h
1651                 xm_file="xm-alloca.h ${xm_file}"
1652                 xm_defines=USG
1653                 tmake_file=t-svr4
1654                 extra_parts="crtbegin.o crtend.o"
1655                 extra_headers=math-68881.h
1656                 float_format=m68k
1657                 ;;
1658         m68k-*-linux-gnuaout*)          # Motorola m68k's running GNU/Linux
1659                                         # with a.out format
1660                 xmake_file=x-linux
1661                 tm_file=m68k/linux-aout.h
1662                 tmake_file="t-linux-aout m68k/t-linux-aout"
1663                 fixincludes=Makefile.in # The headers are ok already.
1664                 extra_headers=math-68881.h
1665                 float_format=m68k
1666                 gnu_ld=yes
1667                 ;;
1668         m68k-*-linux-gnulibc1)          # Motorola m68k's running GNU/Linux
1669                                         # with ELF format using the
1670                                         # GNU/Linux C library 5
1671                 xmake_file=x-linux
1672                 tm_file=m68k/linux.h
1673                 tmake_file="t-linux t-linux-gnulibc1 m68k/t-linux"
1674                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1675                 fixincludes=Makefile.in # The headers are ok already.
1676                 extra_headers=math-68881.h
1677                 float_format=m68k
1678                 gnu_ld=yes
1679                 ;;
1680         m68k-*-linux-gnu*)              # Motorola m68k's running GNU/Linux
1681                                         # with ELF format using glibc 2
1682                                         # aka the GNU/Linux C library 6.
1683                 xmake_file=x-linux
1684                 tm_file=m68k/linux.h
1685                 tmake_file="t-linux m68k/t-linux"
1686                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
1687                 fixincludes=Makefile.in # The headers are ok already.
1688                 extra_headers=math-68881.h
1689                 float_format=m68k
1690                 gnu_ld=yes
1691                 if [[ x$enable_threads = xyes ]]; then
1692                         thread_file='posix'
1693                 fi
1694                 ;;
1695         m68k-*-psos*)
1696                 tmake_file=m68k/t-m68kbare
1697                 tm_file=m68k/m68k-psos.h
1698                 extra_headers=math-68881.h
1699                 float_format=m68k
1700                 ;;
1701         m68k-*-rtems*)
1702                 tmake_file="m68k/t-m68kbare t-rtems"
1703                 tm_file=m68k/rtems.h
1704                 extra_headers=math-68881.h
1705                 float_format=m68k
1706                 ;;
1707
1708         m88k-dg-dgux*)
1709                 case $machine in
1710                   m88k-dg-dguxbcs*)
1711                     tm_file=m88k/dguxbcs.h
1712                     tmake_file=m88k/t-dguxbcs
1713                     ;;
1714                   *)
1715                     tm_file=m88k/dgux.h
1716                     tmake_file=m88k/t-dgux
1717                     ;;
1718                 esac
1719                 extra_parts="crtbegin.o bcscrtbegin.o crtend.o m88kdgux.ld"
1720                 xmake_file=m88k/x-dgux
1721                 if [[ x$gas = xyes ]]
1722                 then
1723                         tmake_file=m88k/t-dgux-gas
1724                 fi
1725                 fixincludes=fixinc.dgux
1726                 ;;
1727         m88k-dolphin-sysv3*)
1728                 tm_file=m88k/dolph.h
1729                 extra_parts="crtbegin.o crtend.o"
1730                 xm_file="m88k/xm-sysv3.h ${xm_file}"
1731                 xmake_file=m88k/x-dolph
1732                 if [[ x$gas = xyes ]]
1733                 then
1734                         tmake_file=m88k/t-m88k-gas
1735                 fi
1736                 ;;
1737         m88k-tektronix-sysv3)
1738                 tm_file=m88k/tekXD88.h
1739                 extra_parts="crtbegin.o crtend.o"
1740                 xm_file="m88k/xm-sysv3.h ${xm_file}"
1741                 xmake_file=m88k/x-tekXD88
1742                 if [[ x$gas = xyes ]]
1743                 then
1744                         tmake_file=m88k/t-m88k-gas
1745                 fi
1746                 ;;
1747         m88k-*-aout*)
1748                 tm_file=m88k/m88k-aout.h
1749                 ;;
1750         m88k-*-coff*)
1751                 tm_file=m88k/m88k-coff.h
1752                 tmake_file=m88k/t-bug
1753                 ;;
1754         m88k-*-luna*)
1755                 tm_file=m88k/luna.h
1756                 extra_parts="crtbegin.o crtend.o"
1757                 if [[ x$gas = xyes ]]
1758                 then
1759                         tmake_file=m88k/t-luna-gas
1760                 else
1761                         tmake_file=m88k/t-luna
1762                 fi
1763                 ;;
1764         m88k-*-sysv3*)
1765                 tm_file=m88k/sysv3.h
1766                 extra_parts="crtbegin.o crtend.o"
1767                 xm_file="m88k/xm-sysv3.h ${xm_file}"
1768                 xmake_file=m88k/x-sysv3
1769                 if [[ x$gas = xyes ]]
1770                 then
1771                         tmake_file=m88k/t-m88k-gas
1772                 fi
1773                 ;;
1774         m88k-*-sysv4*)
1775                 tm_file=m88k/sysv4.h
1776                 extra_parts="crtbegin.o crtend.o"
1777                 xmake_file=m88k/x-sysv4
1778                 tmake_file=m88k/t-sysv4
1779                 ;;
1780         mips-sgi-irix6*)                # SGI System V.4., IRIX 6
1781                 tm_file=mips/iris6.h
1782                 xm_file=mips/xm-iris6.h
1783                 fixincludes=fixinc.irix
1784                 xmake_file=mips/x-iris6
1785                 tmake_file=mips/t-iris6
1786                 if [[ x$enable_threads = xyes ]]; then
1787                         thread_file='irix'
1788                 fi
1789                 ;;
1790         mips-wrs-vxworks)
1791                 tm_file="mips/elf.h libgloss.h"
1792                 tmake_file=mips/t-ecoff
1793                 gas=yes
1794                 gnu_ld=yes
1795                 extra_parts="crtbegin.o crtend.o"
1796 #               thread_file='vxworks'
1797                 ;;
1798         mips-sgi-irix5cross64)          # Irix5 host, Irix 6 target, cross64
1799                 tm_file="mips/iris6.h mips/cross64.h"
1800                 xm_defines=USG
1801                 xm_file="mips/xm-iris5.h"
1802                 fixincludes=Makefile.in
1803                 xmake_file=mips/x-iris
1804                 tmake_file=mips/t-cross64
1805                 # See comment in mips/iris[56].h files.
1806                 use_collect2=yes
1807                 if [[ x$enable_threads = xyes ]]; then
1808                         thread_file='irix'
1809                 fi
1810                 ;;
1811         mips-sni-sysv4)
1812                 if [[ x$gas = xyes ]]
1813                 then
1814                         if [[ x$stabs = xyes ]]
1815                         then
1816                                 tm_file=mips/iris5gdb.h
1817                         else
1818                                 tm_file="mips/sni-svr4.h mips/sni-gas.h"
1819                         fi
1820                 else
1821                         tm_file=mips/sni-svr4.h
1822                 fi
1823                 xm_defines=USG
1824                 xmake_file=mips/x-sni-svr4
1825                 tmake_file=mips/t-mips-gas
1826                 if [[ x$gnu_ld != xyes ]]
1827                 then
1828                         use_collect2=yes
1829                 fi
1830                 ;;
1831         mips-sgi-irix5*)                # SGI System V.4., IRIX 5
1832                 if [[ x$gas = xyes ]]
1833                 then
1834                         tm_file="mips/iris5.h mips/iris5gas.h"
1835                         if [[ x$stabs = xyes ]]
1836                         then
1837                                 tm_file="${tm_file} dbx.h"
1838                         fi
1839                 else
1840                         tm_file=mips/iris5.h
1841                 fi
1842                 xm_defines=USG
1843                 xm_file="mips/xm-iris5.h"
1844                 fixincludes=fixinc.irix
1845                 xmake_file=mips/x-iris
1846                 # mips-tfile doesn't work yet
1847                 tmake_file=mips/t-mips-gas
1848                 # See comment in mips/iris5.h file.
1849                 use_collect2=yes
1850                 if [[ x$enable_threads = xyes ]]; then
1851                         thread_file='irix'
1852                 fi
1853                 ;;
1854         mips-sgi-irix4loser*)           # Mostly like a MIPS.
1855                 tm_file="mips/iris4loser.h mips/iris3.h ${tm_file} mips/iris4.h"
1856                 if [[ x$stabs = xyes ]]; then
1857                         tm_file="${tm_file} dbx.h"
1858                 fi
1859                 xm_defines=USG
1860                 xmake_file=mips/x-iris
1861                 if [[ x$gas = xyes ]]
1862                 then
1863                         tmake_file=mips/t-mips-gas
1864                 else
1865                         extra_passes="mips-tfile mips-tdump"
1866                 fi
1867                 if [[ x$gnu_ld != xyes ]]
1868                 then
1869                         use_collect2=yes
1870                 fi
1871                 if [[ x$enable_threads = xyes ]]; then
1872                         thread_file='irix'
1873                 fi
1874                 ;;
1875         mips-sgi-irix4*)                # Mostly like a MIPS.
1876                 tm_file="mips/iris3.h ${tm_file} mips/iris4.h"
1877                 if [[ x$stabs = xyes ]]; then
1878                         tm_file="${tm_file} dbx.h"
1879                 fi
1880                 xm_defines=USG
1881                 xmake_file=mips/x-iris
1882                 if [[ x$gas = xyes ]]
1883                 then
1884                         tmake_file=mips/t-mips-gas
1885                 else
1886                         extra_passes="mips-tfile mips-tdump"
1887                 fi
1888                 if [[ x$gnu_ld != xyes ]]
1889                 then
1890                         use_collect2=yes
1891                 fi
1892                 if [[ x$enable_threads = xyes ]]; then
1893                         thread_file='irix'
1894                 fi
1895                 ;;
1896         mips-sgi-*)                     # Mostly like a MIPS.
1897                 tm_file="mips/iris3.h ${tm_file}"
1898                 if [[ x$stabs = xyes ]]; then
1899                         tm_file="${tm_file} dbx.h"
1900                 fi
1901                 xm_defines=USG
1902                 xmake_file=mips/x-iris3
1903                 if [[ x$gas = xyes ]]
1904                 then
1905                         tmake_file=mips/t-mips-gas
1906                 else
1907                         extra_passes="mips-tfile mips-tdump"
1908                 fi
1909                 if [[ x$gnu_ld != xyes ]]
1910                 then
1911                         use_collect2=yes
1912                 fi
1913                 ;;
1914         mips-dec-osfrose*)              # Decstation running OSF/1 reference port with OSF/rose.
1915                 tm_file="mips/osfrose.h ${tm_file}"
1916                 xmake_file=mips/x-osfrose
1917                 tmake_file=mips/t-osfrose
1918                 extra_objs=halfpic.o
1919                 use_collect2=yes
1920                 ;;
1921         mips-dec-osf*)                  # Decstation running OSF/1 as shipped by DIGITAL
1922                 tm_file=mips/dec-osf1.h
1923                 if [[ x$stabs = xyes ]]; then
1924                         tm_file="${tm_file} dbx.h"
1925                 fi
1926                 xmake_file=mips/x-dec-osf1
1927                 if [[ x$gas = xyes ]]
1928                 then
1929                         tmake_file=mips/t-mips-gas
1930                 else
1931                         tmake_file=mips/t-ultrix
1932                         extra_passes="mips-tfile mips-tdump"
1933                 fi
1934                 if [[ x$gnu_ld != xyes ]]
1935                 then
1936                         use_collect2=yes
1937                 fi
1938                 ;;
1939         mips-dec-bsd*)                  # Decstation running 4.4 BSD
1940               tm_file=mips/dec-bsd.h
1941               fixincludes=
1942               if [[ x$gas = xyes ]]
1943               then
1944                         tmake_file=mips/t-mips-gas
1945               else
1946                         tmake_file=mips/t-ultrix
1947                         extra_passes="mips-tfile mips-tdump"
1948               fi
1949               if [[ x$gnu_ld != xyes ]]
1950               then
1951                         use_collect2=yes
1952               fi
1953               ;;
1954         mips-dec-netbsd*)                  # Decstation running NetBSD
1955                 tm_file=mips/netbsd.h
1956                 # On NetBSD, the headers are already okay, except for math.h.
1957                 fixincludes=fixinc.wrap
1958                 tmake_file=t-netbsd
1959                 ;;
1960         mips-sony-bsd* | mips-sony-newsos*)     # Sony NEWS 3600 or risc/news.
1961                 tm_file="mips/news4.h ${tm_file}"
1962                 if [[ x$stabs = xyes ]]; then
1963                         tm_file="${tm_file} dbx.h"
1964                 fi
1965                 if [[ x$gas = xyes ]]
1966                 then
1967                         tmake_file=mips/t-mips-gas
1968                 else
1969                         extra_passes="mips-tfile mips-tdump"
1970                 fi
1971                 if [[ x$gnu_ld != xyes ]]
1972                 then
1973                         use_collect2=yes
1974                 fi
1975                 xmake_file=mips/x-sony
1976                 ;;
1977         mips-sony-sysv*)                # Sony NEWS 3800 with NEWSOS5.0.
1978                                         # That is based on svr4.
1979                 # t-svr4 is not right because this system doesn't use ELF.
1980                 tm_file="mips/news5.h ${tm_file}"
1981                 if [[ x$stabs = xyes ]]; then
1982                         tm_file="${tm_file} dbx.h"
1983                 fi
1984                 xm_file="xm-siglist.h ${xm_file}"
1985                 xm_defines=USG
1986                 if [[ x$gas = xyes ]]
1987                 then
1988                         tmake_file=mips/t-mips-gas
1989                 else
1990                         extra_passes="mips-tfile mips-tdump"
1991                 fi
1992                 if [[ x$gnu_ld != xyes ]]
1993                 then
1994                         use_collect2=yes
1995                 fi
1996                 ;;
1997         mips-tandem-sysv4*)             # Tandem S2 running NonStop UX
1998                 tm_file="mips/svr4-5.h mips/svr4-t.h"
1999                 if [[ x$stabs = xyes ]]; then
2000                         tm_file="${tm_file} dbx.h"
2001                 fi
2002                 xm_file="xm-siglist.h ${xm_file}"
2003                 xm_defines=USG
2004                 xmake_file=mips/x-sysv
2005                 if [[ x$gas = xyes ]]
2006                 then
2007                         tmake_file=mips/t-mips-gas
2008                         extra_parts="crtbegin.o crtend.o"
2009                 else
2010                         tmake_file=mips/t-mips
2011                         extra_passes="mips-tfile mips-tdump"
2012                 fi
2013                 if [[ x$gnu_ld != xyes ]]
2014                 then
2015                         use_collect2=yes
2016                 fi
2017                 ;;
2018         mips-*-ultrix* | mips-dec-mach3)        # Decstation.
2019                 tm_file="mips/ultrix.h ${tm_file}"
2020                 if [[ x$stabs = xyes ]]; then
2021                         tm_file="${tm_file} dbx.h"
2022                 fi
2023                 xmake_file=mips/x-ultrix
2024                 if [[ x$gas = xyes ]]
2025                 then
2026                         tmake_file=mips/t-mips-gas
2027                 else
2028                         tmake_file=mips/t-ultrix
2029                         extra_passes="mips-tfile mips-tdump"
2030                 fi
2031                 if [[ x$gnu_ld != xyes ]]
2032                 then
2033                         use_collect2=yes
2034                 fi
2035                 ;;
2036         mips-*-riscos[[56789]]bsd*)
2037                 tm_file=mips/bsd-5.h    # MIPS BSD 4.3, RISC-OS 5.0
2038                 if [[ x$stabs = xyes ]]; then
2039                         tm_file="${tm_file} dbx.h"
2040                 fi
2041                 if [[ x$gas = xyes ]]
2042                 then
2043                         tmake_file=mips/t-bsd-gas
2044                 else
2045                         tmake_file=mips/t-bsd
2046                         extra_passes="mips-tfile mips-tdump"
2047                 fi
2048                 if [[ x$gnu_ld != xyes ]]
2049                 then
2050                         use_collect2=yes
2051                 fi
2052                 ;;
2053         mips-*-bsd* | mips-*-riscosbsd* | mips-*-riscos[[1234]]bsd*)
2054                 tm_file="mips/bsd-4.h ${tm_file}" # MIPS BSD 4.3, RISC-OS 4.0
2055                 if [[ x$stabs = xyes ]]; then
2056                         tm_file="${tm_file} dbx.h"
2057                 fi
2058                 if [[ x$gas = xyes ]]
2059                 then
2060                         tmake_file=mips/t-bsd-gas
2061                 else
2062                         tmake_file=mips/t-bsd
2063                         extra_passes="mips-tfile mips-tdump"
2064                 fi
2065                 if [[ x$gnu_ld != xyes ]]
2066                 then
2067                         use_collect2=yes
2068                 fi
2069                 ;;
2070         mips-*-riscos[[56789]]sysv4*)
2071                 tm_file=mips/svr4-5.h   # MIPS System V.4., RISC-OS 5.0
2072                 if [[ x$stabs = xyes ]]; then
2073                         tm_file="${tm_file} dbx.h"
2074                 fi
2075                 xm_file="xm-siglist.h ${xm_file}"
2076                 xmake_file=mips/x-sysv
2077                 if [[ x$gas = xyes ]]
2078                 then
2079                         tmake_file=mips/t-svr4-gas
2080                 else
2081                         tmake_file=mips/t-svr4
2082                         extra_passes="mips-tfile mips-tdump"
2083                 fi
2084                 if [[ x$gnu_ld != xyes ]]
2085                 then
2086                         use_collect2=yes
2087                 fi
2088                 ;;
2089         mips-*-sysv4* | mips-*-riscos[[1234]]sysv4* | mips-*-riscossysv4*)
2090                 tm_file="mips/svr4-4.h ${tm_file}"
2091                 if [[ x$stabs = xyes ]]; then
2092                         tm_file="${tm_file} dbx.h"
2093                 fi
2094                 xm_defines=USG
2095                 xmake_file=mips/x-sysv
2096                 if [[ x$gas = xyes ]]
2097                 then
2098                         tmake_file=mips/t-svr4-gas
2099                 else
2100                         tmake_file=mips/t-svr4
2101                         extra_passes="mips-tfile mips-tdump"
2102                 fi
2103                 if [[ x$gnu_ld != xyes ]]
2104                 then
2105                         use_collect2=yes
2106                 fi
2107                 ;;
2108         mips-*-riscos[[56789]]sysv*)
2109                 tm_file=mips/svr3-5.h   # MIPS System V.3, RISC-OS 5.0
2110                 if [[ x$stabs = xyes ]]; then
2111                         tm_file="${tm_file} dbx.h"
2112                 fi
2113                 xm_defines=USG
2114                 xmake_file=mips/x-sysv
2115                 if [[ x$gas = xyes ]]
2116                 then
2117                         tmake_file=mips/t-svr3-gas
2118                 else
2119                         tmake_file=mips/t-svr3
2120                         extra_passes="mips-tfile mips-tdump"
2121                 fi
2122                 if [[ x$gnu_ld != xyes ]]
2123                 then
2124                         use_collect2=yes
2125                 fi
2126                 ;;
2127         mips-*-sysv* | mips-*-riscos*sysv*)
2128                 tm_file="mips/svr3-4.h ${tm_file}"
2129                 if [[ x$stabs = xyes ]]; then
2130                         tm_file="${tm_file} dbx.h"
2131                 fi
2132                 xm_defines=USG
2133                 xmake_file=mips/x-sysv
2134                 if [[ x$gas = xyes ]]
2135                 then
2136                         tmake_file=mips/t-svr3-gas
2137                 else
2138                         tmake_file=mips/t-svr3
2139                         extra_passes="mips-tfile mips-tdump"
2140                 fi
2141                 if [[ x$gnu_ld != xyes ]]
2142                 then
2143                         use_collect2=yes
2144                 fi
2145                 ;;
2146         mips-*-riscos[[56789]]*)                # Default MIPS RISC-OS 5.0.
2147                 tm_file=mips/mips-5.h
2148                 if [[ x$stabs = xyes ]]; then
2149                         tm_file="${tm_file} dbx.h"
2150                 fi
2151                 if [[ x$gas = xyes ]]
2152                 then
2153                         tmake_file=mips/t-mips-gas
2154                 else
2155                         extra_passes="mips-tfile mips-tdump"
2156                 fi
2157                 if [[ x$gnu_ld != xyes ]]
2158                 then
2159                         use_collect2=yes
2160                 fi
2161                 ;;
2162         mips-*-gnu*)
2163                 ;;
2164         mipsel-*-ecoff*)
2165                 tm_file=mips/ecoffl.h
2166                 if [[ x$stabs = xyes ]]; then
2167                         tm_file="${tm_file} dbx.h"
2168                 fi
2169                 tmake_file=mips/t-ecoff
2170                 ;;
2171         mips-*-ecoff*)
2172                 tm_file="gofast.h mips/ecoff.h"
2173                 if [[ x$stabs = xyes ]]; then
2174                         tm_file="${tm_file} dbx.h"
2175                 fi
2176                 tmake_file=mips/t-ecoff
2177                 ;;
2178         mipsel-*-elf*)
2179                 tm_file="mips/elfl.h libgloss.h"
2180                 tmake_file=mips/t-ecoff
2181                 ;;
2182         mips-*-elf*)
2183                 tm_file="mips/elf.h libgloss.h"
2184                 tmake_file=mips/t-ecoff
2185                 ;;
2186         mips64el-*-elf*)
2187                 tm_file="mips/elfl64.h libgloss.h"
2188                 tmake_file=mips/t-ecoff
2189                 ;;
2190         mips64orionel-*-elf*)
2191                 tm_file="mips/elforion.h mips/elfl64.h libgloss.h"
2192                 tmake_file=mips/t-ecoff
2193                 ;;
2194         mips64-*-elf*)
2195                 tm_file="mips/elf64.h libgloss.h"
2196                 tmake_file=mips/t-ecoff
2197                 ;;
2198         mips64orion-*-elf*)
2199                 tm_file="mips/elforion.h mips/elf64.h libgloss.h"
2200                 tmake_file=mips/t-ecoff
2201                 ;;
2202         mips64orion-*-rtems*)
2203                 tm_file="mips/elforion.h mips/elf64.h mips/rtems64.h"
2204                 tmake_file="mips/t-ecoff t-rtems"
2205                 ;;
2206         mipstx39el-*-elf*)
2207                 tm_file="mips/r3900.h mips/elfl.h mips/abi64.h libgloss.h"
2208                 tmake_file=mips/t-r3900
2209                 ;;
2210         mipstx39-*-elf*)
2211                 tm_file="mips/r3900.h mips/elf.h mips/abi64.h libgloss.h"
2212                 tmake_file=mips/t-r3900
2213                 ;;
2214         mips-*-*)                               # Default MIPS RISC-OS 4.0.
2215                 if [[ x$stabs = xyes ]]; then
2216                         tm_file="${tm_file} dbx.h"
2217                 fi
2218                 if [[ x$gas = xyes ]]
2219                 then
2220                         tmake_file=mips/t-mips-gas
2221                 else
2222                         extra_passes="mips-tfile mips-tdump"
2223                 fi
2224                 if [[ x$gnu_ld != xyes ]]
2225                 then
2226                         use_collect2=yes
2227                 fi
2228                 ;;
2229         mn10200-*-*)
2230                 cpu_type=mn10200
2231                 tm_file="mn10200/mn10200.h"
2232                 if [[ x$stabs = xyes ]]
2233                 then
2234                         tm_file="${tm_file} dbx.h"
2235                 fi
2236                 use_collect2=no
2237                 ;;
2238         mn10300-*-*)
2239                 cpu_type=mn10300
2240                 tm_file="mn10300/mn10300.h"
2241                 if [[ x$stabs = xyes ]]
2242                 then
2243                         tm_file="${tm_file} dbx.h"
2244                 fi
2245                 use_collect2=no
2246                 ;;
2247         ns32k-encore-bsd*)
2248                 tm_file=ns32k/encore.h
2249                 use_collect2=yes
2250                 ;;
2251         ns32k-sequent-bsd*)
2252                 tm_file=ns32k/sequent.h
2253                 use_collect2=yes
2254                 ;;
2255         ns32k-tek6100-bsd*)
2256                 tm_file=ns32k/tek6100.h
2257                 use_collect2=yes
2258                 ;;
2259         ns32k-tek6200-bsd*)
2260                 tm_file=ns32k/tek6200.h
2261                 use_collect2=yes
2262                 ;;
2263 # This has not been updated to GCC 2.
2264 #       ns32k-ns-genix*)
2265 #               xm_defines=USG
2266 #               xmake_file=ns32k/x-genix
2267 #               tm_file=ns32k/genix.h
2268 #               use_collect2=yes
2269 #               ;;
2270         ns32k-merlin-*)
2271                 tm_file=ns32k/merlin.h
2272                 use_collect2=yes
2273                 ;;
2274         ns32k-pc532-mach*)
2275                 tm_file=ns32k/pc532-mach.h
2276                 use_collect2=yes
2277                 ;;
2278         ns32k-pc532-minix*)
2279                 tm_file=ns32k/pc532-min.h
2280                 xm_file="ns32k/xm-pc532-min.h ${xm-file}"
2281                 xm_defines=USG
2282                 use_collect2=yes
2283                 ;;
2284         ns32k-pc532-netbsd*)
2285                 tm_file=ns32k/netbsd.h
2286                 # On NetBSD, the headers are already okay, except for math.h.
2287                 fixincludes=fixinc.wrap
2288                 tmake_file=t-netbsd
2289                 ;;
2290         pdp11-*-bsd)
2291                 tm_file="${tm_file} pdp11/2bsd.h"
2292                 ;;
2293         pdp11-*-*)
2294                 ;;
2295         pyramid-*-*)
2296                 cpu_type=pyr
2297                 xmake_file=pyr/x-pyr
2298                 use_collect2=yes
2299                 ;;
2300         romp-*-aos*)
2301                 use_collect2=yes
2302                 ;;
2303         romp-*-mach*)
2304                 xmake_file=romp/x-mach
2305                 use_collect2=yes
2306                 ;;
2307         powerpc-*-beos*)
2308                 cpu_type=rs6000
2309                 tm_file=rs6000/beos.h
2310                 xm_file=rs6000/xm-beos.h
2311                 tmake_file=rs6000/t-beos
2312                 xmake_file=rs6000/x-beos
2313                 ;;
2314         powerpc-*-sysv* | powerpc-*-elf*)
2315                 tm_file=rs6000/sysv4.h
2316                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2317                 xm_defines="USG POSIX"
2318                 extra_headers=ppc-asm.h
2319                 if [[ x$gas = xyes ]]
2320                 then
2321                         tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2322                 else
2323                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2324                 fi
2325                 xmake_file=rs6000/x-sysv4
2326                 ;;
2327         powerpc-*-eabiaix*)
2328                 tm_file=rs6000/eabiaix.h
2329                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2330                 fixincludes=Makefile.in
2331                 extra_headers=ppc-asm.h
2332                 ;;
2333         powerpc-*-eabisim*)
2334                 tm_file=rs6000/eabisim.h
2335                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2336                 fixincludes=Makefile.in
2337                 extra_headers=ppc-asm.h
2338                 ;;
2339         powerpc-*-eabi*)
2340                 tm_file=rs6000/eabi.h
2341                 if [[ x$gas = xyes ]]
2342                 then
2343                         tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2344                 else
2345                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2346                 fi
2347                 fixincludes=Makefile.in
2348                 extra_headers=ppc-asm.h
2349                 ;;
2350         powerpc-*-rtems*)
2351                 tm_file=rs6000/rtems.h
2352                 if [[ x$gas = xyes ]]
2353                 then
2354                      tmake_file="rs6000/t-ppcgas t-rtems rs6000/t-ppccomm"
2355                 else
2356                      tmake_file="rs6000/t-ppc t-rtems rs6000/t-ppccomm"
2357                 fi
2358                 fixincludes=Makefile.in
2359                 extra_headers=ppc-asm.h
2360                 ;;
2361         powerpc-*-linux-gnulibc1)
2362                 tm_file=rs6000/linux.h
2363                 xm_file=rs6000/xm-sysv4.h
2364                 out_file=rs6000/rs6000.c
2365                 if [[ x$gas = xyes ]]
2366                 then
2367                         tmake_file="rs6000/t-ppcos t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2368                 else
2369                         tmake_file="rs6000/t-ppc t-linux t-linux-gnulibc1 rs6000/t-ppccomm"
2370                 fi
2371                 xmake_file=x-linux
2372                 fixincludes=Makefile.in
2373                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2374                 extra_headers=ppc-asm.h
2375                 if [[ x$enable_threads = xyes ]]; then
2376                         thread_file='posix'
2377                 fi
2378                 ;;
2379         powerpc-*-linux-gnu*)
2380                 tm_file=rs6000/linux.h
2381                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2382                 xm_defines="USG ${xm_defines}"
2383                 out_file=rs6000/rs6000.c
2384                 if [[ x$gas = xyes ]]
2385                 then
2386                         tmake_file="rs6000/t-ppcos t-linux rs6000/t-ppccomm"
2387                 else
2388                         tmake_file="rs6000/t-ppc t-linux rs6000/t-ppccomm"
2389                 fi
2390                 xmake_file=x-linux
2391                 fixincludes=Makefile.in
2392                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2393                 extra_headers=ppc-asm.h
2394                 if [[ x$enable_threads = xyes ]]; then
2395                         thread_file='posix'
2396                 fi
2397                 ;;
2398         powerpc-wrs-vxworks*)
2399                 cpu_type=rs6000
2400                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2401                 xm_defines="USG POSIX"
2402                 tm_file=rs6000/vxppc.h
2403                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2404                 extra_headers=ppc-asm.h
2405                 thread_file='vxworks'
2406                 ;;
2407         powerpcle-*-sysv* | powerpcle-*-elf*)
2408                 tm_file=rs6000/sysv4le.h
2409                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2410                 xm_defines="USG POSIX"
2411                 if [[ x$gas = xyes ]]
2412                 then
2413                         tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2414                 else
2415                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2416                 fi
2417                 xmake_file=rs6000/x-sysv4
2418                 extra_headers=ppc-asm.h
2419                 ;;
2420         powerpcle-*-eabisim*)
2421                 tm_file=rs6000/eabilesim.h
2422                 tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2423                 fixincludes=Makefile.in
2424                 extra_headers=ppc-asm.h
2425                 ;;
2426         powerpcle-*-eabi*)
2427                 tm_file=rs6000/eabile.h
2428                 if [[ x$gas = xyes ]]
2429                 then
2430                         tmake_file="rs6000/t-ppcgas rs6000/t-ppccomm"
2431                 else
2432                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2433                 fi
2434                 fixincludes=Makefile.in
2435                 extra_headers=ppc-asm.h
2436                 ;;
2437         powerpcle-*-winnt* )
2438                 tm_file=rs6000/win-nt.h
2439                 tmake_file=rs6000/t-winnt
2440 #               extra_objs=pe.o
2441                 fixincludes=Makefile.in
2442                 if [[ x$enable_threads = xyes ]]; then
2443                         thread_file='win32'
2444                 fi
2445                 extra_headers=ppc-asm.h
2446                 ;;
2447         powerpcle-*-pe | powerpcle-*-cygwin32)
2448                 tm_file=rs6000/cygwin32.h
2449                 xm_file="rs6000/xm-cygwin32.h ${xm_file}"
2450                 tmake_file=rs6000/t-winnt
2451                 xmake_file=rs6000/x-cygwin32
2452 #               extra_objs=pe.o
2453                 fixincludes=Makefile.in
2454                 if [[ x$enable_threads = xyes ]]; then
2455                         thread_file='win32'
2456                 fi
2457                 exeext=.exe
2458                 extra_headers=ppc-asm.h
2459                 ;;
2460         powerpcle-*-solaris2*)
2461                 tm_file=rs6000/sol2.h
2462                 xm_file="xm-siglist.h rs6000/xm-sysv4.h"
2463                 xm_defines="USG POSIX"
2464                 if [[ x$gas = xyes ]]
2465                 then
2466                         tmake_file="rs6000/t-ppcos rs6000/t-ppccomm"
2467                 else
2468                         tmake_file="rs6000/t-ppc rs6000/t-ppccomm"
2469                 fi
2470                 xmake_file=rs6000/x-sysv4
2471                 case $machine in
2472                 *-*-solaris2.[[0-4]])
2473                         fixincludes=fixinc.svr4;;
2474                 *)
2475                         fixincludes=fixinc.wrap;;
2476                 esac
2477                 extra_headers=ppc-asm.h
2478                 ;;
2479         rs6000-ibm-aix3.[[01]]*)
2480                 tm_file=rs6000/aix31.h
2481                 xmake_file=rs6000/x-aix31
2482                 use_collect2=yes
2483                 ;;
2484         rs6000-ibm-aix3.2.[[456789]]* | powerpc-ibm-aix3.2.[[456789]]*)
2485                 tm_file=rs6000/aix3newas.h
2486                 if [[ x$host != x$target ]]
2487                 then
2488                         tmake_file=rs6000/t-xnewas
2489                 else
2490                         tmake_file=rs6000/t-newas
2491                 fi
2492                 use_collect2=yes
2493                 ;;
2494         rs6000-ibm-aix4.[[12]].* | powerpc-ibm-aix4.[[12]].*)
2495                 tm_file=rs6000/aix41.h
2496                 if [[ x$host != x$target ]]
2497                 then
2498                         tmake_file=rs6000/t-xnewas
2499                 else
2500                         tmake_file=rs6000/t-newas
2501                 fi
2502                 xmake_file=rs6000/x-aix41
2503                 use_collect2=yes
2504                 ;;
2505         rs6000-ibm-aix4.[[3456789]].* | powerpc-ibm-aix4.[[3456789]].*)
2506                 tm_file=rs6000/aix43.h
2507                 if [[ x$host != x$target ]]
2508                 then
2509                         tmake_file=rs6000/t-xaix43
2510                 else
2511                         tmake_file=rs6000/t-aix43
2512                 fi
2513                 xmake_file=rs6000/x-aix43
2514                 use_collect2=yes
2515                 ;;
2516         rs6000-ibm-aix[[56789]].* | powerpc-ibm-aix[[56789]].*)
2517                 tm_file=rs6000/aix43.h
2518                 if [[ x$host != x$target ]]
2519                 then
2520                         tmake_file=rs6000/t-xaix43
2521                 else
2522                         tmake_file=rs6000/t-aix43
2523                 fi
2524                 xmake_file=rs6000/x-aix43
2525                 use_collect2=yes
2526                 ;;
2527         rs6000-ibm-aix*)
2528                 use_collect2=yes
2529                 ;;
2530         rs6000-bull-bosx)
2531                 use_collect2=yes
2532                 ;;
2533         rs6000-*-mach*)
2534                 tm_file=rs6000/mach.h
2535                 xm_file="${xm_file} rs6000/xm-mach.h"
2536                 xmake_file=rs6000/x-mach
2537                 use_collect2=yes
2538                 ;;
2539         rs6000-*-lynxos*)
2540                 tm_file=rs6000/lynx.h
2541                 xm_file=rs6000/xm-lynx.h
2542                 tmake_file=rs6000/t-rs6000
2543                 xmake_file=rs6000/x-lynx
2544                 use_collect2=yes
2545                 ;;
2546         sh-*-elf*)
2547                 tm_file=sh/elf.h
2548                 float_format=sh
2549                 ;;
2550         sh-*-rtemself*)
2551                 tmake_file="sh/t-sh t-rtems"
2552                 tm_file=sh/rtemself.h
2553                 float_format=sh
2554                 ;;
2555         sh-*-rtems*)
2556                 tmake_file="sh/t-sh t-rtems"
2557                 tm_file=sh/rtems.h
2558                 float_format=sh
2559                 ;;
2560         sh-*-*)
2561                 float_format=sh
2562                 ;;
2563         sparc-tti-*)
2564                 tm_file=sparc/pbd.h
2565                 xm_file="xm-alloca.h ${xm_file}"
2566                 xm_defines=USG
2567                 ;;
2568         sparc-wrs-vxworks* | sparclite-wrs-vxworks*)
2569                 tm_file=sparc/vxsparc.h
2570                 tmake_file=sparc/t-vxsparc
2571                 use_collect2=yes
2572                 thread_file='vxworks'
2573                 ;;
2574         sparc-*-aout*)
2575                 tmake_file=sparc/t-sparcbare
2576                 tm_file="sparc/aout.h libgloss.h"
2577                 ;;
2578         sparc-*-netbsd*)
2579                 tm_file=sparc/netbsd.h
2580                 # On NetBSD, the headers are already okay, except for math.h.
2581                 fixincludes=fixinc.wrap
2582                 tmake_file=t-netbsd
2583                 ;;
2584         sparc-*-bsd*)
2585                 tm_file=sparc/bsd.h
2586                 ;;
2587         sparc-*-elf*)
2588                 tm_file=sparc/elf.h
2589                 tmake_file=sparc/t-elf
2590                 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
2591                 #float_format=i128
2592                 float_format=i64
2593                 ;;
2594         sparc-*-linux-gnuaout*)         # Sparc's running GNU/Linux, a.out
2595                 xm_file="${xm_file} sparc/xm-linux.h"
2596                 tm_file=sparc/linux-aout.h
2597                 xmake_file=x-linux
2598                 fixincludes=Makefile.in #On Linux, the headers are ok already.
2599                 gnu_ld=yes
2600                 ;;
2601         sparc-*-linux-gnulibc1*)        # Sparc's running GNU/Linux, libc5
2602                 xm_file="${xm_file} sparc/xm-linux.h"
2603                 xmake_file=x-linux
2604                 tm_file=sparc/linux.h
2605                 tmake_file="t-linux t-linux-gnulibc1"
2606                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2607                 fixincludes=Makefile.in #On Linux, the headers are ok already.
2608                 gnu_ld=yes
2609                 ;;
2610         sparc-*-linux-gnu*)             # Sparc's running GNU/Linux, libc6
2611                 xm_file="${xm_file} sparc/xm-linux.h"
2612                 xmake_file=x-linux
2613                 tm_file=sparc/linux.h
2614                 tmake_file="t-linux"
2615                 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
2616                 fixincludes=Makefile.in #On Linux, the headers are ok already.
2617                 gnu_ld=yes
2618                 if [[ x$enable_threads = xyes ]]; then
2619                         thread_file='posix'
2620                 fi
2621                 ;;
2622         sparc-*-lynxos*)
2623                 if [[ x$gas = xyes ]]
2624                 then
2625                         tm_file=sparc/lynx.h
2626                 else
2627                         tm_file=sparc/lynx-ng.h
2628                 fi
2629                 xm_file=sparc/xm-lynx.h
2630                 tmake_file=sparc/t-sunos41
2631                 xmake_file=x-lynx
2632                 ;;
2633         sparc-*-rtems*)
2634                 tmake_file="sparc/t-sparcbare t-rtems"
2635                 tm_file=sparc/rtems.h
2636                 ;;
2637         sparc-*-solaris2*)
2638                 if [[ x$gnu_ld = xyes ]]
2639                 then
2640                         tm_file=sparc/sol2.h
2641                 else
2642                         tm_file=sparc/sol2-sld.h
2643                 fi
2644                 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
2645                 xm_defines="USG POSIX"
2646                 tmake_file=sparc/t-sol2
2647                 xmake_file=sparc/x-sysv4
2648                 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
2649                 case $machine in
2650                 *-*-solaris2.[[0-4]])
2651                         fixincludes=fixinc.svr4;;
2652                 *)
2653                         fixincludes=fixinc.wrap;;
2654                 esac
2655                 float_format=i128
2656                 if [[ x${enable_threads} = x ]]; then
2657                     enable_threads=$have_pthread_h
2658                     if [[ x${enable_threads} = x ]]; then
2659                         enable_threads=$have_thread_h
2660                     fi
2661                 fi
2662                 if [[ x${enable_threads} = xyes ]]; then
2663                     if [[ x${have_pthread_h} = xyes ]]; then
2664                         thread_file='posix'
2665                     else
2666                         thread_file='solaris'
2667                     fi
2668                 fi
2669                 ;;
2670         sparc-*-sunos4.0*)
2671                 tm_file=sparc/sunos4.h
2672                 tmake_file=sparc/t-sunos40
2673                 use_collect2=yes
2674                 ;;
2675         sparc-*-sunos4*)
2676                 tm_file=sparc/sunos4.h
2677                 tmake_file=sparc/t-sunos41
2678                 use_collect2=yes
2679                 if [[ x$gas = xyes ]]; then
2680                         tm_file="${tm_file} sparc/sun4gas.h"
2681                 fi
2682                 ;;
2683         sparc-*-sunos3*)
2684                 tm_file=sparc/sun4o3.h
2685                 use_collect2=yes
2686                 ;;
2687         sparc-*-sysv4*)
2688                 tm_file=sparc/sysv4.h
2689                 xm_file="xm-siglist.h sparc/xm-sysv4.h"
2690                 xm_defines="USG POSIX"
2691                 tmake_file=t-svr4
2692                 xmake_file=sparc/x-sysv4
2693                 extra_parts="crtbegin.o crtend.o"
2694                 ;;
2695         sparc-*-vxsim*)
2696                 xm_file="xm-siglist.h sparc/xm-sysv4.h sparc/xm-sol2.h"
2697                 xm_defines="USG POSIX"
2698                 tm_file=sparc/vxsim.h
2699                 tmake_file=sparc/t-vxsparc
2700                 xmake_file=sparc/x-sysv4
2701                 ;;
2702         sparclet-*-aout*)
2703                 tm_file="sparc/splet.h libgloss.h"
2704                 tmake_file=sparc/t-splet
2705                 ;;
2706         sparclite-*-coff*)
2707                 tm_file="sparc/litecoff.h libgloss.h"
2708                 tmake_file=sparc/t-sparclite
2709                 ;;
2710         sparclite-*-aout*)
2711                 tm_file="sparc/lite.h aoutos.h libgloss.h"
2712                 tmake_file=sparc/t-sparclite
2713                 ;;
2714         sparc64-*-aout*)
2715                 tmake_file=sparc/t-sp64
2716                 tm_file=sparc/sp64-aout.h
2717                 ;;
2718         sparc64-*-elf*)
2719                 tmake_file=sparc/t-sp64
2720                 tm_file=sparc/sp64-elf.h
2721                 extra_parts="crtbegin.o crtend.o"
2722                 ;;
2723         sparc64-*-linux*)               # 64-bit Sparc's running GNU/Linux
2724                 tmake_file=sparc/t-sp64
2725                 xm_file="sparc/xm-sp64.h sparc/xm-linux.h"
2726                 tm_file=sparc/linux64.h
2727                 xmake_file=x-linux
2728                 fixincludes=Makefile.in # The headers are ok already.
2729                 gnu_ld=yes
2730                 ;;
2731 # This hasn't been upgraded to GCC 2.
2732 #       tahoe-harris-*)                 # Harris tahoe, using COFF.
2733 #               tm_file=tahoe/harris.h
2734 #               ;;
2735 #       tahoe-*-bsd*)                   # tahoe running BSD
2736 #               ;;
2737         thumb-*-coff* | thumbel-*-coff*)
2738                 tm_file=arm/tcoff.h
2739                 out_file=arm/thumb.c
2740                 xm_file=arm/xm-thumb.h
2741                 md_file=arm/thumb.md
2742                 tmake_file=arm/t-thumb
2743                 fixincludes=Makefile.in # There is nothing to fix
2744                 ;;
2745 # This hasn't been upgraded to GCC 2.
2746 #       tron-*-*)
2747 #               cpu_type=gmicro
2748 #               use_collect2=yes
2749 #               ;;
2750         v850-*-*)
2751                 cpu_type=v850
2752                 tm_file="v850/v850.h"
2753                 xm_file="v850/xm-v850.h"
2754                 tmake_file=v850/t-v850
2755                 if [[ x$stabs = xyes ]]
2756                 then
2757                         tm_file="${tm_file} dbx.h"
2758                 fi
2759                 use_collect2=no
2760                 ;;
2761         vax-*-bsd*)                     # vaxen running BSD
2762                 use_collect2=yes
2763                 float_format=vax
2764                 ;;
2765         vax-*-sysv*)                    # vaxen running system V
2766                 tm_file="${tm_file} vax/vaxv.h"
2767                 xm_defines=USG
2768                 float_format=vax
2769                 ;;
2770         vax-*-netbsd*)
2771                 tm_file="${tm_file} netbsd.h vax/netbsd.h"
2772                 # On NetBSD, the headers are already okay, except for math.h.
2773                 fixincludes=fixinc.wrap
2774                 tmake_file=t-netbsd
2775                 float_format=vax
2776                 ;;
2777         vax-*-ultrix*)                  # vaxen running ultrix
2778                 tm_file="${tm_file} vax/ultrix.h"
2779                 use_collect2=yes
2780                 float_format=vax
2781                 ;;
2782         vax-*-vms*)                     # vaxen running VMS
2783                 xm_file=vax/xm-vms.h
2784                 tm_file=vax/vms.h
2785                 float_format=vax
2786                 ;;
2787         vax-*-*)                        # vax default entry
2788                 float_format=vax
2789                 ;;
2790         we32k-att-sysv*)
2791                 xm_file="${xm_file} xm-svr3"
2792                 use_collect2=yes
2793                 ;;
2794         *)
2795                 echo "Configuration $machine not supported" 1>&2
2796                 exit 1
2797                 ;;
2798         esac
2799
2800         case $machine in
2801         *-*-linux-gnu*)
2802                 ;; # Existing GNU/Linux systems do not use the GNU setup.
2803         *-*-gnu*)
2804                 # On the GNU system, the setup is just about the same on
2805                 # each different CPU.  The specific machines that GNU
2806                 # supports are matched above and just set $cpu_type.
2807                 xm_file="xm-gnu.h ${xm_file}"
2808                 tm_file=${cpu_type}/gnu.h
2809                 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
2810                 # GNU always uses ELF.
2811                 elf=yes
2812                 # GNU tools are the only tools.
2813                 gnu_ld=yes
2814                 gas=yes
2815                 # On GNU, the headers are already okay.
2816                 fixincludes=Makefile.in
2817                 xmake_file=x-linux      # These details are the same as Linux.
2818                 tmake_file=t-gnu        # These are not.
2819                 ;;
2820         *-*-sysv4*)
2821                 fixincludes=fixinc.svr4
2822                 xmake_try_sysv=x-sysv
2823                 install_headers_dir=install-headers-cpio
2824                 ;;
2825         *-*-sysv*)
2826                 install_headers_dir=install-headers-cpio
2827                 ;;
2828         esac
2829
2830         # Distinguish i[34567]86
2831         # Also, do not run mips-tfile on MIPS if using gas.
2832         # Process --with-cpu= for PowerPC/rs6000
2833         target_cpu_default2=
2834         case $machine in
2835         i486-*-*)
2836                 target_cpu_default2=1
2837                 ;;
2838         i586-*-*)
2839                 target_cpu_default2=2
2840                 ;;
2841         i686-*-* | i786-*-*)
2842                 target_cpu_default2=3
2843                 ;;
2844         alpha*-*-*)
2845                 case $machine in
2846                         alphaev6*)
2847                                 target_cpu_default2="MASK_CPU_EV6|MASK_BXW|MASK_CIX|MASK_MAX"
2848                                 ;;
2849                         alphapca56*)
2850                                 target_cpu_default2="MASK_CPU_EV5|MASK_BWX|MASK_MAX"
2851                                 ;;
2852                         alphaev56*)
2853                                 target_cpu_default2="MASK_CPU_EV5|MASK_BWX"
2854                                 ;;
2855                         alphaev5*)
2856                                 target_cpu_default2="MASK_CPU_EV5"
2857                                 ;;
2858                 esac
2859                                 
2860                 if [[ x$gas = xyes ]]
2861                 then
2862                         if [[ "$target_cpu_default2" = "" ]]
2863                         then
2864                                 target_cpu_default2="MASK_GAS"
2865                         else
2866                                 target_cpu_default2="${target_cpu_default2}|MASK_GAS"
2867                         fi
2868                 fi
2869                 ;;
2870         arm*-*-*)
2871                 case "x$with_cpu" in
2872                         x)
2873                                 # The most generic
2874                                 target_cpu_default2="TARGET_CPU_generic"
2875                                 ;;
2876
2877                         # Distinguish cores, and major variants
2878                         # arm7m doesn't exist, but D & I don't affect code
2879                         xarm[23678] | xarm250 | xarm[67][01]0 \
2880                         | xarm7m | xarm7dm | xarm7dmi | xarm7tdmi \
2881                         | xarm7100 | xarm7500 | xarm7500fe | xarm810 \
2882                         | xstrongarm | xstrongarm110)
2883                                 target_cpu_default2="TARGET_CPU_$with_cpu"
2884                                 ;;
2885
2886                         xyes | xno)
2887                                 echo "--with-cpu must be passed a value" 1>&2
2888                                 exit 1
2889                                 ;;
2890
2891                         *)
2892                                 if [[ x$pass2done = xyes ]]
2893                                 then
2894                                         echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
2895                                         exit 1
2896                                 fi
2897                                 ;;
2898                 esac
2899                 ;;
2900
2901         mips*-*-ecoff* | mips*-*-elf*)
2902                 if [[ x$gas = xyes ]]
2903                 then
2904                         if [[ x$gnu_ld = xyes ]]
2905                         then
2906                                 target_cpu_default2=20
2907                         else
2908                                 target_cpu_default2=16
2909                         fi
2910                 fi
2911                 ;;
2912         mips*-*-*)
2913                 if [[ x$gas = xyes ]]
2914                 then
2915                         target_cpu_default2=16
2916                 fi
2917                 ;;
2918         powerpc*-*-* | rs6000-*-*)
2919                 case "x$with_cpu" in
2920                         x)
2921                                 ;;
2922
2923                         xcommon | xpower | xpower2 | xpowerpc | xrios \
2924                           | xrios1 | xrios2 | xrsc | xrsc1 \
2925                           | x601 | x602 | x603 | x603e | x604 | x604e | x620 \
2926                           | x403 | x505 | x801 | x821 | x823 | x860)
2927                                 target_cpu_default2="\"$with_cpu\""
2928                                 ;;
2929
2930                         xyes | xno)
2931                                 echo "--with-cpu must be passed a value" 1>&2
2932                                 exit 1
2933                                 ;;
2934
2935                         *)
2936                                 if [[ x$pass2done = xyes ]]
2937                                 then
2938                                         echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
2939                                         exit 1
2940                                 fi
2941                                 ;;
2942                 esac
2943                 ;;
2944         sparc*-*-*)
2945                 case ".$with_cpu" in
2946                         .)
2947                                 target_cpu_default2=TARGET_CPU_"`echo $machine | sed 's/-.*$//'`"
2948                                 ;;
2949                         .supersparc | .ultrasparc | .v7 | .v8 | .v9)
2950                                 target_cpu_default2="TARGET_CPU_$with_cpu"
2951                                 ;;
2952                         *)
2953                                 if [[ x$pass2done = xyes ]]
2954                                 then
2955                                         echo "Unknown cpu used with --with-cpu=$with_cpu" 1>&2
2956                                         exit 1
2957                                 fi
2958                                 ;;
2959                 esac
2960                 ;;
2961         esac
2962
2963         if [[ "$target_cpu_default2" != "" ]]
2964         then
2965                 if [[ "$target_cpu_default" != "" ]]
2966                 then
2967                         target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
2968                 else
2969                         target_cpu_default=$target_cpu_default2
2970                 fi
2971         fi
2972
2973         # No need for collect2 if we have the GNU linker.
2974         # Actually, there is now; GNU ld doesn't handle the EH info or
2975         # collecting for shared libraries.
2976         #case x$gnu_ld in
2977         #xyes)
2978         #       use_collect2=
2979         #       ;;
2980         #esac
2981
2982 # Save data on machine being used to compile GCC in build_xm_file.
2983 # Save data on host machine in vars host_xm_file and host_xmake_file.
2984         if [[ x$pass1done = x ]]
2985         then
2986                 if [[ x"$xm_file" = x ]]
2987                 then build_xm_file=$cpu_type/xm-$cpu_type.h
2988                 else build_xm_file=$xm_file
2989                 fi
2990                 build_xm_defines=$xm_defines
2991                 build_install_headers_dir=$install_headers_dir
2992                 build_exeext=$exeext
2993                 pass1done=yes
2994         else
2995                 if [[ x$pass2done = x ]]
2996                 then
2997                         if [[ x"$xm_file" = x ]]
2998                         then host_xm_file=$cpu_type/xm-$cpu_type.h
2999                         else host_xm_file=$xm_file
3000                         fi
3001                         host_xm_defines=$xm_defines
3002                         if [[ x"$xmake_file" = x ]]
3003                         then xmake_file=$cpu_type/x-$cpu_type
3004                         fi
3005                         host_xmake_file="$xmake_file"
3006                         host_truncate_target=$truncate_target
3007                         host_extra_gcc_objs=$extra_gcc_objs
3008                         host_extra_objs=$extra_host_objs
3009                         host_exeext=$exeext
3010                         pass2done=yes
3011                 fi
3012         fi
3013 done
3014
3015 extra_objs="${host_extra_objs} ${extra_objs}"
3016
3017 # Default the target-machine variables that were not explicitly set.
3018 if [[ x"$tm_file" = x ]]
3019 then tm_file=$cpu_type/$cpu_type.h; fi
3020
3021 if [[ x$extra_headers = x ]]
3022 then extra_headers=; fi
3023
3024 if [[ x"$xm_file" = x ]]
3025 then xm_file=$cpu_type/xm-$cpu_type.h; fi
3026
3027 if [[ x$md_file = x ]]
3028 then md_file=$cpu_type/$cpu_type.md; fi
3029
3030 if [[ x$out_file = x ]]
3031 then out_file=$cpu_type/$cpu_type.c; fi
3032
3033 if [[ x"$tmake_file" = x ]]
3034 then tmake_file=$cpu_type/t-$cpu_type
3035 fi
3036
3037 if [[ x$float_format = x ]]
3038 then float_format=i64
3039 fi
3040
3041 if [[ x$enable_haifa = x ]]
3042 then
3043   case $target in
3044     alpha*-* | hppa1.?-* | powerpc*-* | rs6000-* | *sparc-* | m32r*-*)
3045       enable_haifa=yes;;
3046   esac
3047 fi
3048
3049 # Say what files are being used for the output code and MD file.
3050 echo "Using \`$srcdir/config/$out_file' to output insns."
3051 echo "Using \`$srcdir/config/$md_file' as machine description file."
3052
3053 count=a
3054 for f in $tm_file; do
3055         count=${count}x
3056 done
3057 if [[ $count = ax ]]; then
3058         echo "Using \`$srcdir/config/$tm_file' as target machine macro file."
3059 else
3060         echo "Using the following target machine macro files:"
3061         for f in $tm_file; do
3062                 echo "  $srcdir/config/$f"
3063         done
3064 fi
3065
3066 count=a
3067 for f in $host_xm_file; do
3068         count=${count}x
3069 done
3070 if [[ $count = ax ]]; then
3071         echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file."
3072 else
3073         echo "Using the following host machine macro files:"
3074         for f in $host_xm_file; do
3075                 echo "  $srcdir/config/$f"
3076         done
3077 fi
3078
3079 if [[ "$host_xm_file" != "$build_xm_file" ]]; then
3080         count=a
3081         for f in $build_xm_file; do
3082                 count=${count}x
3083         done
3084         if [[ $count = ax ]]; then
3085                 echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file."
3086         else
3087                 echo "Using the following build machine macro files:"
3088                 for f in $build_xm_file; do
3089                         echo "  $srcdir/config/$f"
3090                 done
3091         fi
3092 fi
3093
3094 if [[ x$thread_file = x ]]; then
3095         if [[ x$target_thread_file != x ]]; then
3096                 thread_file=$target_thread_file
3097         else
3098                 thread_file='single'
3099         fi
3100 fi
3101
3102 # Set up the header files.
3103 # $links is the list of header files to create.
3104 # $vars is the list of shell variables with file names to include.
3105 # auto-host.h is the file containing items generated by autoconf and is
3106 # the first file included by config.h.
3107 null_defines=
3108 host_xm_file="auto-host.h ${host_xm_file}"
3109
3110 # If host=build, it is correct to have hconfig include auto-host.h
3111 # as well.  If host!=build, we are in error and need to do more 
3112 # work to find out the build config parameters.
3113 if [[ x$host = x$build ]]
3114 then
3115         build_xm_file="auto-host.h ${build_xm_file}"
3116 else
3117         # We create a subdir, then run autoconf in the subdir.
3118         # To prevent recursion we set host and build for the new
3119         # invocation of configure to the build for this invocation
3120         # of configure. 
3121         tempdir=build.$$
3122         rm -rf $tempdir
3123         mkdir $tempdir
3124         cd $tempdir
3125         case ${srcdir} in
3126         /*) realsrcdir=${srcdir};;
3127         *) realsrcdir=../${srcdir};;
3128         esac
3129         CC=${CC_FOR_BUILD} ${realsrcdir}/configure \
3130                 --target=$target --host=$build --build=$build
3131
3132         # We just finished tests for the build machine, so rename
3133         # the file auto-build.h in the gcc directory.
3134         mv auto-host.h ../auto-build.h
3135         cd ..
3136         rm -rf $tempdir
3137         build_xm_file="auto-build.h ${build_xm_file}"
3138 fi
3139
3140 vars="host_xm_file tm_file xm_file build_xm_file"
3141 links="config.h tm.h tconfig.h hconfig.h"
3142 defines="host_xm_defines null_defines xm_defines build_xm_defines"
3143
3144 rm -f config.bak
3145 if [[ -f config.status ]]; then mv -f config.status config.bak; fi
3146
3147 # Make the links.
3148 while [[ -n "$vars" ]]
3149 do
3150         set $vars; var=$1; shift; vars=$*
3151         set $links; link=$1; shift; links=$*
3152         set $defines; define=$1; shift; defines=$*
3153
3154         rm -f $link
3155
3156         # Define TARGET_CPU_DEFAULT if the system wants one.
3157         # This substitutes for lots of *.h files.
3158         if [[ "$target_cpu_default" != "" -a $link = tm.h ]]
3159         then
3160                 echo "#define TARGET_CPU_DEFAULT ($target_cpu_default)" >>$link
3161         fi
3162
3163         for file in `eval echo '$'$var`; do
3164                 echo "#include \"$file\"" >>$link
3165         done
3166
3167         for def in `eval echo '$'$define`; do
3168                 echo "#ifndef $def" >>$link
3169                 echo "#define $def" >>$link
3170                 echo "#endif" >>$link
3171         done
3172 done
3173
3174 # Truncate the target if necessary
3175 if [[ x$host_truncate_target != x ]]; then
3176         target=`echo $target | sed -e 's/\(..............\).*/\1/'`
3177 fi
3178
3179 # Get the version trigger filename from the toplevel
3180 if [[ "${with_gcc_version_trigger+set}" = set ]]; then
3181         gcc_version_trigger=$with_gcc_version_trigger
3182 else
3183         gcc_version_trigger=${srcdir}/version.c
3184 fi
3185 gcc_version=`sed -e 's/.*\"\([[^ \"]]*\)[[ \"]].*/\1/' < ${gcc_version_trigger}`
3186
3187 # Get an absolute path to the GCC top-level source directory
3188 holddir=`pwd`
3189 cd $srcdir
3190 topdir=`pwd`
3191 cd $holddir
3192
3193 # Conditionalize the makefile for this host machine.
3194 # Make-host contains the concatenation of all host makefile fragments
3195 # [there can be more than one].  This file is built by configure.frag.
3196 host_overrides=Make-host
3197 dep_host_xmake_file=
3198 for f in .. ${host_xmake_file}
3199 do
3200         if [[ -f ${srcdir}/config/$f ]]
3201         then
3202                 dep_host_xmake_file="${dep_host_xmake_file} ${srcdir}/config/$f"
3203         fi
3204 done
3205
3206 # Conditionalize the makefile for this target machine.
3207 # Make-target contains the concatenation of all host makefile fragments
3208 # [there can be more than one].  This file is built by configure.frag.
3209 target_overrides=Make-target
3210 dep_tmake_file=
3211 for f in .. ${tmake_file}
3212 do
3213         if [[ -f ${srcdir}/config/$f ]]
3214         then
3215                 dep_tmake_file="${dep_tmake_file} ${srcdir}/config/$f"
3216         fi
3217 done
3218
3219 # If the host doesn't support symlinks, modify CC in
3220 # FLAGS_TO_PASS so CC="stage1/xgcc -Bstage1/" works.
3221 # Otherwise, we can use "CC=$(CC)".
3222 rm -f symtest.tem
3223 if $symbolic_link $srcdir/gcc.c symtest.tem 2>/dev/null
3224 then
3225         cc_set_by_configure="\$(CC)"
3226         stage_prefix_set_by_configure="\$(STAGE_PREFIX)"
3227 else
3228         rm -f symtest.tem
3229         if cp -p $srcdir/gcc.c symtest.tem 2>/dev/null
3230         then
3231                 symbolic_link="cp -p"
3232         else
3233                 symbolic_link="cp"
3234         fi
3235         cc_set_by_configure="\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`"
3236         stage_prefix_set_by_configure="\`case '\$(STAGE_PREFIX)' in stage*) echo '\$(STAGE_PREFIX)' | sed -e 's|stage|../stage|g';; *) echo '\$(STAGE_PREFIX)';; esac\`"
3237 fi
3238 rm -f symtest.tem
3239
3240 out_object_file=`basename $out_file .c`.o
3241
3242 tm_file_list=
3243 for f in $tm_file; do
3244         tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
3245 done
3246
3247 host_xm_file_list=
3248 for f in $host_xm_file; do
3249         if test $f != "auto-host.h"; then
3250                 host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f"
3251         else
3252                 host_xm_file_list="${host_xm_file_list} auto-host.h"
3253         fi
3254 done
3255
3256 build_xm_file_list=
3257 for f in $build_xm_file; do
3258         if test $f != "auto-build.h"; then
3259                 if test $f != "auto-host.h"; then
3260                         build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f"
3261                 else
3262                         build_xm_file_list="${build_xm_file_list} auto-host.h"
3263                 fi
3264         else
3265                 build_xm_file_list="${build_xm_file_list} auto-build.h"
3266         fi
3267 done
3268
3269 # Define macro CROSS_COMPILE in compilation
3270 # if this is a cross-compiler.
3271 # Also use all.cross instead of all.internal
3272 # and add cross-make to Makefile.
3273 cross_overrides="/dev/null"
3274 if [[ x$host != x$target ]]
3275 then
3276         cross_defines="CROSS=-DCROSS_COMPILE"
3277         cross_overrides="${topdir}/cross-make"
3278 fi
3279
3280 # When building gcc with a cross-compiler, we need to fix a few things.
3281 # This must come after cross-make as we want all.build to override
3282 # all.cross.
3283 build_overrides="/dev/null"
3284 if [[ x$build != x$host ]]
3285 then
3286         build_overrides="${topdir}/build-make"
3287 fi
3288
3289 # Expand extra_headers to include complete path.
3290 # This substitutes for lots of t-* files.
3291 extra_headers_list=
3292 if [[ "x$extra_headers" = x ]]
3293 then true
3294 else
3295         # Prepend ${srcdir}/ginclude/ to every entry in extra_headers.
3296         for file in $extra_headers;
3297         do
3298                 extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/${file}"
3299         done
3300 fi
3301
3302 # Add a definition of USE_COLLECT2 if system wants one.
3303 # Also tell toplev.c what to do.
3304 # This substitutes for lots of t-* files.
3305 if [[ x$use_collect2 = x ]]
3306 then
3307         will_use_collect2=
3308         maybe_use_collect2=
3309 else
3310         will_use_collect2="collect2"
3311         maybe_use_collect2="-DUSE_COLLECT2"
3312 fi
3313
3314 # NEED TO CONVERT
3315 # Set MD_DEPS if the real md file is in md.pre-cpp.
3316 # Set MD_CPP to the cpp to pass the md file through.  Md files use ';'
3317 # for line oriented comments, so we must always use a GNU cpp.  If
3318 # building gcc with a cross compiler, use the cross compiler just
3319 # built.  Otherwise, we can use the cpp just built.
3320 md_file_sub=
3321 if [[ "x$md_cppflags" = x ]]
3322 then
3323         md_file_sub=$srcdir/config/$md_file
3324 else
3325         md_file=md
3326 fi
3327
3328 # If we have gas in the build tree, make a link to it.
3329 if [[ -f ../gas/Makefile ]]; then
3330         rm -f as; $symbolic_link ../gas/as-new$host_exeext as$host_exeext 2>/dev/null
3331 fi
3332
3333 # If we have nm in the build tree, make a link to it.
3334 if [[ -f ../binutils/Makefile ]]; then
3335         rm -f nm; $symbolic_link ../binutils/nm-new$host_exeext nm$host_exeext 2>/dev/null
3336 fi
3337
3338 # If we have ld in the build tree, make a link to it.
3339 if [[ -f ../ld/Makefile ]]; then
3340 #       if [[ x$use_collect2 = x ]]; then
3341 #               rm -f ld; $symbolic_link ../ld/ld-new$host_exeext ld$host_exeext 2>/dev/null
3342 #       else
3343                 rm -f collect-ld; $symbolic_link ../ld/ld-new$host_exeext collect-ld$host_exeext 2>/dev/null
3344 #       fi
3345 fi
3346
3347 # Figure out what assembler alignment features are present.
3348 AC_MSG_CHECKING(assembler alignment features)
3349 gcc_cv_as=
3350 gcc_cv_as_alignment_features=
3351 gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,gcc$,gas,'`
3352 if [[ -x as$host_exeext ]]; then
3353         # Build using assembler in the current directory.
3354         gcc_cv_as=./as$host_exeext
3355 elif [[ -f $gcc_cv_as_gas_srcdir/configure.in ]]; then
3356         # Single tree build which includes gas.
3357         for f in $gcc_cv_as_gas_srcdir/configure $gcc_cv_as_gas_srcdir/configure.in $gcc_cv_as_gas_srcdir/Makefile.in
3358         do
3359                 gcc_cv_gas_version=`grep '^VERSION=[[0-9]]*\.[[0-9]]*' $f`
3360                 if [[ x$gcc_cv_gas_version != x ]]; then
3361                         break
3362                 fi
3363         done
3364         gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([[0-9]]*\)"`
3365         gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[[0-9]]*\.\([[0-9]]*\)"`
3366         if [[ x$gcc_cv_gas_major_version != x -a x$gcc_cv_gas_minor_version != x ]]; then
3367                 # Gas version 2.6 and later support for .balign and .p2align.
3368                 # bytes to skip when using .p2align.
3369                 if [[ "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 6 -o "$gcc_cv_gas_major_version" -gt 2 ]]; then
3370                         gcc_cv_as_alignment_features=".balign and .p2align"
3371                         AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN)
3372                 fi
3373                 # Gas version 2.8 and later support specifying the maximum
3374                 # bytes to skip when using .p2align.
3375                 if [[ "$gcc_cv_gas_major_version" -eq 2 -a "$gcc_cv_gas_minor_version" -ge 8 -o "$gcc_cv_gas_major_version" -gt 2 ]]; then
3376                         gcc_cv_as_alignment_features=".p2align including maximum skip"
3377                         AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN)
3378                 fi
3379         fi
3380 elif [[ x$host = x$target ]]; then
3381         # Native build.
3382         gcc_cv_as=as$host_exeext
3383 fi
3384 if [[ x$gcc_cv_as != x ]]; then
3385         # Check if we have .balign and .p2align
3386         echo ".balign  4" > conftest.s
3387         echo ".p2align  2" >> conftest.s
3388         if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
3389                 gcc_cv_as_alignment_features=".balign and .p2align"
3390                 AC_DEFINE(HAVE_GAS_BALIGN_AND_P2ALIGN)
3391         fi
3392         rm -f conftest.s conftest.o
3393         # Check if specifying the maximum bytes to skip when
3394         # using .p2align is supported.
3395         echo ".p2align 4,,7" > conftest.s
3396         if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then
3397                 gcc_cv_as_alignment_features=".p2align including maximum skip"
3398                 AC_DEFINE(HAVE_GAS_MAX_SKIP_P2ALIGN)
3399         fi
3400         rm -f conftest.s conftest.o
3401 fi
3402 AC_MSG_RESULT($gcc_cv_as_alignment_features)
3403
3404 # Figure out what language subdirectories are present.
3405 subdirs=
3406 for lang in ${srcdir}/*/config-lang.in ..
3407 do
3408         case $lang in
3409         ..) ;;
3410         # The odd quoting in the next line works around
3411         # an apparent bug in bash 1.12 on linux.
3412         ${srcdir}/[[*]]/config-lang.in) ;;
3413         *) subdirs="$subdirs `echo $lang | sed -e 's,^.*/\([[^/]]*\)/config-lang.in$,\1,'`" ;;
3414         esac
3415 done
3416
3417 # Make gthr-default.h if we have a thread file.
3418 gthread_flags=
3419 if [[ $thread_file != single ]]; then
3420     rm -f gthr-default.h
3421     echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h
3422     gthread_flags=-DHAVE_GTHR_DEFAULT
3423 fi
3424 AC_SUBST(gthread_flags)
3425
3426 # Make empty files to contain the specs and options for each language.
3427 # Then add #include lines to for a compiler that has specs and/or options.
3428
3429 lang_specs_files=
3430 lang_options_files=
3431 rm -f specs.h options.h
3432 touch specs.h options.h
3433 for subdir in . $subdirs
3434 do
3435         if [[ -f $srcdir/$subdir/lang-specs.h ]]; then
3436                 echo "#include \"$subdir/lang-specs.h\"" >>specs.h
3437                 lang_specs_files="$lang_specs_files $srcdir/$subdir/lang-specs.h"
3438         fi
3439         if [[ -f $srcdir/$subdir/lang-options.h ]]; then
3440                 echo "#include \"$subdir/lang-options.h\"" >>options.h
3441                 lang_options_files="$lang_options_files $srcdir/$subdir/lang-options.h"
3442         fi
3443 done
3444
3445 # These (without "all_") are set in each config-lang.in.
3446 # `language' must be a single word so is spelled singularly.
3447 all_languages=
3448 all_boot_languages=
3449 all_compilers=
3450 all_stagestuff=
3451 all_diff_excludes=
3452 all_outputs=Makefile
3453 # List of language makefile fragments.
3454 all_lang_makefiles=
3455 all_headers=
3456 all_lib2funcs=
3457
3458 # Add the language fragments.
3459 # Languages are added via two mechanisms.  Some information must be
3460 # recorded in makefile variables, these are defined in config-lang.in.
3461 # We accumulate them and plug them into the main Makefile.
3462 # The other mechanism is a set of hooks for each of the main targets
3463 # like `clean', `install', etc.
3464
3465 language_fragments="Make-lang"
3466 language_hooks="Make-hooks"
3467 oldstyle_subdirs=
3468
3469 for s in .. $subdirs
3470 do
3471         if [[ $s != ".." ]]
3472         then
3473                 language=
3474                 boot_language=
3475                 compilers=
3476                 stagestuff=
3477                 diff_excludes=
3478                 headers=
3479                 outputs=
3480                 lib2funcs=
3481                 . ${srcdir}/$s/config-lang.in
3482                 if [[ "x$language" = x ]]
3483                 then
3484                         echo "${srcdir}/$s/config-lang.in doesn't set \$language." 1>&2
3485                         exit 1
3486                 fi
3487                 all_lang_makefiles="$all_lang_makefiles ${srcdir}/$s/Make-lang.in ${srcdir}/$s/Makefile.in"
3488                 all_languages="$all_languages $language"
3489                 if [[ "x$boot_language" = xyes ]]
3490                 then
3491                         all_boot_languages="$all_boot_languages $language"
3492                 fi
3493                 all_compilers="$all_compilers $compilers"
3494                 all_stagestuff="$all_stagestuff $stagestuff"
3495                 all_diff_excludes="$all_diff_excludes $diff_excludes"
3496                 all_headers="$all_headers $headers"
3497                 all_outputs="$all_outputs $outputs"
3498                 if [[ x$outputs = x ]]
3499                 then
3500                         oldstyle_subdirs="$oldstyle_subdirs $s"
3501                 fi
3502                 all_lib2funcs="$all_lib2funcs $lib2funcs"
3503         fi
3504 done
3505
3506 # Since we can't use `::' targets, we link each language in
3507 # with a set of hooks, reached indirectly via lang.${target}.
3508
3509 rm -f Make-hooks
3510 touch Make-hooks
3511 target_list="all.build all.cross start.encap rest.encap \
3512         info dvi \
3513         install-normal install-common install-info install-man \
3514         uninstall distdir \
3515         mostlyclean clean distclean extraclean maintainer-clean \
3516         stage1 stage2 stage3 stage4"
3517 for t in $target_list
3518 do
3519         x=
3520         for l in .. $all_languages
3521         do
3522                 if [[ $l != ".." ]]; then
3523                         x="$x $l.$t"
3524                 fi
3525         done
3526         echo "lang.$t: $x" >> Make-hooks
3527 done
3528
3529 # If we're not building in srcdir, create .gdbinit.
3530
3531 if [[ ! -f Makefile.in ]]; then
3532         echo "dir ." > .gdbinit
3533         echo "dir ${srcdir}" >> .gdbinit
3534         if [[ x$gdb_needs_out_file_path = xyes ]]
3535         then
3536                 echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
3537         fi
3538         if [[ "x$subdirs" != x ]]; then
3539                 for s in $subdirs
3540                 do
3541                         echo "dir ${srcdir}/$s" >> .gdbinit
3542                 done
3543         fi
3544         echo "source ${srcdir}/.gdbinit" >> .gdbinit
3545 fi
3546
3547 # Define variables host_canonical and build_canonical
3548 # because some Cygnus local changes in the Makefile depend on them.
3549 build_canonical=${build}
3550 host_canonical=${host}
3551 target_subdir=
3552 if [[ "${host}" != "${target}" ]] ; then
3553     target_subdir=${target}/
3554 fi
3555 AC_SUBST(build_canonical)
3556 AC_SUBST(host_canonical)
3557 AC_SUBST(target_subdir)
3558         
3559 # If this is using newlib, then define inhibit_libc in
3560 # LIBGCC2_CFLAGS.  This will cause __eprintf to be left out of
3561 # libgcc.a, but that's OK because newib should have its own version of
3562 # assert.h.
3563 inhibit_libc=
3564 if [[ x$with_newlib = xyes ]]; then
3565         inhibit_libc=-Dinhibit_libc
3566 fi
3567 AC_SUBST(inhibit_libc)
3568
3569 # Override SCHED_OBJ and SCHED_CFLAGS to enable the Haifa scheduler.
3570 sched_prefix=
3571 sched_cflags=
3572 if [[ x$enable_haifa = xyes ]]; then
3573     echo "Using the Haifa scheduler."
3574     sched_prefix=haifa-
3575     sched_cflags=-DHAIFA
3576 fi
3577 AC_SUBST(sched_prefix)
3578 AC_SUBST(sched_cflags)
3579 if [[ x$enable_haifa != x ]]; then
3580     # Explicitly remove files that need to be recompiled for the Haifa scheduler.
3581     for x in genattrtab.o toplev.o loop.o unroll.o *sched.o; do
3582         if [[ -f $x ]]; then
3583             echo "Removing $x"
3584             rm -f $x
3585         fi
3586     done
3587 fi
3588
3589 # Nothing to do for FLOAT_H, float_format already handled.
3590 objdir=`pwd`
3591 AC_SUBST(objdir)
3592
3593 # Process the language and host/target makefile fragments.
3594 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
3595
3596 # Substitute configuration variables
3597 AC_SUBST(subdirs)
3598 AC_SUBST(all_languages)
3599 AC_SUBST(all_boot_languages)
3600 AC_SUBST(all_compilers)
3601 AC_SUBST(all_lang_makefiles)
3602 AC_SUBST(all_stagestuff)
3603 AC_SUBST(all_diff_excludes)
3604 AC_SUBST(all_lib2funcs)
3605 AC_SUBST(all_headers)
3606 AC_SUBST(cpp_main)
3607 AC_SUBST(extra_passes)
3608 AC_SUBST(extra_programs)
3609 AC_SUBST(extra_parts)
3610 AC_SUBST(extra_c_objs)
3611 AC_SUBST(extra_cxx_objs)
3612 AC_SUBST(extra_cpp_objs)
3613 AC_SUBST(extra_c_flags)
3614 AC_SUBST(extra_objs)
3615 AC_SUBST(host_extra_gcc_objs)
3616 AC_SUBST(extra_headers_list)
3617 AC_SUBST(dep_host_xmake_file)
3618 AC_SUBST(dep_tmake_file)
3619 AC_SUBST(out_file)
3620 AC_SUBST(out_object_file)
3621 AC_SUBST(md_file)
3622 AC_SUBST(tm_file_list)
3623 AC_SUBST(build_xm_file_list)
3624 AC_SUBST(host_xm_file_list)
3625 AC_SUBST(lang_specs_files)
3626 AC_SUBST(lang_options_files)
3627 AC_SUBST(thread_file)
3628 AC_SUBST(gcc_version)
3629 AC_SUBST(gcc_version_trigger)
3630 AC_SUBST(local_prefix)
3631 AC_SUBST(gxx_include_dir)
3632 AC_SUBST(fixincludes)
3633 AC_SUBST(build_install_headers_dir)
3634 AC_SUBST(build_exeext)
3635 AC_SUBST(host_exeext)
3636 AC_SUBST(float_format)
3637 AC_SUBST(will_use_collect2)
3638 AC_SUBST(maybe_use_collect2)
3639 AC_SUBST(cc_set_by_configure)
3640 AC_SUBST(stage_prefix_set_by_configure)
3641 AC_SUBST(install)
3642 AC_SUBST(symbolic_link)
3643
3644 AC_SUBST_FILE(target_overrides)
3645 AC_SUBST_FILE(host_overrides)
3646 AC_SUBST(cross_defines)
3647 AC_SUBST_FILE(cross_overrides)
3648 AC_SUBST_FILE(build_overrides)
3649 AC_SUBST_FILE(language_fragments)
3650 AC_SUBST_FILE(language_hooks)
3651
3652 # Echo that links are built
3653 if [[ x$host = x$target ]]
3654 then
3655         str1="native "
3656 else
3657         str1="cross-"
3658         str2=" from $host"
3659 fi
3660
3661 if [[ x$host != x$build ]]
3662 then
3663         str3=" on a $build system"
3664 fi
3665
3666 if [[ "x$str2" != x ]] || [[ "x$str3" != x ]]
3667 then
3668         str4=
3669 fi
3670
3671 echo "Links are now set up to build a ${str1}compiler for ${target}$str4" 1>&2
3672
3673 if [[ "x$str2" != x ]] || [[ "x$str3" != x ]]
3674 then
3675         echo " ${str2}${str3}." 1>&2
3676 fi
3677
3678 # Truncate the target if necessary
3679 if [[ x$host_truncate_target != x ]]; then
3680         target=`echo $target | sed -e 's/\(..............\).*/\1/'`
3681 fi
3682
3683 # Configure the subdirectories
3684 # AC_CONFIG_SUBDIRS($subdirs)
3685
3686 # Create the Makefile
3687 # and configure language subdirectories
3688 AC_OUTPUT($all_outputs,
3689 [
3690 . $srcdir/configure.lang
3691 case x$CONFIG_HEADERS in
3692 xauto-host.h:config.in)
3693 echo > cstamp-h ;;
3694 esac
3695 # If the host supports symlinks, point stage[1234] at ../stage[1234] so
3696 # bootstrapping and the installation procedure can still use
3697 # CC="stage1/xgcc -Bstage1/".  If the host doesn't support symlinks,
3698 # FLAGS_TO_PASS has been modified to solve the problem there.
3699 # This is virtually a duplicate of what happens in configure.lang; we do
3700 # an extra check to make sure this only happens if ln -s can be used.
3701 if [[ "$symbolic_link" = "ln -s" ]]; then
3702  for d in .. ${subdirs} ; do
3703    if [[ $d != .. ]]; then
3704         STARTDIR=`pwd`
3705         cd $d
3706         for t in stage1 stage2 stage3 stage4 include
3707         do
3708                 rm -f $t
3709                 $symbolic_link ../$t $t 2>/dev/null
3710         done
3711         cd $STARTDIR
3712    fi
3713  done
3714 else true ; fi
3715 ],
3716 [
3717 host='${host}'
3718 build='${build}'
3719 target='${target}'
3720 target_alias='${target_alias}'
3721 srcdir='${srcdir}'
3722 subdirs='${subdirs}'
3723 oldstyle_subdirs='${oldstyle_subdirs}'
3724 symbolic_link='${symbolic_link}'
3725 program_transform_set='${program_transform_set}'
3726 program_transform_name='${program_transform_name}'
3727 dep_host_xmake_file='${dep_host_xmake_file}'
3728 host_xmake_file='${host_xmake_file}'
3729 dep_tmake_file='${dep_tmake_file}'
3730 tmake_file='${tmake_file}'
3731 thread_file='${thread_file}'
3732 gcc_version='${gcc_version}'
3733 gcc_version_trigger='${gcc_version_trigger}'
3734 local_prefix='${local_prefix}'
3735 build_install_headers_dir='${build_install_headers_dir}'
3736 build_exeext='${build_exeext}'
3737 host_exeext='${host_exeext}'
3738 out_file='${out_file}'
3739 gdb_needs_out_file_path='${gdb_needs_out_file_path}'
3740 SET_MAKE='${SET_MAKE}'
3741 target_list='${target_list}'
3742 target_overrides='${target_overrides}'
3743 host_overrides='${host_overrides}'
3744 cross_defines='${cross_defines}'
3745 cross_overrides='${cross_overrides}'
3746 build_overrides='${build_overrides}'
3747 ])