OSDN Git Service

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