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