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