]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config.gcc
Daily bump.
[thirdparty/gcc.git] / gcc / config.gcc
CommitLineData
a89ea0df 1# GCC target-specific configuration file.
8d8da227
JM
2# Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
3# 2008 Free Software Foundation, Inc.
61ed06c3 4
1322177d 5#This file is part of GCC.
61ed06c3 6
1322177d
LB
7#GCC is free software; you can redistribute it and/or modify it under
8#the terms of the GNU General Public License as published by the Free
9dcd6f09 9#Software Foundation; either version 3, or (at your option) any later
1322177d 10#version.
61ed06c3 11
1322177d
LB
12#GCC is distributed in the hope that it will be useful, but WITHOUT
13#ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14#FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
15#for more details.
61ed06c3
HPN
16
17#You should have received a copy of the GNU General Public License
9dcd6f09
NC
18#along with GCC; see the file COPYING3. If not see
19#<http://www.gnu.org/licenses/>.
61ed06c3 20
a89ea0df
NN
21# This is the GCC target-specific configuration file
22# where a configuration type is mapped to different system-specific
23# definitions and files. This is invoked by the autoconf-generated
24# configure script. Putting it in a separate shell file lets us skip
25# running autoconf when modifying target-specific information.
61ed06c3 26
fa958513
DJ
27# When you change the cases in the OS or target switches, consider
28# updating ../libgcc/config.host also.
29
b01bc573 30# This file switches on the shell variable ${target}, and also uses the
61ed06c3
HPN
31# following shell variables:
32#
33# with_* Various variables as set by configure.
34#
615be2cf 35# enable_threads Either the name, yes or no depending on whether
61ed06c3
HPN
36# threads support was requested.
37#
2121a768 38# default_use_cxa_atexit
c5dde55b
NC
39# The default value for the $enable___cxa_atexit
40# variable. enable___cxa_atexit needs to be set to
41# "yes" for the correct operation of C++ destructors
42# but it relies upon the presence of a non-standard C
43# library function called __cxa_atexit.
44# Since not all C libraries provide __cxa_atexit the
45# default value of $default_use_cxa_atexit is set to
46# "no" except for targets which are known to be OK.
2121a768 47#
61ed06c3
HPN
48# gas_flag Either yes or no depending on whether GNU as was
49# requested.
50#
51# gnu_ld_flag Either yes or no depending on whether GNU ld was
52# requested.
53
54# This file sets the following shell variables for use by the
55# autoconf-generated configure script:
56#
b01bc573
NN
57# cpu_type The name of the cpu, if different from the first
58# chunk of the canonical target name.
61ed06c3 59#
d5355cb2
JDA
60# tm_defines List of target macros to define for all compilations.
61#
61ed06c3 62# tm_file A list of target macro files, if different from
32fb7c9d
FS
63# "$cpu_type/$cpu_type.h". Usually it's constructed
64# per target in a way like this:
c40409ce 65# tm_file="${tm_file} dbxelf.h elfos.h svr4.h ${cpu_type.h}/elf.h"
32fb7c9d
FS
66# Note that the preferred order is:
67# - specific target header "${cpu_type}/${cpu_type.h}"
a4a4b1d3 68# - generic headers like dbxelf.h elfos.h, etc.
32fb7c9d
FS
69# - specializing target headers like ${cpu_type.h}/elf.h
70# This helps to keep OS specific stuff out of the CPU
71# defining header ${cpu_type}/${cpu_type.h}.
61ed06c3 72#
9c63c208
SL
73# It is possible to include automatically-generated
74# build-directory files by prefixing them with "./".
75# All other files should relative to $srcdir/config.
76#
61ed06c3
HPN
77# tm_p_file Location of file with declarations for functions
78# in $out_file.
79#
80# out_file The name of the machine description C support
81# file, if different from "$cpu_type/$cpu_type.c".
82#
83# md_file The name of the machine-description file, if
84# different from "$cpu_type/$cpu_type.md".
85#
86# tmake_file A list of machine-description-specific
87# makefile-fragments, if different from
88# "$cpu_type/t-$cpu_type".
89#
1c0ca89d
ZW
90# extra_modes The name of the file containing a list of extra
91# machine modes, if necessary and different from
92# "$cpu_type/$cpu_type-modes.def".
93#
61ed06c3
HPN
94# extra_objs List of extra objects that should be linked into
95# the compiler proper (cc1, cc1obj, cc1plus)
96# depending on target.
97#
30500d84
KC
98# extra_gcc_objs List of extra objects that should be linked into
99# the compiler driver (gcc) depending on target.
100#
61ed06c3 101# extra_headers List of used header files from the directory
817e13c4 102# config/${cpu_type}.
61ed06c3 103#
1617e5ee
GK
104# use_gcc_tgmath If set, add tgmath.h to the list of used header
105# files.
106#
61ed06c3
HPN
107# extra_passes List of extra executables compiled for this target
108# machine, used for compiling from source to object.
109#
110# extra_parts List of extra object files that should be compiled
111# for this target machine.
112#
113# extra_programs Like extra_passes, but these are used when linking.
114#
75685792
RS
115# extra_options List of target-dependent .opt files.
116#
ff7cc307 117# c_target_objs List of extra target-dependent objects that be
aac69a49 118# linked into the C compiler only.
0e5a4ad8 119#
ff7cc307 120# cxx_target_objs List of extra target-dependent objects that be
aac69a49 121# linked into the C++ compiler only.
0e5a4ad8 122#
c776a6d0
DF
123# fortran_target_objs List of extra target-dependent objects that be
124# linked into the fortran compiler only.
125#
ef69da62
SS
126# target_gtfiles List of extra source files with type information.
127#
61ed06c3
HPN
128# xm_defines List of macros to define when compiling for the
129# target machine.
130#
131# xm_file List of files to include when compiling for the
132# target machine.
133#
134# use_collect2 Set to yes or no, depending on whether collect2
135# will be used.
136#
137# target_cpu_default Set to override the default target model.
138#
61ed06c3
HPN
139# gdb_needs_out_file_path
140# Set to yes if gdb needs a dir command with
141# `dirname $out_file`.
142#
61ed06c3
HPN
143# thread_file Set to control which thread package to use.
144#
145# gas Set to yes or no depending on whether the target
146# system normally uses GNU as.
4977bab6
ZW
147#
148# need_64bit_hwint Set to yes if HOST_WIDE_INT must be 64 bits wide
1197924d
KH
149# for this target. This is true iff this target
150# supports "long" or "wchar_t" wider than 32 bits.
11835124
DM
151# The setting made here must match the one made in
152# other locations such as libcpp/configure.ac
7816bea0
DJ
153#
154# configure_default_options
155# Set to an initializer for configure_default_options
156# in configargs.h, based on --with-cpu et cetera.
587dc9c6
NN
157#
158# use_fixproto Set to "yes" if fixproto should be run normally,
159# "no" if fixproto should never be run.
61ed06c3
HPN
160
161# The following variables are used in each case-construct to build up the
162# outgoing variables:
163#
61ed06c3
HPN
164# gnu_ld Set to yes or no depending on whether the target
165# system normally uses GNU ld.
166
167out_file=
61ed06c3
HPN
168tmake_file=
169extra_headers=
1617e5ee 170use_gcc_tgmath=yes
61ed06c3
HPN
171extra_passes=
172extra_parts=
173extra_programs=
174extra_objs=
61ed06c3 175extra_gcc_objs=
75685792 176extra_options=
aac69a49
NC
177c_target_objs=
178cxx_target_objs=
c776a6d0 179fortran_target_objs=
d5355cb2 180tm_defines=
61ed06c3 181xm_defines=
61ed06c3
HPN
182# Set this to force installation and use of collect2.
183use_collect2=
184# Set this to override the default target model.
185target_cpu_default=
61ed06c3
HPN
186# Set this if gdb needs a dir command with `dirname $out_file`
187gdb_needs_out_file_path=
61ed06c3
HPN
188# Set this to control which thread package will be used.
189thread_file=
190# Reinitialize these from the flag values every loop pass, since some
191# configure entries modify them.
192gas="$gas_flag"
193gnu_ld="$gnu_ld_flag"
2121a768 194default_use_cxa_atexit=no
6ab185d6 195target_gtfiles=
4977bab6 196need_64bit_hwint=
61ed06c3 197
ec2a60b0
NN
198# Default to not using fixproto. Targets which need fixproto should
199# specifically set this to 'yes'.
200use_fixproto=no
587dc9c6 201
6a38414a
NN
202# Don't carry these over build->host->target. Please.
203xm_file=
204md_file=
205
9340544b 206# Obsolete configurations.
e68152b6
JM
207case ${target} in
208# Avoid generic cases below matching.
209 h8300-*-rtems* | h8300-*-elf* \
210 | sh-*-elf* | sh-*-symbianelf* | sh-*-linux* | sh-*-netbsdelf* \
211 | sh-*-rtems* | sh-wrs-vxworks) ;;
212 arm-*-coff* \
213 | armel-*-coff* \
214 | h8300-*-* \
215 | i[34567]86-*-aout* \
216 | i[34567]86-*-coff* \
217 | m68k-*-aout* \
218 | m68k-*-coff* \
219 | sh-*-* \
220 | mips-sgi-irix[56]* \
221 | pdp11-*-bsd \
222 | rs6000-ibm-aix4.[12]* \
223 | powerpc-ibm-aix4.[12]* \
224 )
225 if test "x$enable_obsolete" != xyes; then
226 echo "*** Configuration ${target} is obsolete." >&2
227 echo "*** Specify --enable-obsolete to build it anyway." >&2
228 echo "*** Support will be REMOVED in the next major release of GCC," >&2
229 echo "*** unless a maintainer comes forward." >&2
230 exit 1
231 fi;;
232esac
9340544b 233
7c942e17
ZW
234# Unsupported targets list. Do not put an entry in this list unless
235# it would otherwise be caught by a more permissive pattern. The list
236# should be in alphabetical order.
b01bc573 237case ${target} in
cd985f66 238 i[34567]86-go32-* \
7c942e17 239 | i[34567]86-*-go32* \
7c942e17 240 | mips64orion*-*-rtems* \
7c942e17
ZW
241 | sparc-hal-solaris2* \
242 | thumb-*-* \
cd985f66 243 | *-*-linux*aout* \
7c942e17 244 | *-*-linux*coff* \
cd985f66 245 | *-*-linux*libc1* \
7c942e17
ZW
246 | *-*-linux*oldld* \
247 | *-*-rtemsaout* \
248 | *-*-rtemscoff* \
cd985f66
JM
249 | *-*-solaris2.[0-6] \
250 | *-*-solaris2.[0-6].* \
251 | *-*-sysv* \
9ab346a1 252 | vax-*-vms* \
7c942e17 253 )
b01bc573 254 echo "*** Configuration ${target} not supported" 1>&2
7c942e17
ZW
255 exit 1
256 ;;
257esac
258
61ed06c3 259# Set default cpu_type, tm_file, tm_p_file and xm_file so it can be
ba1e6c0b
JM
260# updated in each machine entry. Also set default extra_headers for some
261# machines.
61ed06c3 262tm_p_file=
b01bc573 263cpu_type=`echo ${target} | sed 's/-.*$//'`
a8e04fe6 264cpu_is_64bit=
b01bc573 265case ${target} in
38b2d076
DD
266m32c*-*-*)
267 cpu_type=m32c
268 tmake_file=m32c/t-m32c
269 ;;
61ed06c3
HPN
270alpha*-*-*)
271 cpu_type=alpha
4977bab6 272 need_64bit_hwint=yes
61ed06c3 273 ;;
2beef00e
AO
274am33_2.0-*-linux*)
275 cpu_type=mn10300
276 ;;
150b72ed
DJ
277arm*-*-*)
278 cpu_type=arm
88f77cba 279 extra_headers="mmintrin.h arm_neon.h"
b76c3c4b
PB
280 c_target_objs="arm-c.o"
281 cxx_target_objs="arm-c.o"
150b72ed 282 ;;
0d4a78eb
BS
283bfin*-*)
284 cpu_type=bfin
285 ;;
99c5227a
HPN
286crisv32-*)
287 cpu_type=cris
288 ;;
faf9ab98
AH
289frv*) cpu_type=frv
290 ;;
7d33c31d
KH
291fido-*-*)
292 cpu_type=m68k
293 extra_headers=math-68881.h
294 ;;
61ed06c3
HPN
295i[34567]86-*-*)
296 cpu_type=i386
ab442df7
MM
297 c_target_objs="i386-c.o"
298 cxx_target_objs="i386-c.o"
b3172cab 299 extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h
3b8dd071 300 pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h
8b96a312 301 nmmintrin.h bmmintrin.h mmintrin-common.h
35cbb299 302 wmmintrin.h cross-stdarg.h"
61ed06c3 303 ;;
14f73b5a
JH
304x86_64-*-*)
305 cpu_type=i386
ab442df7
MM
306 c_target_objs="i386-c.o"
307 cxx_target_objs="i386-c.o"
b3172cab 308 extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h
3b8dd071 309 pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h
8b96a312 310 nmmintrin.h bmmintrin.h mmintrin-common.h
35cbb299 311 wmmintrin.h cross-stdarg.h"
4977bab6 312 need_64bit_hwint=yes
14f73b5a 313 ;;
817e13c4
JM
314ia64-*-*)
315 extra_headers=ia64intrin.h
4977bab6 316 need_64bit_hwint=yes
817e13c4 317 ;;
cd985f66 318hppa*-*-*)
61ed06c3
HPN
319 cpu_type=pa
320 ;;
ad126521
KI
321m32r*-*-*)
322 cpu_type=m32r
323 ;;
ba1e6c0b
JM
324m68k-*-*)
325 extra_headers=math-68881.h
61ed06c3
HPN
326 ;;
327mips*-*-*)
328 cpu_type=mips
4977bab6 329 need_64bit_hwint=yes
93581857 330 extra_headers="loongson.h"
61ed06c3 331 ;;
61ed06c3
HPN
332powerpc*-*-*)
333 cpu_type=rs6000
437cc56a 334 extra_headers="ppc-asm.h altivec.h spe.h ppu_intrinsics.h paired.h spu2vmx.h vec_types.h si2vmx.h"
4977bab6 335 need_64bit_hwint=yes
a8e04fe6 336 case x$with_cpu in
d40c9e33 337 xpowerpc64|xdefault64|x6[23]0|x970|xG5|xpower[34567]|xpower6x|xrs64a|xcell)
a8e04fe6
AM
338 cpu_is_64bit=yes
339 ;;
340 esac
4977bab6
ZW
341 ;;
342rs6000*-*-*)
343 need_64bit_hwint=yes
344 ;;
bdcee471
CL
345score*-*-*)
346 cpu_type=score
347 ;;
61ed06c3
HPN
348sparc*-*-*)
349 cpu_type=sparc
5f7ca34b 350 need_64bit_hwint=yes
61ed06c3 351 ;;
85d9c13c
TS
352spu*-*-*)
353 cpu_type=spu
354 need_64bit_hwint=yes
355 ;;
4977bab6 356s390*-*-*)
6cecb0aa 357 cpu_type=s390
4977bab6
ZW
358 need_64bit_hwint=yes
359 ;;
b4eb03fe 360# Note the 'l'; we need to be able to match e.g. "shle" or "shl".
a1fcb9a1 361sh[123456789lbe]*-*-* | sh-*-*)
fa5322fa 362 cpu_type=sh
4977bab6 363 need_64bit_hwint=yes
fa5322fa 364 ;;
61ed06c3
HPN
365esac
366
367tm_file=${cpu_type}/${cpu_type}.h
b6d7afec 368if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-protos.h
61ed06c3 369then
b6d7afec
ZW
370 tm_p_file=${cpu_type}/${cpu_type}-protos.h
371fi
1c0ca89d
ZW
372extra_modes=
373if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-modes.def
374then
375 extra_modes=${cpu_type}/${cpu_type}-modes.def
376fi
75685792
RS
377if test -f ${srcdir}/config/${cpu_type}/${cpu_type}.opt
378then
379 extra_options="${extra_options} ${cpu_type}/${cpu_type}.opt"
380fi
e564e618 381
b01bc573 382case ${target} in
922e3e33 383i[34567]86-*-*)
0e462a95 384 if test "x$enable_cld" = xyes; then
922e3e33
UB
385 tm_defines="${tm_defines} USE_IX86_CLD=1"
386 fi
387 ;;
e564e618
DB
388x86_64-*-*)
389 tm_file="i386/biarch64.h ${tm_file}"
0e462a95 390 if test "x$enable_cld" = xyes; then
922e3e33
UB
391 tm_defines="${tm_defines} USE_IX86_CLD=1"
392 fi
e564e618
DB
393 ;;
394esac
395
61ed06c3 396# On a.out targets, we need to use collect2.
b01bc573 397case ${target} in
61ed06c3
HPN
398*-*-*aout*)
399 use_collect2=yes
400 ;;
0e5a4ad8 401esac
61ed06c3 402
4977bab6 403# Common parts for widely ported systems.
b01bc573 404case ${target} in
4d6d5bb2 405*-*-darwin*)
80c85ca2
MS
406 tm_file="${tm_file} darwin.h"
407 case ${target} in
408 *-*-darwin9*)
409 tm_file="${tm_file} darwin9.h"
410 ;;
411 esac
412 tm_file="${tm_file} ${cpu_type}/darwin.h"
4d6d5bb2 413 tm_p_file="${tm_p_file} darwin-protos.h"
040b1c5a 414 tmake_file="t-darwin ${cpu_type}/t-darwin t-slibgcc-darwin"
4d6d5bb2 415 target_gtfiles="\$(srcdir)/config/darwin.c"
6ac49599 416 extra_options="${extra_options} darwin.opt"
ab442df7
MM
417 c_target_objs="${c_target_objs} darwin-c.o"
418 cxx_target_objs="${cxx_target_objs} darwin-c.o"
c776a6d0 419 fortran_target_objs="darwin-f.o"
4d6d5bb2 420 extra_objs="darwin.o"
e46b55d0 421 extra_gcc_objs="darwin-driver.o"
747b9f55 422 default_use_cxa_atexit=yes
4d6d5bb2
NN
423 case ${enable_threads} in
424 "" | yes | posix) thread_file='posix' ;;
425 esac
426 ;;
427*-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
428 # This is the place-holder for the generic a.out configuration
429 # of FreeBSD. No actual configuration resides here since
430 # there was only ever a bare-bones ix86 configuration for
431 # a.out and it exists solely in the machine-specific section.
432 # This place-holder must exist to avoid dropping into
433 # the generic ELF configuration of FreeBSD (i.e. it must be
434 # ordered before that section).
435 ;;
436*-*-freebsd*)
437 # This is the generic ELF configuration of FreeBSD. Later
438 # machine-specific sections may refine and add to this
439 # configuration.
440 #
441 # Due to tm_file entry ordering issues that vary between cpu
442 # architectures, we only define fbsd_tm_file to allow the
443 # machine-specific section to dictate the final order of all
444 # entries of tm_file with the minor exception that components
445 # of the tm_file set here will always be of the form:
446 #
447 # freebsd<version_number>.h [freebsd-<conf_option>.h ...] freebsd-spec.h freebsd.h
448 #
449 # The machine-specific section should not tamper with this
450 # ordering but may order all other entries of tm_file as it
451 # pleases around the provided core setting.
452 gas=yes
453 gnu_ld=yes
454 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
b2449d40
CR
455 fbsd_major=`echo ${target} | sed -e 's/.*freebsd//g' | sed -e 's/\..*//g'`
456 tm_defines="${tm_defines} FBSD_MAJOR=${fbsd_major}"
4d6d5bb2
NN
457 tmake_file="t-slibgcc-elf-ver t-freebsd"
458 case ${enable_threads} in
459 no)
460 fbsd_tm_file="${fbsd_tm_file} freebsd-nthr.h"
461 ;;
769e49eb 462 "" | yes | posix)
4d6d5bb2
NN
463 thread_file='posix'
464 tmake_file="${tmake_file} t-freebsd-thread"
465 # Before 5.0, FreeBSD can't bind shared libraries to -lc
466 # when "optionally" threaded via weak pthread_* checks.
467 case ${target} in
468 *-*-freebsd[34] | *-*-freebsd[34].*)
469 tmake_file="${tmake_file} t-slibgcc-nolc-override"
470 ;;
471 esac
472 ;;
f7288899 473 *)
4d6d5bb2
NN
474 echo 'Unknown thread configuration for FreeBSD'
475 exit 1
476 ;;
477 esac
478 fbsd_tm_file="${fbsd_tm_file} freebsd-spec.h freebsd.h"
479 ;;
cfafe973 480*-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu)
4d6d5bb2 481 # Must come before *-*-gnu* (because of *-*-linux-gnu* systems).
e3029773 482 extra_parts="crtbegin.o crtbeginS.o crtbeginT.o crtend.o crtendS.o"
464aea98 483 extra_options="${extra_options} linux.opt"
e3029773
NN
484 gas=yes
485 gnu_ld=yes
486 case ${enable_threads} in
487 "" | yes | posix) thread_file='posix' ;;
488 esac
65d151a7 489 tmake_file="t-slibgcc-elf-ver t-linux"
464aea98
JM
490 case ${target} in
491 *-*-*uclibc*)
7bd85ce0
JM
492 tm_defines="${tm_defines} UCLIBC_DEFAULT=1"
493 ;;
494 *)
495 tm_defines="${tm_defines} UCLIBC_DEFAULT=0"
464aea98
JM
496 ;;
497 esac
c5dde55b
NC
498 # Assume that glibc or uClibc are being used and so __cxa_atexit is provided.
499 default_use_cxa_atexit=yes
1617e5ee 500 use_gcc_tgmath=no
e3029773 501 ;;
5eeab2e3 502*-*-gnu*)
e3029773
NN
503 # On the Hurd, the setup is just about the same on
504 # each different CPU. The specific machines that we
505 # support are matched above and just set $cpu_type.
506 tm_file="${cpu_type}/gnu.h"
507 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
508 # GNU tools are the only tools.
509 gas=yes
510 gnu_ld=yes
511 # These details are the same as for Linux.
512 # But here we need a little extra magic.
513 tmake_file="t-slibgcc-elf-ver t-linux t-gnu"
514 case ${target} in
515 alpha*)
516 tm_file="${cpu_type}/${cpu_type}.h alpha/elf.h alpha/linux.h alpha/linux-elf.h gnu.h ${tm_file}"
517 ;;
518 i[34567]86-*-*)
519 tm_file="${cpu_type}/${cpu_type}.h i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h linux.h i386/linux.h gnu.h ${tm_file}"
520 ;;
521 esac
c5dde55b
NC
522 # Assume that glibc is being used and so __cxa_atexit is provided.
523 default_use_cxa_atexit=yes
1617e5ee 524 use_gcc_tgmath=no
e3029773 525 ;;
f982f805 526*-*-netbsd*)
e3029773
NN
527 tmake_file="t-slibgcc-elf-ver t-libc-ok t-netbsd t-libgcc-pic"
528 gas=yes
529 gnu_ld=yes
51b7c247 530
e3029773
NN
531 # NetBSD 2.0 and later get POSIX threads enabled by default.
532 # Allow them to be explicitly enabled on any other version.
533 case ${enable_threads} in
534 "")
535 case ${target} in
536 *-*-netbsd[2-9]* | *-*-netbsdelf[2-9]*)
537 thread_file='posix'
538 tm_defines="${tm_defines} NETBSD_ENABLE_PTHREADS"
539 ;;
540 esac
541 ;;
542 yes | posix)
543 thread_file='posix'
544 tm_defines="${tm_defines} NETBSD_ENABLE_PTHREADS"
545 ;;
546 esac
1169f9e0 547
e3029773
NN
548 # NetBSD 1.7 and later are set up to use GCC's crtstuff for
549 # ELF configurations. We will clear extra_parts in the
550 # a.out configurations.
551 case ${target} in
552 *-*-netbsd*1.[7-9]* | *-*-netbsd[2-9]* | *-*-netbsdelf[2-9]*)
553 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
554 ;;
555 esac
2121a768 556
e3029773
NN
557 # NetBSD 2.0 and later provide __cxa_atexit(), which we use by
558 # default (unless overridden by --disable-__cxa_atexit).
559 case ${target} in
560 *-*-netbsd[2-9]* | *-*-netbsdelf[2-9]*)
561 default_use_cxa_atexit=yes
562 ;;
563 esac
564 ;;
4d6d5bb2
NN
565*-*-openbsd*)
566 tmake_file="t-libc-ok t-openbsd t-libgcc-pic"
e3029773 567 case ${enable_threads} in
4d6d5bb2 568 yes)
e3029773 569 thread_file='posix'
4d6d5bb2 570 tmake_file="${tmake_file} t-openbsd-thread"
e3029773
NN
571 ;;
572 esac
378b66d4
ME
573 case ${target} in
574 *-*-openbsd2.*|*-*-openbsd3.[012])
575 tm_defines="${tm_defines} HAS_LIBC_R=1" ;;
576 esac
e3029773 577 ;;
8179b3c8
NN
578*-*-rtems*)
579 case ${enable_threads} in
580 yes) thread_file='rtems' ;;
581 esac
582 ;;
4977bab6 583*-*-vxworks*)
e3029773 584 tmake_file=t-vxworks
2eab15c9
PE
585 xm_defines=POSIX
586 extra_options="${extra_options} vxworks.opt"
b2f4bed8 587 extra_objs=vxworks.o
55047c9d
PE
588 case ${enable_threads} in
589 no) ;;
590 "" | yes | vxworks) thread_file='vxworks' ;;
591 *) echo 'Unknown thread configuration for VxWorks'; exit 1 ;;
592 esac
e3029773 593 ;;
c5dde55b
NC
594*-*-elf)
595 # Assume that newlib is being used and so __cxa_atexit is provided.
596 default_use_cxa_atexit=yes
597 ;;
61ed06c3
HPN
598esac
599
b01bc573 600case ${target} in
61ed06c3
HPN
601# Support site-specific machine types.
602*local*)
b01bc573 603 rest=`echo ${target} | sed -e "s/$cpu_type-//"`
61ed06c3 604 tm_file=${cpu_type}/$rest.h
4dc0535b
ZW
605 if test -f $srcdir/config/${cpu_type}/xm-$rest.h
606 then xm_file=${cpu_type}/xm-$rest.h
61ed06c3 607 fi
4dc0535b
ZW
608 if test -f $srcdir/config/${cpu_type}/t-$rest
609 then tmake_file=${cpu_type}/t-$rest
61ed06c3
HPN
610 fi
611 ;;
61ed06c3
HPN
612alpha*-*-linux*)
613 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h"
614 target_cpu_default="MASK_GAS"
fbf2ca7b 615 tmake_file="${tmake_file} alpha/t-crtfm alpha/t-alpha alpha/t-ieee alpha/t-linux"
61ed06c3 616 ;;
83248d49
RM
617alpha*-*-gnu*)
618 target_cpu_default="MASK_GAS"
619 tmake_file="${tmake_file} alpha/t-crtfm alpha/t-alpha alpha/t-ieee"
620 ;;
61ed06c3 621alpha*-*-freebsd*)
9e405fe5 622 tm_file="${tm_file} ${fbsd_tm_file} alpha/elf.h alpha/freebsd.h"
61ed06c3 623 target_cpu_default="MASK_GAS"
cea3bd3e
RH
624 tmake_file="${tmake_file} alpha/t-crtfm alpha/t-alpha alpha/t-ieee"
625 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
61ed06c3
HPN
626 ;;
627alpha*-*-netbsd*)
f982f805 628 tm_file="${tm_file} netbsd.h alpha/elf.h netbsd-elf.h alpha/netbsd.h"
61ed06c3 629 target_cpu_default="MASK_GAS"
cea3bd3e 630 tmake_file="${tmake_file} alpha/t-alpha alpha/t-ieee"
61ed06c3 631 ;;
61ed06c3 632alpha*-*-openbsd*)
620b87b3 633 tm_defines="${tm_defines} OBSD_NO_DYNAMIC_LIBRARIES OBSD_HAS_DECLARE_FUNCTION_NAME OBSD_HAS_DECLARE_FUNCTION_SIZE OBSD_HAS_DECLARE_OBJECT"
ca11c37c 634 tm_file="alpha/alpha.h openbsd.h alpha/openbsd.h"
61ed06c3
HPN
635 # default x-alpha is only appropriate for dec-osf.
636 target_cpu_default="MASK_GAS"
637 tmake_file="alpha/t-alpha alpha/t-ieee"
638 ;;
c7bdf0a6 639alpha*-dec-osf[45]*)
61ed06c3
HPN
640 if test x$stabs = xyes
641 then
642 tm_file="${tm_file} dbx.h"
643 fi
644 if test x$gas != xyes
645 then
646 extra_passes="mips-tfile mips-tdump"
647 fi
648 use_collect2=yes
c7bdf0a6
ZW
649 tmake_file="alpha/t-alpha alpha/t-ieee alpha/t-crtfm alpha/t-osf4"
650 tm_file="${tm_file} alpha/osf.h"
817e13c4 651 extra_headers=va_list.h
b01bc573 652 case ${target} in
61ed06c3 653 *-*-osf4*)
d432c7a5 654 # Define TARGET_SUPPORT_ARCH except on 4.0a.
b01bc573 655 case ${target} in
c7bdf0a6 656 *-*-osf4.0a) ;;
620b87b3 657 *) tm_defines="${tm_defines} TARGET_SUPPORT_ARCH=1"
c7bdf0a6 658 esac
61ed06c3
HPN
659 ;;
660 *-*-osf5*)
c7bdf0a6 661 tm_file="${tm_file} alpha/osf5.h"
620b87b3 662 tm_defines="${tm_defines} TARGET_SUPPORT_ARCH=1"
61ed06c3
HPN
663 ;;
664 esac
769e49eb
NN
665 case ${enable_threads} in
666 "" | yes | posix)
2a4e8ebc
RO
667 thread_file='posix'
668 tmake_file="${tmake_file} alpha/t-osf-pthread"
669 ;;
670 esac
61ed06c3 671 ;;
b6bfa876 672alpha64-dec-*vms*)
cf0005c6 673 tm_file="${tm_file} alpha/vms.h alpha/vms64.h"
4977bab6 674 xm_file="alpha/xm-vms.h"
b6bfa876 675 tmake_file="alpha/t-alpha alpha/t-vms alpha/t-vms64 alpha/t-ieee"
b6bfa876
DR
676 prefix=/gnu
677 local_prefix=/gnu
678 ;;
ef057c45 679alpha*-dec-*vms*)
cf0005c6 680 tm_file="${tm_file} alpha/vms.h"
4dc0535b 681 xm_file=alpha/xm-vms.h
61ed06c3 682 tmake_file="alpha/t-alpha alpha/t-vms alpha/t-ieee"
ef057c45
DR
683 prefix=/gnu
684 local_prefix=/gnu
61ed06c3 685 ;;
2cc07db4 686arc-*-elf*)
c40409ce 687 tm_file="dbxelf.h elfos.h svr4.h ${tm_file}"
2cc07db4
RH
688 extra_parts="crtinit.o crtfini.o"
689 ;;
61ed06c3 690arm-*-coff* | armel-*-coff*)
ca11c37c 691 tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h"
315cd6b5 692 tmake_file="arm/t-arm arm/t-arm-coff"
61ed06c3 693 ;;
55047c9d 694arm-wrs-vxworks)
c447f774 695 tm_file="elfos.h arm/elf.h arm/aout.h ${tm_file} vx-common.h vxworks.h arm/vxworks.h"
2f71a20a 696 tmake_file="${tmake_file} arm/t-arm arm/t-vxworks"
55047c9d 697 ;;
cd985f66 698arm*-*-freebsd*)
5742588d 699 tm_file="dbxelf.h elfos.h ${fbsd_tm_file} arm/elf.h arm/aout.h arm/freebsd.h arm/arm.h"
2f71a20a 700 tmake_file="${tmake_file} arm/t-arm arm/t-strongarm-elf"
5742588d 701 ;;
69474c3c 702arm*-*-netbsdelf*)
ff3afb56 703 tm_file="dbxelf.h elfos.h netbsd.h netbsd-elf.h arm/elf.h arm/aout.h arm/arm.h arm/netbsd-elf.h"
2f71a20a 704 tmake_file="${tmake_file} arm/t-arm arm/t-netbsd"
69474c3c 705 ;;
61ed06c3 706arm*-*-netbsd*)
f982f805 707 tm_file="arm/aout.h arm/arm.h netbsd.h netbsd-aout.h arm/netbsd.h"
2f71a20a 708 tmake_file="t-netbsd arm/t-arm arm/t-netbsd"
1169f9e0 709 extra_parts=""
5721cd84 710 use_collect2=yes
61ed06c3 711 ;;
14879e76 712arm*-*-linux*) # ARM GNU/Linux with ELF
f7288899 713 tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h"
d3a9662c
BF
714 case $target in
715 arm*b-*)
716 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
717 ;;
718 esac
077fc835 719 tmake_file="${tmake_file} t-linux arm/t-arm"
077fc835 720 case ${target} in
464aea98 721 arm*-*-linux-*eabi)
077fc835
KH
722 tm_file="$tm_file arm/bpabi.h arm/linux-eabi.h"
723 tmake_file="$tmake_file arm/t-arm-elf arm/t-bpabi arm/t-linux-eabi"
f7288899 724 # The BPABI long long divmod functions return a 128-bit value in
077fc835
KH
725 # registers r0-r3. Correctly modeling that requires the use of
726 # TImode.
727 need_64bit_hwint=yes
728 # The EABI requires the use of __cxa_atexit.
729 default_use_cxa_atexit=yes
730 ;;
731 *)
732 tmake_file="$tmake_file arm/t-linux"
733 ;;
734 esac
735 tm_file="$tm_file arm/aout.h arm/arm.h"
bf98ec6c 736 tmake_file="${tmake_file} arm/t-arm-softfp soft-fp/t-softfp"
61ed06c3
HPN
737 ;;
738arm*-*-uclinux*) # ARM ucLinux
433d52fd 739 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/linux-gas.h arm/uclinux-elf.h"
2f71a20a 740 tmake_file="arm/t-arm arm/t-arm-elf"
c147eacb
PB
741 case ${target} in
742 arm*-*-uclinux-*eabi)
743 tm_file="$tm_file arm/bpabi.h arm/uclinux-eabi.h"
744 tmake_file="$tmake_file arm/t-bpabi"
745 # The BPABI long long divmod functions return a 128-bit value in
746 # registers r0-r3. Correctly modeling that requires the use of
747 # TImode.
748 need_64bit_hwint=yes
749 # The EABI requires the use of __cxa_atexit.
750 default_use_cxa_atexit=yes
751 esac
752 tm_file="$tm_file arm/aout.h arm/arm.h"
bf98ec6c 753 tmake_file="${tmake_file} arm/t-arm-softfp soft-fp/t-softfp"
61ed06c3 754 ;;
61ed06c3 755arm*-*-ecos-elf)
c40409ce 756 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/ecos-elf.h"
315cd6b5 757 tmake_file="arm/t-arm arm/t-arm-elf"
bf98ec6c 758 tmake_file="${tmake_file} arm/t-arm-softfp soft-fp/t-softfp"
0e5a4ad8 759 ;;
b3f8d95d 760arm*-*-eabi* | arm*-*-symbianelf* )
f7288899 761 # The BPABI long long divmod functions return a 128-bit value in
b3f8d95d
MM
762 # registers r0-r3. Correctly modeling that requires the use of
763 # TImode.
764 need_64bit_hwint=yes
e6fc6c9b 765 default_use_cxa_atexit=yes
b3f8d95d 766 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/bpabi.h"
0393a68a 767 tmake_file="arm/t-arm arm/t-arm-elf"
b3f8d95d 768 case ${target} in
f9a02408 769 arm*-*-eabi*)
8abc1906 770 tm_file="$tm_file arm/eabi.h"
f9a02408 771 tmake_file="${tmake_file} arm/t-bpabi"
8abc1906 772 extra_options="${extra_options} arm/eabi.opt"
f9a02408 773 ;;
b3f8d95d
MM
774 arm*-*-symbianelf*)
775 tm_file="${tm_file} arm/symbian.h"
f9a02408
MM
776 # We do not include t-bpabi for Symbian OS because the system
777 # provides its own implementation of the BPABI functions.
c0354bf4 778 tmake_file="${tmake_file} arm/t-symbian"
b3f8d95d
MM
779 ;;
780 esac
781 tm_file="${tm_file} arm/aout.h arm/arm.h"
bf98ec6c 782 tmake_file="${tmake_file} arm/t-arm-softfp soft-fp/t-softfp"
336bd6ac 783 ;;
f22b4bc4 784arm*-*-rtems*)
f22b4bc4 785 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/rtems-elf.h rtems.h"
70d64189 786 tmake_file="arm/t-arm arm/t-arm-elf t-rtems arm/t-rtems"
bf98ec6c 787 tmake_file="${tmake_file} arm/t-arm-softfp soft-fp/t-softfp"
f22b4bc4 788 ;;
cd985f66 789arm*-*-elf)
c40409ce 790 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h"
2f71a20a 791 tmake_file="arm/t-arm arm/t-arm-elf"
bf98ec6c 792 tmake_file="${tmake_file} arm/t-arm-softfp soft-fp/t-softfp"
61ed06c3 793 ;;
52f97a3b 794arm*-wince-pe*)
ca11c37c 795 tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h arm/pe.h arm/wince-pe.h"
2f71a20a 796 tmake_file="arm/t-arm arm/t-wince-pe"
c54c7322 797 extra_options="${extra_options} arm/pe.opt"
52f97a3b
NC
798 extra_objs="pe.o"
799 ;;
61ed06c3 800arm-*-pe*)
ca11c37c 801 tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h arm/pe.h"
2f71a20a 802 tmake_file="arm/t-arm arm/t-pe"
c54c7322 803 extra_options="${extra_options} arm/pe.opt"
61ed06c3
HPN
804 extra_objs="pe.o"
805 ;;
63933fc3
RC
806avr-*-rtems*)
807 tm_file="avr/avr.h dbxelf.h avr/rtems.h rtems.h"
91ff9507 808 tmake_file="avr/t-avr t-rtems avr/t-rtems"
63933fc3 809 ;;
61ed06c3 810avr-*-*)
ca11c37c 811 tm_file="avr/avr.h dbxelf.h"
61ed06c3 812 ;;
0d4a78eb
BS
813bfin*-elf*)
814 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h"
6bad46f7
JZ
815 tmake_file=bfin/t-bfin-elf
816 use_collect2=no
817 ;;
1f4174d4 818bfin*-uclinux*)
cfb6473a 819 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h linux.h bfin/uclinux.h"
6bad46f7
JZ
820 tmake_file=bfin/t-bfin-uclinux
821 tm_defines="${tm_defines} UCLIBC_DEFAULT=1"
cfb6473a 822 extra_options="${extra_options} linux.opt"
6bad46f7
JZ
823 use_collect2=no
824 ;;
344189f9 825bfin*-linux-uclibc*)
ea2382be 826 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h linux.h bfin/linux.h ./linux-sysroot-suffix.h"
6bad46f7
JZ
827 tmake_file="t-slibgcc-elf-ver bfin/t-bfin-linux"
828 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
829 use_collect2=no
830 ;;
152167d5
RC
831bfin*-rtems*)
832 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h bfin/rtems.h rtems.h"
833 tmake_file="bfin/t-bfin t-rtems bfin/t-rtems"
6bad46f7 834 ;;
0d4a78eb
BS
835bfin*-*)
836 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h"
6bad46f7
JZ
837 tmake_file=bfin/t-bfin
838 use_collect2=no
839 ;;
99c5227a
HPN
840crisv32-*-elf | crisv32-*-none)
841 tm_file="dbxelf.h elfos.h ${tm_file}"
842 tmake_file="cris/t-cris"
843 target_cpu_default=32
844 gas=yes
845 extra_options="${extra_options} cris/elf.opt"
846 ;;
0b85d816 847cris-*-elf | cris-*-none)
c40409ce 848 tm_file="dbxelf.h elfos.h ${tm_file}"
0b85d816
HPN
849 tmake_file="cris/t-cris cris/t-elfmulti"
850 gas=yes
2a186d97 851 extra_options="${extra_options} cris/elf.opt"
0b85d816 852 ;;
99c5227a 853crisv32-*-linux* | cris-*-linux*)
c40409ce 854 tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h cris/linux.h"
65d151a7 855 # We need to avoid using t-linux, so override default tmake_file
3fc87ac1 856 tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux"
2a186d97 857 extra_options="${extra_options} cris/linux.opt"
99c5227a
HPN
858 case $target in
859 cris-*-*)
860 target_cpu_default=10
861 ;;
862 crisv32-*-*)
863 target_cpu_default=32
864 ;;
865 esac
0b85d816 866 ;;
db869733
PW
867crx-*-elf)
868 tm_file="elfos.h ${tm_file}"
869 extra_parts="crtbegin.o crtend.o"
870 use_collect2=no
871 ;;
61ed06c3 872fr30-*-elf)
c40409ce 873 tm_file="dbxelf.h elfos.h svr4.h ${tm_file}"
61ed06c3
HPN
874 tmake_file=fr30/t-fr30
875 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
876 ;;
36a05131
BS
877frv-*-elf)
878 tm_file="dbxelf.h elfos.h svr4.h ${tm_file} frv/frv-abi.h"
879 tmake_file=frv/t-frv
880 ;;
34208acf
AO
881frv-*-*linux*)
882 tm_file="dbxelf.h elfos.h svr4.h ${tm_file} \
883 linux.h frv/linux.h frv/frv-abi.h"
65d151a7 884 tmake_file="${tmake_file} frv/t-frv frv/t-linux"
34208acf 885 ;;
4c5bf198
RC
886h8300-*-rtems*)
887 tmake_file="h8300/t-h8300 h8300/t-elf t-rtems h8300/t-rtems"
888 tm_file="h8300/h8300.h dbxelf.h elfos.h h8300/elf.h h8300/rtems.h rtems.h"
889 ;;
9f5b774b
R
890h8300-*-elf*)
891 tmake_file="h8300/t-h8300 h8300/t-elf"
ca11c37c 892 tm_file="h8300/h8300.h dbxelf.h elfos.h h8300/elf.h"
9f5b774b 893 ;;
61ed06c3 894h8300-*-*)
ca11c37c 895 tm_file="h8300/h8300.h dbxcoff.h h8300/coff.h"
61ed06c3 896 ;;
cd985f66 897hppa*64*-*-linux*)
d711cf67 898 target_cpu_default="MASK_PA_11|MASK_PA_20"
581d9404
JDA
899 tm_file="pa/pa64-start.h ${tm_file} dbxelf.h elfos.h svr4.h linux.h \
900 pa/pa-linux.h pa/pa64-regs.h pa/pa-64.h pa/pa64-linux.h"
65d151a7 901 tmake_file="${tmake_file} pa/t-linux64"
c21a2372 902 gas=yes gnu_ld=yes
4977bab6 903 need_64bit_hwint=yes
c21a2372 904 ;;
cd985f66 905hppa*-*-linux*)
d711cf67 906 target_cpu_default="MASK_PA_11|MASK_NO_SPACE_REGS"
c40409ce 907 tm_file="${tm_file} dbxelf.h elfos.h svr4.h linux.h pa/pa-linux.h \
c21a2372 908 pa/pa32-regs.h pa/pa32-linux.h"
65d151a7 909 tmake_file="${tmake_file} pa/t-linux"
4720d5ca
JDA
910 # Set the libgcc version number
911 if test x$sjlj = x1; then
912 tmake_file="$tmake_file pa/t-slibgcc-sjlj-ver"
913 else
914 tmake_file="$tmake_file pa/t-slibgcc-dwarf-ver"
8c958ed2 915 fi
61ed06c3 916 ;;
ca11c37c
ZW
917# port not yet contributed.
918#hppa*-*-openbsd*)
d711cf67 919# target_cpu_default="MASK_PA_11"
ca11c37c 920# ;;
d711cf67
JDA
921hppa[12]*-*-hpux10*)
922 case ${target} in
923 hppa1.1-*-* | hppa2*-*-*)
924 target_cpu_default="MASK_PA_11"
925 ;;
926 esac
927 tm_file="${tm_file} pa/pa32-regs.h dbxelf.h pa/som.h \
928 pa/pa-hpux.h pa/pa-hpux10.h"
66617831 929 extra_options="${extra_options} pa/pa-hpux.opt"
d711cf67
JDA
930 case ${target} in
931 *-*-hpux10.[1-9]*)
932 tm_file="${tm_file} pa/pa-hpux1010.h"
66617831 933 extra_options="${extra_options} pa/pa-hpux1010.opt"
d711cf67 934 ;;
61ed06c3 935 esac
5a1a4450 936 tmake_file="pa/t-pa-hpux10 pa/t-pa-hpux pa/t-hpux-shlib"
615be2cf
NN
937 case ${enable_threads} in
938 "")
939 if test x$have_pthread_h = xyes ; then
940 tmake_file="${tmake_file} pa/t-dce-thr"
941 fi
942 ;;
943 yes | dce)
944 tmake_file="${tmake_file} pa/t-dce-thr"
945 ;;
61ed06c3 946 esac
4720d5ca
JDA
947 # Set the libgcc version number
948 if test x$sjlj = x1; then
949 tmake_file="$tmake_file pa/t-slibgcc-sjlj-ver"
950 else
951 tmake_file="$tmake_file pa/t-slibgcc-dwarf-ver"
9fb1c9db 952 fi
61ed06c3 953 use_collect2=yes
543b6009 954 gas=yes
61ed06c3
HPN
955 ;;
956hppa*64*-*-hpux11*)
d711cf67 957 target_cpu_default="MASK_PA_11|MASK_PA_20"
7b79fe71
JDA
958 if test x$gnu_ld = xyes
959 then
d711cf67 960 target_cpu_default="${target_cpu_default}|MASK_GNU_LD"
7b79fe71 961 fi
543b6009
SE
962 tm_file="pa/pa64-start.h ${tm_file} dbxelf.h elfos.h \
963 pa/pa64-regs.h pa/pa-hpux.h pa/pa-hpux1010.h \
964 pa/pa-hpux11.h"
d711cf67 965 case ${target} in
1fb641a1 966 *-*-hpux11.[1-9]*)
d711cf67 967 tm_file="${tm_file} pa/pa-hpux1111.h pa/pa-64.h pa/pa64-hpux.h"
66617831 968 extra_options="${extra_options} pa/pa-hpux1111.opt"
d711cf67
JDA
969 ;;
970 *)
971 tm_file="${tm_file} pa/pa-64.h pa/pa64-hpux.h"
972 ;;
973 esac
66617831
RS
974 extra_options="${extra_options} pa/pa-hpux.opt \
975 pa/pa-hpux1010.opt pa/pa64-hpux.opt"
4977bab6 976 need_64bit_hwint=yes
3f0b8b66 977 tmake_file="pa/t-pa64 pa/t-pa-hpux pa/t-hpux-shlib"
4720d5ca
JDA
978 # Set the libgcc version number
979 if test x$sjlj = x1; then
980 tmake_file="$tmake_file pa/t-slibgcc-sjlj-ver"
981 else
982 tmake_file="$tmake_file pa/t-slibgcc-dwarf-ver"
9fb1c9db 983 fi
8b89a26a
JDA
984 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o \
985 libgcc_stub.a"
7e2055ec 986 case x${enable_threads} in
27ca3a61 987 x | xyes | xposix )
f7288899 988 thread_file=posix
7e2055ec
ZW
989 ;;
990 esac
543b6009 991 gas=yes
61ed06c3 992 ;;
d711cf67
JDA
993hppa[12]*-*-hpux11*)
994 case ${target} in
995 hppa1.1-*-* | hppa2*-*-*)
996 target_cpu_default="MASK_PA_11"
997 ;;
998 esac
999 tm_file="${tm_file} pa/pa32-regs.h dbxelf.h pa/som.h \
66617831
RS
1000 pa/pa-hpux.h pa/pa-hpux1010.h pa/pa-hpux11.h"
1001 extra_options="${extra_options} pa/pa-hpux.opt pa/pa-hpux1010.opt"
d711cf67
JDA
1002 case ${target} in
1003 *-*-hpux11.[1-9]*)
1004 tm_file="${tm_file} pa/pa-hpux1111.h"
66617831 1005 extra_options="${extra_options} pa/pa-hpux1111.opt"
7e2055ec
ZW
1006 ;;
1007 esac
5a1a4450 1008 tmake_file="pa/t-pa-hpux11 pa/t-pa-hpux pa/t-hpux-shlib"
4720d5ca
JDA
1009 # Set the libgcc version number
1010 if test x$sjlj = x1; then
1011 tmake_file="$tmake_file pa/t-slibgcc-sjlj-ver"
1012 else
1013 tmake_file="$tmake_file pa/t-slibgcc-dwarf-ver"
9fb1c9db 1014 fi
7e2055ec 1015 case x${enable_threads} in
27ca3a61 1016 x | xyes | xposix )
f7288899 1017 thread_file=posix
7e2055ec
ZW
1018 ;;
1019 esac
61ed06c3 1020 use_collect2=yes
543b6009 1021 gas=yes
61ed06c3 1022 ;;
b069de3b 1023i[34567]86-*-darwin*)
f7288899 1024 need_64bit_hwint=yes
703706d7
GK
1025
1026 # This is so that '.../configure && make' doesn't fail due to
1027 # config.guess deciding that the configuration is i386-*-darwin* and
1028 # then this file using that to set --with-cpu=i386 which has no -m64
1029 # support.
703706d7 1030 with_cpu=${with_cpu:-generic}
ff473280 1031 tmake_file="${tmake_file} i386/t-crtpc i386/t-crtfm"
b069de3b 1032 ;;
9519e677 1033x86_64-*-darwin*)
9519e677 1034 with_cpu=${with_cpu:-generic}
ab442df7 1035 tmake_file="${tmake_file} t-darwin ${cpu_type}/t-darwin64 t-slibgcc-darwin i386/t-crtpc i386/t-crtfm"
9519e677
EC
1036 tm_file="${tm_file} ${cpu_type}/darwin64.h"
1037 ;;
61ed06c3 1038i[34567]86-*-elf*)
39ed301b 1039 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h"
ab442df7 1040 tmake_file="${tmake_file} i386/t-i386elf t-svr4"
a10dc289
HK
1041 ;;
1042x86_64-*-elf*)
1043 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h i386/x86-64.h"
ab442df7 1044 tmake_file="${tmake_file} i386/t-i386elf t-svr4"
61ed06c3 1045 ;;
61ed06c3 1046i[34567]86-*-aout*)
39ed301b 1047 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/gstabs.h i386/i386-aout.h"
61ed06c3 1048 ;;
61ed06c3 1049i[34567]86-*-freebsd*)
39ed301b 1050 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${fbsd_tm_file} i386/freebsd.h"
e564e618
DB
1051 ;;
1052x86_64-*-freebsd*)
39ed301b 1053 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${fbsd_tm_file} i386/x86-64.h i386/freebsd.h i386/freebsd64.h"
d3ef67ea 1054 tmake_file="${tmake_file} i386/t-crtstuff"
61ed06c3 1055 ;;
6ea0279f 1056i[34567]86-*-netbsdelf*)
39ed301b 1057 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-elf.h i386/netbsd-elf.h"
6ea0279f 1058 ;;
61ed06c3 1059i[34567]86-*-netbsd*)
39ed301b 1060 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/gstabs.h netbsd.h netbsd-aout.h i386/netbsd.h"
ab442df7 1061 tmake_file="${tmake_file} t-netbsd"
1169f9e0 1062 extra_parts=""
5721cd84 1063 use_collect2=yes
61ed06c3 1064 ;;
7c884404 1065x86_64-*-netbsd*)
39ed301b 1066 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-elf.h i386/x86-64.h i386/netbsd64.h"
d3ef67ea 1067 tmake_file="${tmake_file} i386/t-crtstuff"
7c884404 1068 ;;
378b66d4 1069i[34567]86-*-openbsd2.*|i[34567]86-*openbsd3.[0123])
ca11c37c 1070 tm_file="i386/i386.h i386/unix.h i386/bsd.h i386/gas.h i386/gstabs.h openbsd-oldgas.h openbsd.h i386/openbsd.h"
f1cf4606 1071 # needed to unconfuse gdb
ab442df7 1072 tmake_file="${tmake_file} t-libc-ok t-openbsd i386/t-openbsd"
61ed06c3
HPN
1073 # we need collect2 until our bug is fixed...
1074 use_collect2=yes
1075 ;;
378b66d4 1076i[34567]86-*-openbsd*)
75a3bd9d 1077 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h"
378b66d4
ME
1078 tm_file="${tm_file} openbsd.h i386/openbsdelf.h"
1079 gas=yes
1080 gnu_ld=yes
378b66d4 1081 ;;
61ed06c3 1082i[34567]86-*-coff*)
39ed301b 1083 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/i386-coff.h"
61ed06c3 1084 ;;
cfafe973
RM
1085i[34567]86-*-linux* | i[34567]86-*-kfreebsd*-gnu | i[34567]86-*-knetbsd*-gnu)
1086 # Intel 80386's running GNU/*
61ed06c3 1087 # with ELF format using glibc 2
0f45f0f5 1088 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h linux.h"
cfafe973 1089 case ${target} in
0f45f0f5
JM
1090 i[34567]86-*-linux*)
1091 if test x$enable_targets = xall; then
1092 tm_file="${tm_file} i386/x86-64.h i386/linux64.h"
1093 tm_defines="${tm_defines} TARGET_BI_ARCH=1"
ff473280 1094 tmake_file="${tmake_file} i386/t-linux64"
0f45f0f5 1095 need_64bit_hwint=yes
0f45f0f5 1096 case X"${with_cpu}" in
aafc814c 1097 Xgeneric|Xcore2|Xnocona|Xx86-64|Xamdfam10|Xbarcelona|Xk8|Xopteron|Xathlon64|Xathlon-fx)
0f45f0f5
JM
1098 ;;
1099 X)
8981c15b
JM
1100 if test x$with_cpu_64 = x; then
1101 with_cpu_64=generic
1102 fi
0f45f0f5
JM
1103 ;;
1104 *)
1105 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2
aafc814c 1106 echo "generic core2 nocona x86-64 amdfam10 barcelona k8 opteron athlon64 athlon-fx" 1>&2
0f45f0f5
JM
1107 exit 1
1108 ;;
1109 esac
1110 else
1111 tm_file="${tm_file} i386/linux.h"
1112 fi
1113 ;;
1114 i[34567]86-*-knetbsd*-gnu) tm_file="${tm_file} i386/linux.h knetbsd-gnu.h i386/knetbsd-gnu.h" ;;
1115 i[34567]86-*-kfreebsd*-gnu) tm_file="${tm_file} i386/linux.h kfreebsd-gnu.h i386/kfreebsd-gnu.h" ;;
cfafe973 1116 esac
577565f9 1117 tmake_file="${tmake_file} i386/t-crtstuff i386/t-crtpc i386/t-crtfm t-dfprules"
61ed06c3 1118 ;;
44379973 1119x86_64-*-linux* | x86_64-*-kfreebsd*-gnu | x86_64-*-knetbsd*-gnu)
39ed301b 1120 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h linux.h \
32fb7c9d 1121 i386/x86-64.h i386/linux64.h"
44379973
RM
1122 case ${target} in
1123 x86_64-*-kfreebsd*-gnu) tm_file="${tm_file} kfreebsd-gnu.h" ;;
1124 x86_64-*-knetbsd*-gnu) tm_file="${tm_file} knetbsd-gnu.h" ;;
1125 esac
ff473280 1126 tmake_file="${tmake_file} i386/t-linux64 i386/t-crtstuff i386/t-crtpc i386/t-crtfm t-dfprules"
14f73b5a 1127 ;;
61ed06c3 1128i[34567]86-*-gnu*)
61ed06c3 1129 ;;
61ed06c3
HPN
1130i[34567]86-pc-msdosdjgpp*)
1131 xm_file=i386/xm-djgpp.h
267409e8 1132 tm_file="dbxcoff.h ${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/djgpp.h"
ab442df7 1133 tmake_file="${tmake_file} i386/t-djgpp"
6ac49599 1134 extra_options="${extra_options} i386/djgpp.opt"
61ed06c3
HPN
1135 gnu_ld=yes
1136 gas=yes
61ed06c3 1137 ;;
61ed06c3 1138i[34567]86-*-lynxos*)
4f587cb0
AN
1139 xm_defines=POSIX
1140 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/lynx.h lynx.h"
ab442df7 1141 tmake_file="${tmake_file} i386/t-crtstuff t-lynx"
4f587cb0 1142 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
6ac49599 1143 extra_options="${extra_options} lynx.opt"
4f587cb0
AN
1144 thread_file=lynx
1145 gnu_ld=yes
1146 gas=yes
61ed06c3 1147 ;;
61fec9ff 1148i[3456x]86-*-netware*)
f199d860 1149 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h tm-dwarf2.h i386/netware.h"
ab442df7 1150 tmake_file="${tmake_file} i386/t-netware"
61fec9ff
JB
1151 extra_objs=netware.o
1152 case /${with_ld} in
1153 */nwld)
1154 extra_objs="$extra_objs nwld.o"
1155 tm_file="${tm_file} i386/nwld.h"
1156 tmake_file="${tmake_file} i386/t-nwld"
1157 extra_parts="crt0.o libgcc.def libc.def libcpre.def posixpre.def"
1158 ;;
1159 esac
1160 case x${enable_threads} in
1161 x | xyes | xposix) thread_file='posix';;
1162 xnks) thread_file='nks';;
1163 xno) ;;
1164 *) echo 'Unknown thread configuration for NetWare' >&2; exit 1;;
1165 esac
1166 ;;
f2feed2c 1167i[34567]86-*-nto-qnx*)
ca11c37c 1168 tm_file="${tm_file} i386/att.h dbxelf.h tm-dwarf2.h elfos.h svr4.h i386/unix.h i386/nto.h"
ab442df7 1169 tmake_file="${tmake_file} i386/t-nto"
f2feed2c
GP
1170 gnu_ld=yes
1171 gas=yes
1172 ;;
c7bdf0a6 1173i[34567]86-*-rtems*)
39ed301b 1174 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h i386/rtemself.h rtems.h"
61ed06c3 1175 extra_parts="crtbegin.o crtend.o crti.o crtn.o"
ab442df7 1176 tmake_file="${tmake_file} i386/t-rtems-i386 i386/t-crtstuff t-rtems"
61ed06c3 1177 ;;
61ed06c3 1178i[34567]86-*-solaris2*)
18167442
EB
1179 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h svr4.h i386/sysv4.h sol2.h"
1180 case ${target} in
ec23ed60
EB
1181 *-*-solaris2.1[0-9]*)
1182 tm_file="${tm_file} sol2-10.h"
1183 ;;
18167442
EB
1184 esac
1185 tm_file="${tm_file} i386/sol2.h"
ab442df7
MM
1186 tmake_file="${tmake_file} t-sol2 i386/t-sol2 t-svr4"
1187 c_target_objs="${c_target_objs} sol2-c.o"
1188 cxx_target_objs="${cxx_target_objs} sol2-c.o"
07a43492
DJ
1189 extra_objs="sol2.o"
1190 tm_p_file="${tm_p_file} sol2-protos.h"
7b3a4df5
RH
1191 if test x$gnu_ld = xyes; then
1192 tmake_file="$tmake_file t-slibgcc-elf-ver"
a8e68029 1193 tm_defines="${tm_defines} TARGET_GNU_LD=1"
7b3a4df5
RH
1194 else
1195 tmake_file="$tmake_file t-slibgcc-sld"
1196 fi
79387e57
RS
1197 if test x$gas = xyes; then
1198 tm_file="usegas.h ${tm_file}"
1199 fi
cd985f66 1200 tm_file="$tm_file tm-dwarf2.h"
a8e68029 1201 case ${target} in
f42eccdb 1202 *-*-solaris2.1[0-9]*)
a8e68029
DJ
1203 tm_file="${tm_file} i386/x86-64.h i386/sol2-10.h"
1204 tm_defines="${tm_defines} TARGET_BI_ARCH=1"
d3ef67ea 1205 tmake_file="$tmake_file i386/t-crtstuff i386/t-sol2-10"
a8e68029 1206 need_64bit_hwint=yes
28a026d9 1207 case X"${with_cpu}" in
aafc814c 1208 Xgeneric|Xcore2|Xnocona|Xx86-64|Xamdfam10|Xbarcelona|Xk8|Xopteron|Xathlon64|Xathlon-fx)
28a026d9
L
1209 ;;
1210 X)
8981c15b
JM
1211 if test x$with_cpu_64 = x; then
1212 with_cpu_64=generic
1213 fi
28a026d9
L
1214 ;;
1215 *)
1216 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2
aafc814c 1217 echo "generic core2 nocona x86-64 amdfam10 barcelona k8 opteron athlon64 athlon-fx" 1>&2
28a026d9
L
1218 exit 1
1219 ;;
1220 esac
f7288899 1221 # Solaris 2.10 provides crt1.o, crti.o, crtn.o, and gcrt1.o as
a8e68029
DJ
1222 # part of the base system.
1223 extra_parts="gmon.o crtbegin.o crtend.o"
1224 ;;
1225 *)
1226 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
1227 ;;
1228 esac
615be2cf 1229 case ${enable_threads}:${have_pthread_h}:${have_thread_h} in
18167442 1230 "":yes:* | yes:yes:* )
cd985f66 1231 thread_file=posix
18167442
EB
1232 ;;
1233 "":*:yes | yes:*:yes )
1234 thread_file=solaris
1235 ;;
615be2cf 1236 esac
61ed06c3 1237 ;;
d442d7d9 1238i[4567]86-wrs-vxworks|i[4567]86-wrs-vxworksae)
f4de8ba6 1239 tm_file="${tm_file} i386/unix.h i386/att.h elfos.h svr4.h vx-common.h"
d442d7d9
PE
1240 case ${target} in
1241 *-vxworksae*)
f4de8ba6 1242 tm_file="${tm_file} vxworksae.h i386/vx-common.h i386/vxworksae.h"
d442d7d9
PE
1243 tmake_file="${tmake_file} i386/t-vxworks i386/t-vxworksae"
1244 ;;
1245 *)
f4de8ba6 1246 tm_file="${tm_file} vxworks.h i386/vx-common.h i386/vxworks.h"
d442d7d9
PE
1247 tmake_file="${tmake_file} i386/t-vxworks"
1248 ;;
1249 esac
55047c9d 1250 ;;
61ed06c3 1251i[34567]86-*-pe | i[34567]86-*-cygwin*)
70e5e841 1252 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygming.h i386/cygwin.h"
4dc0535b 1253 xm_file=i386/xm-cygwin.h
ab442df7 1254 tmake_file="${tmake_file} i386/t-cygwin i386/t-cygming"
90aa6719 1255 target_gtfiles="\$(srcdir)/config/i386/winnt.c"
6ac49599 1256 extra_options="${extra_options} i386/cygming.opt"
43d9ad1d 1257 extra_objs="winnt.o winnt-stubs.o"
ab442df7
MM
1258 c_target_objs="${c_target_objs} cygwin2.o msformat-c.o"
1259 cxx_target_objs="${cxx_target_objs} cygwin2.o winnt-cxx.o msformat-c.o"
30500d84 1260 extra_gcc_objs=cygwin1.o
61ed06c3 1261 if test x$enable_threads = xyes; then
70e5e841 1262 thread_file='posix'
61ed06c3 1263 fi
61ed06c3 1264 ;;
e8930cc1 1265i[34567]86-*-mingw* | x86_64-*-mingw*)
70e5e841 1266 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygming.h i386/mingw32.h"
4dc0535b 1267 xm_file=i386/xm-mingw32.h
ab442df7 1268 tmake_file="${tmake_file} i386/t-cygming i386/t-mingw32"
90aa6719 1269 target_gtfiles="\$(srcdir)/config/i386/winnt.c"
6ac49599 1270 extra_options="${extra_options} i386/cygming.opt"
43d9ad1d 1271 extra_objs="winnt.o winnt-stubs.o"
ab442df7
MM
1272 c_target_objs="${c_target_objs} msformat-c.o"
1273 cxx_target_objs="${cxx_target_objs} winnt-cxx.o msformat-c.o"
97388150 1274 default_use_cxa_atexit=yes
50c0d3fd 1275 case ${enable_threads} in
e1a1c424
NC
1276 "" | yes | win32)
1277 thread_file='win32'
1278 tmake_file="${tmake_file} i386/t-gthr-win32"
1279 ;;
50c0d3fd 1280 esac
b01bc573 1281 case ${target} in
e8930cc1
KT
1282 x86_64-*-mingw*)
1283 tmake_file="${tmake_file} i386/t-crtfm"
61ed06c3 1284 ;;
e8930cc1
KT
1285 *)
1286 ;;
1287 esac
1288 case ${target} in
1289 *mingw32crt*)
1290 tm_file="${tm_file} i386/crtdll.h"
1291 ;;
1292 *mingw32msv* | *mingw*)
09eaf5a5 1293 ;;
61ed06c3
HPN
1294 esac
1295 ;;
04cec1a7 1296i[34567]86-*-interix3*)
39ed301b 1297 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/i386-interix.h i386/i386-interix3.h interix.h interix3.h"
ab442df7 1298 tmake_file="${tmake_file} i386/t-interix"
84512347 1299 extra_objs=winnt.o
90aa6719 1300 target_gtfiles="\$(srcdir)/config/i386/winnt.c"
04cec1a7
DR
1301 if test x$enable_threads = xyes ; then
1302 thread_file='posix'
1303 fi
1304 if test x$stabs = xyes ; then
1305 tm_file="${tm_file} dbxcoff.h"
1306 fi
1307 ;;
61ed06c3 1308ia64*-*-elf*)
c40409ce 1309 tm_file="${tm_file} dbxelf.h elfos.h ia64/sysv4.h ia64/elf.h"
61ed06c3
HPN
1310 tmake_file="ia64/t-ia64"
1311 target_cpu_default="0"
1312 if test x$gas = xyes
1313 then
1314 target_cpu_default="${target_cpu_default}|MASK_GNU_AS"
1315 fi
1316 if test x$gnu_ld = xyes
1317 then
1318 target_cpu_default="${target_cpu_default}|MASK_GNU_LD"
1319 fi
32b4f6f4 1320 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtfastmath.o"
61ed06c3 1321 ;;
243a7070 1322ia64*-*-freebsd*)
fee42cc1 1323 tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} ia64/sysv4.h ia64/freebsd.h"
243a7070
DB
1324 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD"
1325 tmake_file="${tmake_file} ia64/t-ia64"
32b4f6f4 1326 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtfastmath.o"
243a7070 1327 ;;
61ed06c3 1328ia64*-*-linux*)
c40409ce 1329 tm_file="${tm_file} dbxelf.h elfos.h svr4.h linux.h ia64/sysv4.h ia64/linux.h"
443728bb
L
1330 tmake_file="${tmake_file} ia64/t-ia64 t-libunwind ia64/t-glibc"
1331 if test x$with_system_libunwind != xyes ; then
1332 tmake_file="${tmake_file} t-libunwind-elf ia64/t-glibc-libunwind"
1333 fi
61ed06c3 1334 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD"
32b4f6f4 1335 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtfastmath.o"
61ed06c3 1336 ;;
7e5b9908 1337ia64*-*-hpux*)
c15c90bb 1338 tm_file="${tm_file} dbxelf.h elfos.h svr4.h ia64/sysv4.h ia64/hpux.h"
23c108af 1339 tmake_file="ia64/t-ia64 ia64/t-hpux"
7e5b9908 1340 target_cpu_default="MASK_GNU_AS"
7e2055ec 1341 case x$enable_threads in
79e8b6c0 1342 x | xyes | xposix )
7e2055ec
ZW
1343 thread_file=posix
1344 ;;
1345 esac
cad61762 1346 use_collect2=no
34c1864f
SE
1347 c_target_objs="ia64-c.o"
1348 cxx_target_objs="ia64-c.o"
dbdd120f 1349 extra_options="${extra_options} ia64/ilp32.opt"
7e5b9908 1350 ;;
6b3d1e47 1351iq2000*-*-elf*)
ca11c37c 1352 tm_file="svr4.h elfos.h iq2000/iq2000.h"
6b3d1e47
SC
1353 tmake_file=iq2000/t-iq2000
1354 out_file=iq2000/iq2000.c
6b3d1e47
SC
1355 md_file=iq2000/iq2000.md
1356 ;;
61ed06c3 1357m32r-*-elf*)
c40409ce 1358 tm_file="dbxelf.h elfos.h svr4.h ${tm_file}"
3a30516d 1359 extra_parts="crtinit.o crtfini.o"
37ec8b7a 1360 ;;
ad126521
KI
1361m32rle-*-elf*)
1362 tm_file="dbxelf.h elfos.h svr4.h m32r/little.h ${tm_file}"
1363 extra_parts="crtinit.o crtfini.o m32rx/crtinit.o m32rx/crtfini.o"
ad126521
KI
1364 ;;
1365m32r-*-linux*)
1366 tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} m32r/linux.h"
65d151a7 1367 # We override the tmake_file for linux -- why?
986ce408 1368 tmake_file="t-slibgcc-elf-ver m32r/t-linux"
ad126521 1369 gnu_ld=yes
ad126521
KI
1370 if test x$enable_threads = xyes; then
1371 thread_file='posix'
1372 fi
1373 ;;
1374m32rle-*-linux*)
1375 tm_file="dbxelf.h elfos.h svr4.h linux.h m32r/little.h ${tm_file} m32r/linux.h"
65d151a7 1376 # We override the tmake_file for linux -- why?
986ce408 1377 tmake_file="t-slibgcc-elf-ver m32r/t-linux"
ad126521 1378 gnu_ld=yes
ad126521
KI
1379 if test x$enable_threads = xyes; then
1380 thread_file='posix'
1381 fi
1382 ;;
61ed06c3
HPN
1383# m68hc11 and m68hc12 share the same machine description.
1384m68hc11-*-*|m6811-*-*)
a929bc28 1385 tm_file="dbxelf.h elfos.h usegas.h m68hc11/m68hc11.h"
61ed06c3
HPN
1386 tm_p_file="m68hc11/m68hc11-protos.h"
1387 md_file="m68hc11/m68hc11.md"
1388 out_file="m68hc11/m68hc11.c"
a929bc28 1389 tmake_file="m68hc11/t-m68hc11"
61ed06c3
HPN
1390 ;;
1391m68hc12-*-*|m6812-*-*)
a929bc28 1392 tm_file="m68hc11/m68hc12.h dbxelf.h elfos.h usegas.h m68hc11/m68hc11.h"
61ed06c3 1393 tm_p_file="m68hc11/m68hc11-protos.h"
61ed06c3
HPN
1394 md_file="m68hc11/m68hc11.md"
1395 out_file="m68hc11/m68hc11.c"
a929bc28 1396 tmake_file="m68hc11/t-m68hc11"
df3a97a8 1397 extra_options="${extra_options} m68hc11/m68hc11.opt"
61ed06c3 1398 ;;
61ed06c3 1399m68k-*-aout*)
59fbf3cb 1400 default_m68k_cpu=68020
10e96df4
NS
1401 default_cf_cpu=5206
1402 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-mlibs"
a96533d5 1403 tm_file="${tm_file} m68k/m68k-none.h m68k/m68kemb.h m68k/m68k-aout.h libgloss.h"
61ed06c3
HPN
1404 ;;
1405m68k-*-coff*)
59fbf3cb 1406 default_m68k_cpu=68020
10e96df4
NS
1407 default_cf_cpu=5206
1408 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-mlibs"
cf909b0d 1409 tm_defines="${tm_defines} MOTOROLA=1"
a96533d5 1410 tm_file="${tm_file} m68k/m68k-none.h m68k/m68kemb.h dbxcoff.h m68k/coff.h dbx.h"
61ed06c3 1411 ;;
cd985f66 1412m68k-*-elf* | fido-*-elf*)
7d33c31d
KH
1413 case ${target} in
1414 fido-*-elf*)
1415 # Check that $with_cpu makes sense.
1416 case $with_cpu in
1417 "" | "fidoa")
1418 ;;
1419 *)
1420 echo "Cannot accept --with-cpu=$with_cpu"
1421 exit 1
1422 ;;
1423 esac
1424 with_cpu=fidoa
1425 ;;
1426 *)
1427 default_m68k_cpu=68020
1428 default_cf_cpu=5206
1429 ;;
1430 esac
a96533d5 1431 tm_file="${tm_file} m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h m68k/m68kemb.h m68k/m68020-elf.h"
cf909b0d 1432 tm_defines="${tm_defines} MOTOROLA=1"
7d33c31d
KH
1433 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-m68kelf"
1434 # Add multilibs for targets other than fido.
1435 case ${target} in
1436 fido-*-elf*)
1437 ;;
1438 *)
1439 tmake_file="$tmake_file m68k/t-mlibs"
1440 ;;
1441 esac
bb8602be 1442 extra_parts="crtbegin.o crtend.o"
61ed06c3 1443 ;;
cd985f66 1444m68k*-*-netbsdelf*)
59fbf3cb 1445 default_m68k_cpu=68020
10e96df4 1446 default_cf_cpu=5475
2fd95d71 1447 tm_file="${tm_file} dbxelf.h elfos.h netbsd.h netbsd-elf.h m68k/netbsd-elf.h"
cf909b0d 1448 tm_defines="${tm_defines} MOTOROLA=1"
2fd95d71 1449 ;;
7ea98c5a 1450m68k*-*-openbsd*)
59fbf3cb 1451 default_m68k_cpu=68020
10e96df4 1452 default_cf_cpu=5475
7ea98c5a 1453 # needed to unconfuse gdb
59fbf3cb 1454 tm_defines="${tm_defines} OBSD_OLD_GAS"
a96533d5 1455 tm_file="${tm_file} openbsd.h m68k/openbsd.h"
7ea98c5a
GN
1456 tmake_file="t-libc-ok t-openbsd m68k/t-openbsd"
1457 # we need collect2 until our bug is fixed...
1458 use_collect2=yes
1459 ;;
4529dbf1
RS
1460m68k-*-uclinuxoldabi*) # Motorola m68k/ColdFire running uClinux
1461 # with uClibc, using the original
1462 # m68k-elf-based ABI
1463 default_m68k_cpu=68020
10e96df4 1464 default_cf_cpu=5206
a96533d5 1465 tm_file="${tm_file} m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h m68k/uclinux-oldabi.h"
cf909b0d 1466 tm_defines="${tm_defines} MOTOROLA=1"
47b41fa3 1467 tmake_file="m68k/t-floatlib m68k/t-uclinux"
4529dbf1
RS
1468 ;;
1469m68k-*-uclinux*) # Motorola m68k/ColdFire running uClinux
1470 # with uClibc, using the new GNU/Linux-style
1471 # ABI.
59fbf3cb 1472 default_m68k_cpu=68020
10e96df4 1473 default_cf_cpu=5206
3ca43df7 1474 tm_file="${tm_file} dbxelf.h elfos.h svr4.h linux.h flat.h m68k/linux.h m68k/uclinux.h ./sysroot-suffix.h"
cf909b0d 1475 tm_defines="${tm_defines} MOTOROLA=1 UCLIBC_DEFAULT=1"
78218d89 1476 extra_options="${extra_options} linux.opt"
10e96df4 1477 tmake_file="m68k/t-floatlib m68k/t-uclinux m68k/t-mlibs"
ba591f5a 1478 ;;
61ed06c3
HPN
1479m68k-*-linux*) # Motorola m68k's running GNU/Linux
1480 # with ELF format using glibc 2
1481 # aka the GNU/Linux C library 6.
59fbf3cb 1482 default_m68k_cpu=68020
10e96df4 1483 default_cf_cpu=5475
368b55f6
NS
1484 with_arch=${with_arch:-m68k}
1485 tm_file="${tm_file} dbxelf.h elfos.h svr4.h linux.h m68k/linux.h ./sysroot-suffix.h"
4af06170 1486 extra_options="${extra_options} m68k/ieee.opt"
cf909b0d 1487 tm_defines="${tm_defines} MOTOROLA=1"
368b55f6 1488 tmake_file="${tmake_file} m68k/t-floatlib m68k/t-linux m68k/t-mlibs"
8c958ed2
MK
1489 # if not configured with --enable-sjlj-exceptions, bump the
1490 # libgcc version number
1491 if test x$sjlj != x1; then
1492 tmake_file="$tmake_file m68k/t-slibgcc-elf-ver"
1493 fi
61ed06c3 1494 ;;
c7bdf0a6 1495m68k-*-rtems*)
59fbf3cb 1496 default_m68k_cpu=68020
10e96df4
NS
1497 default_cf_cpu=5206
1498 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-crtstuff t-rtems m68k/t-rtems m68k/t-mlibs"
a96533d5 1499 tm_file="${tm_file} m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h m68k/m68kemb.h m68k/m68020-elf.h m68k/rtemself.h rtems.h"
cf909b0d 1500 tm_defines="${tm_defines} MOTOROLA=1"
bb8602be 1501 extra_parts="crtbegin.o crtend.o"
61ed06c3 1502 ;;
61ed06c3 1503mcore-*-elf)
c40409ce 1504 tm_file="dbxelf.h elfos.h svr4.h ${tm_file} mcore/mcore-elf.h"
61ed06c3 1505 tmake_file=mcore/t-mcore
a929bc28 1506 inhibit_libc=true
61ed06c3
HPN
1507 ;;
1508mcore-*-pe*)
ca11c37c 1509 tm_file="svr3.h dbxcoff.h ${tm_file} mcore/mcore-pe.h"
61ed06c3 1510 tmake_file=mcore/t-mcore-pe
a929bc28 1511 inhibit_libc=true
61ed06c3 1512 ;;
82563d35
RS
1513mips-sgi-irix[56]*)
1514 tm_file="elfos.h ${tm_file} mips/iris.h"
1515 tmake_file="mips/t-iris mips/t-slibgcc-irix"
5811cb27 1516 target_cpu_default="MASK_ABICALLS"
82563d35
RS
1517 case ${target} in
1518 *-*-irix5*)
1519 tm_file="${tm_file} mips/iris5.h"
1520 ;;
1521
1522 *-*-irix6*)
1523 tm_file="${tm_file} mips/iris6.h"
1524 tmake_file="${tmake_file} mips/t-iris6"
620b87b3 1525 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_N32"
82563d35
RS
1526 ;;
1527 esac
1528 if test "x$stabs" = xyes
61ed06c3 1529 then
82563d35 1530 tm_file="${tm_file} dbx.h mips/dbxmdebug.h"
61ed06c3 1531 fi
3e35cb0c
RO
1532 if test "x$gnu_ld" = xyes
1533 then
82563d35 1534 tm_defines="${tm_defines} IRIX_USING_GNU_LD"
3e35cb0c 1535 fi
40f5cc95
RO
1536 case ${enable_threads}:${have_pthread_h} in
1537 "":yes | yes:yes ) thread_file=posix ;;
1538 esac
ec2a60b0 1539 use_fixproto=yes
61ed06c3 1540 ;;
f982f805 1541mips*-*-netbsd*) # NetBSD/mips, either endian.
5811cb27 1542 target_cpu_default="MASK_ABICALLS"
ca11c37c 1543 tm_file="elfos.h ${tm_file} mips/elf.h netbsd.h netbsd-elf.h mips/netbsd.h"
61ed06c3 1544 ;;
f2d6ca50 1545mips64*-*-linux* | mipsisa64*-*-linux*)
3bd6d4c4 1546 tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h mips/linux64.h"
08d0963a 1547 tmake_file="${tmake_file} mips/t-linux64 mips/t-libgcc-mips16"
5d2a73d5 1548 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_N32"
900e3ae5
DJ
1549 case ${target} in
1550 mips64el-st-linux-gnu)
1551 tm_file="${tm_file} mips/st.h"
1552 tmake_file="${tmake_file} mips/t-st"
1553 ;;
f2d6ca50
AN
1554 mipsisa64r2*-*-linux*)
1555 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=65"
1556 ;;
900e3ae5 1557 esac
3bd6d4c4
AO
1558 gnu_ld=yes
1559 gas=yes
66471b47 1560 test x$with_llsc != x || with_llsc=yes
3bd6d4c4 1561 ;;
61ed06c3 1562mips*-*-linux*) # Linux MIPS, either endian.
2017ed61 1563 tm_file="dbxelf.h elfos.h svr4.h linux.h ${tm_file} mips/linux.h"
08d0963a 1564 tmake_file="${tmake_file} mips/t-libgcc-mips16"
b01bc573 1565 case ${target} in
9303e5df
NS
1566 mipsisa32r2*)
1567 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33"
009da785 1568 ;;
9303e5df
NS
1569 mipsisa32*)
1570 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=32"
009da785 1571 esac
66471b47 1572 test x$with_llsc != x || with_llsc=yes
61ed06c3 1573 ;;
ca11c37c 1574mips*-*-openbsd*)
620b87b3 1575 tm_defines="${tm_defines} OBSD_HAS_DECLARE_FUNCTION_NAME OBSD_HAS_DECLARE_OBJECT OBSD_HAS_CORRECT_SPECS"
5811cb27 1576 target_cpu_default="MASK_ABICALLS"
ca11c37c 1577 tm_file="mips/mips.h openbsd.h mips/openbsd.h mips/sdb.h"
b01bc573 1578 case ${target} in
f7288899 1579 mips*el-*-openbsd*)
ca11c37c
ZW
1580 tm_defines="${tm_defines} TARGET_ENDIAN_DEFAULT=0";;
1581 *) tm_defines="${tm_defines} TARGET_ENDIAN_DEFAULT=MASK_BIG_ENDIAN";;
1582 esac
61ed06c3 1583 ;;
0ea339ea
NS
1584mips*-sde-elf*)
1585 tm_file="elfos.h ${tm_file} mips/elf.h mips/sde.h"
1586 tmake_file="mips/t-sde mips/t-libgcc-mips16"
d9dced13
RS
1587 case "${with_newlib}" in
1588 yes)
1589 # newlib / libgloss.
1590 ;;
1591 *)
1592 # MIPS toolkit libraries.
1593 tm_file="$tm_file mips/sdemtk.h"
1594 tmake_file="$tmake_file mips/t-sdemtk"
1595 extra_options="$extra_options mips/sdemtk.opt"
1596 case ${enable_threads} in
1597 "" | yes | mipssde)
1598 thread_file='mipssde'
1599 ;;
1600 esac
1601 ;;
1602 esac
0ea339ea
NS
1603 case ${target} in
1604 mipsisa32r2*)
1605 tm_defines="MIPS_ISA_DEFAULT=33 MIPS_ABI_DEFAULT=ABI_32"
1606 ;;
1607 mipsisa32*)
1608 tm_defines="MIPS_ISA_DEFAULT=32 MIPS_ABI_DEFAULT=ABI_32"
1609 ;;
1610 mipsisa64*)
1611 tm_defines="MIPS_ISA_DEFAULT=64 MIPS_ABI_DEFAULT=ABI_N32"
1612 ;;
1613 esac
1614 ;;
e2c14f5d
RS
1615mipsisa32-*-elf* | mipsisa32el-*-elf* | \
1616mipsisa32r2-*-elf* | mipsisa32r2el-*-elf* | \
5c44e275 1617mipsisa64-*-elf* | mipsisa64el-*-elf*)
e9475fa3 1618 tm_file="elfos.h ${tm_file} mips/elf.h"
0ea339ea 1619 tmake_file="mips/t-isa3264 mips/t-libgcc-mips16"
e2c14f5d
RS
1620 case ${target} in
1621 mipsisa32r2*)
1622 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33"
1623 ;;
1624 mipsisa32*)
1625 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=32"
1626 ;;
1627 mipsisa64*)
1628 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64"
1629 ;;
1630 esac
1631 case ${target} in
1632 mipsisa32*-*-elfoabi*)
1633 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_32"
1634 tm_file="${tm_file} mips/elfoabi.h"
1635 ;;
1636 mipsisa64*-*-elfoabi*)
1637 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_O64"
1638 tm_file="${tm_file} mips/elfoabi.h"
1639 ;;
1640 *-*-elf*)
1641 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_EABI"
1642 ;;
1643 esac
5c44e275 1644 ;;
5ce6f47b 1645mipsisa64sr71k-*-elf*)
e9475fa3 1646 tm_file="elfos.h ${tm_file} mips/elf.h"
5ce6f47b 1647 tmake_file=mips/t-sr71k
5811cb27 1648 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
620b87b3 1649 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64 MIPS_CPU_STRING_DEFAULT=\\\"sr71000\\\" MIPS_ABI_DEFAULT=ABI_EABI"
5ce6f47b 1650 ;;
3d41dbb0 1651mipsisa64sb1-*-elf* | mipsisa64sb1el-*-elf*)
e9475fa3 1652 tm_file="elfos.h ${tm_file} mips/elf.h"
0ea339ea 1653 tmake_file="mips/t-elf mips/t-libgcc-mips16 mips/t-sb1"
5811cb27 1654 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
620b87b3 1655 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64 MIPS_CPU_STRING_DEFAULT=\\\"sb1\\\" MIPS_ABI_DEFAULT=ABI_O64"
3d41dbb0 1656 ;;
74826b0f 1657mips-*-elf* | mipsel-*-elf*)
e9475fa3 1658 tm_file="elfos.h ${tm_file} mips/elf.h"
0ea339ea 1659 tmake_file="mips/t-elf mips/t-libgcc-mips16"
61ed06c3 1660 ;;
74826b0f 1661mips64-*-elf* | mips64el-*-elf*)
e9475fa3 1662 tm_file="elfos.h ${tm_file} mips/elf.h"
0ea339ea 1663 tmake_file="mips/t-elf mips/t-libgcc-mips16"
5811cb27 1664 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
620b87b3 1665 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_O64"
61ed06c3 1666 ;;
5ce6f47b 1667mips64vr-*-elf* | mips64vrel-*-elf*)
e9475fa3 1668 tm_file="mips/vr.h elfos.h ${tm_file} mips/elf.h"
5ce6f47b
EC
1669 tmake_file=mips/t-vr
1670 ;;
74826b0f 1671mips64orion-*-elf* | mips64orionel-*-elf*)
e9475fa3 1672 tm_file="elfos.h ${tm_file} mips/elforion.h mips/elf.h"
0ea339ea 1673 tmake_file="mips/t-elf mips/t-libgcc-mips16"
5811cb27 1674 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
620b87b3 1675 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_O64"
61ed06c3 1676 ;;
bc98ef7f 1677mips*-*-rtems*)
e9475fa3 1678 tm_file="elfos.h ${tm_file} mips/elf.h mips/rtems.h rtems.h"
0ea339ea 1679 tmake_file="mips/t-elf mips/t-libgcc-mips16 t-rtems mips/t-rtems"
61ed06c3 1680 ;;
55047c9d 1681mips-wrs-vxworks)
f4de8ba6 1682 tm_file="elfos.h ${tm_file} svr4.h mips/elf.h vx-common.h vxworks.h mips/vxworks.h"
55047c9d 1683 tmake_file="${tmake_file} mips/t-vxworks"
55047c9d 1684 ;;
74826b0f 1685mipstx39-*-elf* | mipstx39el-*-elf*)
e9475fa3 1686 tm_file="elfos.h ${tm_file} mips/r3900.h mips/elf.h"
0ea339ea 1687 tmake_file="mips/t-r3900 mips/t-libgcc-mips16"
61ed06c3 1688 ;;
bcf684c7 1689mmix-knuth-mmixware)
4977bab6 1690 need_64bit_hwint=yes
bcf684c7 1691 ;;
61ed06c3 1692mn10300-*-*)
c40409ce 1693 tm_file="dbxelf.h elfos.h svr4.h ${tm_file}"
61ed06c3
HPN
1694 if test x$stabs = xyes
1695 then
1696 tm_file="${tm_file} dbx.h"
1697 fi
1698 use_collect2=no
1699 ;;
61ed06c3
HPN
1700pdp11-*-bsd)
1701 tm_file="${tm_file} pdp11/2bsd.h"
ec2a60b0 1702 use_fixproto=yes
61ed06c3
HPN
1703 ;;
1704pdp11-*-*)
1705 ;;
ca11c37c
ZW
1706# port not yet contributed
1707#powerpc-*-openbsd*)
49721058 1708# tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-fprules-fpbit "
ca11c37c
ZW
1709# extra_headers=
1710# ;;
2bfcf297 1711powerpc64-*-linux*)
a8e04fe6
AM
1712 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h"
1713 test x$with_cpu != x || cpu_is_64bit=yes
1714 test x$cpu_is_64bit != xyes || tm_file="${tm_file} rs6000/default64.h"
1715 tm_file="rs6000/biarch64.h ${tm_file} rs6000/linux64.h"
7f970b70
AM
1716 if test x${enable_secureplt} = xyes; then
1717 tm_file="rs6000/secureplt.h ${tm_file}"
1718 fi
78f5898b 1719 extra_options="${extra_options} rs6000/sysv4.opt rs6000/linux64.opt"
49721058 1720 tmake_file="t-dfprules rs6000/t-fprules ${tmake_file} rs6000/t-ppccomm rs6000/t-linux64 rs6000/t-fprules-softfp soft-fp/t-softfp"
2bfcf297 1721 ;;
ddb28441
RM
1722powerpc64-*-gnu*)
1723 tm_file="${cpu_type}/${cpu_type}.h elfos.h svr4.h freebsd-spec.h gnu.h rs6000/sysv4.h rs6000/linux64.h rs6000/gnu.h"
78f5898b 1724 extra_options="${extra_options} rs6000/sysv4.opt rs6000/linux64.opt"
49721058 1725 tmake_file="rs6000/t-fprules t-slibgcc-elf-ver t-gnu rs6000/t-linux64 rs6000/t-fprules-softfp soft-fp/t-softfp"
ddb28441 1726 ;;
18922061 1727powerpc-*-darwin*)
78f5898b 1728 extra_options="${extra_options} rs6000/darwin.opt"
747b9f55 1729 extra_parts="crt2.o"
f0b81cbc 1730 case ${target} in
ed5b9f96 1731 *-darwin1[0-9]* | *-darwin[8-9]*)
f7288899 1732 tmake_file="${tmake_file} rs6000/t-darwin8"
ed5b9f96
GK
1733 tm_file="${tm_file} rs6000/darwin8.h"
1734 ;;
1735 *-darwin7*)
1736 tm_file="${tm_file} rs6000/darwin7.h"
1737 ;;
1738 *-darwin[0-6]*)
1739 ;;
f0b81cbc 1740 esac
5fb4cf24 1741 extra_headers=altivec.h
18922061 1742 ;;
b8ec3cc8
EC
1743powerpc64-*-darwin*)
1744 tm_file="${tm_file} ${cpu_type}/darwin8.h ${cpu_type}/darwin64.h"
1745 extra_options="${extra_options} ${cpu_type}/darwin.opt"
1746 # We're omitting t-darwin8 to avoid building any multilibs
1747 extra_headers=altivec.h
1748 ;;
b91da81f 1749powerpc*-*-freebsd*)
c40409ce 1750 tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} rs6000/sysv4.h rs6000/freebsd.h"
49721058 1751 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
78f5898b 1752 extra_options="${extra_options} rs6000/sysv4.opt"
b91da81f 1753 ;;
edf1b3f3 1754powerpc-*-netbsd*)
a4967b8d
JT
1755 tm_file="${tm_file} dbxelf.h elfos.h netbsd.h netbsd-elf.h freebsd-spec.h rs6000/sysv4.h rs6000/netbsd.h"
1756 tmake_file="${tmake_file} rs6000/t-netbsd"
78f5898b 1757 extra_options="${extra_options} rs6000/sysv4.opt"
edf1b3f3 1758 ;;
518878e1 1759powerpc-*-eabispe*)
eca0d5e8 1760 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabispe.h"
78f5898b 1761 extra_options="${extra_options} rs6000/sysv4.opt"
00c060a4 1762 tmake_file="rs6000/t-spe rs6000/t-ppccomm"
518878e1 1763 ;;
cf6ede82 1764powerpc-*-eabisimaltivec*)
eca0d5e8 1765 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabisim.h rs6000/eabialtivec.h"
78f5898b 1766 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1767 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcendian rs6000/t-ppccomm"
cf6ede82 1768 ;;
61ed06c3 1769powerpc-*-eabisim*)
eca0d5e8 1770 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabisim.h"
78f5898b 1771 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1772 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcgas rs6000/t-ppccomm"
61ed06c3
HPN
1773 ;;
1774powerpc-*-elf*)
c40409ce 1775 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h"
78f5898b 1776 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1777 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcgas rs6000/t-ppccomm"
61ed06c3 1778 ;;
10baca6b 1779powerpc-*-eabialtivec*)
eca0d5e8 1780 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabialtivec.h"
78f5898b 1781 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1782 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcendian rs6000/t-ppccomm"
10baca6b 1783 ;;
61ed06c3 1784powerpc-*-eabi*)
eca0d5e8 1785 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h"
78f5898b 1786 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1787 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcgas rs6000/t-ppccomm"
61ed06c3
HPN
1788 ;;
1789powerpc-*-rtems*)
eca0d5e8 1790 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/rtems.h rtems.h"
78f5898b 1791 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1792 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-rtems t-rtems rs6000/t-ppccomm"
61ed06c3 1793 ;;
7c942e17 1794powerpc-*-linux*altivec*)
10baca6b 1795 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h rs6000/linuxaltivec.h"
78f5898b 1796 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1797 tmake_file="rs6000/t-fprules rs6000/t-fprules-softfp soft-fp/t-softfp rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
10baca6b 1798 ;;
7c942e17 1799powerpc-*-linux*spe*)
eca0d5e8 1800 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h rs6000/linuxspe.h rs6000/e500.h"
78f5898b 1801 extra_options="${extra_options} rs6000/sysv4.opt"
4f011e1e 1802 tmake_file="t-dfprules rs6000/t-fprules rs6000/t-fprules-softfp soft-fp/t-softfp rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
2f3f95e9 1803 ;;
96038623
DE
1804powerpc-*-linux*paired*)
1805 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/linux.h rs6000/750cl.h"
1806 extra_options="${extra_options} rs6000/sysv4.opt"
1807 tmake_file="rs6000/t-fprules rs6000/t-fprules-softfp soft-fp/t-softfp rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
1808 ;;
61ed06c3 1809powerpc-*-linux*)
a8e04fe6 1810 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h"
78f5898b 1811 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1812 tmake_file="t-dfprules rs6000/t-fprules rs6000/t-fprules-softfp soft-fp/t-softfp rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
a8e04fe6
AM
1813 case ${enable_targets}:${cpu_is_64bit} in
1814 *powerpc64* | all:* | *:yes)
1815 if test x$cpu_is_64bit = xyes; then
1816 tm_file="${tm_file} rs6000/default64.h"
1817 fi
1818 tm_file="rs6000/biarch64.h ${tm_file} rs6000/linux64.h"
1819 tmake_file="$tmake_file rs6000/t-linux64"
f75aac9e 1820 extra_options="${extra_options} rs6000/linux64.opt"
a8e04fe6
AM
1821 ;;
1822 *)
1823 tm_file="${tm_file} rs6000/linux.h"
1824 ;;
1825 esac
7f970b70
AM
1826 if test x${enable_secureplt} = xyes; then
1827 tm_file="rs6000/secureplt.h ${tm_file}"
1828 fi
61ed06c3 1829 ;;
ddb28441
RM
1830powerpc-*-gnu-gnualtivec*)
1831 tm_file="${cpu_type}/${cpu_type}.h elfos.h svr4.h freebsd-spec.h gnu.h rs6000/sysv4.h rs6000/linux.h rs6000/linuxaltivec.h rs6000/gnu.h"
78f5898b 1832 extra_options="${extra_options} rs6000/sysv4.opt"
49721058 1833 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcos t-slibgcc-elf-ver t-gnu rs6000/t-ppccomm"
ddb28441
RM
1834 if test x$enable_threads = xyes; then
1835 thread_file='posix'
1836 fi
1837 ;;
1838powerpc-*-gnu*)
1839 tm_file="${cpu_type}/${cpu_type}.h elfos.h svr4.h freebsd-spec.h gnu.h rs6000/sysv4.h rs6000/linux.h rs6000/gnu.h"
49721058 1840 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcos t-slibgcc-elf-ver t-gnu rs6000/t-ppccomm"
78f5898b 1841 extra_options="${extra_options} rs6000/sysv4.opt"
ddb28441
RM
1842 if test x$enable_threads = xyes; then
1843 thread_file='posix'
1844 fi
1845 ;;
2eab15c9 1846powerpc-wrs-vxworks|powerpc-wrs-vxworksae)
f4de8ba6 1847 tm_file="${tm_file} elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h"
49721058 1848 tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppccomm rs6000/t-vxworks"
78f5898b 1849 extra_options="${extra_options} rs6000/sysv4.opt"
4977bab6 1850 extra_headers=ppc-asm.h
2eab15c9
PE
1851 case ${target} in
1852 *-vxworksae*)
eca0d5e8 1853 tm_file="${tm_file} vx-common.h vxworksae.h rs6000/vxworks.h rs6000/e500.h rs6000/vxworksae.h"
2eab15c9
PE
1854 tmake_file="${tmake_file} rs6000/t-vxworksae"
1855 ;;
1856 *-vxworks*)
eca0d5e8 1857 tm_file="${tm_file} vx-common.h vxworks.h rs6000/vxworks.h rs6000/e500.h"
2eab15c9
PE
1858 ;;
1859 esac
4977bab6 1860 ;;
4f587cb0
AN
1861powerpc-*-lynxos*)
1862 xm_defines=POSIX
1863 tm_file="${tm_file} dbxelf.h elfos.h rs6000/sysv4.h rs6000/lynx.h lynx.h"
1864 tmake_file="t-lynx rs6000/t-lynx"
78f5898b 1865 extra_options="${extra_options} rs6000/sysv4.opt lynx.opt"
4f587cb0 1866 extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o"
6ac49599 1867 extra_options="${extra_options} lynx.opt"
4f587cb0
AN
1868 thread_file=lynx
1869 gnu_ld=yes
1870 gas=yes
1871 ;;
61ed06c3 1872powerpcle-*-elf*)
c40409ce 1873 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/sysv4le.h"
49721058 1874 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcgas rs6000/t-ppccomm"
78f5898b 1875 extra_options="${extra_options} rs6000/sysv4.opt"
61ed06c3
HPN
1876 ;;
1877powerpcle-*-eabisim*)
eca0d5e8 1878 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h rs6000/e500.h rs6000/eabisim.h"
49721058 1879 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcgas rs6000/t-ppccomm"
78f5898b 1880 extra_options="${extra_options} rs6000/sysv4.opt"
61ed06c3
HPN
1881 ;;
1882powerpcle-*-eabi*)
eca0d5e8 1883 tm_file="${tm_file} dbxelf.h elfos.h svr4.h freebsd-spec.h rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h rs6000/e500.h"
49721058 1884 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-ppcgas rs6000/t-ppccomm"
78f5898b 1885 extra_options="${extra_options} rs6000/sysv4.opt"
61ed06c3 1886 ;;
61ed06c3 1887rs6000-ibm-aix4.[12]* | powerpc-ibm-aix4.[12]*)
2bfcf297 1888 tm_file="${tm_file} rs6000/aix.h rs6000/aix41.h rs6000/xcoff.h"
49721058 1889 tmake_file="rs6000/t-fprules rs6000/t-fprules-fpbit rs6000/t-newas"
432218ba 1890 extra_options="${extra_options} rs6000/aix41.opt"
61ed06c3 1891 use_collect2=yes
ba1e6c0b 1892 extra_headers=
ec2a60b0 1893 use_fixproto=yes
61ed06c3
HPN
1894 ;;
1895rs6000-ibm-aix4.[3456789]* | powerpc-ibm-aix4.[3456789]*)
9739c90c 1896 tm_file="rs6000/biarch64.h ${tm_file} rs6000/aix.h rs6000/aix43.h rs6000/xcoff.h"
61ed06c3 1897 tmake_file=rs6000/t-aix43
432218ba 1898 extra_options="${extra_options} rs6000/aix64.opt"
61ed06c3
HPN
1899 use_collect2=yes
1900 thread_file='aix'
ba1e6c0b 1901 extra_headers=
61ed06c3 1902 ;;
5f5d5417 1903rs6000-ibm-aix5.1.* | powerpc-ibm-aix5.1.*)
9739c90c 1904 tm_file="rs6000/biarch64.h ${tm_file} rs6000/aix.h rs6000/aix51.h rs6000/xcoff.h"
432218ba 1905 extra_options="${extra_options} rs6000/aix64.opt"
61ed06c3 1906 tmake_file=rs6000/t-aix43
61ed06c3
HPN
1907 use_collect2=yes
1908 thread_file='aix'
ba1e6c0b 1909 extra_headers=
61ed06c3 1910 ;;
ca94e524 1911rs6000-ibm-aix5.2.* | powerpc-ibm-aix5.2.*)
5f5d5417
DE
1912 tm_file="${tm_file} rs6000/aix.h rs6000/aix52.h rs6000/xcoff.h"
1913 tmake_file=rs6000/t-aix52
432218ba 1914 extra_options="${extra_options} rs6000/aix64.opt"
5f5d5417
DE
1915 use_collect2=yes
1916 thread_file='aix'
1917 extra_headers=
1918 ;;
ba6a1b78 1919rs6000-ibm-aix5.3.* | powerpc-ibm-aix5.3.*)
ca94e524
DE
1920 tm_file="${tm_file} rs6000/aix.h rs6000/aix53.h rs6000/xcoff.h"
1921 tmake_file=rs6000/t-aix52
1922 extra_options="${extra_options} rs6000/aix64.opt"
1923 use_collect2=yes
1924 thread_file='aix'
c4a79427 1925 extra_headers=altivec.h
ca94e524 1926 ;;
ba6a1b78
DE
1927rs6000-ibm-aix[6789].* | powerpc-ibm-aix[6789].*)
1928 tm_file="${tm_file} rs6000/aix.h rs6000/aix61.h rs6000/xcoff.h"
1929 tmake_file=rs6000/t-aix52
1930 extra_options="${extra_options} rs6000/aix64.opt"
1931 use_collect2=yes
1932 thread_file='aix'
1933 extra_headers=altivec.h
1934 ;;
0e5a4ad8 1935s390-*-linux*)
c40409ce 1936 tm_file="s390/s390.h dbxelf.h elfos.h svr4.h linux.h s390/linux.h"
4dc19cc0 1937 tmake_file="${tmake_file} t-dfprules s390/t-crtstuff s390/t-linux"
9628a767 1938 ;;
0e5a4ad8 1939s390x-*-linux*)
58d10f89 1940 tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h svr4.h linux.h s390/linux.h"
70eeb10b
UW
1941 tm_p_file=s390/s390-protos.h
1942 md_file=s390/s390.md
1c0ca89d 1943 extra_modes=s390/s390-modes.def
70eeb10b 1944 out_file=s390/s390.c
4dc19cc0 1945 tmake_file="${tmake_file} t-dfprules s390/t-crtstuff s390/t-linux s390/t-linux64"
9628a767 1946 ;;
24fe22c9 1947s390x-ibm-tpf*)
a8ba31f2
EC
1948 tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h svr4.h s390/tpf.h"
1949 tm_p_file=s390/s390-protos.h
1950 md_file=s390/s390.md
1951 extra_modes=s390/s390-modes.def
1952 out_file=s390/s390.c
1953 extra_parts="crtbeginS.o crtendS.o"
1954 tmake_file="s390/t-crtstuff s390/t-tpf"
1955 thread_file='tpf'
1956 extra_options="${extra_options} s390/tpf.opt"
24fe22c9 1957 ;;
bdcee471
CL
1958score-*-elf)
1959 tm_file="dbxelf.h elfos.h score/elf.h score/score.h"
1960 tmake_file=score/t-score-elf
254f5222 1961 extra_objs="score7.o score3.o"
bdcee471 1962 ;;
cd985f66 1963sh-*-elf* | sh[12346l]*-*-elf* | \
b55e3aad 1964sh-*-symbianelf* | sh[12346l]*-*-symbianelf* | \
93fea8d3 1965 sh-*-linux* | sh[2346lbe]*-*-linux* | \
da28a3b9
JR
1966 sh-*-netbsdelf* | shl*-*-netbsdelf* | sh5-*-netbsd* | sh5l*-*-netbsd* | \
1967 sh64-*-netbsd* | sh64l*-*-netbsd*)
1968 tmake_file="${tmake_file} sh/t-sh sh/t-elf"
1969 if test x${with_endian} = x; then
1970 case ${target} in
1971 sh[1234]*be-*-* | sh[1234]*eb-*-*) with_endian=big ;;
1972 shbe-*-* | sheb-*-*) with_endian=big,little ;;
1973 sh[1234]l* | sh[34]*-*-linux*) with_endian=little ;;
1974 shl* | sh64l* | sh*-*-linux* | \
1975 sh5l* | sh-superh-elf) with_endian=little,big ;;
1976 sh[1234]*-*-*) with_endian=big ;;
1977 *) with_endian=big,little ;;
1978 esac
1979 fi
1980 case ${with_endian} in
1981 big|little) tmake_file="${tmake_file} sh/t-1e" ;;
1982 big,little|little,big) ;;
1983 *) echo "with_endian=${with_endian} not supported."; exit 1 ;;
1984 esac
1985 case ${with_endian} in
1986 little*) tm_file="sh/little.h ${tm_file}" ;;
1987 esac
1988 tm_file="${tm_file} dbxelf.h elfos.h"
b01bc573 1989 case ${target} in
da28a3b9
JR
1990 sh*-*-netbsd*) ;;
1991 *) tm_file="${tm_file} svr4.h" ;;
dbf87f32 1992 esac
da28a3b9 1993 tm_file="${tm_file} sh/elf.h"
b01bc573 1994 case ${target} in
da28a3b9 1995 sh*-*-linux*) tmake_file="${tmake_file} sh/t-linux"
65f527e0 1996 tm_file="${tm_file} linux.h sh/linux.h" ;;
da28a3b9 1997 sh*-*-netbsd*) tm_file="${tm_file} netbsd.h netbsd-elf.h sh/netbsd-elf.h" ;;
8c1aaf26
R
1998 sh*-superh-elf) if test x$with_libgloss != xno; then
1999 with_libgloss=yes
2000 tm_file="${tm_file} sh/newlib.h"
2001 fi
8999fdc7
R
2002 tm_file="${tm_file} sh/embed-elf.h sh/superh.h"
2003 tmake_file="${tmake_file} sh/t-superh"
25e651ca 2004 extra_options="${extra_options} sh/superh.opt" ;;
8c1aaf26
R
2005 *) if test x$with_newlib = xyes \
2006 && test x$with_libgloss = xyes; then
2007 tm_file="${tm_file} sh/newlib.h"
2008 fi
2009 tm_file="${tm_file} sh/embed-elf.h" ;;
da28a3b9
JR
2010 esac
2011 case ${target} in
2012 sh5*-*-netbsd*)
2013 # SHmedia, 32-bit ABI
2014 tmake_file="${tmake_file} sh/t-sh64 sh/t-netbsd"
2015 ;;
2016 sh64*-netbsd*)
2017 # SHmedia, 64-bit ABI
2018 tmake_file="${tmake_file} sh/t-sh64 sh/t-netbsd sh/t-netbsd-sh5-64"
2019 ;;
2020 *-*-netbsd)
2021 tmake_file="${tmake_file} sh/t-netbsd"
2022 ;;
2023 sh64*-*-linux*)
2024 tmake_file="${tmake_file} sh/t-sh64 sh/t-linux64"
2025 tm_file="${tm_file} sh/sh64.h"
2026 extra_headers="shmedia.h ushmedia.h sshmedia.h"
2027 ;;
dbf87f32
R
2028 sh64*)
2029 tmake_file="${tmake_file} sh/t-sh64"
2030 tm_file="${tm_file} sh/sh64.h"
2031 extra_headers="shmedia.h ushmedia.h sshmedia.h"
dbf87f32 2032 ;;
b55e3aad
NC
2033 *-*-symbianelf*)
2034 tmake_file="sh/t-symbian"
2035 tm_file="sh/symbian-pre.h sh/little.h ${tm_file} sh/symbian-post.h"
2036 extra_objs="symbian.o"
2037 extra_parts="crt1.o crti.o crtn.o crtbegin.o crtend.o crtbeginS.o crtendS.o"
f7288899 2038 ;;
8bc6e101 2039 esac
da28a3b9
JR
2040 # sed el/eb endian suffixes away to avoid confusion with sh[23]e
2041 case `echo ${target} | sed 's/e[lb]-/-/'` in
2042 sh64*-*-netbsd*) sh_cpu_target=sh5-64media ;;
2043 sh64* | sh5*-*-netbsd*) sh_cpu_target=sh5-32media ;;
312209c6
AO
2044 sh4a_single_only*) sh_cpu_target=sh4a-single-only ;;
2045 sh4a_single*) sh_cpu_target=sh4a-single ;;
2046 sh4a_nofpu*) sh_cpu_target=sh4a-nofpu ;;
2047 sh4al) sh_cpu_target=sh4al ;;
2048 sh4a*) sh_cpu_target=sh4a ;;
da28a3b9
JR
2049 sh4_single_only*) sh_cpu_target=sh4-single-only ;;
2050 sh4_single*) sh_cpu_target=sh4-single ;;
2051 sh4_nofpu*) sh_cpu_target=sh4-nofpu ;;
2052 sh4* | sh-superh-*) sh_cpu_target=sh4 ;;
2053 sh3e*) sh_cpu_target=sh3e ;;
2054 sh*-*-netbsd* | sh3*) sh_cpu_target=sh3 ;;
157371cf
AO
2055 sh2a_single_only*) sh_cpu_target=sh2a-single-only ;;
2056 sh2a_single*) sh_cpu_target=sh2a-single ;;
2057 sh2a_nofpu*) sh_cpu_target=sh2a-nofpu ;;
2058 sh2a*) sh_cpu_target=sh2a ;;
da28a3b9
JR
2059 sh2e*) sh_cpu_target=sh2e ;;
2060 sh2*) sh_cpu_target=sh2 ;;
2061 *) sh_cpu_target=sh1 ;;
8f48afc1 2062 esac
8c1aaf26
R
2063 # did the user say --without-fp ?
2064 if test x$with_fp = xno; then
2065 case ${sh_cpu_target} in
2066 sh5-*media) sh_cpu_target=${sh_cpu_target}-nofpu ;;
2067 sh4al | sh1) ;;
2068 sh4a* ) sh_cpu_target=sh4a-nofpu ;;
2069 sh4*) sh_cpu_target=sh4-nofpu ;;
2070 sh3*) sh_cpu_target=sh3 ;;
2071 sh2a*) sh_cpu_target=sh2a-nofpu ;;
2072 sh2*) sh_cpu_target=sh2 ;;
2073 *) echo --without-fp not available for $target: ignored
2074 esac
2075 tm_defines="$tm_defines STRICT_NOFPU=1"
2076 fi
da28a3b9
JR
2077 sh_cpu_default="`echo $with_cpu|sed s/^m/sh/|tr A-Z_ a-z-`"
2078 case $sh_cpu_default in
2079 sh5-64media-nofpu | sh5-64media | \
2080 sh5-32media-nofpu | sh5-32media | sh5-compact-nofpu | sh5-compact | \
157371cf 2081 sh2a-single-only | sh2a-single | sh2a-nofpu | sh2a | \
312209c6 2082 sh4a-single-only | sh4a-single | sh4a-nofpu | sh4a | sh4al | \
27a0ce7d 2083 sh4-single-only | sh4-single | sh4-nofpu | sh4 | sh4-300 | \
bf09b512 2084 sh3e | sh3 | sh2e | sh2 | sh1) ;;
da28a3b9
JR
2085 "") sh_cpu_default=${sh_cpu_target} ;;
2086 *) echo "with_cpu=$with_cpu not supported"; exit 1 ;;
dbf87f32 2087 esac
da28a3b9
JR
2088 sh_multilibs=${with_multilib_list}
2089 if test x${sh_multilibs} = x ; then
2090 case ${target} in
8c1aaf26 2091 sh64-superh-linux* | \
da28a3b9
JR
2092 sh[1234]*) sh_multilibs=${sh_cpu_target} ;;
2093 sh64* | sh5*) sh_multilibs=m5-32media,m5-32media-nofpu,m5-compact,m5-compact-nofpu,m5-64media,m5-64media-nofpu ;;
2094 sh-superh-*) sh_multilibs=m4,m4-single,m4-single-only,m4-nofpu ;;
2095 sh*-*-linux*) sh_multilibs=m1,m3e,m4 ;;
2096 sh*-*-netbsd*) sh_multilibs=m3,m3e,m4 ;;
157371cf 2097 *) sh_multilibs=m1,m2,m2e,m4,m4-single,m4-single-only,m2a,m2a-single ;;
da28a3b9 2098 esac
8c1aaf26
R
2099 if test x$with_fp = xno; then
2100 sh_multilibs="`echo $sh_multilibs|sed -e s/m4/sh4-nofpu/ -e s/,m4-[^,]*//g -e s/,m[23]e// -e s/m2a,m2a-single/m2a-nofpu/ -e s/m5-..m....,//g`"
2101 fi
da28a3b9 2102 fi
25e651ca 2103 target_cpu_default=SELECT_`echo ${sh_cpu_default}|tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`
da28a3b9 2104 tm_defines=${tm_defines}' SH_MULTILIB_CPU_DEFAULT=\"'`echo $sh_cpu_default|sed s/sh/m/`'\"'
25e651ca 2105 sh_multilibs=`echo $sh_multilibs,$sh_cpu_default | sed -e 's/[ ,/][ ,]*/ /g' -e 's/ $//' -e 's/^m/sh/' -e 's/ m/ sh/g' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ_ abcdefghijklmnopqrstuvwxyz-`
da28a3b9
JR
2106 for sh_multilib in ${sh_multilibs}; do
2107 case ${sh_multilib} in
2108 sh1 | sh2 | sh2e | sh3 | sh3e | \
27a0ce7d 2109 sh4 | sh4-single | sh4-single-only | sh4-nofpu | sh4-300 |\
312209c6 2110 sh4a | sh4a-single | sh4a-single-only | sh4a-nofpu | sh4al | \
157371cf 2111 sh2a | sh2a-single | sh2a-single-only | sh2a-nofpu | \
da28a3b9
JR
2112 sh5-64media | sh5-64media-nofpu | \
2113 sh5-32media | sh5-32media-nofpu | \
2114 sh5-compact | sh5-compact-nofpu)
2115 tmake_file="${tmake_file} sh/t-mlib-${sh_multilib}"
25e651ca 2116 tm_defines="$tm_defines SUPPORT_`echo $sh_multilib|tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`=1"
da28a3b9
JR
2117 ;;
2118 *)
2119 echo "with_multilib_list=${sh_multilib} not supported."
2120 exit 1
2121 ;;
2122 esac
2123 done
25e651ca 2124 if test x${enable_incomplete_targets} = xyes ; then
c0fb94d7 2125 tm_defines="$tm_defines SUPPORT_SH1=1 SUPPORT_SH2E=1 SUPPORT_SH4=1 SUPPORT_SH4_SINGLE=1 SUPPORT_SH2A=1 SUPPORT_SH2A_SINGLE=1 SUPPORT_SH5_32MEDIA=1 SUPPORT_SH5_32MEDIA_NOFPU=1 SUPPORT_SH5_64MEDIA=1 SUPPORT_SH5_64MEDIA_NOFPU=1"
da28a3b9 2126 fi
fa5322fa 2127 ;;
314733e2 2128sh-*-rtems*)
be33b729 2129 tmake_file="sh/t-sh sh/t-elf t-rtems sh/t-rtems"
314733e2
RC
2130 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sh/elf.h sh/embed-elf.h sh/rtemself.h rtems.h"
2131 ;;
55047c9d
PE
2132sh-wrs-vxworks)
2133 tmake_file="$tmake_file sh/t-sh sh/t-elf sh/t-vxworks"
f5c7290e 2134 tm_file="${tm_file} elfos.h svr4.h sh/elf.h sh/embed-elf.h vx-common.h vxworks.h sh/vxworks.h"
55047c9d 2135 ;;
61ed06c3 2136sh-*-*)
10d6ea27 2137 tm_file="${tm_file} dbxcoff.h sh/coff.h"
61ed06c3 2138 ;;
69474c3c 2139sparc-*-netbsdelf*)
0b85af22 2140 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h netbsd.h netbsd-elf.h sparc/netbsd-elf.h"
fe609b0f 2141 extra_options="${extra_options} sparc/long-double-switch.opt"
69474c3c 2142 ;;
91f0fcee 2143sparc64-*-openbsd*)
0b85af22 2144 tm_file="sparc/openbsd1-64.h ${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sparc/sp64-elf.h openbsd.h sparc/openbsd64.h"
fe609b0f 2145 extra_options="${extra_options} sparc/little-endian.opt"
91f0fcee
ME
2146 gas=yes gnu_ld=yes
2147 with_cpu=ultrasparc
91f0fcee 2148 ;;
61ed06c3 2149sparc-*-elf*)
81b47219 2150 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sparc/sp-elf.h"
a261e0cc 2151 tmake_file="sparc/t-elf sparc/t-crtfm"
61ed06c3 2152 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
61ed06c3 2153 ;;
981f6289 2154sparc-*-linux*) # SPARC's running GNU/Linux, libc6
5f7ca34b 2155 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h linux.h"
fe609b0f 2156 extra_options="${extra_options} sparc/long-double-switch.opt"
ccbdd3bc 2157 tmake_file="${tmake_file} sparc/t-linux"
5f7ca34b
DM
2158 if test x$enable_targets = xall; then
2159 tm_file="sparc/biarch64.h ${tm_file} sparc/linux64.h"
ccbdd3bc 2160 tmake_file="${tmake_file} sparc/t-linux64"
5f7ca34b
DM
2161 else
2162 tm_file="${tm_file} sparc/linux.h"
5f7ca34b 2163 fi
ccbdd3bc 2164 tmake_file="${tmake_file} sparc/t-crtfm"
61ed06c3 2165 ;;
c7bdf0a6 2166sparc-*-rtems*)
81b47219 2167 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sparc/sp-elf.h sparc/rtemself.h rtems.h"
2d69e3cb 2168 tmake_file="sparc/t-elf sparc/t-crtfm t-rtems"
61ed06c3 2169 extra_parts="crti.o crtn.o crtbegin.o crtend.o"
61ed06c3 2170 ;;
8947df0c 2171sparc64-*-solaris2* | sparcv9-*-solaris2*)
ec23ed60
EB
2172 tm_file="sparc/biarch64.h ${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sol2.h"
2173 case ${target} in
2174 *-*-solaris2.1[0-9]*)
2175 tm_file="${tm_file} sol2-10.h"
2176 ;;
2177 esac
2178 tm_file="${tm_file} sparc/sol2.h sparc/sol2-64.h sparc/sol2-bi.h"
3fc602a0
RH
2179 if test x$gnu_ld = xyes; then
2180 tm_file="${tm_file} sparc/sol2-gld.h sparc/sol2-gld-bi.h"
61ed06c3 2181 fi
f0871dfe 2182 if test x$gas = xyes; then
5d865dac 2183 tm_file="${tm_file} sparc/sol2-gas.h sparc/sol2-gas-bi.h"
f0871dfe 2184 fi
fdbe66f2 2185 tm_file="${tm_file} tm-dwarf2.h"
a2bec818 2186 tmake_file="t-sol2 sparc/t-sol2 sparc/t-sol2-64 sparc/t-crtfm"
61ed06c3 2187 if test x$gnu_ld = xyes; then
7b3a4df5 2188 tmake_file="$tmake_file t-slibgcc-elf-ver"
61ed06c3 2189 else
7b3a4df5 2190 tmake_file="$tmake_file t-slibgcc-sld"
61ed06c3 2191 fi
a2bec818
DJ
2192 c_target_objs="sol2-c.o"
2193 cxx_target_objs="sol2-c.o"
07a43492
DJ
2194 extra_objs="sol2.o"
2195 tm_p_file="${tm_p_file} sol2-protos.h"
61ed06c3 2196 extra_parts="crt1.o crti.o crtn.o gcrt1.o crtbegin.o crtend.o"
615be2cf 2197 case ${enable_threads}:${have_pthread_h}:${have_thread_h} in
fe7378d2
EB
2198 "":yes:* | yes:yes:* ) thread_file=posix ;;
2199 "":*:yes | yes:*:yes ) thread_file=solaris ;;
615be2cf 2200 esac
61ed06c3 2201 ;;
8947df0c 2202sparc-*-solaris2*)
18167442
EB
2203 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sol2.h"
2204 case ${target} in
ec23ed60
EB
2205 *-*-solaris2.1[0-9]*)
2206 tm_file="${tm_file} sol2-10.h"
2207 ;;
18167442
EB
2208 esac
2209 tm_file="${tm_file} sparc/sol2.h"
3fc602a0
RH
2210 if test x$gnu_ld = xyes; then
2211 tm_file="${tm_file} sparc/sol2-gld.h"
61ed06c3 2212 fi
5d865dac
EB
2213 if test x$gas = xyes; then
2214 tm_file="${tm_file} sparc/sol2-gas.h"
2215 fi
a2bec818 2216 tmake_file="t-sol2 sparc/t-sol2 sparc/t-crtfm"
61ed06c3 2217 if test x$gnu_ld = xyes; then
7b3a4df5 2218 tmake_file="$tmake_file t-slibgcc-elf-ver"
61ed06c3 2219 else
7b3a4df5 2220 tmake_file="$tmake_file t-slibgcc-sld"
61ed06c3 2221 fi
cd985f66
JM
2222 tm_file="sparc/biarch64.h ${tm_file} sparc/sol2-bi.h"
2223 if test x$gnu_ld = xyes; then
2224 tm_file="${tm_file} sparc/sol2-gld-bi.h"
2225 fi
2226 if test x$gas = xyes; then
2227 tm_file="${tm_file} sparc/sol2-gas-bi.h"
2228 fi
2229 tm_file="${tm_file} tm-dwarf2.h"
2230 tmake_file="$tmake_file sparc/t-sol2-64"
2231 test x$with_cpu != x || with_cpu=v9
a2bec818
DJ
2232 c_target_objs="sol2-c.o"
2233 cxx_target_objs="sol2-c.o"
07a43492
DJ
2234 extra_objs="sol2.o"
2235 tm_p_file="${tm_p_file} sol2-protos.h"
3fc602a0 2236 extra_parts="crt1.o crti.o crtn.o gcrt1.o gmon.o crtbegin.o crtend.o"
615be2cf 2237 case ${enable_threads}:${have_pthread_h}:${have_thread_h} in
18167442 2238 "":yes:* | yes:yes:* )
cd985f66 2239 thread_file=posix
18167442
EB
2240 ;;
2241 "":*:yes | yes:*:yes )
2242 thread_file=solaris
2243 ;;
615be2cf 2244 esac
61ed06c3 2245 ;;
1910440e
RS
2246sparc-wrs-vxworks)
2247 tm_file="${tm_file} elfos.h svr4.h sparc/sysv4.h vx-common.h vxworks.h sparc/vxworks.h"
2248 tmake_file="${tmake_file} sparc/t-vxworks"
2249 ;;
61ed06c3 2250sparc64-*-elf*)
81b47219 2251 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h sparc/sp64-elf.h"
fe609b0f 2252 extra_options="${extra_options} sparc/little-endian.opt"
2d69e3cb 2253 tmake_file="${tmake_file} sparc/t-crtfm"
61ed06c3
HPN
2254 extra_parts="crtbegin.o crtend.o"
2255 ;;
c7240cbd
DB
2256sparc64-*-freebsd*|ultrasparc-*-freebsd*)
2257 tm_file="${tm_file} ${fbsd_tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/freebsd.h"
fe609b0f 2258 extra_options="${extra_options} sparc/long-double-switch.opt"
2d69e3cb 2259 tmake_file="${tmake_file} sparc/t-crtfm"
c7240cbd 2260 case "x$with_cpu" in
e0054185 2261 xultrasparc) ;;
c7240cbd
DB
2262 x) with_cpu=ultrasparc ;;
2263 *) echo "$with_cpu not supported for freebsd target"; exit 1 ;;
2264 esac
2265 ;;
981f6289 2266sparc64-*-linux*) # 64-bit SPARC's running GNU/Linux
5f7ca34b 2267 tm_file="sparc/biarch64.h ${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h linux.h sparc/linux64.h"
fe609b0f 2268 extra_options="${extra_options} sparc/long-double-switch.opt"
fbf2ca7b 2269 tmake_file="${tmake_file} sparc/t-linux sparc/t-linux64 sparc/t-crtfm"
61ed06c3 2270 ;;
4cb7482c 2271sparc64-*-netbsd*)
4cb7482c
MG
2272 tm_file="sparc/biarch64.h ${tm_file}"
2273 tm_file="${tm_file} dbxelf.h elfos.h svr4.h sparc/sysv4.h netbsd.h netbsd-elf.h sparc/netbsd-elf.h"
fe609b0f
EB
2274 extra_options="${extra_options} sparc/long-double-switch.opt"
2275 tmake_file="${tmake_file} sparc/t-netbsd64"
4cb7482c 2276 ;;
85d9c13c
TS
2277spu-*-elf*)
2278 tm_file="dbxelf.h elfos.h spu/spu-elf.h spu/spu.h"
2279 tmake_file="spu/t-spu-elf"
2280 extra_headers="spu_intrinsics.h spu_internals.h vmx2spu.h spu_mfcio.h vec_types.h"
2281 extra_modes=spu/spu-modes.def
2282 c_target_objs="${c_target_objs} spu-c.o"
2283 cxx_target_objs="${cxx_target_objs} spu-c.o"
2284 ;;
70d65164
NC
2285v850e1-*-*)
2286 target_cpu_default="TARGET_CPU_v850e1"
2287 tm_file="dbxelf.h elfos.h svr4.h v850/v850.h"
2288 tm_p_file=v850/v850-protos.h
2289 tmake_file=v850/t-v850e
2290 md_file=v850/v850.md
2291 out_file=v850/v850.c
df3a97a8 2292 extra_options="${extra_options} v850/v850.opt"
70d65164
NC
2293 if test x$stabs = xyes
2294 then
2295 tm_file="${tm_file} dbx.h"
2296 fi
2297 use_collect2=no
2298 c_target_objs="v850-c.o"
2299 cxx_target_objs="v850-c.o"
2300 ;;
b4378319
NC
2301v850e-*-*)
2302 target_cpu_default="TARGET_CPU_v850e"
2303 tm_file="dbxelf.h elfos.h svr4.h v850/v850.h"
2304 tm_p_file=v850/v850-protos.h
c490cc89 2305 tmake_file=v850/t-v850e
b4378319
NC
2306 md_file=v850/v850.md
2307 out_file=v850/v850.c
df3a97a8 2308 extra_options="${extra_options} v850/v850.opt"
b4378319
NC
2309 if test x$stabs = xyes
2310 then
2311 tm_file="${tm_file} dbx.h"
2312 fi
2313 use_collect2=no
2314 c_target_objs="v850-c.o"
2315 cxx_target_objs="v850-c.o"
2316 ;;
61ed06c3
HPN
2317v850-*-*)
2318 target_cpu_default="TARGET_CPU_generic"
c40409ce 2319 tm_file="dbxelf.h elfos.h svr4.h ${tm_file}"
61ed06c3
HPN
2320 tmake_file=v850/t-v850
2321 if test x$stabs = xyes
2322 then
2323 tm_file="${tm_file} dbx.h"
2324 fi
2325 use_collect2=no
c3edd394
NC
2326 c_target_objs="v850-c.o"
2327 cxx_target_objs="v850-c.o"
61ed06c3 2328 ;;
69474c3c 2329vax-*-netbsdelf*)
ec20cffb 2330 tm_file="${tm_file} elfos.h netbsd.h netbsd-elf.h vax/elf.h vax/netbsd-elf.h"
69474c3c 2331 ;;
61ed06c3 2332vax-*-netbsd*)
f982f805 2333 tm_file="${tm_file} netbsd.h netbsd-aout.h vax/netbsd.h"
61ed06c3 2334 tmake_file=t-netbsd
1169f9e0 2335 extra_parts=""
5721cd84 2336 use_collect2=yes
61ed06c3
HPN
2337 ;;
2338vax-*-openbsd*)
ca11c37c 2339 tm_file="vax/vax.h vax/openbsd1.h openbsd.h vax/openbsd.h"
61ed06c3
HPN
2340 use_collect2=yes
2341 ;;
14d269bb
GK
2342xstormy16-*-elf)
2343 # For historical reasons, the target files omit the 'x'.
c40409ce 2344 tm_file="dbxelf.h elfos.h svr4.h stormy16/stormy16.h"
14d269bb
GK
2345 tm_p_file=stormy16/stormy16-protos.h
2346 md_file=stormy16/stormy16.md
2347 out_file=stormy16/stormy16.c
d45d2353 2348 extra_options=stormy16/stormy16.opt
14d269bb
GK
2349 tmake_file="stormy16/t-stormy16"
2350 extra_parts="crtbegin.o crtend.o"
2351 ;;
6d656178 2352xtensa*-*-elf*)
03984308 2353 tm_file="${tm_file} dbxelf.h elfos.h svr4.h xtensa/elf.h"
1f37a5b2 2354 tmake_file="xtensa/t-xtensa xtensa/t-elf"
03984308 2355 ;;
6d656178 2356xtensa*-*-linux*)
03984308 2357 tm_file="${tm_file} dbxelf.h elfos.h svr4.h linux.h xtensa/linux.h"
65d151a7 2358 tmake_file="${tmake_file} xtensa/t-xtensa xtensa/t-linux"
03984308 2359 ;;
2beef00e
AO
2360am33_2.0-*-linux*)
2361 tm_file="mn10300/mn10300.h dbxelf.h elfos.h linux.h mn10300/linux.h"
65d151a7 2362 tmake_file="${tmake_file} mn10300/t-linux"
2beef00e 2363 gas=yes gnu_ld=yes
2beef00e
AO
2364 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
2365 use_collect2=no
2366 ;;
38b2d076
DD
2367m32c-*-elf*)
2368 tm_file="dbxelf.h elfos.h svr4.h ${tm_file}"
2369 c_target_objs="m32c-pragma.o"
2370 cxx_target_objs="m32c-pragma.o"
38b2d076 2371 ;;
61ed06c3 2372*)
b01bc573 2373 echo "*** Configuration ${target} not supported" 1>&2
61ed06c3
HPN
2374 exit 1
2375 ;;
2376esac
2377
f6bc51cb 2378case ${target} in
f6bc51cb 2379i[34567]86-*-linux* | x86_64-*-linux*)
ab442df7 2380 tmake_file="${tmake_file} i386/t-pmm_malloc i386/t-i386"
f6bc51cb
L
2381 ;;
2382i[34567]86-*-* | x86_64-*-*)
ab442df7 2383 tmake_file="${tmake_file} i386/t-gmm_malloc i386/t-i386"
f6bc51cb
L
2384 ;;
2385esac
2386
73f09c99 2387# Support for --with-cpu and related options (and a few unrelated options,
a89ea0df 2388# too).
35341073
NN
2389case ${with_cpu} in
2390 yes | no)
2391 echo "--with-cpu must be passed a value" 1>&2
2392 exit 1
2393 ;;
2394esac
83079d89 2395
35341073
NN
2396# If there is no $with_cpu option, try to infer one from ${target}.
2397# This block sets nothing except for with_cpu.
2398if test x$with_cpu = x ; then
2399 case ${target} in
d326eaf0
JH
2400 i386-*-*)
2401 with_cpu=i386
2402 ;;
35341073
NN
2403 i486-*-*)
2404 with_cpu=i486
2405 ;;
2406 i586-*-*)
43aba518 2407 case ${target_noncanonical} in
35341073
NN
2408 k6_2-*)
2409 with_cpu=k6-2
2410 ;;
2411 k6_3-*)
2412 with_cpu=k6-3
2413 ;;
2414 k6-*)
2415 with_cpu=k6
2416 ;;
2417 pentium_mmx-*|winchip_c6-*|winchip2-*|c3-*)
2418 with_cpu=pentium-mmx
2419 ;;
2420 *)
2421 with_cpu=pentium
2422 ;;
2423 esac
2424 ;;
2425 i686-*-* | i786-*-*)
43aba518 2426 case ${target_noncanonical} in
aafc814c 2427 amdfam10-*|barcelona-*)
21efb4d4
HJ
2428 with_cpu=amdfam10
2429 ;;
9a609388 2430 k8-*|opteron-*|athlon_64-*)
35341073
NN
2431 with_cpu=k8
2432 ;;
2433 athlon_xp-*|athlon_mp-*|athlon_4-*)
2434 with_cpu=athlon-4
2435 ;;
2436 athlon_tbird-*|athlon-*)
2437 with_cpu=athlon
2438 ;;
537bbabd
EC
2439 geode-*)
2440 with_cpu=geode
2441 ;;
35341073
NN
2442 pentium2-*)
2443 with_cpu=pentium2
2444 ;;
5bbeea44 2445 pentium3-*|pentium3m-*)
35341073
NN
2446 with_cpu=pentium3
2447 ;;
5bbeea44 2448 pentium4-*|pentium4m-*)
35341073
NN
2449 with_cpu=pentium4
2450 ;;
5bbeea44
JH
2451 prescott-*)
2452 with_cpu=prescott
2453 ;;
2454 nocona-*)
2455 with_cpu=nocona
2456 ;;
30fd45a0
EC
2457 core2-*)
2458 with_cpu=core2
2459 ;;
5bbeea44
JH
2460 pentium_m-*)
2461 with_cpu=pentium-m
2462 ;;
d326eaf0 2463 pentiumpro-*)
35341073
NN
2464 with_cpu=pentiumpro
2465 ;;
d326eaf0
JH
2466 *)
2467 with_cpu=generic
2468 ;;
35341073
NN
2469 esac
2470 ;;
2471 x86_64-*-*)
d326eaf0 2472 case ${target_noncanonical} in
aafc814c 2473 amdfam10-*|barcelona-*)
21efb4d4
HJ
2474 with_cpu=amdfam10
2475 ;;
d326eaf0
JH
2476 k8-*|opteron-*|athlon_64-*)
2477 with_cpu=k8
2478 ;;
2479 nocona-*)
2480 with_cpu=nocona
2481 ;;
30fd45a0
EC
2482 core2-*)
2483 with_cpu=core2
2484 ;;
d326eaf0
JH
2485 *)
2486 with_cpu=generic
2487 ;;
2488 esac
35341073
NN
2489 ;;
2490 alphaev6[78]*-*-*)
2491 with_cpu=ev67
2492 ;;
2493 alphaev6*-*-*)
2494 with_cpu=ev6
2495 ;;
2496 alphapca56*-*-*)
2497 with_cpu=pca56
2498 ;;
2499 alphaev56*-*-*)
2500 with_cpu=ev56
2501 ;;
2502 alphaev5*-*-*)
2503 with_cpu=ev5
2504 ;;
faf9ab98 2505 frv-*-*linux* | frv400-*-*linux*)
34208acf
AO
2506 with_cpu=fr400
2507 ;;
faf9ab98
AH
2508 frv550-*-*linux*)
2509 with_cpu=fr550
2510 ;;
59fbf3cb 2511 m68k*-*-*)
10e96df4
NS
2512 case "$with_arch" in
2513 "cf")
2514 with_cpu=${default_cf_cpu}
2515 ;;
2516 "" | "m68k")
2517 with_cpu=m${default_m68k_cpu}
2518 ;;
2519 esac
59fbf3cb 2520 ;;
9200d6c8
RS
2521 mips*-*-vxworks)
2522 with_arch=mips2
2523 ;;
35341073
NN
2524 sparc*-*-*)
2525 with_cpu="`echo ${target} | sed 's/-.*$//'`"
35341073
NN
2526 ;;
2527 esac
8981c15b
JM
2528
2529 # Avoid overriding --with-cpu-32 and --with-cpu-64 values.
2530 case ${target} in
2531 i[34567]86-*-*|x86_64-*-*)
2532 if test x$with_cpu != x; then
2533 if test x$with_cpu_32 != x || test x$with_cpu_64 != x; then
2534 if test x$with_cpu_32 = x; then
2535 with_cpu_32=$with_cpu
2536 fi
2537 if test x$with_cpu_64 = x; then
2538 with_cpu_64=$with_cpu
2539 fi
2540 with_cpu=
2541 fi
2542 fi
2543 ;;
2544 esac
35341073 2545fi
83079d89 2546
fe3e7450
AM
2547# Similarly for --with-schedule.
2548if test x$with_schedule = x; then
2549 case ${target} in
cd985f66 2550 hppa1*)
fe3e7450
AM
2551 # Override default PA8000 scheduling model.
2552 with_schedule=7100LC
2553 ;;
2554 esac
2555fi
83079d89 2556
fe3e7450
AM
2557# Validate and mark as valid any --with options supported
2558# by this target. In order to use a particular --with option
2559# you must list it in supported_defaults; validating the value
2560# is optional. This case statement should set nothing besides
2561# supported_defaults.
7816bea0 2562
fe3e7450
AM
2563supported_defaults=
2564case "${target}" in
83079d89 2565 alpha*-*-*)
7816bea0
DJ
2566 supported_defaults="cpu tune"
2567 for which in cpu tune; do
2568 eval "val=\$with_$which"
b597bfd8
NN
2569 case "$val" in
2570 "" \
2571 | ev4 | ev45 | 21064 | ev5 | 21164 | ev56 | 21164a \
2572 | pca56 | 21164PC | 21164pc | ev6 | 21264 | ev67 \
2573 | 21264a)
7816bea0
DJ
2574 ;;
2575 *)
2576 echo "Unknown CPU used in --with-$which=$val" 1>&2
2577 exit 1
2578 ;;
2579 esac
2580 done
2581 ;;
2582
2583 arm*-*-*)
3cf94279 2584 supported_defaults="arch cpu float tune fpu abi mode"
7816bea0 2585 for which in cpu tune; do
2682e19f 2586 # See if it matches any of the entries in arm-cores.def
7816bea0 2587 eval "val=\$with_$which"
b73f075a 2588 if [ x"$val" = x ] \
d98a72fd 2589 || grep "^ARM_CORE(\"$val\"," \
b73f075a
PB
2590 ${srcdir}/config/arm/arm-cores.def \
2591 > /dev/null; then
2592 # Ok
d98a72fd
RE
2593 new_val=`grep "^ARM_CORE(\"$val\"," \
2594 ${srcdir}/config/arm/arm-cores.def | \
2595 sed -e 's/^[^,]*,[ ]*//' | \
2596 sed -e 's/,.*$//'`
32078532 2597 eval "target_${which}_cname=$new_val"
d98a72fd 2598 echo "For $val real value is $new_val"
b73f075a
PB
2599 true
2600 else
2601 echo "Unknown CPU used in --with-$which=$val" 1>&2
2602 exit 1
2682e19f 2603 fi
7816bea0
DJ
2604 done
2605
b597bfd8
NN
2606 case "$with_arch" in
2607 "" \
9b66ebb1 2608 | armv[23456] | armv2a | armv3m | armv4t | armv5t \
bf98ec6c
PB
2609 | armv5te | armv6j |armv6k | armv6z | armv6zk | armv6-m \
2610 | armv7 | armv7-a | armv7-r | armv7-m \
fa91adc6 2611 | iwmmxt | ep9312)
83079d89 2612 # OK
4ed47bea
JM
2613 ;;
2614 *)
7816bea0 2615 echo "Unknown arch used in --with-arch=$with_arch" 1>&2
83079d89 2616 exit 1
73f09c99
DJ
2617 ;;
2618 esac
83079d89 2619
b597bfd8
NN
2620 case "$with_float" in
2621 "" \
9b66ebb1 2622 | soft | hard | softfp)
83079d89 2623 # OK
73f09c99 2624 ;;
83079d89 2625 *)
7816bea0 2626 echo "Unknown floating point type used in --with-float=$with_float" 1>&2
83079d89 2627 exit 1
73f09c99
DJ
2628 ;;
2629 esac
7816bea0 2630
9b66ebb1
PB
2631 case "$with_fpu" in
2632 "" \
88f77cba 2633 | fpa | fpe2 | fpe3 | maverick | vfp | vfp3 | neon )
9b66ebb1
PB
2634 # OK
2635 ;;
2636 *)
5848830f
PB
2637 echo "Unknown fpu used in --with-fpu=$with_fpu" 2>&1
2638 exit 1
2639 ;;
2640 esac
2641
2642 case "$with_abi" in
2643 "" \
2644 | apcs-gnu | atpcs | aapcs | iwmmxt )
2645 #OK
2646 ;;
2647 *)
2648 echo "Unknown ABI used in --with-abi=$with_abi"
9b66ebb1
PB
2649 exit 1
2650 ;;
2651 esac
2652
3cf94279
PB
2653 case "$with_mode" in
2654 "" \
2655 | arm | thumb )
2656 #OK
2657 ;;
2658 *)
2659 echo "Unknown mode used in --with-mode=$with_mode"
2660 exit 1
2661 ;;
2662 esac
2663
7816bea0 2664 if test "x$with_arch" != x && test "x$with_cpu" != x; then
5848830f 2665 echo "Warning: --with-arch overrides --with-cpu=$with_cpu" 1>&2
7816bea0 2666 fi
73f09c99 2667 ;;
73f09c99 2668
34208acf
AO
2669 fr*-*-*linux*)
2670 supported_defaults=cpu
2671 case "$with_cpu" in
2672 fr400) ;;
faf9ab98 2673 fr550) ;;
34208acf
AO
2674 *)
2675 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2
2676 exit 1
2677 ;;
2678 esac
2679 ;;
2680
cd985f66 2681 fido-*-* | m68k*-*-*)
10e96df4
NS
2682 supported_defaults="arch cpu"
2683 case "$with_arch" in
2684 "" | "m68k"| "cf")
2685 m68k_arch_family="$with_arch"
2686 ;;
2687 *)
2688 echo "Invalid --with-arch=$with_arch" 1>&2
2689 exit 1
2690 ;;
2691 esac
59fbf3cb
NS
2692
2693 # We always have a $with_cpu setting here.
3704aae9 2694 case "$with_cpu" in
900ec02d
JB
2695 "m68000" | "m68010" | "m68020" | "m68030" | "m68040" | "m68060")
2696 m68k_cpu_ident=$with_cpu
2697 ;;
2698 "m68020-40")
2699 m68k_cpu_ident=m68020
2700 tm_defines="$tm_defines M68K_DEFAULT_TUNE=u68020_40"
2701 ;;
2702 "m68020-60")
2703 m68k_cpu_ident=m68020
2704 tm_defines="$tm_defines M68K_DEFAULT_TUNE=u68020_60"
3704aae9
RZ
2705 ;;
2706 *)
900ec02d
JB
2707 # We need the C identifier rather than the string.
2708 m68k_cpu_ident=`awk -v arg="\"$with_cpu\"" \
2709 'BEGIN { FS="[ \t]*[,()][ \t]*" }; \
2710 $1 == "M68K_DEVICE" && $2 == arg { print $3 }' \
2711 ${srcdir}/config/m68k/m68k-devices.def`
2712 if [ x"$m68k_cpu_ident" = x ] ; then
2713 echo "Unknown CPU used in --with-cpu=$with_cpu" 1>&2
2714 exit 1
2715 fi
2716 with_cpu="mcpu=$with_cpu"
3704aae9
RZ
2717 ;;
2718 esac
2719 ;;
2720
cd985f66 2721 hppa*-*-*)
7816bea0
DJ
2722 supported_defaults="arch schedule"
2723
b597bfd8
NN
2724 case "$with_arch" in
2725 "" | 1.0 | 1.1 | 2.0)
7816bea0
DJ
2726 # OK
2727 ;;
2728 *)
2729 echo "Unknown architecture used in --with-arch=$with_arch" 1>&2
2730 exit 1
2731 ;;
2732 esac
2733
b597bfd8
NN
2734 case "$with_schedule" in
2735 "" | 700 | 7100 | 7100LC | 7200 | 7300 | 8000)
83079d89
DJ
2736 # OK
2737 ;;
2738 *)
2739 echo "Unknown processor used in --with-schedule=$with_schedule." 1>&2
2740 exit 1
2741 ;;
2742 esac
73f09c99 2743 ;;
73f09c99 2744
83079d89 2745 i[34567]86-*-* | x86_64-*-*)
8981c15b
JM
2746 supported_defaults="arch arch_32 arch_64 cpu cpu_32 cpu_64 tune tune_32 tune_64"
2747 for which in arch arch_32 arch_64 cpu cpu_32 cpu_64 tune tune_32 tune_64; do
7816bea0 2748 eval "val=\$with_$which"
16aa42c0 2749 case ${val} in
d326eaf0 2750 i386 | i486 \
16aa42c0
NN
2751 | i586 | pentium | pentium-mmx | winchip-c6 | winchip2 \
2752 | c3 | c3-2 | i686 | pentiumpro | pentium2 | pentium3 \
2753 | pentium4 | k6 | k6-2 | k6-3 | athlon | athlon-tbird \
537bbabd 2754 | athlon-4 | athlon-xp | athlon-mp | geode \
d326eaf0
JH
2755 | prescott | pentium-m | pentium4m | pentium3m)
2756 case "${target}" in
2757 x86_64-*-*)
8981c15b
JM
2758 case "x$which" in
2759 *_32)
2760 ;;
2761 *)
2762 echo "CPU given in --with-$which=$val doesn't support 64bit mode." 1>&2
2763 exit 1
2764 ;;
2765 esac
d326eaf0
JH
2766 ;;
2767 esac
2768 # OK
2769 ;;
aafc814c 2770 "" | amdfam10 | barcelona | k8 | opteron | athlon64 | athlon-fx | nocona | core2 | generic)
7816bea0
DJ
2771 # OK
2772 ;;
2773 *)
2774 echo "Unknown CPU given in --with-$which=$val." 1>&2
2775 exit 1
2776 ;;
2777 esac
2778 done
2779 ;;
2780
2781 mips*-*-*)
e21d5757 2782 supported_defaults="abi arch float tune divide llsc mips-plt"
7816bea0 2783
16aa42c0
NN
2784 case ${with_float} in
2785 "" | soft | hard)
83079d89
DJ
2786 # OK
2787 ;;
2788 *)
7816bea0 2789 echo "Unknown floating point type used in --with-float=$with_float" 1>&2
83079d89
DJ
2790 exit 1
2791 ;;
2792 esac
73f09c99 2793
16aa42c0
NN
2794 case ${with_abi} in
2795 "" | 32 | o64 | n32 | 64 | eabi)
83079d89
DJ
2796 # OK
2797 ;;
2798 *)
7816bea0 2799 echo "Unknown ABI used in --with-abi=$with_abi" 1>&2
83079d89
DJ
2800 exit 1
2801 ;;
2802 esac
9f0df97a
DD
2803
2804 case ${with_divide} in
2805 "" | breaks | traps)
2806 # OK
2807 ;;
2808 *)
2809 echo "Unknown division check type use in --with-divide=$with_divide" 1>&2
2810 exit 1
66471b47
DD
2811 ;;
2812 esac
2813
2814 case ${with_llsc} in
2815 yes)
2816 with_llsc=llsc
2817 ;;
2818 no)
2819 with_llsc="no-llsc"
2820 ;;
2821 "")
2822 # OK
2823 ;;
2824 *)
2825 echo "Unknown llsc type used in --with-llsc" 1>&2
2826 exit 1
2827 ;;
9f0df97a 2828 esac
e21d5757
DJ
2829
2830 case ${with_mips_plt} in
2831 yes)
2832 with_mips_plt=plt
2833 ;;
2834 no)
2835 with_mips_plt=no-plt
2836 ;;
2837 "")
2838 ;;
2839 *)
2840 echo "Unknown --with-mips-plt argument: $with_mips_plt" 1>&2
2841 exit 1
2842 ;;
2843 esac
73f09c99 2844 ;;
73f09c99 2845
7816bea0
DJ
2846 powerpc*-*-* | rs6000-*-*)
2847 supported_defaults="cpu float tune"
2848
2849 for which in cpu tune; do
2850 eval "val=\$with_$which"
16aa42c0 2851 case ${val} in
1ab1739c
JJ
2852 default32 | default64)
2853 with_which="with_$which"
2854 eval $with_which=
2855 ;;
b0bfee6e
DE
2856 405cr)
2857 tm_defines="${tm_defines} CONFIG_PPC405CR"
2858 eval "with_$which=405"
2859 ;;
1ab1739c 2860 "" | common \
d40c9e33 2861 | power | power[234567] | power6x | powerpc | powerpc64 \
16aa42c0 2862 | rios | rios1 | rios2 | rsc | rsc1 | rs64a \
4adf8008
PB
2863 | 401 | 403 | 405 | 405fp | 440 | 440fp | 464 | 464fp \
2864 | 505 | 601 | 602 | 603 | 603e | ec603e | 604 \
edae5fe3
DE
2865 | 604e | 620 | 630 | 740 | 750 | 7400 | 7450 \
2866 | e300c[23] | 854[08] | e500mc \
2867 | 801 | 821 | 823 | 860 | 970 | G3 | G4 | G5 | cell)
7816bea0
DJ
2868 # OK
2869 ;;
2870 *)
2871 echo "Unknown cpu used in --with-$which=$val." 1>&2
2872 exit 1
2873 ;;
2874 esac
2875 done
2876 ;;
2877
f13e0d4e
UW
2878 s390*-*-*)
2879 supported_defaults="arch mode tune"
2880
2881 for which in arch tune; do
2882 eval "val=\$with_$which"
16aa42c0 2883 case ${val} in
93538e8e 2884 "" | g5 | g6 | z900 | z990 | z9-109 | z9-ec | z10)
f13e0d4e
UW
2885 # OK
2886 ;;
2887 *)
2888 echo "Unknown cpu used in --with-$which=$val." 1>&2
2889 exit 1
2890 ;;
2891 esac
2892 done
2893
16aa42c0
NN
2894 case ${with_mode} in
2895 "" | esa | zarch)
f13e0d4e
UW
2896 # OK
2897 ;;
2898 *)
2899 echo "Unknown architecture mode used in --with-mode=$with_mode." 1>&2
2900 exit 1
2901 ;;
2902 esac
2903 ;;
2904
da28a3b9
JR
2905 sh[123456ble]-*-* | sh-*-*)
2906 supported_defaults="cpu"
25e651ca 2907 case "`echo $with_cpu | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ_ abcdefghijklmnopqrstuvwxyz- | sed s/sh/m/`" in
da28a3b9
JR
2908 "" | m1 | m2 | m2e | m3 | m3e | m4 | m4-single | m4-single-only | m4-nofpu )
2909 # OK
2910 ;;
157371cf
AO
2911 m2a | m2a-single | m2a-single-only | m2a-nofpu)
2912 ;;
312209c6
AO
2913 m4a | m4a-single | m4a-single-only | m4a-nofpu | m4al)
2914 ;;
da28a3b9
JR
2915 *)
2916 echo "Unknown CPU used in --with-cpu=$with_cpu, known values:" 1>&2
2917 echo "m1 m2 m2e m3 m3e m4 m4-single m4-single-only m4-nofpu" 1>&2
312209c6 2918 echo "m4a m4a-single m4a-single-only m4a-nofpu m4al" 1>&2
157371cf 2919 echo "m2a m2a-single m2a-single-only m2a-nofpu" 1>&2
da28a3b9
JR
2920 exit 1
2921 ;;
2922 esac
2923 ;;
83079d89 2924 sparc*-*-*)
7816bea0
DJ
2925 supported_defaults="cpu float tune"
2926
2927 for which in cpu tune; do
2928 eval "val=\$with_$which"
16aa42c0
NN
2929 case ${val} in
2930 "" | sparc | sparcv9 | sparc64 | sparc86x \
2931 | v7 | cypress | v8 | supersparc | sparclite | f930 \
2932 | f934 | hypersparc | sparclite86x | sparclet | tsc701 \
9eeaed6e 2933 | v9 | ultrasparc | ultrasparc3 | niagara | niagara2)
7816bea0
DJ
2934 # OK
2935 ;;
2936 *)
2937 echo "Unknown cpu used in --with-$which=$val" 1>&2
2938 exit 1
2939 ;;
2940 esac
2941 done
73f09c99 2942
16aa42c0
NN
2943 case ${with_float} in
2944 "" | soft | hard)
83079d89
DJ
2945 # OK
2946 ;;
2947 *)
7816bea0 2948 echo "Unknown floating point type used in --with-float=$with_float" 1>&2
83079d89
DJ
2949 exit 1
2950 ;;
2951 esac
73f09c99 2952 ;;
73f09c99 2953
39aeae85
SL
2954 spu-*-*)
2955 supported_defaults="arch tune"
2956
2957 for which in arch tune; do
2958 eval "val=\$with_$which"
2959 case ${val} in
2960 "" | cell | celledp)
2961 # OK
2962 ;;
2963 *)
2964 echo "Unknown cpu used in --with-$which=$val." 1>&2
2965 exit 1
2966 ;;
2967 esac
2968 done
2969 ;;
2970
83079d89 2971 v850*-*-*)
7816bea0 2972 supported_defaults=cpu
16aa42c0
NN
2973 case ${with_cpu} in
2974 "" | v850e | v850e1)
83079d89
DJ
2975 # OK
2976 ;;
2977 *)
2978 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2
2979 exit 1
2980 ;;
2981 esac
73f09c99 2982 ;;
fe3e7450 2983esac
73f09c99 2984
fe3e7450
AM
2985# Set some miscellaneous flags for particular targets.
2986target_cpu_default2=
2987case ${target} in
83079d89 2988 alpha*-*-*)
83079d89
DJ
2989 if test x$gas = xyes
2990 then
7816bea0 2991 target_cpu_default2="MASK_GAS"
83079d89 2992 fi
73f09c99 2993 ;;
73f09c99 2994
83079d89 2995 arm*-*-*)
32078532
RE
2996 if test x$target_cpu_cname = x
2997 then
2998 target_cpu_default2=TARGET_CPU_generic
2999 else
3000 target_cpu_default2=TARGET_CPU_$target_cpu_cname
3001 fi
83079d89 3002 ;;
0e5a4ad8 3003
cd985f66 3004 hppa*-*-*)
d711cf67 3005 target_cpu_default2="MASK_BIG_SWITCH"
83079d89 3006 if test x$gas = xyes
61ed06c3 3007 then
d711cf67 3008 target_cpu_default2="${target_cpu_default2}|MASK_GAS|MASK_JUMP_IN_DELAY"
83079d89 3009 fi
73f09c99 3010 ;;
73f09c99 3011
cd985f66 3012 fido*-*-* | m68k*-*-*)
900ec02d 3013 target_cpu_default2=$m68k_cpu_ident
10e96df4
NS
3014 if [ x"$m68k_arch_family" != x ]; then
3015 tmake_file="m68k/t-$m68k_arch_family $tmake_file"
3016 fi
900ec02d
JB
3017 ;;
3018
ff473280
L
3019 i[34567]86-*-darwin* | x86_64-*-darwin*)
3020 tmake_file="${tmake_file} i386/t-fprules-softfp soft-fp/t-softfp"
3021 ;;
3022 i[34567]86-*-linux* | x86_64-*-linux*)
3023 tmake_file="${tmake_file} i386/t-fprules-softfp soft-fp/t-softfp i386/t-linux"
3024 ;;
3025
83079d89 3026 mips*-*-*)
5811cb27
RS
3027 if test x$gnu_ld = xyes
3028 then
21c425ee 3029 target_cpu_default2="MASK_SPLIT_ADDRESSES"
5811cb27 3030 fi
b01bc573 3031 case ${target} in
83079d89
DJ
3032 mips*el-*-*)
3033 tm_defines="TARGET_ENDIAN_DEFAULT=0 $tm_defines"
3034 ;;
3035 esac
83079d89
DJ
3036 if test "x$enable_gofast" = xyes
3037 then
c15c90bb 3038 tm_defines="US_SOFTWARE_GOFAST $tm_defines"
83079d89
DJ
3039 tmake_file="mips/t-gofast $tmake_file"
3040 else
3041 tmake_file="mips/t-mips $tmake_file"
74826b0f
EC
3042 fi
3043 ;;
83079d89
DJ
3044
3045 powerpc*-*-* | rs6000-*-*)
7816bea0
DJ
3046 # FIXME: The PowerPC port uses the value set at compile time,
3047 # although it's only cosmetic.
83079d89 3048 if test "x$with_cpu" != x
61ed06c3 3049 then
83079d89 3050 target_cpu_default2="\\\"$with_cpu\\\""
61ed06c3 3051 fi
83079d89
DJ
3052 out_file=rs6000/rs6000.c
3053 c_target_objs="${c_target_objs} rs6000-c.o"
3054 cxx_target_objs="${cxx_target_objs} rs6000-c.o"
3055 tmake_file="rs6000/t-rs6000 ${tmake_file}"
4d4cbc0e
AH
3056
3057 if test x$enable_e500_double = xyes
3058 then
3059 tm_file="$tm_file rs6000/e500-double.h"
3060 fi
74826b0f 3061 ;;
73f09c99 3062
a6ab9fc0
R
3063 sh[123456ble]*-*-* | sh-*-*)
3064 c_target_objs="${c_target_objs} sh-c.o"
3065 cxx_target_objs="${cxx_target_objs} sh-c.o"
3066 ;;
3067
83079d89 3068 sparc*-*-*)
7816bea0
DJ
3069 # Some standard aliases.
3070 case x$with_cpu in
3071 xsparc)
3072 with_cpu=v7
3073 ;;
7816bea0
DJ
3074 xsparcv9 | xsparc64)
3075 with_cpu=v9
3076 ;;
3077 esac
3078
a4d05547 3079 # The SPARC port checks this value at compile-time.
73f09c99
DJ
3080 target_cpu_default2="TARGET_CPU_$with_cpu"
3081 ;;
83079d89 3082 v850*-*-*)
7816bea0
DJ
3083 # FIXME: The v850 is "special" in that it does not support
3084 # runtime CPU selection, only --with-cpu.
83079d89
DJ
3085 case "x$with_cpu" in
3086 x)
3087 ;;
3088 xv850e)
3089 target_cpu_default2="TARGET_CPU_$with_cpu"
3090 ;;
3091 esac
3092 ;;
fe3e7450 3093esac
61ed06c3 3094
fe3e7450 3095t=
e21d5757 3096all_defaults="abi cpu cpu_32 cpu_64 arch arch_32 arch_64 tune tune_32 tune_64 schedule float mode fpu divide llsc mips-plt"
fe3e7450
AM
3097for option in $all_defaults
3098do
e21d5757 3099 eval "val=\$with_"`echo $option | sed s/-/_/g`
fe3e7450
AM
3100 if test -n "$val"; then
3101 case " $supported_defaults " in
3102 *" $option "*)
3103 ;;
3104 *)
3105 echo "This target does not support --with-$option." 2>&1
6e0eea31 3106 echo "Valid --with options are: $supported_defaults" 2>&1
fe3e7450
AM
3107 exit 1
3108 ;;
3109 esac
7816bea0 3110
fe3e7450
AM
3111 if test "x$t" = x
3112 then
3113 t="{ \"$option\", \"$val\" }"
3114 else
3115 t="${t}, { \"$option\", \"$val\" }"
7816bea0 3116 fi
7816bea0 3117 fi
fe3e7450 3118done
7816bea0 3119
fe3e7450
AM
3120if test "x$t" = x
3121then
3122 configure_default_options="{ { NULL, NULL} }"
3123else
3124 configure_default_options="{ ${t} }"
3125fi
3126
3127if test "$target_cpu_default2" != ""
3128then
3129 if test "$target_cpu_default" != ""
61ed06c3 3130 then
fe3e7450
AM
3131 target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
3132 else
3133 target_cpu_default=$target_cpu_default2
61ed06c3 3134 fi
fe3e7450 3135fi