]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/config.gcc
Move libgcc_tm_file to toplevel libgcc
[thirdparty/gcc.git] / gcc / config.gcc
1 # GCC target-specific configuration file.
2 # Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
3 # 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
4
5 #This file is part of GCC.
6
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
9 #Software Foundation; either version 3, or (at your option) any later
10 #version.
11
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.
16
17 #You should have received a copy of the GNU General Public License
18 #along with GCC; see the file COPYING3. If not see
19 #<http://www.gnu.org/licenses/>.
20
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.
26
27 # When you change the cases in the OS or target switches, consider
28 # updating ../libgcc/config.host also.
29
30 # This file switches on the shell variable ${target}, and also uses the
31 # following shell variables:
32 #
33 # with_* Various variables as set by configure.
34 #
35 # enable_threads Either the name, yes or no depending on whether
36 # threads support was requested.
37 #
38 # default_use_cxa_atexit
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.
47 #
48 # default_gnu_indirect_function
49 # The default value for the $enable_gnu_indirect_function
50 # variable. enable_gnu_indirect_function relies
51 # upon the presence of a non-standard gnu ifunc support
52 # in the assembler, linker and dynamic linker.
53 # Since not all libraries provide the dynamic linking
54 # support, the default value of
55 # $default_gnu_indirect_function is set to
56 # "no" except for targets which are known to be OK.
57 #
58 # gas_flag Either yes or no depending on whether GNU as was
59 # requested.
60 #
61 # gnu_ld_flag Either yes or no depending on whether GNU ld was
62 # requested.
63
64 # This file sets the following shell variables for use by the
65 # autoconf-generated configure script:
66 #
67 # cpu_type The name of the cpu, if different from the first
68 # chunk of the canonical target name.
69 #
70 # tm_defines List of target macros to define for all compilations.
71 #
72 # tm_file A list of target macro files, if different from
73 # "$cpu_type/$cpu_type.h". Usually it's constructed
74 # per target in a way like this:
75 # tm_file="${tm_file} dbxelf.h elfos.h ${cpu_type.h}/elf.h"
76 # Note that the preferred order is:
77 # - specific target header "${cpu_type}/${cpu_type.h}"
78 # - generic headers like dbxelf.h elfos.h, etc.
79 # - specializing target headers like ${cpu_type.h}/elf.h
80 # This helps to keep OS specific stuff out of the CPU
81 # defining header ${cpu_type}/${cpu_type.h}.
82 #
83 # It is possible to include automatically-generated
84 # build-directory files by prefixing them with "./".
85 # All other files should relative to $srcdir/config.
86 #
87 # tm_p_file Location of file with declarations for functions
88 # in $out_file.
89 #
90 # out_file The name of the machine description C support
91 # file, if different from "$cpu_type/$cpu_type.c".
92 #
93 # common_out_file The name of the source file for code shared between
94 # the compiler proper and the driver.
95 #
96 # md_file The name of the machine-description file, if
97 # different from "$cpu_type/$cpu_type.md".
98 #
99 # tmake_file A list of machine-description-specific
100 # makefile-fragments, if different from
101 # "$cpu_type/t-$cpu_type".
102 #
103 # extra_modes The name of the file containing a list of extra
104 # machine modes, if necessary and different from
105 # "$cpu_type/$cpu_type-modes.def".
106 #
107 # extra_objs List of extra objects that should be linked into
108 # the compiler proper (cc1, cc1obj, cc1plus)
109 # depending on target.
110 #
111 # extra_gcc_objs List of extra objects that should be linked into
112 # the compiler driver (gcc) depending on target.
113 #
114 # extra_headers List of used header files from the directory
115 # config/${cpu_type}.
116 #
117 # user_headers_inc_next_pre
118 # List of header file names of internal gcc header
119 # files, which should be prefixed by an include_next.
120 # user_headers_inc_next_post
121 # List of header file names of internal gcc header
122 # files, which should be postfixed by an include_next.
123 # use_gcc_tgmath If set, add tgmath.h to the list of used header
124 # files.
125 #
126 # use_gcc_stdint If "wrap", install a version of stdint.h that
127 # wraps the system's copy for hosted compilations;
128 # if "provide", provide a version of systems without
129 # such a system header; otherwise "none", do not
130 # provide such a header at all.
131 #
132 # extra_passes List of extra executables compiled for this target
133 # machine, used for compiling from source to object.
134 #
135 # extra_programs Like extra_passes, but these are used when linking.
136 #
137 # extra_options List of target-dependent .opt files.
138 #
139 # c_target_objs List of extra target-dependent objects that be
140 # linked into the C compiler only.
141 #
142 # cxx_target_objs List of extra target-dependent objects that be
143 # linked into the C++ compiler only.
144 #
145 # fortran_target_objs List of extra target-dependent objects that be
146 # linked into the fortran compiler only.
147 #
148 # target_gtfiles List of extra source files with type information.
149 #
150 # xm_defines List of macros to define when compiling for the
151 # target machine.
152 #
153 # xm_file List of files to include when compiling for the
154 # target machine.
155 #
156 # use_collect2 Set to yes or no, depending on whether collect2
157 # will be used.
158 #
159 # target_cpu_default Set to override the default target model.
160 #
161 # gdb_needs_out_file_path
162 # Set to yes if gdb needs a dir command with
163 # `dirname $out_file`.
164 #
165 # thread_file Set to control which thread package to use.
166 #
167 # gas Set to yes or no depending on whether the target
168 # system normally uses GNU as.
169 #
170 # need_64bit_hwint Set to yes if HOST_WIDE_INT must be 64 bits wide
171 # for this target. This is true if this target
172 # supports "long" or "wchar_t" wider than 32 bits,
173 # or BITS_PER_WORD is wider than 32 bits.
174 # The setting made here must match the one made in
175 # other locations such as libcpp/configure.ac
176 #
177 # configure_default_options
178 # Set to an initializer for configure_default_options
179 # in configargs.h, based on --with-cpu et cetera.
180 #
181 # native_system_header_dir
182 # Where system header files are found for this
183 # target. This defaults to /usr/include. If
184 # the --with-sysroot configure option or the
185 # --sysroot command line option is used this
186 # will be relative to the sysroot.
187
188 # The following variables are used in each case-construct to build up the
189 # outgoing variables:
190 #
191 # gnu_ld Set to yes or no depending on whether the target
192 # system normally uses GNU ld.
193 #
194 # target_has_targetcm Set to yes or no depending on whether the target
195 # has its own definition of targetcm.
196 #
197 # target_has_targetm_common Set to yes or no depending on whether the
198 # target has its own definition of targetm_common.
199
200 out_file=
201 common_out_file=
202 tmake_file=
203 extra_headers=
204 user_headers_inc_next_pre=
205 user_headers_inc_next_post=
206 use_gcc_tgmath=yes
207 use_gcc_stdint=none
208 extra_passes=
209 extra_programs=
210 extra_objs=
211 extra_gcc_objs=
212 extra_options=
213 c_target_objs=
214 cxx_target_objs=
215 fortran_target_objs=
216 target_has_targetcm=no
217 target_has_targetm_common=yes
218 tm_defines=
219 xm_defines=
220 # Set this to force installation and use of collect2.
221 use_collect2=
222 # Set this to override the default target model.
223 target_cpu_default=
224 # Set this if gdb needs a dir command with `dirname $out_file`
225 gdb_needs_out_file_path=
226 # Set this to control which thread package will be used.
227 thread_file=
228 # Reinitialize these from the flag values every loop pass, since some
229 # configure entries modify them.
230 gas="$gas_flag"
231 gnu_ld="$gnu_ld_flag"
232 default_use_cxa_atexit=no
233 default_gnu_indirect_function=no
234 target_gtfiles=
235 need_64bit_hwint=
236 need_64bit_isa=
237 native_system_header_dir=/usr/include
238
239 # Don't carry these over build->host->target. Please.
240 xm_file=
241 md_file=
242
243 # Obsolete configurations.
244 case ${target} in
245 alpha*-dec-osf5.1* \
246 | i[34567]86-*-interix3* \
247 | mips-sgi-irix6.5 \
248 | mips*-*-openbsd* \
249 | score-* \
250 | *-*-solaris2.8* \
251 )
252 if test "x$enable_obsolete" != xyes; then
253 echo "*** Configuration ${target} is obsolete." >&2
254 echo "*** Specify --enable-obsolete to build it anyway." >&2
255 echo "*** Support will be REMOVED in the next major release of GCC," >&2
256 echo "*** unless a maintainer comes forward." >&2
257 exit 1
258 fi;;
259 esac
260
261 # Unsupported targets list. Do not put an entry in this list unless
262 # it would otherwise be caught by a more permissive pattern. The list
263 # should be in alphabetical order.
264 case ${target} in
265 i[34567]86-go32-* \
266 | i[34567]86-*-go32* \
267 | m68k-*-uclinuxoldabi* \
268 | mips64orion*-*-rtems* \
269 | pdp11-*-bsd \
270 | sparc-hal-solaris2* \
271 | thumb-*-* \
272 | *-*-freebsd[12] | *-*-freebsd[12].* \
273 | *-*-freebsd*aout* \
274 | *-*-linux*aout* \
275 | *-*-linux*coff* \
276 | *-*-linux*libc1* \
277 | *-*-linux*oldld* \
278 | *-*-rtemsaout* \
279 | *-*-rtemscoff* \
280 | *-*-solaris2 \
281 | *-*-solaris2.[0-7] \
282 | *-*-solaris2.[0-7].* \
283 | *-*-sysv* \
284 | vax-*-vms* \
285 )
286 echo "*** Configuration ${target} not supported" 1>&2
287 exit 1
288 ;;
289 esac
290
291 # Set default cpu_type, tm_file, tm_p_file and xm_file so it can be
292 # updated in each machine entry. Also set default extra_headers for some
293 # machines.
294 tm_p_file=
295 cpu_type=`echo ${target} | sed 's/-.*$//'`
296 cpu_is_64bit=
297 case ${target} in
298 m32c*-*-*)
299 cpu_type=m32c
300 tmake_file=m32c/t-m32c
301 target_has_targetm_common=no
302 ;;
303 alpha*-*-*)
304 cpu_type=alpha
305 need_64bit_hwint=yes
306 extra_options="${extra_options} g.opt"
307 ;;
308 am33_2.0-*-linux*)
309 cpu_type=mn10300
310 ;;
311 arm*-*-*)
312 cpu_type=arm
313 extra_headers="mmintrin.h arm_neon.h"
314 c_target_objs="arm-c.o"
315 cxx_target_objs="arm-c.o"
316 extra_options="${extra_options} arm/arm-tables.opt"
317 ;;
318 avr-*-*)
319 cpu_type=avr
320 c_target_objs="avr-c.o"
321 cxx_target_objs="avr-c.o"
322 extra_options="${extra_options} avr/avr-tables.opt"
323 ;;
324 bfin*-*)
325 cpu_type=bfin
326 ;;
327 crisv32-*)
328 cpu_type=cris
329 ;;
330 frv*) cpu_type=frv
331 extra_options="${extra_options} g.opt"
332 ;;
333 moxie*) cpu_type=moxie
334 target_has_targetm_common=no
335 ;;
336 fido-*-*)
337 cpu_type=m68k
338 extra_headers=math-68881.h
339 extra_options="${extra_options} m68k/m68k-tables.opt"
340 ;;
341 i[34567]86-*-*)
342 cpu_type=i386
343 c_target_objs="i386-c.o"
344 cxx_target_objs="i386-c.o"
345 need_64bit_hwint=yes
346 extra_options="${extra_options} fused-madd.opt"
347 extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h
348 pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h
349 nmmintrin.h bmmintrin.h fma4intrin.h wmmintrin.h
350 immintrin.h x86intrin.h avxintrin.h xopintrin.h
351 ia32intrin.h cross-stdarg.h lwpintrin.h popcntintrin.h
352 lzcntintrin.h bmiintrin.h bmi2intrin.h tbmintrin.h
353 avx2intrin.h fmaintrin.h"
354 ;;
355 x86_64-*-*)
356 cpu_type=i386
357 c_target_objs="i386-c.o"
358 cxx_target_objs="i386-c.o"
359 extra_options="${extra_options} fused-madd.opt"
360 extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h
361 pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h
362 nmmintrin.h bmmintrin.h fma4intrin.h wmmintrin.h
363 immintrin.h x86intrin.h avxintrin.h xopintrin.h
364 ia32intrin.h cross-stdarg.h lwpintrin.h popcntintrin.h
365 lzcntintrin.h bmiintrin.h tbmintrin.h bmi2intrin.h
366 avx2intrin.h fmaintrin.h"
367 need_64bit_hwint=yes
368 ;;
369 ia64-*-*)
370 extra_headers=ia64intrin.h
371 need_64bit_hwint=yes
372 extra_options="${extra_options} g.opt fused-madd.opt"
373 ;;
374 hppa*-*-*)
375 cpu_type=pa
376 ;;
377 lm32*)
378 extra_options="${extra_options} g.opt"
379 ;;
380 m32r*-*-*)
381 cpu_type=m32r
382 extra_options="${extra_options} g.opt"
383 ;;
384 m68k-*-*)
385 extra_headers=math-68881.h
386 extra_options="${extra_options} m68k/m68k-tables.opt"
387 ;;
388 microblaze*-*-*)
389 cpu_type=microblaze
390 extra_options="${extra_options} g.opt"
391 ;;
392 mips*-*-*)
393 cpu_type=mips
394 need_64bit_hwint=yes
395 extra_headers="loongson.h"
396 extra_options="${extra_options} g.opt mips/mips-tables.opt"
397 ;;
398 picochip-*-*)
399 cpu_type=picochip
400 ;;
401 powerpc*-*-*)
402 cpu_type=rs6000
403 extra_headers="ppc-asm.h altivec.h spe.h ppu_intrinsics.h paired.h spu2vmx.h vec_types.h si2vmx.h"
404 need_64bit_hwint=yes
405 case x$with_cpu in
406 xpowerpc64|xdefault64|x6[23]0|x970|xG5|xpower[34567]|xpower6x|xrs64a|xcell|xa2|xe500mc64)
407 cpu_is_64bit=yes
408 ;;
409 esac
410 extra_options="${extra_options} g.opt fused-madd.opt rs6000/rs6000-tables.opt"
411 ;;
412 rs6000*-*-*)
413 need_64bit_hwint=yes
414 extra_options="${extra_options} g.opt fused-madd.opt rs6000/rs6000-tables.opt"
415 ;;
416 score*-*-*)
417 cpu_type=score
418 extra_options="${extra_options} g.opt"
419 ;;
420 sparc*-*-*)
421 cpu_type=sparc
422 c_target_objs="sparc-c.o"
423 cxx_target_objs="sparc-c.o"
424 extra_headers="visintrin.h"
425 need_64bit_hwint=yes
426 ;;
427 spu*-*-*)
428 cpu_type=spu
429 need_64bit_hwint=yes
430 ;;
431 s390*-*-*)
432 cpu_type=s390
433 need_64bit_hwint=yes
434 extra_options="${extra_options} fused-madd.opt"
435 ;;
436 # Note the 'l'; we need to be able to match e.g. "shle" or "shl".
437 sh[123456789lbe]*-*-* | sh-*-*)
438 cpu_type=sh
439 need_64bit_hwint=yes
440 ;;
441 v850*-*-*)
442 cpu_type=v850
443 ;;
444 tic6x-*-*)
445 cpu_type=c6x
446 extra_headers="c6x_intrinsics.h"
447 extra_options="${extra_options} c6x/c6x-tables.opt"
448 ;;
449 xtensa*-*-*)
450 extra_options="${extra_options} fused-madd.opt"
451 ;;
452 esac
453
454 tm_file=${cpu_type}/${cpu_type}.h
455 if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-protos.h
456 then
457 tm_p_file=${cpu_type}/${cpu_type}-protos.h
458 fi
459 extra_modes=
460 if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-modes.def
461 then
462 extra_modes=${cpu_type}/${cpu_type}-modes.def
463 fi
464 if test -f ${srcdir}/config/${cpu_type}/${cpu_type}.opt
465 then
466 extra_options="${extra_options} ${cpu_type}/${cpu_type}.opt"
467 fi
468
469 case ${target} in
470 i[34567]86-*-*)
471 if test "x$enable_cld" = xyes; then
472 tm_defines="${tm_defines} USE_IX86_CLD=1"
473 fi
474 if test "x$enable_frame_pointer" = xyes; then
475 tm_defines="${tm_defines} USE_IX86_FRAME_POINTER=1"
476 fi
477 tm_file="vxworks-dummy.h ${tm_file}"
478 ;;
479 x86_64-*-*)
480 tm_file="i386/biarch64.h ${tm_file}"
481 if test "x$enable_cld" = xyes; then
482 tm_defines="${tm_defines} USE_IX86_CLD=1"
483 fi
484 if test "x$enable_frame_pointer" = xyes; then
485 tm_defines="${tm_defines} USE_IX86_FRAME_POINTER=1"
486 fi
487 tm_file="vxworks-dummy.h ${tm_file}"
488 ;;
489 esac
490
491 # On a.out targets, we need to use collect2.
492 case ${target} in
493 *-*-*aout*)
494 use_collect2=yes
495 ;;
496 esac
497
498 # Common C libraries.
499 tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3"
500
501 # Common parts for widely ported systems.
502 case ${target} in
503 *-*-darwin*)
504 tmake_file="t-darwin ${cpu_type}/t-darwin"
505 tm_file="${tm_file} darwin.h"
506 case ${target} in
507 *-*-darwin9*)
508 tm_file="${tm_file} darwin9.h"
509 ;;
510 *-*-darwin[12][0-9]*)
511 tm_file="${tm_file} darwin9.h darwin10.h"
512 ;;
513 esac
514 tm_file="${tm_file} ${cpu_type}/darwin.h"
515 tm_p_file="${tm_p_file} darwin-protos.h"
516 target_gtfiles="\$(srcdir)/config/darwin.c"
517 extra_options="${extra_options} darwin.opt"
518 c_target_objs="${c_target_objs} darwin-c.o"
519 cxx_target_objs="${cxx_target_objs} darwin-c.o"
520 fortran_target_objs="darwin-f.o"
521 target_has_targetcm=yes
522 extra_objs="darwin.o"
523 extra_gcc_objs="darwin-driver.o"
524 default_use_cxa_atexit=yes
525 use_gcc_stdint=wrap
526 case ${enable_threads} in
527 "" | yes | posix) thread_file='posix' ;;
528 esac
529 ;;
530 *-*-freebsd*)
531 # This is the generic ELF configuration of FreeBSD. Later
532 # machine-specific sections may refine and add to this
533 # configuration.
534 #
535 # Due to tm_file entry ordering issues that vary between cpu
536 # architectures, we only define fbsd_tm_file to allow the
537 # machine-specific section to dictate the final order of all
538 # entries of tm_file with the minor exception that components
539 # of the tm_file set here will always be of the form:
540 #
541 # freebsd<version_number>.h [freebsd-<conf_option>.h ...] freebsd-spec.h freebsd.h
542 #
543 # The machine-specific section should not tamper with this
544 # ordering but may order all other entries of tm_file as it
545 # pleases around the provided core setting.
546 gas=yes
547 gnu_ld=yes
548 fbsd_major=`echo ${target} | sed -e 's/.*freebsd//g' | sed -e 's/\..*//g'`
549 tm_defines="${tm_defines} FBSD_MAJOR=${fbsd_major}"
550 tmake_file="t-slibgcc"
551 case ${enable_threads} in
552 no)
553 fbsd_tm_file="${fbsd_tm_file} freebsd-nthr.h"
554 ;;
555 "" | yes | posix)
556 thread_file='posix'
557 ;;
558 *)
559 echo 'Unknown thread configuration for FreeBSD'
560 exit 1
561 ;;
562 esac
563 fbsd_tm_file="${fbsd_tm_file} freebsd-spec.h freebsd.h freebsd-stdint.h"
564 extra_options="$extra_options rpath.opt freebsd.opt"
565 case ${target} in
566 *-*-freebsd[345].*)
567 :;;
568 *)
569 default_use_cxa_atexit=yes;;
570 esac
571 # need_64bit_hwint=yes # system compiler has this for all arch!
572 use_gcc_stdint=wrap
573 ;;
574 *-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu | *-*-gnu* | *-*-kopensolaris*-gnu)
575 extra_options="$extra_options gnu-user.opt"
576 gas=yes
577 gnu_ld=yes
578 case ${enable_threads} in
579 "" | yes | posix) thread_file='posix' ;;
580 esac
581 tmake_file="t-slibgcc"
582 case $target in
583 *-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu | *-*-kopensolaris*-gnu)
584 :;;
585 *-*-gnu*)
586 native_system_header_dir=/include
587 ;;
588 esac
589 # glibc / uclibc / bionic switch.
590 # uclibc and bionic aren't usable for GNU/Hurd and neither for GNU/k*BSD.
591 case $target in
592 *linux*)
593 extra_options="$extra_options linux.opt";;
594 esac
595 case $target in
596 *-*-*android*)
597 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_BIONIC"
598 ;;
599 *-*-*uclibc*)
600 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC"
601 ;;
602 *)
603 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_GLIBC"
604 ;;
605 esac
606 # Assume that glibc or uClibc or Bionic are being used and so __cxa_atexit
607 # is provided.
608 default_use_cxa_atexit=yes
609 use_gcc_tgmath=no
610 use_gcc_stdint=wrap
611 # Add Android userspace support to Linux targets.
612 case $target in
613 *linux*)
614 tm_file="$tm_file linux-android.h"
615 extra_options="$extra_options linux-android.opt"
616 ;;
617 esac
618 # Enable compilation for Android by default for *android* targets.
619 case $target in
620 *-*-*android*)
621 tm_defines="$tm_defines ANDROID_DEFAULT=1"
622 ;;
623 *)
624 tm_defines="$tm_defines ANDROID_DEFAULT=0"
625 ;;
626 esac
627 ;;
628 *-*-netbsd*)
629 tmake_file="t-slibgcc"
630 gas=yes
631 gnu_ld=yes
632
633 # NetBSD 2.0 and later get POSIX threads enabled by default.
634 # Allow them to be explicitly enabled on any other version.
635 case ${enable_threads} in
636 "")
637 case ${target} in
638 *-*-netbsd[2-9]* | *-*-netbsdelf[2-9]*)
639 thread_file='posix'
640 tm_defines="${tm_defines} NETBSD_ENABLE_PTHREADS"
641 ;;
642 esac
643 ;;
644 yes | posix)
645 thread_file='posix'
646 tm_defines="${tm_defines} NETBSD_ENABLE_PTHREADS"
647 ;;
648 esac
649
650 # NetBSD 2.0 and later provide __cxa_atexit(), which we use by
651 # default (unless overridden by --disable-__cxa_atexit).
652 case ${target} in
653 *-*-netbsd[2-9]* | *-*-netbsdelf[2-9]*)
654 default_use_cxa_atexit=yes
655 ;;
656 esac
657 ;;
658 *-*-openbsd*)
659 tmake_file="t-openbsd"
660 case ${enable_threads} in
661 yes)
662 thread_file='posix'
663 ;;
664 esac
665 case ${target} in
666 *-*-openbsd2.*|*-*-openbsd3.[012])
667 tm_defines="${tm_defines} HAS_LIBC_R=1" ;;
668 esac
669 ;;
670 *-*-rtems*)
671 case ${enable_threads} in
672 yes) thread_file='rtems' ;;
673 esac
674 extra_options="${extra_options} rtems.opt"
675 use_gcc_stdint=wrap
676 ;;
677 *-*-uclinux*)
678 extra_options="$extra_options gnu-user.opt"
679 use_gcc_stdint=wrap
680 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC SINGLE_LIBC"
681 ;;
682 *-*-solaris2*)
683 # i?86-*-solaris2* needs to insert headers between cpu default and
684 # Solaris 2 specific ones.
685 sol2_tm_file="dbxelf.h elfos.h ${cpu_type}/sysv4.h sol2.h ${cpu_type}/sol2.h"
686 case ${target} in
687 *-*-solaris2.1[0-9]*)
688 sol2_tm_file="${sol2_tm_file} sol2-10.h"
689 use_gcc_stdint=wrap
690 ;;
691 *)
692 use_gcc_stdint=provide
693 ;;
694 esac
695 if test x$gnu_ld = xyes; then
696 tm_file="usegld.h ${tm_file}"
697 fi
698 if test x$gas = xyes; then
699 tm_file="usegas.h ${tm_file}"
700 fi
701 tm_p_file="${tm_p_file} sol2-protos.h"
702 tmake_file="${tmake_file} t-sol2 t-slibgcc"
703 c_target_objs="${c_target_objs} sol2-c.o"
704 cxx_target_objs="${cxx_target_objs} sol2-c.o sol2-cxx.o"
705 extra_objs="sol2.o sol2-stubs.o"
706 extra_options="${extra_options} sol2.opt"
707 case ${enable_threads}:${have_pthread_h}:${have_thread_h} in
708 "":yes:* | yes:yes:* )
709 thread_file=posix
710 ;;
711 esac
712 ;;
713 *-*-*vms*)
714 extra_options="${extra_options} vms/vms.opt"
715 xmake_file=vms/x-vms
716 tmake_file="vms/t-vms t-slibgcc"
717 extra_objs="vms.o"
718 target_gtfiles="$target_gtfiles \$(srcdir)/config/vms/vms.c"
719 tm_p_file="${tm_p_file} vms/vms-protos.h"
720 if test x$gnu_ld != xyes; then
721 # Build wrappers for native case.
722 extra_programs="ld\$(exeext) ar\$(exeext)"
723 tmake_file="$tmake_file vms/t-vmsnative"
724 fi
725 ;;
726 *-*-vxworks*)
727 tmake_file=t-vxworks
728 xm_defines=POSIX
729 extra_options="${extra_options} vxworks.opt"
730 extra_objs=vxworks.o
731 case ${enable_threads} in
732 no) ;;
733 "" | yes | vxworks) thread_file='vxworks' ;;
734 *) echo 'Unknown thread configuration for VxWorks'; exit 1 ;;
735 esac
736 ;;
737 *-*-elf)
738 # Assume that newlib is being used and so __cxa_atexit is provided.
739 default_use_cxa_atexit=yes
740 use_gcc_stdint=wrap
741 ;;
742 esac
743
744 case ${target} in
745 alpha*-*-linux*)
746 tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h glibc-stdint.h"
747 extra_options="${extra_options} alpha/elf.opt"
748 target_cpu_default="MASK_GAS"
749 ;;
750 alpha*-*-freebsd*)
751 tm_file="${tm_file} ${fbsd_tm_file} alpha/elf.h alpha/freebsd.h"
752 extra_options="${extra_options} alpha/elf.opt"
753 target_cpu_default="MASK_GAS"
754 ;;
755 alpha*-*-netbsd*)
756 tm_file="${tm_file} netbsd.h alpha/elf.h netbsd-elf.h alpha/netbsd.h"
757 extra_options="${extra_options} netbsd.opt netbsd-elf.opt \
758 alpha/elf.opt"
759 target_cpu_default="MASK_GAS"
760 ;;
761 alpha*-*-openbsd*)
762 tm_defines="${tm_defines} OBSD_HAS_DECLARE_FUNCTION_NAME OBSD_HAS_DECLARE_FUNCTION_SIZE OBSD_HAS_DECLARE_OBJECT"
763 tm_file="alpha/alpha.h alpha/elf.h openbsd.h openbsd-stdint.h alpha/openbsd.h openbsd-libpthread.h"
764 extra_options="${extra_options} openbsd.opt alpha/elf.opt"
765 # default x-alpha is only appropriate for dec-osf.
766 target_cpu_default="MASK_GAS"
767 ;;
768 alpha*-dec-osf5.1*)
769 if test x$stabs = xyes
770 then
771 tm_file="${tm_file} dbx.h"
772 fi
773 # mips-tfile and mips-tdump are only used with the native assembler
774 # and require the Tru64 UNIX <a.out.h>, so only build native.
775 if test x$gas != xyes && test x${host} = x${target}
776 then
777 extra_passes="mips-tfile mips-tdump"
778 fi
779 use_collect2=yes
780 tmake_file="t-slibgcc"
781 tm_file="${tm_file} alpha/osf5.h"
782 tm_defines="${tm_defines} TARGET_SUPPORT_ARCH=1"
783 extra_options="${extra_options} rpath.opt alpha/osf5.opt"
784 extra_headers=va_list.h
785 use_gcc_stdint=provide
786 case ${enable_threads} in
787 "" | yes | posix)
788 thread_file='posix'
789 ;;
790 esac
791 ;;
792 alpha64-dec-*vms*)
793 tm_file="${tm_file} alpha/vms.h alpha/vms64.h"
794 xm_file="alpha/xm-vms.h vms/xm-vms64.h"
795 tmake_file="${tmake_file} vms/t-vms64 alpha/t-vms"
796 ;;
797 alpha*-dec-*vms*)
798 tm_file="${tm_file} alpha/vms.h"
799 xm_file="alpha/xm-vms.h"
800 tmake_file="${tmake_file} alpha/t-vms"
801 ;;
802 arm-wrs-vxworks)
803 tm_file="elfos.h arm/elf.h arm/aout.h ${tm_file} vx-common.h vxworks.h arm/vxworks.h"
804 extra_options="${extra_options} arm/vxworks.opt"
805 tmake_file="${tmake_file} arm/t-arm arm/t-vxworks"
806 ;;
807 arm*-*-freebsd*)
808 tm_file="dbxelf.h elfos.h ${fbsd_tm_file} arm/elf.h arm/aout.h arm/freebsd.h arm/arm.h"
809 tmake_file="${tmake_file} arm/t-arm arm/t-strongarm-elf"
810 ;;
811 arm*-*-netbsdelf*)
812 tm_file="dbxelf.h elfos.h netbsd.h netbsd-elf.h arm/elf.h arm/aout.h arm/arm.h arm/netbsd-elf.h"
813 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
814 tmake_file="${tmake_file} arm/t-arm"
815 ;;
816 arm*-*-linux*) # ARM GNU/Linux with ELF
817 tm_file="dbxelf.h elfos.h gnu-user.h linux.h linux-android.h glibc-stdint.h arm/elf.h arm/linux-gas.h arm/linux-elf.h"
818 case $target in
819 arm*b-*)
820 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1"
821 ;;
822 esac
823 tmake_file="${tmake_file} arm/t-arm"
824 case ${target} in
825 arm*-*-linux-*eabi)
826 tm_file="$tm_file arm/bpabi.h arm/linux-eabi.h"
827 tmake_file="$tmake_file arm/t-arm-elf arm/t-linux-eabi"
828 # Define multilib configuration for arm-linux-androideabi.
829 case ${target} in
830 *-androideabi)
831 tmake_file="$tmake_file arm/t-linux-androideabi"
832 ;;
833 esac
834 # The BPABI long long divmod functions return a 128-bit value in
835 # registers r0-r3. Correctly modeling that requires the use of
836 # TImode.
837 need_64bit_hwint=yes
838 # The EABI requires the use of __cxa_atexit.
839 default_use_cxa_atexit=yes
840 ;;
841 *)
842 tmake_file="$tmake_file arm/t-linux"
843 ;;
844 esac
845 with_tls=${with_tls:-gnu}
846 tm_file="$tm_file arm/aout.h arm/arm.h"
847 ;;
848 arm*-*-uclinux*) # ARM ucLinux
849 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/linux-gas.h arm/uclinux-elf.h glibc-stdint.h"
850 tmake_file="arm/t-arm arm/t-arm-elf"
851 case ${target} in
852 arm*-*-uclinux*eabi)
853 tm_file="$tm_file arm/bpabi.h arm/uclinux-eabi.h"
854 # The BPABI long long divmod functions return a 128-bit value in
855 # registers r0-r3. Correctly modeling that requires the use of
856 # TImode.
857 need_64bit_hwint=yes
858 # The EABI requires the use of __cxa_atexit.
859 default_use_cxa_atexit=yes
860 esac
861 tm_file="$tm_file arm/aout.h arm/arm.h"
862 ;;
863 arm*-*-ecos-elf)
864 tm_file="dbxelf.h elfos.h newlib-stdint.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/ecos-elf.h"
865 tmake_file="arm/t-arm arm/t-arm-elf"
866 ;;
867 arm*-*-eabi* | arm*-*-symbianelf* )
868 # The BPABI long long divmod functions return a 128-bit value in
869 # registers r0-r3. Correctly modeling that requires the use of
870 # TImode.
871 need_64bit_hwint=yes
872 default_use_cxa_atexit=yes
873 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/bpabi.h"
874 tmake_file="arm/t-arm arm/t-arm-elf"
875 case ${target} in
876 arm*-*-eabi*)
877 tm_file="$tm_file newlib-stdint.h"
878 use_gcc_stdint=wrap
879 ;;
880 arm*-*-symbianelf*)
881 tm_file="${tm_file} arm/symbian.h"
882 # We do not include t-bpabi for Symbian OS because the system
883 # provides its own implementation of the BPABI functions.
884 tmake_file="${tmake_file} arm/t-symbian"
885 ;;
886 esac
887 tm_file="${tm_file} arm/aout.h arm/arm.h"
888 ;;
889 arm*-*-rtems*)
890 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 newlib-stdint.h"
891 tmake_file="arm/t-arm arm/t-arm-elf t-rtems arm/t-rtems"
892 ;;
893 arm*-*-elf)
894 tm_file="dbxelf.h elfos.h newlib-stdint.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h"
895 tmake_file="arm/t-arm arm/t-arm-elf"
896 ;;
897 arm*-wince-pe*)
898 tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h arm/pe.h arm/wince-pe.h"
899 tmake_file="arm/t-arm arm/t-wince-pe"
900 extra_options="${extra_options} arm/pe.opt"
901 extra_objs="pe.o"
902 ;;
903 avr-*-rtems*)
904 tm_file="elfos.h avr/elf.h avr/avr.h dbxelf.h avr/rtems.h rtems.h newlib-stdint.h"
905 tmake_file="avr/t-avr t-rtems avr/t-rtems"
906 extra_gcc_objs="driver-avr.o avr-devices.o"
907 extra_objs="avr-devices.o avr-log.o"
908 ;;
909 avr-*-*)
910 tm_file="elfos.h avr/elf.h avr/avr.h dbxelf.h newlib-stdint.h"
911 use_gcc_stdint=wrap
912 extra_gcc_objs="driver-avr.o avr-devices.o"
913 extra_objs="avr-devices.o avr-log.o"
914 ;;
915 bfin*-elf*)
916 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h bfin/elf.h"
917 tmake_file=bfin/t-bfin-elf
918 use_collect2=no
919 ;;
920 bfin*-uclinux*)
921 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h gnu-user.h linux.h glibc-stdint.h bfin/uclinux.h"
922 tmake_file=bfin/t-bfin-uclinux
923 use_collect2=no
924 ;;
925 bfin*-linux-uclibc*)
926 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h gnu-user.h linux.h glibc-stdint.h bfin/linux.h ./linux-sysroot-suffix.h"
927 tmake_file="bfin/t-bfin-linux t-slibgcc"
928 use_collect2=no
929 ;;
930 bfin*-rtems*)
931 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h bfin/rtems.h rtems.h newlib-stdint.h"
932 tmake_file="t-rtems bfin/t-rtems"
933 ;;
934 bfin*-*)
935 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h bfin/elf.h"
936 use_collect2=no
937 use_gcc_stdint=wrap
938 ;;
939 crisv32-*-elf | crisv32-*-none)
940 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
941 tmake_file="cris/t-cris"
942 target_cpu_default=32
943 gas=yes
944 extra_options="${extra_options} cris/elf.opt"
945 use_gcc_stdint=wrap
946 ;;
947 cris-*-elf | cris-*-none)
948 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
949 tmake_file="cris/t-cris cris/t-elfmulti"
950 gas=yes
951 extra_options="${extra_options} cris/elf.opt"
952 use_gcc_stdint=wrap
953 ;;
954 crisv32-*-linux* | cris-*-linux*)
955 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h glibc-stdint.h cris/linux.h"
956 # We need to avoid using t-linux, so override default tmake_file
957 tmake_file="cris/t-cris cris/t-linux t-slibgcc"
958 extra_options="${extra_options} cris/linux.opt"
959 case $target in
960 cris-*-*)
961 target_cpu_default=10
962 ;;
963 crisv32-*-*)
964 target_cpu_default=32
965 ;;
966 esac
967 ;;
968 fr30-*-elf)
969 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
970 ;;
971 frv-*-elf)
972 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
973 tmake_file=frv/t-frv
974 ;;
975 frv-*-*linux*)
976 tm_file="dbxelf.h elfos.h ${tm_file} \
977 gnu-user.h linux.h glibc-stdint.h frv/linux.h"
978 tmake_file="${tmake_file} frv/t-frv frv/t-linux"
979 ;;
980 moxie-*-elf)
981 gas=yes
982 gnu_ld=yes
983 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
984 tmake_file="${tmake_file} moxie/t-moxie"
985 ;;
986 moxie-*-uclinux*)
987 gas=yes
988 gnu_ld=yes
989 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h glibc-stdint.h moxie/uclinux.h"
990 tmake_file="${tmake_file} moxie/t-moxie"
991 ;;
992 moxie-*-rtems*)
993 tmake_file="${tmake_file} moxie/t-moxie t-rtems"
994 tm_file="moxie/moxie.h dbxelf.h elfos.h moxie/rtems.h rtems.h newlib-stdint.h"
995 ;;
996 h8300-*-rtems*)
997 tmake_file="h8300/t-h8300 t-rtems h8300/t-rtems"
998 tm_file="h8300/h8300.h dbxelf.h elfos.h h8300/elf.h h8300/rtems.h rtems.h newlib-stdint.h"
999 ;;
1000 h8300-*-elf*)
1001 tmake_file="h8300/t-h8300"
1002 tm_file="h8300/h8300.h dbxelf.h elfos.h newlib-stdint.h h8300/elf.h"
1003 ;;
1004 hppa*64*-*-linux*)
1005 target_cpu_default="MASK_PA_11|MASK_PA_20"
1006 tm_file="pa/pa64-start.h ${tm_file} dbxelf.h elfos.h gnu-user.h linux.h \
1007 glibc-stdint.h pa/pa-linux.h pa/pa64-regs.h pa/pa-64.h \
1008 pa/pa64-linux.h"
1009 gas=yes gnu_ld=yes
1010 need_64bit_hwint=yes
1011 ;;
1012 hppa*-*-linux*)
1013 target_cpu_default="MASK_PA_11|MASK_NO_SPACE_REGS"
1014 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h pa/pa-linux.h \
1015 pa/pa32-regs.h pa/pa32-linux.h"
1016 ;;
1017 # port not yet contributed.
1018 #hppa*-*-openbsd*)
1019 # target_cpu_default="MASK_PA_11"
1020 # ;;
1021 hppa[12]*-*-hpux10*)
1022 case ${target} in
1023 hppa1.1-*-* | hppa2*-*-*)
1024 target_cpu_default="MASK_PA_11"
1025 ;;
1026 esac
1027 tm_file="${tm_file} pa/pa32-regs.h dbxelf.h pa/som.h \
1028 pa/pa-hpux.h pa/pa-hpux10.h"
1029 extra_options="${extra_options} pa/pa-hpux.opt pa/pa-hpux10.opt"
1030 case ${target} in
1031 *-*-hpux10.[1-9]*)
1032 tm_file="${tm_file} pa/pa-hpux1010.h"
1033 extra_options="${extra_options} pa/pa-hpux1010.opt"
1034 ;;
1035 esac
1036 use_gcc_stdint=provide
1037 tm_file="${tm_file} hpux-stdint.h"
1038 tmake_file="t-slibgcc"
1039 case ${enable_threads} in
1040 "")
1041 if test x$have_pthread_h = xyes ; then
1042 tmake_file="${tmake_file} pa/t-dce-thr"
1043 fi
1044 ;;
1045 yes | dce)
1046 tmake_file="${tmake_file} pa/t-dce-thr"
1047 ;;
1048 esac
1049 use_collect2=yes
1050 gas=yes
1051 if test "x$with_dwarf2" != x; then
1052 echo "Warning: dwarf2 debug format is not supported for this target, --with-dwarf2 ignored" 1>&2
1053 dwarf2=no
1054 fi
1055 ;;
1056 hppa*64*-*-hpux11*)
1057 target_cpu_default="MASK_PA_11|MASK_PA_20"
1058 if test x$gnu_ld = xyes
1059 then
1060 target_cpu_default="${target_cpu_default}|MASK_GNU_LD"
1061 fi
1062 tm_file="pa/pa64-start.h ${tm_file} dbxelf.h elfos.h \
1063 pa/pa64-regs.h pa/pa-hpux.h pa/pa-hpux1010.h \
1064 pa/pa-hpux11.h"
1065 case ${target} in
1066 *-*-hpux11.[12]*)
1067 tm_file="${tm_file} pa/pa-hpux1111.h pa/pa-64.h pa/pa64-hpux.h"
1068 extra_options="${extra_options} pa/pa-hpux1111.opt"
1069 ;;
1070 *-*-hpux11.[3-9]*)
1071 tm_file="${tm_file} pa/pa-hpux1131.h pa/pa-64.h pa/pa64-hpux.h"
1072 extra_options="${extra_options} pa/pa-hpux1131.opt"
1073 ;;
1074 *)
1075 tm_file="${tm_file} pa/pa-64.h pa/pa64-hpux.h"
1076 ;;
1077 esac
1078 extra_options="${extra_options} pa/pa-hpux.opt \
1079 pa/pa-hpux1010.opt pa/pa64-hpux.opt hpux11.opt"
1080 need_64bit_hwint=yes
1081 tmake_file="t-slibgcc"
1082 case x${enable_threads} in
1083 x | xyes | xposix )
1084 thread_file=posix
1085 ;;
1086 esac
1087 gas=yes
1088 case ${target} in
1089 *-*-hpux11.[01]*)
1090 use_gcc_stdint=provide
1091 tm_file="${tm_file} hpux-stdint.h"
1092 ;;
1093 *-*-hpux11.[23]*)
1094 use_gcc_stdint=wrap
1095 tm_file="${tm_file} hpux-stdint.h"
1096 ;;
1097 esac
1098 ;;
1099 hppa[12]*-*-hpux11*)
1100 case ${target} in
1101 hppa1.1-*-* | hppa2*-*-*)
1102 target_cpu_default="MASK_PA_11"
1103 ;;
1104 esac
1105 tm_file="${tm_file} pa/pa32-regs.h dbxelf.h pa/som.h \
1106 pa/pa-hpux.h pa/pa-hpux1010.h pa/pa-hpux11.h"
1107 extra_options="${extra_options} pa/pa-hpux.opt pa/pa-hpux1010.opt \
1108 hpux11.opt"
1109 case ${target} in
1110 *-*-hpux11.[12]*)
1111 tm_file="${tm_file} pa/pa-hpux1111.h"
1112 extra_options="${extra_options} pa/pa-hpux1111.opt"
1113 ;;
1114 *-*-hpux11.[3-9]*)
1115 tm_file="${tm_file} pa/pa-hpux1131.h"
1116 extra_options="${extra_options} pa/pa-hpux1131.opt"
1117 ;;
1118 esac
1119 tmake_file="t-slibgcc"
1120 case x${enable_threads} in
1121 x | xyes | xposix )
1122 thread_file=posix
1123 ;;
1124 esac
1125 use_collect2=yes
1126 gas=yes
1127 case ${target} in
1128 *-*-hpux11.[01]*)
1129 use_gcc_stdint=provide
1130 tm_file="${tm_file} hpux-stdint.h"
1131 ;;
1132 *-*-hpux11.[23]*)
1133 use_gcc_stdint=wrap
1134 tm_file="${tm_file} hpux-stdint.h"
1135 ;;
1136 esac
1137 if test "x$with_dwarf2" != x; then
1138 echo "Warning: dwarf2 debug format is not supported for this target, --with-dwarf2 ignored" 1>&2
1139 dwarf2=no
1140 fi
1141 ;;
1142 i[34567]86-*-darwin*)
1143 need_64bit_isa=yes
1144 # Baseline choice for a machine that allows m64 support.
1145 with_cpu=${with_cpu:-core2}
1146 tmake_file="${tmake_file} t-slibgcc"
1147 ;;
1148 x86_64-*-darwin*)
1149 with_cpu=${with_cpu:-core2}
1150 tmake_file="${tmake_file} ${cpu_type}/t-darwin64 t-slibgcc"
1151 tm_file="${tm_file} ${cpu_type}/darwin64.h"
1152 ;;
1153 i[34567]86-*-elf*)
1154 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h"
1155 ;;
1156 x86_64-*-elf*)
1157 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h"
1158 ;;
1159 i[34567]86-*-freebsd*)
1160 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${fbsd_tm_file} i386/freebsd.h"
1161 ;;
1162 x86_64-*-freebsd*)
1163 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"
1164 ;;
1165 i[34567]86-*-netbsdelf*)
1166 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-elf.h i386/netbsd-elf.h"
1167 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
1168 ;;
1169 x86_64-*-netbsd*)
1170 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"
1171 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
1172 ;;
1173 i[34567]86-*-openbsd2.*|i[34567]86-*openbsd3.[0123])
1174 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"
1175 extra_options="${extra_options} openbsd.opt"
1176 # needed to unconfuse gdb
1177 tmake_file="${tmake_file} t-openbsd i386/t-openbsd"
1178 # we need collect2 until our bug is fixed...
1179 use_collect2=yes
1180 ;;
1181 i[34567]86-*-openbsd*)
1182 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h"
1183 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h i386/openbsdelf.h"
1184 extra_options="${extra_options} openbsd.opt"
1185 gas=yes
1186 gnu_ld=yes
1187 ;;
1188 i[34567]86-*-linux* | i[34567]86-*-kfreebsd*-gnu | i[34567]86-*-knetbsd*-gnu | i[34567]86-*-gnu* | i[34567]86-*-kopensolaris*-gnu)
1189 # Intel 80386's running GNU/*
1190 # with ELF format using glibc 2
1191 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h gnu-user.h glibc-stdint.h"
1192 case ${target} in
1193 i[34567]86-*-linux*)
1194 tm_file="${tm_file} linux.h"
1195 # Assume modern glibc
1196 default_gnu_indirect_function=yes
1197 if test x$enable_targets = xall; then
1198 tm_file="${tm_file} i386/x86-64.h i386/gnu-user64.h i386/linux64.h"
1199 tm_defines="${tm_defines} TARGET_BI_ARCH=1"
1200 tmake_file="${tmake_file} i386/t-linux64"
1201 x86_multilibs="${with_multilib_list}"
1202 if test "$x86_multilibs" = "default"; then
1203 x86_multilibs="m64,m32"
1204 fi
1205 x86_multilibs=`echo $x86_multilibs | sed -e 's/,/ /g'`
1206 for x86_multilib in ${x86_multilibs}; do
1207 case ${x86_multilib} in
1208 m32 | m64 | mx32)
1209 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${x86_multilib}"
1210 ;;
1211 *)
1212 echo "--with-multilib-list=${x86_with_multilib} not supported."
1213 exit 1
1214 esac
1215 done
1216 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'`
1217 need_64bit_isa=yes
1218 case X"${with_cpu}" in
1219 Xgeneric|Xatom|Xcore2|Xcorei7|Xcorei7-avx|Xnocona|Xx86-64|Xbdver2|Xbdver1|Xbtver1|Xamdfam10|Xbarcelona|Xk8|Xopteron|Xathlon64|Xathlon-fx|Xathlon64-sse3|Xk8-sse3|Xopteron-sse3)
1220 ;;
1221 X)
1222 if test x$with_cpu_64 = x; then
1223 with_cpu_64=generic
1224 fi
1225 ;;
1226 *)
1227 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2
1228 echo "generic atom core2 corei7 corei7-avx nocona x86-64 bdver2 bdver1 btver1 amdfam10 barcelona k8 opteron athlon64 athlon-fx athlon64-sse3 k8-sse3 opteron-sse3" 1>&2
1229 exit 1
1230 ;;
1231 esac
1232 else
1233 tm_file="${tm_file} i386/gnu-user.h i386/linux.h"
1234 fi
1235 ;;
1236 i[34567]86-*-knetbsd*-gnu)
1237 tm_file="${tm_file} i386/gnu-user.h knetbsd-gnu.h i386/knetbsd-gnu.h"
1238 ;;
1239 i[34567]86-*-kfreebsd*-gnu)
1240 tm_file="${tm_file} i386/gnu-user.h kfreebsd-gnu.h i386/kfreebsd-gnu.h"
1241 ;;
1242 i[34567]86-*-kopensolaris*-gnu)
1243 tm_file="${tm_file} i386/gnu-user.h kopensolaris-gnu.h i386/kopensolaris-gnu.h"
1244 ;;
1245 i[34567]86-*-gnu*)
1246 tm_file="$tm_file i386/gnu-user.h gnu.h i386/gnu.h"
1247 ;;
1248 esac
1249 ;;
1250 x86_64-*-linux* | x86_64-*-kfreebsd*-gnu | x86_64-*-knetbsd*-gnu)
1251 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h gnu-user.h glibc-stdint.h \
1252 i386/x86-64.h i386/gnu-user64.h"
1253 case ${target} in
1254 x86_64-*-linux*)
1255 tm_file="${tm_file} linux.h i386/linux64.h"
1256 # Assume modern glibc
1257 default_gnu_indirect_function=yes
1258 ;;
1259 x86_64-*-kfreebsd*-gnu)
1260 tm_file="${tm_file} kfreebsd-gnu.h i386/kfreebsd-gnu64.h"
1261 ;;
1262 x86_64-*-knetbsd*-gnu)
1263 tm_file="${tm_file} knetbsd-gnu.h"
1264 ;;
1265 esac
1266 tmake_file="${tmake_file} i386/t-linux64"
1267 x86_multilibs="${with_multilib_list}"
1268 if test "$x86_multilibs" = "default"; then
1269 x86_multilibs="m64,m32"
1270 fi
1271 x86_multilibs=`echo $x86_multilibs | sed -e 's/,/ /g'`
1272 for x86_multilib in ${x86_multilibs}; do
1273 case ${x86_multilib} in
1274 m32 | m64 | mx32)
1275 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${x86_multilib}"
1276 ;;
1277 *)
1278 echo "--with-multilib-list=${x86_with_multilib} not supported."
1279 exit 1
1280 esac
1281 done
1282 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'`
1283 ;;
1284 i[34567]86-pc-msdosdjgpp*)
1285 xm_file=i386/xm-djgpp.h
1286 tm_file="dbxcoff.h ${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/djgpp.h i386/djgpp-stdint.h"
1287 native_system_header_dir=/dev/env/DJDIR/include
1288 extra_options="${extra_options} i386/djgpp.opt"
1289 gnu_ld=yes
1290 gas=yes
1291 use_gcc_stdint=wrap
1292 ;;
1293 i[34567]86-*-lynxos*)
1294 xm_defines=POSIX
1295 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/lynx.h lynx.h"
1296 tmake_file="${tmake_file} t-lynx"
1297 extra_options="${extra_options} lynx.opt"
1298 thread_file=lynx
1299 gnu_ld=yes
1300 gas=yes
1301 ;;
1302 i[34567]86-*-nto-qnx*)
1303 tm_file="${tm_file} i386/att.h dbxelf.h tm-dwarf2.h elfos.h i386/unix.h i386/nto.h"
1304 extra_options="${extra_options} i386/nto.opt"
1305 gnu_ld=yes
1306 gas=yes
1307 ;;
1308 i[34567]86-*-rtems*)
1309 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h i386/rtemself.h rtems.h newlib-stdint.h"
1310 tmake_file="${tmake_file} i386/t-rtems t-rtems"
1311 ;;
1312 i[34567]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*)
1313 tm_file="${tm_file} i386/unix.h i386/att.h ${sol2_tm_file}"
1314 # Set default arch_32 to pentium4, tune_32 to generic like the other
1315 # i386 targets, although config.guess defaults to i386-pc-solaris2*.
1316 case ${target} in
1317 *-*-solaris2.[89]*)
1318 # Solaris 8 and 9/x86 cannot execute SSE/SSE2 instructions by
1319 # default.
1320 with_arch_32=${with_arch_32:-pentiumpro}
1321 ;;
1322 *)
1323 with_arch_32=${with_arch_32:-pentium4}
1324 ;;
1325 esac
1326 with_tune_32=${with_tune_32:-generic}
1327 case ${target} in
1328 *-*-solaris2.1[0-9]*)
1329 tm_file="${tm_file} i386/x86-64.h i386/sol2-bi.h sol2-bi.h"
1330 tm_defines="${tm_defines} TARGET_BI_ARCH=1"
1331 tmake_file="$tmake_file i386/t-sol2-64"
1332 need_64bit_isa=yes
1333 case X"${with_cpu}" in
1334 Xgeneric|Xatom|Xcore2|Xcorei7|Xcorei7-avx|Xnocona|Xx86-64|Xbdver2|Xbdver1|Xbtver1|Xamdfam10|Xbarcelona|Xk8|Xopteron|Xathlon64|Xathlon-fx|Xathlon64-sse3|Xk8-sse3|Xopteron-sse3)
1335 ;;
1336 X)
1337 if test x$with_cpu_64 = x; then
1338 with_cpu_64=generic
1339 fi
1340 ;;
1341 *)
1342 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2
1343 echo "generic atom core2 corei7 corei7-avx nocona x86-64 bdver2 bdver1 btver1 amdfam10 barcelona k8 opteron athlon64 athlon-fx athlon64-sse3 k8-sse3 opteron-sse3" 1>&2
1344 exit 1
1345 ;;
1346 esac
1347 ;;
1348 esac
1349 ;;
1350 i[4567]86-wrs-vxworks|i[4567]86-wrs-vxworksae)
1351 tm_file="${tm_file} i386/unix.h i386/att.h elfos.h vx-common.h"
1352 case ${target} in
1353 *-vxworksae*)
1354 tm_file="${tm_file} vxworksae.h i386/vx-common.h i386/vxworksae.h"
1355 tmake_file="${tmake_file} i386/t-vxworks i386/t-vxworksae"
1356 ;;
1357 *)
1358 tm_file="${tm_file} vxworks.h i386/vx-common.h i386/vxworks.h"
1359 tmake_file="${tmake_file} i386/t-vxworks"
1360 ;;
1361 esac
1362 ;;
1363 i[34567]86-*-cygwin*)
1364 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygming.h i386/cygwin.h i386/cygwin-stdint.h"
1365 xm_file=i386/xm-cygwin.h
1366 tmake_file="${tmake_file} i386/t-cygming t-slibgcc"
1367 target_gtfiles="\$(srcdir)/config/i386/winnt.c"
1368 extra_options="${extra_options} i386/cygming.opt"
1369 extra_objs="winnt.o winnt-stubs.o"
1370 c_target_objs="${c_target_objs} msformat-c.o"
1371 cxx_target_objs="${cxx_target_objs} winnt-cxx.o msformat-c.o"
1372 if test x$enable_threads = xyes; then
1373 thread_file='posix'
1374 fi
1375 use_gcc_stdint=wrap
1376 ;;
1377 i[34567]86-*-mingw* | x86_64-*-mingw*)
1378 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygming.h"
1379 xm_file=i386/xm-mingw32.h
1380 case ${target} in
1381 x86_64-*-* | *-w64-*)
1382 need_64bit_isa=yes
1383 ;;
1384 *)
1385 ;;
1386 esac
1387 if test x$enable_threads = xposix ; then
1388 tm_file="${tm_file} i386/mingw-pthread.h"
1389 fi
1390 tm_file="${tm_file} i386/mingw32.h"
1391 # This makes the logic if mingw's or the w64 feature set has to be used
1392 case ${target} in
1393 *-w64-*)
1394 user_headers_inc_next_post="${user_headers_inc_next_post} float.h"
1395 user_headers_inc_next_pre="${user_headers_inc_next_pre} stddef.h stdarg.h"
1396 tm_file="${tm_file} i386/mingw-w64.h"
1397 if test x$enable_targets = xall; then
1398 tm_defines="${tm_defines} TARGET_BI_ARCH=1"
1399 case X"${with_cpu}" in
1400 Xgeneric|Xatom|Xcore2|Xcorei7|Xcorei7-avx|Xnocona|Xx86-64|Xbdver2|Xbdver1|Xbtver1|Xamdfam10|Xbarcelona|Xk8|Xopteron|Xathlon64|Xathlon-fx|Xathlon64-sse3|Xk8-sse3|Xopteron-sse3)
1401 ;;
1402 X)
1403 if test x$with_cpu_64 = x; then
1404 with_cpu_64=generic
1405 fi
1406 ;;
1407 *)
1408 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2
1409 echo "generic atom core2 corei7 Xcorei7-avx nocona x86-64 bdver2 bdver1 btver1 amdfam10 barcelona k8 opteron athlon64 athlon-fx athlon64-sse3 k8-sse3 opteron-sse3" 1>&2
1410 exit 1
1411 ;;
1412 esac
1413 fi
1414 ;;
1415 *)
1416 ;;
1417 esac
1418 tm_file="${tm_file} i386/mingw-stdint.h"
1419 tmake_file="${tmake_file} i386/t-cygming t-slibgcc"
1420 case ${target} in
1421 x86_64-w64-*)
1422 tmake_file="${tmake_file} i386/t-mingw-w64"
1423 ;;
1424 i[34567]86-w64-*)
1425 tmake_file="${tmake_file} i386/t-mingw-w32"
1426 ;;
1427 esac
1428 native_system_header_dir=/mingw/include
1429 target_gtfiles="\$(srcdir)/config/i386/winnt.c"
1430 extra_options="${extra_options} i386/cygming.opt i386/mingw.opt"
1431 case ${target} in
1432 *-w64-*)
1433 extra_options="${extra_options} i386/mingw-w64.opt"
1434 ;;
1435 *)
1436 ;;
1437 esac
1438 extra_objs="winnt.o winnt-stubs.o"
1439 c_target_objs="${c_target_objs} msformat-c.o"
1440 cxx_target_objs="${cxx_target_objs} winnt-cxx.o msformat-c.o"
1441 default_use_cxa_atexit=yes
1442 use_gcc_stdint=wrap
1443 case ${enable_threads} in
1444 "" | yes | win32)
1445 thread_file='win32'
1446 ;;
1447 posix)
1448 thread_file='posix'
1449 ;;
1450 esac
1451 case ${target} in
1452 *mingw32crt*)
1453 tm_file="${tm_file} i386/crtdll.h"
1454 ;;
1455 *mingw32msv* | *mingw*)
1456 ;;
1457 esac
1458 ;;
1459 i[34567]86-*-interix3*)
1460 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"
1461 tmake_file="${tmake_file} i386/t-interix"
1462 extra_options="${extra_options} rpath.opt interix.opt"
1463 extra_objs=winnt.o
1464 target_gtfiles="\$(srcdir)/config/i386/winnt.c"
1465 if test x$enable_threads = xyes ; then
1466 thread_file='posix'
1467 fi
1468 if test x$stabs = xyes ; then
1469 tm_file="${tm_file} dbxcoff.h"
1470 fi
1471 ;;
1472 ia64*-*-elf*)
1473 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h ia64/sysv4.h ia64/elf.h"
1474 tmake_file="ia64/t-ia64"
1475 target_cpu_default="0"
1476 if test x$gas = xyes
1477 then
1478 target_cpu_default="${target_cpu_default}|MASK_GNU_AS"
1479 fi
1480 if test x$gnu_ld = xyes
1481 then
1482 target_cpu_default="${target_cpu_default}|MASK_GNU_LD"
1483 fi
1484 ;;
1485 ia64*-*-freebsd*)
1486 tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} ia64/sysv4.h ia64/freebsd.h"
1487 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD"
1488 tmake_file="${tmake_file} ia64/t-ia64"
1489 ;;
1490 ia64*-*-linux*)
1491 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ia64/sysv4.h ia64/linux.h"
1492 tmake_file="${tmake_file} ia64/t-ia64 t-libunwind"
1493 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD"
1494 ;;
1495 ia64*-*-hpux*)
1496 tm_file="${tm_file} dbxelf.h elfos.h ia64/sysv4.h ia64/hpux.h"
1497 tmake_file="ia64/t-ia64 ia64/t-hpux t-slibgcc"
1498 target_cpu_default="MASK_GNU_AS"
1499 case x$enable_threads in
1500 x | xyes | xposix )
1501 thread_file=posix
1502 ;;
1503 esac
1504 use_collect2=no
1505 c_target_objs="ia64-c.o"
1506 cxx_target_objs="ia64-c.o"
1507 extra_options="${extra_options} ia64/ilp32.opt hpux11.opt"
1508 use_gcc_stdint=wrap
1509 tm_file="${tm_file} hpux-stdint.h"
1510 case ${target} in
1511 *-*-hpux11.3*)
1512 tm_file="${tm_file} ia64/hpux-unix2003.h"
1513 ;;
1514 esac
1515 ;;
1516 ia64-hp-*vms*)
1517 tm_file="${tm_file} elfos.h ia64/sysv4.h ia64/elf.h ia64/vms.h ia64/vms64.h"
1518 xm_file="vms/xm-vms.h vms/xm-vms64.h"
1519 tmake_file="${tmake_file} vms/t-vms64 ia64/t-ia64"
1520 target_cpu_default="0"
1521 if test x$gas = xyes
1522 then
1523 target_cpu_default="${target_cpu_default}|MASK_GNU_AS"
1524 fi
1525 extra_options="${extra_options} ia64/vms.opt"
1526 ;;
1527 iq2000*-*-elf*)
1528 tm_file="elfos.h newlib-stdint.h iq2000/iq2000.h"
1529 out_file=iq2000/iq2000.c
1530 md_file=iq2000/iq2000.md
1531 ;;
1532 lm32-*-elf*)
1533 tm_file="dbxelf.h elfos.h ${tm_file}"
1534 tmake_file="${tmake_file} lm32/t-lm32"
1535 ;;
1536 lm32-*-rtems*)
1537 tm_file="dbxelf.h elfos.h ${tm_file} lm32/rtems.h rtems.h newlib-stdint.h"
1538 tmake_file="${tmake_file} lm32/t-lm32"
1539 tmake_file="${tmake_file} t-rtems"
1540 ;;
1541 lm32-*-uclinux*)
1542 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h lm32/uclinux-elf.h"
1543 tmake_file="${tmake_file} lm32/t-lm32"
1544 ;;
1545 m32r-*-elf*)
1546 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
1547 ;;
1548 m32rle-*-elf*)
1549 tm_file="dbxelf.h elfos.h newlib-stdint.h m32r/little.h ${tm_file}"
1550 ;;
1551 m32r-*-rtems*)
1552 tm_file="dbxelf.h elfos.h ${tm_file} m32r/rtems.h rtems.h newlib-stdint.h"
1553 tmake_file="m32r/t-m32r t-rtems"
1554 ;;
1555 m32r-*-linux*)
1556 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} m32r/linux.h"
1557 # We override the tmake_file for linux -- why?
1558 tmake_file="m32r/t-linux t-slibgcc"
1559 gnu_ld=yes
1560 if test x$enable_threads = xyes; then
1561 thread_file='posix'
1562 fi
1563 ;;
1564 m32rle-*-linux*)
1565 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h m32r/little.h ${tm_file} m32r/linux.h"
1566 # We override the tmake_file for linux -- why?
1567 tmake_file="m32r/t-linux t-slibgcc"
1568 gnu_ld=yes
1569 if test x$enable_threads = xyes; then
1570 thread_file='posix'
1571 fi
1572 ;;
1573 m68k-*-elf* | fido-*-elf*)
1574 case ${target} in
1575 fido-*-elf*)
1576 # Check that $with_cpu makes sense.
1577 case $with_cpu in
1578 "" | "fidoa")
1579 ;;
1580 *)
1581 echo "Cannot accept --with-cpu=$with_cpu"
1582 exit 1
1583 ;;
1584 esac
1585 with_cpu=fidoa
1586 ;;
1587 *)
1588 default_m68k_cpu=68020
1589 default_cf_cpu=5206
1590 ;;
1591 esac
1592 tm_file="${tm_file} m68k/m68k-none.h m68k/m68kelf.h dbxelf.h elfos.h newlib-stdint.h m68k/m68kemb.h m68k/m68020-elf.h"
1593 tm_defines="${tm_defines} MOTOROLA=1"
1594 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-m68kelf"
1595 # Add multilibs for targets other than fido.
1596 case ${target} in
1597 fido-*-elf*)
1598 ;;
1599 *)
1600 tmake_file="$tmake_file m68k/t-mlibs"
1601 ;;
1602 esac
1603 ;;
1604 m68k*-*-netbsdelf*)
1605 default_m68k_cpu=68020
1606 default_cf_cpu=5475
1607 tm_file="${tm_file} dbxelf.h elfos.h netbsd.h netbsd-elf.h m68k/netbsd-elf.h"
1608 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
1609 tm_defines="${tm_defines} MOTOROLA=1"
1610 ;;
1611 m68k*-*-openbsd*)
1612 default_m68k_cpu=68020
1613 default_cf_cpu=5475
1614 # needed to unconfuse gdb
1615 tm_defines="${tm_defines} OBSD_OLD_GAS"
1616 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h m68k/openbsd.h"
1617 extra_options="${extra_options} openbsd.opt"
1618 tmake_file="t-openbsd m68k/t-openbsd"
1619 # we need collect2 until our bug is fixed...
1620 use_collect2=yes
1621 ;;
1622 m68k-*-uclinux*) # Motorola m68k/ColdFire running uClinux
1623 # with uClibc, using the new GNU/Linux-style
1624 # ABI.
1625 default_m68k_cpu=68020
1626 default_cf_cpu=5206
1627 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h flat.h m68k/linux.h m68k/uclinux.h ./sysroot-suffix.h"
1628 extra_options="${extra_options} m68k/uclinux.opt"
1629 tm_defines="${tm_defines} MOTOROLA=1"
1630 tmake_file="m68k/t-floatlib m68k/t-uclinux m68k/t-mlibs"
1631 ;;
1632 m68k-*-linux*) # Motorola m68k's running GNU/Linux
1633 # with ELF format using glibc 2
1634 # aka the GNU/Linux C library 6.
1635 default_m68k_cpu=68020
1636 default_cf_cpu=5475
1637 with_arch=${with_arch:-m68k}
1638 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h m68k/linux.h ./sysroot-suffix.h"
1639 extra_options="${extra_options} m68k/ieee.opt"
1640 tm_defines="${tm_defines} MOTOROLA=1"
1641 tmake_file="${tmake_file} m68k/t-floatlib m68k/t-linux m68k/t-mlibs"
1642 ;;
1643 m68k-*-rtems*)
1644 default_m68k_cpu=68020
1645 default_cf_cpu=5206
1646 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-crtstuff t-rtems m68k/t-rtems m68k/t-mlibs"
1647 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 newlib-stdint.h"
1648 tm_defines="${tm_defines} MOTOROLA=1"
1649 ;;
1650 mcore-*-elf)
1651 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file} mcore/mcore-elf.h"
1652 tmake_file=mcore/t-mcore
1653 inhibit_libc=true
1654 ;;
1655 mep-*-*)
1656 tm_file="dbxelf.h elfos.h ${tm_file}"
1657 tmake_file=mep/t-mep
1658 c_target_objs="mep-pragma.o"
1659 cxx_target_objs="mep-pragma.o"
1660 if test -d "${srcdir}/../newlib/libc/include" &&
1661 test "x$with_headers" = x; then
1662 with_headers=yes
1663 fi
1664 use_gcc_stdint=wrap
1665 ;;
1666 microblaze*-linux*)
1667 tm_file="${tm_file} dbxelf.h gnu-user.h linux.h microblaze/linux.h"
1668 c_target_objs="${c_target_objs} microblaze-c.o"
1669 cxx_target_objs="${cxx_target_objs} microblaze-c.o"
1670 ;;
1671 microblaze*-*-*)
1672 tm_file="${tm_file} dbxelf.h"
1673 c_target_objs="${c_target_objs} microblaze-c.o"
1674 cxx_target_objs="${cxx_target_objs} microblaze-c.o"
1675 tmake_file="${tmake_file} microblaze/t-microblaze"
1676 ;;
1677 mips-sgi-irix6.5*)
1678 tm_file="elfos.h ${tm_file} mips/iris6.h"
1679 tmake_file="mips/t-irix6 t-slibgcc"
1680 extra_options="${extra_options} rpath.opt mips/iris6.opt"
1681 target_cpu_default="MASK_ABICALLS"
1682 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_N32"
1683 # Only IRIX Development Foundation 1.3 for IRIX 6.5 provides stdint.h.
1684 use_gcc_stdint=wrap
1685 if test "x$stabs" = xyes
1686 then
1687 tm_file="${tm_file} dbx.h"
1688 fi
1689 if test "x$gnu_ld" = xyes
1690 then
1691 tm_defines="${tm_defines} IRIX_USING_GNU_LD"
1692 fi
1693 case ${enable_threads}:${have_pthread_h} in
1694 "":yes | yes:yes ) thread_file=posix ;;
1695 esac
1696 ;;
1697 mips*-*-netbsd*) # NetBSD/mips, either endian.
1698 target_cpu_default="MASK_ABICALLS"
1699 tm_file="elfos.h ${tm_file} mips/elf.h netbsd.h netbsd-elf.h mips/netbsd.h"
1700 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
1701 ;;
1702 mips64*-*-linux* | mipsisa64*-*-linux*)
1703 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/gnu-user64.h mips/linux64.h"
1704 tmake_file="${tmake_file} mips/t-linux64"
1705 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_N32"
1706 case ${target} in
1707 mips64el-st-linux-gnu)
1708 tm_file="${tm_file} mips/st.h"
1709 tmake_file="${tmake_file} mips/t-st"
1710 ;;
1711 mips64octeon*-*-linux*)
1712 tm_defines="${tm_defines} MIPS_CPU_STRING_DEFAULT=\\\"octeon\\\""
1713 target_cpu_default=MASK_SOFT_FLOAT_ABI
1714 ;;
1715 mipsisa64r2*-*-linux*)
1716 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=65"
1717 ;;
1718 esac
1719 gnu_ld=yes
1720 gas=yes
1721 test x$with_llsc != x || with_llsc=yes
1722 ;;
1723 mips*-*-linux*) # Linux MIPS, either endian.
1724 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/linux.h"
1725 if test x$enable_targets = xall; then
1726 tm_file="${tm_file} mips/gnu-user64.h mips/linux64.h"
1727 tmake_file="${tmake_file} mips/t-linux64"
1728 fi
1729 case ${target} in
1730 mipsisa32r2*)
1731 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33"
1732 ;;
1733 mipsisa32*)
1734 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=32"
1735 esac
1736 test x$with_llsc != x || with_llsc=yes
1737 ;;
1738 mips*-*-openbsd*)
1739 tm_defines="${tm_defines} OBSD_HAS_DECLARE_FUNCTION_NAME OBSD_HAS_DECLARE_OBJECT OBSD_HAS_CORRECT_SPECS"
1740 target_cpu_default="MASK_ABICALLS"
1741 tm_file="mips/mips.h openbsd.h openbsd-stdint.h openbsd-libpthread.h mips/openbsd.h mips/sdb.h"
1742 extra_options="${extra_options} openbsd.opt"
1743 case ${target} in
1744 mips*el-*-openbsd*)
1745 tm_defines="${tm_defines} TARGET_ENDIAN_DEFAULT=0";;
1746 *) tm_defines="${tm_defines} TARGET_ENDIAN_DEFAULT=MASK_BIG_ENDIAN";;
1747 esac
1748 ;;
1749 mips*-sde-elf*)
1750 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/sde.h"
1751 tmake_file="mips/t-sde"
1752 extra_options="${extra_options} mips/sde.opt"
1753 case "${with_newlib}" in
1754 yes)
1755 # newlib / libgloss.
1756 ;;
1757 *)
1758 # MIPS toolkit libraries.
1759 tm_file="$tm_file mips/sdemtk.h"
1760 tmake_file="$tmake_file mips/t-sdemtk"
1761 case ${enable_threads} in
1762 "" | yes | mipssde)
1763 thread_file='mipssde'
1764 ;;
1765 esac
1766 ;;
1767 esac
1768 case ${target} in
1769 mipsisa32r2*)
1770 tm_defines="MIPS_ISA_DEFAULT=33 MIPS_ABI_DEFAULT=ABI_32"
1771 ;;
1772 mipsisa32*)
1773 tm_defines="MIPS_ISA_DEFAULT=32 MIPS_ABI_DEFAULT=ABI_32"
1774 ;;
1775 mipsisa64r2*)
1776 tm_defines="MIPS_ISA_DEFAULT=65 MIPS_ABI_DEFAULT=ABI_N32"
1777 ;;
1778 mipsisa64*)
1779 tm_defines="MIPS_ISA_DEFAULT=64 MIPS_ABI_DEFAULT=ABI_N32"
1780 ;;
1781 esac
1782 ;;
1783 mipsisa32-*-elf* | mipsisa32el-*-elf* | \
1784 mipsisa32r2-*-elf* | mipsisa32r2el-*-elf* | \
1785 mipsisa64-*-elf* | mipsisa64el-*-elf* | \
1786 mipsisa64r2-*-elf* | mipsisa64r2el-*-elf*)
1787 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h"
1788 tmake_file="mips/t-isa3264"
1789 case ${target} in
1790 mipsisa32r2*)
1791 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33"
1792 ;;
1793 mipsisa32*)
1794 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=32"
1795 ;;
1796 mipsisa64r2*)
1797 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=65"
1798 ;;
1799 mipsisa64*)
1800 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64"
1801 ;;
1802 esac
1803 case ${target} in
1804 mipsisa32*-*-elfoabi*)
1805 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_32"
1806 tm_file="${tm_file} mips/elfoabi.h"
1807 ;;
1808 mipsisa64*-*-elfoabi*)
1809 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_O64"
1810 tm_file="${tm_file} mips/elfoabi.h"
1811 ;;
1812 *-*-elf*)
1813 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_EABI"
1814 ;;
1815 esac
1816 ;;
1817 mipsisa64sr71k-*-elf*)
1818 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h"
1819 tmake_file=mips/t-sr71k
1820 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
1821 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64 MIPS_CPU_STRING_DEFAULT=\\\"sr71000\\\" MIPS_ABI_DEFAULT=ABI_EABI"
1822 ;;
1823 mipsisa64sb1-*-elf* | mipsisa64sb1el-*-elf*)
1824 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h"
1825 tmake_file="mips/t-elf mips/t-sb1"
1826 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
1827 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64 MIPS_CPU_STRING_DEFAULT=\\\"sb1\\\" MIPS_ABI_DEFAULT=ABI_O64"
1828 ;;
1829 mips-*-elf* | mipsel-*-elf*)
1830 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h"
1831 tmake_file="mips/t-elf"
1832 ;;
1833 mips64-*-elf* | mips64el-*-elf*)
1834 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h"
1835 tmake_file="mips/t-elf"
1836 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
1837 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_O64"
1838 ;;
1839 mips64vr-*-elf* | mips64vrel-*-elf*)
1840 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/vr.h mips/elf.h"
1841 tmake_file=mips/t-vr
1842 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_EABI"
1843 ;;
1844 mips64orion-*-elf* | mips64orionel-*-elf*)
1845 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elforion.h mips/elf.h"
1846 tmake_file="mips/t-elf"
1847 target_cpu_default="MASK_64BIT|MASK_FLOAT64"
1848 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_O64"
1849 ;;
1850 mips*-*-rtems*)
1851 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/rtems.h rtems.h"
1852 tmake_file="mips/t-elf t-rtems mips/t-rtems"
1853 ;;
1854 mips-wrs-vxworks)
1855 tm_file="elfos.h ${tm_file} mips/elf.h vx-common.h vxworks.h mips/vxworks.h"
1856 tmake_file="${tmake_file} mips/t-vxworks"
1857 ;;
1858 mipstx39-*-elf* | mipstx39el-*-elf*)
1859 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/r3900.h mips/elf.h"
1860 tmake_file="mips/t-r3900"
1861 ;;
1862 mmix-knuth-mmixware)
1863 tm_file="${tm_file} newlib-stdint.h"
1864 need_64bit_hwint=yes
1865 use_gcc_stdint=wrap
1866 ;;
1867 mn10300-*-*)
1868 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
1869 if test x$stabs = xyes
1870 then
1871 tm_file="${tm_file} dbx.h"
1872 fi
1873 use_collect2=no
1874 use_gcc_stdint=wrap
1875 ;;
1876 pdp11-*-*)
1877 tm_file="${tm_file} newlib-stdint.h"
1878 use_gcc_stdint=wrap
1879 ;;
1880 picochip-*)
1881 tm_file="${tm_file} newlib-stdint.h"
1882 use_gcc_stdint=wrap
1883 tmake_file="picochip/t-picochip t-pnt16-warn"
1884 ;;
1885 # port not yet contributed
1886 #powerpc-*-openbsd*)
1887 # tmake_file="${tmake_file} rs6000/t-fprules"
1888 # extra_headers=
1889 # ;;
1890 powerpc-*-darwin*)
1891 extra_options="${extra_options} rs6000/darwin.opt"
1892 case ${target} in
1893 *-darwin1[0-9]* | *-darwin[8-9]*)
1894 tmake_file="${tmake_file} rs6000/t-darwin8"
1895 tm_file="${tm_file} rs6000/darwin8.h"
1896 ;;
1897 *-darwin7*)
1898 tm_file="${tm_file} rs6000/darwin7.h"
1899 ;;
1900 *-darwin[0-6]*)
1901 ;;
1902 esac
1903 tmake_file="${tmake_file} t-slibgcc"
1904 extra_headers=altivec.h
1905 ;;
1906 powerpc64-*-darwin*)
1907 extra_options="${extra_options} ${cpu_type}/darwin.opt"
1908 tmake_file="${tmake_file} ${cpu_type}/t-darwin64 t-slibgcc"
1909 tm_file="${tm_file} ${cpu_type}/darwin8.h ${cpu_type}/darwin64.h"
1910 extra_headers=altivec.h
1911 ;;
1912 powerpc-*-freebsd*)
1913 tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} rs6000/sysv4.h rs6000/freebsd.h"
1914 tmake_file="rs6000/t-fprules rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
1915 extra_options="${extra_options} rs6000/sysv4.opt"
1916 ;;
1917 powerpc-*-netbsd*)
1918 tm_file="${tm_file} dbxelf.h elfos.h netbsd.h netbsd-elf.h freebsd-spec.h rs6000/sysv4.h rs6000/netbsd.h"
1919 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
1920 tmake_file="${tmake_file} rs6000/t-netbsd"
1921 extra_options="${extra_options} rs6000/sysv4.opt"
1922 ;;
1923 powerpc-*-eabispe*)
1924 tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabispe.h"
1925 extra_options="${extra_options} rs6000/sysv4.opt"
1926 tmake_file="rs6000/t-spe rs6000/t-ppccomm"
1927 use_gcc_stdint=wrap
1928 ;;
1929 powerpc-*-eabisimaltivec*)
1930 tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabisim.h rs6000/eabialtivec.h"
1931 extra_options="${extra_options} rs6000/sysv4.opt"
1932 tmake_file="rs6000/t-fprules rs6000/t-ppcendian rs6000/t-ppccomm"
1933 use_gcc_stdint=wrap
1934 ;;
1935 powerpc-*-eabisim*)
1936 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabisim.h"
1937 extra_options="${extra_options} rs6000/sysv4.opt"
1938 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm"
1939 use_gcc_stdint=wrap
1940 ;;
1941 powerpc-*-elf*)
1942 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h"
1943 extra_options="${extra_options} rs6000/sysv4.opt"
1944 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm"
1945 ;;
1946 powerpc-*-eabialtivec*)
1947 tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/eabialtivec.h"
1948 extra_options="${extra_options} rs6000/sysv4.opt"
1949 tmake_file="rs6000/t-fprules rs6000/t-ppcendian rs6000/t-ppccomm"
1950 use_gcc_stdint=wrap
1951 ;;
1952 powerpc-xilinx-eabi*)
1953 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/singlefp.h rs6000/xfpu.h rs6000/xilinx.h"
1954 extra_options="${extra_options} rs6000/sysv4.opt rs6000/xilinx.opt"
1955 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm rs6000/t-xilinx"
1956 use_gcc_stdint=wrap
1957 ;;
1958 powerpc-*-eabi*)
1959 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h"
1960 extra_options="${extra_options} rs6000/sysv4.opt"
1961 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm"
1962 use_gcc_stdint=wrap
1963 ;;
1964 powerpc-*-rtems*)
1965 tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/rtems.h rtems.h"
1966 extra_options="${extra_options} rs6000/sysv4.opt"
1967 tmake_file="rs6000/t-fprules rs6000/t-rtems t-rtems rs6000/t-ppccomm"
1968 ;;
1969 powerpc-*-linux* | powerpc64-*-linux*)
1970 tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h rs6000/sysv4.h"
1971 extra_options="${extra_options} rs6000/sysv4.opt"
1972 tmake_file="rs6000/t-fprules rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm"
1973 maybe_biarch=yes
1974 case ${target} in
1975 powerpc64-*-linux*spe* | powerpc64-*-linux*paired*)
1976 echo "*** Configuration ${target} not supported" 1>&2
1977 exit 1
1978 ;;
1979 powerpc-*-linux*spe* | powerpc-*-linux*paired*)
1980 maybe_biarch=
1981 ;;
1982 powerpc64-*-linux*)
1983 test x$with_cpu != x || cpu_is_64bit=yes
1984 maybe_biarch=always
1985 ;;
1986 esac
1987 case ${maybe_biarch}:${enable_targets}:${cpu_is_64bit} in
1988 always:* | yes:*powerpc64* | yes:all:* | yes:*:yes)
1989 if test x$cpu_is_64bit = xyes; then
1990 tm_file="${tm_file} rs6000/default64.h"
1991 fi
1992 tm_file="rs6000/biarch64.h ${tm_file} rs6000/linux64.h glibc-stdint.h"
1993 tmake_file="$tmake_file rs6000/t-linux64"
1994 extra_options="${extra_options} rs6000/linux64.opt"
1995 ;;
1996 *)
1997 tm_file="${tm_file} rs6000/linux.h glibc-stdint.h"
1998 ;;
1999 esac
2000 case ${target} in
2001 powerpc*-*-linux*ppc476*)
2002 tm_file="${tm_file} rs6000/476.h"
2003 extra_options="${extra_options} rs6000/476.opt" ;;
2004 powerpc*-*-linux*altivec*)
2005 tm_file="${tm_file} rs6000/linuxaltivec.h" ;;
2006 powerpc*-*-linux*spe*)
2007 tm_file="${tm_file} rs6000/linuxspe.h rs6000/e500.h" ;;
2008 powerpc*-*-linux*paired*)
2009 tm_file="${tm_file} rs6000/750cl.h" ;;
2010 esac
2011 if test x${enable_secureplt} = xyes; then
2012 tm_file="rs6000/secureplt.h ${tm_file}"
2013 fi
2014 ;;
2015 powerpc-wrs-vxworks|powerpc-wrs-vxworksae)
2016 tm_file="${tm_file} elfos.h freebsd-spec.h rs6000/sysv4.h"
2017 tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-ppccomm rs6000/t-vxworks"
2018 extra_options="${extra_options} rs6000/sysv4.opt"
2019 extra_headers=ppc-asm.h
2020 case ${target} in
2021 *-vxworksae*)
2022 tm_file="${tm_file} vx-common.h vxworksae.h rs6000/vxworks.h rs6000/e500.h"
2023 tmake_file="${tmake_file} rs6000/t-vxworksae"
2024 ;;
2025 *-vxworks*)
2026 tm_file="${tm_file} vx-common.h vxworks.h rs6000/vxworks.h rs6000/e500.h"
2027 ;;
2028 esac
2029 ;;
2030 powerpc-*-lynxos*)
2031 xm_defines=POSIX
2032 tm_file="${tm_file} dbxelf.h elfos.h rs6000/sysv4.h rs6000/lynx.h lynx.h"
2033 tmake_file="t-lynx rs6000/t-lynx"
2034 extra_options="${extra_options} rs6000/sysv4.opt lynx.opt"
2035 thread_file=lynx
2036 gnu_ld=yes
2037 gas=yes
2038 ;;
2039 powerpcle-*-elf*)
2040 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/sysv4le.h"
2041 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm"
2042 extra_options="${extra_options} rs6000/sysv4.opt"
2043 ;;
2044 powerpcle-*-eabisim*)
2045 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h rs6000/e500.h rs6000/eabisim.h"
2046 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm"
2047 extra_options="${extra_options} rs6000/sysv4.opt"
2048 use_gcc_stdint=wrap
2049 ;;
2050 powerpcle-*-eabi*)
2051 tm_file="${tm_file} dbxelf.h elfos.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h rs6000/e500.h"
2052 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm"
2053 extra_options="${extra_options} rs6000/sysv4.opt"
2054 use_gcc_stdint=wrap
2055 ;;
2056 rs6000-ibm-aix4.[3456789]* | powerpc-ibm-aix4.[3456789]*)
2057 tm_file="rs6000/biarch64.h ${tm_file} rs6000/aix.h rs6000/aix43.h rs6000/xcoff.h rs6000/aix-stdint.h"
2058 tmake_file="rs6000/t-aix43 t-slibgcc"
2059 extra_options="${extra_options} rs6000/aix64.opt"
2060 use_collect2=yes
2061 thread_file='aix'
2062 use_gcc_stdint=provide
2063 extra_headers=
2064 ;;
2065 rs6000-ibm-aix5.1.* | powerpc-ibm-aix5.1.*)
2066 tm_file="rs6000/biarch64.h ${tm_file} rs6000/aix.h rs6000/aix51.h rs6000/xcoff.h rs6000/aix-stdint.h"
2067 extra_options="${extra_options} rs6000/aix64.opt"
2068 tmake_file="rs6000/t-aix43 t-slibgcc"
2069 use_collect2=yes
2070 thread_file='aix'
2071 use_gcc_stdint=wrap
2072 extra_headers=
2073 ;;
2074 rs6000-ibm-aix5.2.* | powerpc-ibm-aix5.2.*)
2075 tm_file="${tm_file} rs6000/aix.h rs6000/aix52.h rs6000/xcoff.h rs6000/aix-stdint.h"
2076 tmake_file="rs6000/t-aix52 t-slibgcc"
2077 extra_options="${extra_options} rs6000/aix64.opt"
2078 use_collect2=yes
2079 thread_file='aix'
2080 use_gcc_stdint=wrap
2081 extra_headers=
2082 ;;
2083 rs6000-ibm-aix5.3.* | powerpc-ibm-aix5.3.*)
2084 tm_file="${tm_file} rs6000/aix.h rs6000/aix53.h rs6000/xcoff.h rs6000/aix-stdint.h"
2085 tmake_file="rs6000/t-aix52 t-slibgcc"
2086 extra_options="${extra_options} rs6000/aix64.opt"
2087 use_collect2=yes
2088 thread_file='aix'
2089 use_gcc_stdint=wrap
2090 extra_headers=altivec.h
2091 ;;
2092 rs6000-ibm-aix[6789].* | powerpc-ibm-aix[6789].*)
2093 tm_file="${tm_file} rs6000/aix.h rs6000/aix61.h rs6000/xcoff.h rs6000/aix-stdint.h"
2094 tmake_file="rs6000/t-aix52 t-slibgcc"
2095 extra_options="${extra_options} rs6000/aix64.opt"
2096 use_collect2=yes
2097 thread_file='aix'
2098 use_gcc_stdint=wrap
2099 extra_headers=altivec.h
2100 ;;
2101 rx-*-elf*)
2102 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
2103 tmake_file="${tmake_file} rx/t-rx"
2104 ;;
2105 s390-*-linux*)
2106 tm_file="s390/s390.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h s390/linux.h"
2107 if test x$enable_targets = xall; then
2108 tmake_file="${tmake_file} s390/t-linux64"
2109 fi
2110 ;;
2111 s390x-*-linux*)
2112 tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h s390/linux.h"
2113 tm_p_file=s390/s390-protos.h
2114 md_file=s390/s390.md
2115 extra_modes=s390/s390-modes.def
2116 out_file=s390/s390.c
2117 tmake_file="${tmake_file} s390/t-linux64"
2118 ;;
2119 s390x-ibm-tpf*)
2120 tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h s390/tpf.h"
2121 tm_p_file=s390/s390-protos.h
2122 md_file=s390/s390.md
2123 extra_modes=s390/s390-modes.def
2124 out_file=s390/s390.c
2125 thread_file='tpf'
2126 extra_options="${extra_options} s390/tpf.opt"
2127 ;;
2128 score-*-elf)
2129 gas=yes
2130 gnu_ld=yes
2131 tm_file="dbxelf.h elfos.h score/elf.h score/score.h newlib-stdint.h"
2132 ;;
2133 sh-*-elf* | sh[12346l]*-*-elf* | \
2134 sh-*-linux* | sh[2346lbe]*-*-linux* | \
2135 sh-*-netbsdelf* | shl*-*-netbsdelf* | sh5-*-netbsd* | sh5l*-*-netbsd* | \
2136 sh64-*-netbsd* | sh64l*-*-netbsd*)
2137 tmake_file="${tmake_file} sh/t-sh sh/t-elf"
2138 if test x${with_endian} = x; then
2139 case ${target} in
2140 sh[1234]*be-*-* | sh[1234]*eb-*-*) with_endian=big ;;
2141 shbe-*-* | sheb-*-*) with_endian=big,little ;;
2142 sh[1234]l* | sh[34]*-*-linux*) with_endian=little ;;
2143 shl* | sh64l* | sh*-*-linux* | \
2144 sh5l* | sh-superh-elf) with_endian=little,big ;;
2145 sh[1234]*-*-*) with_endian=big ;;
2146 *) with_endian=big,little ;;
2147 esac
2148 fi
2149 # TM_ENDIAN_CONFIG is used by t-sh to determine multilibs.
2150 # First word : the default endian.
2151 # Second word: the secondary endian (optional).
2152 case ${with_endian} in
2153 big) TM_ENDIAN_CONFIG=mb ;;
2154 little) TM_ENDIAN_CONFIG=ml ;;
2155 big,little) TM_ENDIAN_CONFIG="mb ml" ;;
2156 little,big) TM_ENDIAN_CONFIG="ml mb" ;;
2157 *) echo "with_endian=${with_endian} not supported."; exit 1 ;;
2158 esac
2159 case ${with_endian} in
2160 little*) tm_file="sh/little.h ${tm_file}" ;;
2161 esac
2162 tm_file="${tm_file} dbxelf.h elfos.h sh/elf.h"
2163 case ${target} in
2164 sh*-*-linux*) tmake_file="${tmake_file} sh/t-linux"
2165 tm_file="${tm_file} gnu-user.h linux.h glibc-stdint.h sh/linux.h" ;;
2166 sh*-*-netbsd*)
2167 tm_file="${tm_file} netbsd.h netbsd-elf.h sh/netbsd-elf.h"
2168 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
2169
2170 ;;
2171 sh*-superh-elf) if test x$with_libgloss != xno; then
2172 with_libgloss=yes
2173 tm_file="${tm_file} sh/newlib.h"
2174 fi
2175 tm_file="${tm_file} sh/embed-elf.h"
2176 tm_file="${tm_file} sh/superh.h"
2177 extra_options="${extra_options} sh/superh.opt" ;;
2178 *) if test x$with_newlib = xyes \
2179 && test x$with_libgloss = xyes; then
2180 tm_file="${tm_file} sh/newlib.h"
2181 fi
2182 tm_file="${tm_file} sh/embed-elf.h" ;;
2183 esac
2184 case ${target} in
2185 sh5*-*-netbsd*)
2186 # SHmedia, 32-bit ABI
2187 tmake_file="${tmake_file} sh/t-sh64"
2188 ;;
2189 sh64*-netbsd*)
2190 # SHmedia, 64-bit ABI
2191 tmake_file="${tmake_file} sh/t-sh64 sh/t-netbsd-sh5-64"
2192 ;;
2193 *-*-netbsd)
2194 ;;
2195 sh64*-*-linux*)
2196 tmake_file="${tmake_file} sh/t-sh64"
2197 tm_file="${tm_file} sh/sh64.h"
2198 extra_headers="shmedia.h ushmedia.h sshmedia.h"
2199 ;;
2200 sh64*)
2201 tmake_file="${tmake_file} sh/t-sh64"
2202 tm_file="${tm_file} sh/sh64.h"
2203 if test x$with_newlib = xyes; then
2204 tm_file="${tm_file} newlib-stdint.h"
2205 fi
2206 extra_headers="shmedia.h ushmedia.h sshmedia.h"
2207 ;;
2208 *-*-elf*)
2209 tm_file="${tm_file} newlib-stdint.h"
2210 ;;
2211 esac
2212 # sed el/eb endian suffixes away to avoid confusion with sh[23]e
2213 case `echo ${target} | sed 's/e[lb]-/-/'` in
2214 sh64*-*-netbsd*) sh_cpu_target=sh5-64media ;;
2215 sh64* | sh5*-*-netbsd*) sh_cpu_target=sh5-32media ;;
2216 sh4a_single_only*) sh_cpu_target=sh4a-single-only ;;
2217 sh4a_single*) sh_cpu_target=sh4a-single ;;
2218 sh4a_nofpu*) sh_cpu_target=sh4a-nofpu ;;
2219 sh4al) sh_cpu_target=sh4al ;;
2220 sh4a*) sh_cpu_target=sh4a ;;
2221 sh4_single_only*) sh_cpu_target=sh4-single-only ;;
2222 sh4_single*) sh_cpu_target=sh4-single ;;
2223 sh4_nofpu*) sh_cpu_target=sh4-nofpu ;;
2224 sh4* | sh-superh-*) sh_cpu_target=sh4 ;;
2225 sh3e*) sh_cpu_target=sh3e ;;
2226 sh*-*-netbsd* | sh3*) sh_cpu_target=sh3 ;;
2227 sh2a_single_only*) sh_cpu_target=sh2a-single-only ;;
2228 sh2a_single*) sh_cpu_target=sh2a-single ;;
2229 sh2a_nofpu*) sh_cpu_target=sh2a-nofpu ;;
2230 sh2a*) sh_cpu_target=sh2a ;;
2231 sh2e*) sh_cpu_target=sh2e ;;
2232 sh2*) sh_cpu_target=sh2 ;;
2233 *) sh_cpu_target=sh1 ;;
2234 esac
2235 # did the user say --without-fp ?
2236 if test x$with_fp = xno; then
2237 case ${sh_cpu_target} in
2238 sh5-*media) sh_cpu_target=${sh_cpu_target}-nofpu ;;
2239 sh4al | sh1) ;;
2240 sh4a* ) sh_cpu_target=sh4a-nofpu ;;
2241 sh4*) sh_cpu_target=sh4-nofpu ;;
2242 sh3*) sh_cpu_target=sh3 ;;
2243 sh2a*) sh_cpu_target=sh2a-nofpu ;;
2244 sh2*) sh_cpu_target=sh2 ;;
2245 *) echo --without-fp not available for $target: ignored
2246 esac
2247 tm_defines="$tm_defines STRICT_NOFPU=1"
2248 fi
2249 sh_cpu_default="`echo $with_cpu|sed s/^m/sh/|tr A-Z_ a-z-`"
2250 case $sh_cpu_default in
2251 sh5-64media-nofpu | sh5-64media | \
2252 sh5-32media-nofpu | sh5-32media | sh5-compact-nofpu | sh5-compact | \
2253 sh2a-single-only | sh2a-single | sh2a-nofpu | sh2a | \
2254 sh4a-single-only | sh4a-single | sh4a-nofpu | sh4a | sh4al | \
2255 sh4-single-only | sh4-single | sh4-nofpu | sh4 | sh4-300 | \
2256 sh3e | sh3 | sh2e | sh2 | sh1) ;;
2257 "") sh_cpu_default=${sh_cpu_target} ;;
2258 *) echo "with_cpu=$with_cpu not supported"; exit 1 ;;
2259 esac
2260 sh_multilibs=${with_multilib_list}
2261 if test "$sh_multilibs" = "default" ; then
2262 case ${target} in
2263 sh64-superh-linux* | \
2264 sh[1234]*) sh_multilibs=${sh_cpu_target} ;;
2265 sh64* | sh5*) sh_multilibs=m5-32media,m5-32media-nofpu,m5-compact,m5-compact-nofpu,m5-64media,m5-64media-nofpu ;;
2266 sh-superh-*) sh_multilibs=m4,m4-single,m4-single-only,m4-nofpu ;;
2267 sh*-*-linux*) sh_multilibs=m1,m3e,m4 ;;
2268 sh*-*-netbsd*) sh_multilibs=m3,m3e,m4 ;;
2269 *) sh_multilibs=m1,m2,m2e,m4,m4-single,m4-single-only,m2a,m2a-single ;;
2270 esac
2271 if test x$with_fp = xno; then
2272 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`"
2273 fi
2274 fi
2275 target_cpu_default=SELECT_`echo ${sh_cpu_default}|tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`
2276 tm_defines=${tm_defines}' SH_MULTILIB_CPU_DEFAULT=\"'`echo $sh_cpu_default|sed s/sh/m/`'\"'
2277 tm_defines="$tm_defines SUPPORT_`echo $sh_cpu_default | sed 's/^m/sh/' | tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`=1"
2278 sh_multilibs=`echo $sh_multilibs | sed -e 's/,/ /g' -e 's/^[Ss][Hh]/m/' -e 's/ [Ss][Hh]/ m/g' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ_ abcdefghijklmnopqrstuvwxyz-`
2279 for sh_multilib in ${sh_multilibs}; do
2280 case ${sh_multilib} in
2281 m1 | m2 | m2e | m3 | m3e | \
2282 m4 | m4-single | m4-single-only | m4-nofpu | m4-300 |\
2283 m4a | m4a-single | m4a-single-only | m4a-nofpu | m4al | \
2284 m2a | m2a-single | m2a-single-only | m2a-nofpu | \
2285 m5-64media | m5-64media-nofpu | \
2286 m5-32media | m5-32media-nofpu | \
2287 m5-compact | m5-compact-nofpu)
2288 # TM_MULTILIB_CONFIG is used by t-sh for the non-endian multilib definition
2289 # It is passed to MULTIILIB_OPTIONS verbatim.
2290 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG}/${sh_multilib}"
2291 tm_defines="$tm_defines SUPPORT_`echo $sh_multilib | sed 's/^m/sh/' | tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`=1"
2292 ;;
2293 \!*) # TM_MULTILIB_EXCEPTIONS_CONFIG is used by t-sh
2294 # It is passed the MULTILIB_EXCEPTIONS verbatim.
2295 TM_MULTILIB_EXCEPTIONS_CONFIG="${TM_MULTILIB_EXCEPTIONS_CONFIG} `echo $sh_multilib | sed 's/^!//'`" ;;
2296 *)
2297 echo "with_multilib_list=${sh_multilib} not supported."
2298 exit 1
2299 ;;
2300 esac
2301 done
2302 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's:^/::'`
2303 if test x${enable_incomplete_targets} = xyes ; then
2304 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"
2305 fi
2306 tm_file="$tm_file ./sysroot-suffix.h"
2307 tmake_file="$tmake_file t-sysroot-suffix"
2308 ;;
2309 sh-*-rtems*)
2310 tmake_file="sh/t-sh t-rtems sh/t-rtems"
2311 tm_file="${tm_file} dbxelf.h elfos.h sh/elf.h sh/embed-elf.h sh/rtemself.h rtems.h newlib-stdint.h"
2312 ;;
2313 sh-wrs-vxworks)
2314 tmake_file="$tmake_file sh/t-sh sh/t-vxworks"
2315 tm_file="${tm_file} elfos.h sh/elf.h sh/embed-elf.h vx-common.h vxworks.h sh/vxworks.h"
2316 ;;
2317 sparc-*-elf*)
2318 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h sparc/sysv4.h sparc/sp-elf.h"
2319 case ${target} in
2320 *-leon-*)
2321 tmake_file="sparc/t-sparc sparc/t-leon"
2322 ;;
2323 *-leon[3-9]*)
2324 tmake_file="sparc/t-sparc sparc/t-leon3"
2325 ;;
2326 *)
2327 tmake_file="sparc/t-sparc sparc/t-elf"
2328 ;;
2329 esac
2330 ;;
2331 sparc-*-rtems*)
2332 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/sp-elf.h sparc/rtemself.h rtems.h newlib-stdint.h"
2333 tmake_file="sparc/t-sparc sparc/t-elf t-rtems"
2334 ;;
2335 sparc-*-linux*)
2336 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h gnu-user.h linux.h glibc-stdint.h"
2337 extra_options="${extra_options} sparc/long-double-switch.opt"
2338 case ${target} in
2339 *-leon-*)
2340 tmake_file="${tmake_file} sparc/t-sparc sparc/t-leon"
2341 ;;
2342 *-leon[3-9]*)
2343 tmake_file="${tmake_file} sparc/t-sparc sparc/t-leon3"
2344 ;;
2345 *)
2346 tmake_file="${tmake_file} sparc/t-sparc"
2347 ;;
2348 esac
2349 if test x$enable_targets = xall; then
2350 tm_file="sparc/biarch64.h ${tm_file} sparc/linux64.h"
2351 tmake_file="${tmake_file} sparc/t-linux64"
2352 else
2353 tm_file="${tm_file} sparc/linux.h"
2354 fi
2355 ;;
2356 sparc-*-netbsdelf*)
2357 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h netbsd.h netbsd-elf.h sparc/netbsd-elf.h"
2358 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
2359 extra_options="${extra_options} sparc/long-double-switch.opt"
2360 tmake_file="${tmake_file} sparc/t-sparc"
2361 ;;
2362 sparc*-*-solaris2*)
2363 tm_file="sparc/biarch64.h ${tm_file} ${sol2_tm_file} sol2-bi.h"
2364 case ${target} in
2365 sparc64-*-* | sparcv9-*-*)
2366 tm_file="sparc/default-64.h ${tm_file}"
2367 ;;
2368 *)
2369 test x$with_cpu != x || with_cpu=v9
2370 ;;
2371 esac
2372 tmake_file="${tmake_file} sparc/t-sparc sparc/t-sol2-64"
2373 ;;
2374 sparc-wrs-vxworks)
2375 tm_file="${tm_file} elfos.h sparc/sysv4.h vx-common.h vxworks.h sparc/vxworks.h"
2376 tmake_file="${tmake_file} sparc/t-sparc sparc/t-vxworks"
2377 ;;
2378 sparc64-*-elf*)
2379 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h sparc/sysv4.h sparc/sp64-elf.h"
2380 extra_options="${extra_options}"
2381 tmake_file="${tmake_file} sparc/t-sparc"
2382 ;;
2383 sparc64-*-rtems*)
2384 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h sparc/sysv4.h sparc/sp64-elf.h sparc/rtemself.h rtems.h"
2385 extra_options="${extra_options}"
2386 tmake_file="${tmake_file} sparc/t-sparc t-rtems"
2387 ;;
2388 sparc64-*-linux*)
2389 tm_file="sparc/biarch64.h ${tm_file} dbxelf.h elfos.h sparc/sysv4.h gnu-user.h linux.h glibc-stdint.h sparc/default-64.h sparc/linux64.h"
2390 extra_options="${extra_options} sparc/long-double-switch.opt"
2391 tmake_file="${tmake_file} sparc/t-sparc sparc/t-linux64"
2392 ;;
2393 sparc64-*-freebsd*|ultrasparc-*-freebsd*)
2394 tm_file="${tm_file} ${fbsd_tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/freebsd.h"
2395 extra_options="${extra_options} sparc/long-double-switch.opt"
2396 case "x$with_cpu" in
2397 xultrasparc) ;;
2398 x) with_cpu=ultrasparc ;;
2399 *) echo "$with_cpu not supported for freebsd target"; exit 1 ;;
2400 esac
2401 tmake_file="${tmake_file} sparc/t-sparc"
2402 ;;
2403 sparc64-*-netbsd*)
2404 tm_file="sparc/biarch64.h ${tm_file}"
2405 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h netbsd.h netbsd-elf.h sparc/netbsd-elf.h"
2406 extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
2407 extra_options="${extra_options} sparc/long-double-switch.opt"
2408 tmake_file="${tmake_file} sparc/t-sparc sparc/t-netbsd64"
2409 ;;
2410 sparc64-*-openbsd*)
2411 tm_file="sparc/openbsd1-64.h ${tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/sp64-elf.h"
2412 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h sparc/openbsd64.h"
2413 extra_options="${extra_options} openbsd.opt"
2414 extra_options="${extra_options}"
2415 gas=yes gnu_ld=yes
2416 with_cpu=ultrasparc
2417 tmake_file="${tmake_file} sparc/t-sparc"
2418 ;;
2419 spu-*-elf*)
2420 tm_file="dbxelf.h elfos.h spu/spu-elf.h spu/spu.h newlib-stdint.h"
2421 tmake_file="spu/t-spu-elf"
2422 native_system_header_dir=/include
2423 extra_headers="spu_intrinsics.h spu_internals.h vmx2spu.h spu_mfcio.h vec_types.h spu_cache.h"
2424 extra_modes=spu/spu-modes.def
2425 c_target_objs="${c_target_objs} spu-c.o"
2426 cxx_target_objs="${cxx_target_objs} spu-c.o"
2427 ;;
2428 tic6x-*-elf)
2429 tm_file="elfos.h ${tm_file} c6x/elf-common.h c6x/elf.h"
2430 tm_file="${tm_file} dbxelf.h tm-dwarf2.h newlib-stdint.h"
2431 tmake_file="c6x/t-c6x c6x/t-c6x-elf"
2432 use_collect2=no
2433 ;;
2434 tic6x-*-uclinux)
2435 tm_file="elfos.h ${tm_file} gnu-user.h linux.h c6x/elf-common.h c6x/uclinux-elf.h"
2436 tm_file="${tm_file} dbxelf.h tm-dwarf2.h glibc-stdint.h"
2437 tm_file="${tm_file} ./sysroot-suffix.h"
2438 tmake_file="t-sysroot-suffix t-slibgcc"
2439 tmake_file="${tmake_file} c6x/t-c6x c6x/t-c6x-elf c6x/t-c6x-uclinux"
2440 use_collect2=no
2441 ;;
2442 v850*-*-*)
2443 case ${target} in
2444 v850e2v3-*-*)
2445 target_cpu_default="TARGET_CPU_v850e2v3"
2446 ;;
2447 v850e2-*-*)
2448 target_cpu_default="TARGET_CPU_v850e2"
2449 ;;
2450 v850e1-*-* | v850es-*-*)
2451 target_cpu_default="TARGET_CPU_v850e1"
2452 ;;
2453 v850e-*-*)
2454 target_cpu_default="TARGET_CPU_v850e"
2455 ;;
2456 v850-*-*)
2457 target_cpu_default="TARGET_CPU_generic"
2458 ;;
2459 esac
2460 tm_file="dbxelf.h elfos.h newlib-stdint.h v850/v850.h"
2461 if test x$stabs = xyes
2462 then
2463 tm_file="${tm_file} dbx.h"
2464 fi
2465 use_collect2=no
2466 c_target_objs="v850-c.o"
2467 cxx_target_objs="v850-c.o"
2468 use_gcc_stdint=wrap
2469 ;;
2470 vax-*-linux*)
2471 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h vax/elf.h vax/linux.h"
2472 extra_options="${extra_options} vax/elf.opt"
2473 ;;
2474 vax-*-netbsdelf*)
2475 tm_file="${tm_file} elfos.h netbsd.h netbsd-elf.h vax/elf.h vax/netbsd-elf.h"
2476 extra_options="${extra_options} netbsd.opt netbsd-elf.opt vax/elf.opt"
2477 ;;
2478 vax-*-openbsd*)
2479 tm_file="vax/vax.h vax/openbsd1.h openbsd.h openbsd-stdint.h openbsd-pthread.h vax/openbsd.h"
2480 extra_options="${extra_options} openbsd.opt"
2481 use_collect2=yes
2482 ;;
2483 xstormy16-*-elf)
2484 # For historical reasons, the target files omit the 'x'.
2485 tm_file="dbxelf.h elfos.h newlib-stdint.h stormy16/stormy16.h"
2486 tm_p_file=stormy16/stormy16-protos.h
2487 md_file=stormy16/stormy16.md
2488 out_file=stormy16/stormy16.c
2489 extra_options=stormy16/stormy16.opt
2490 tmake_file="stormy16/t-stormy16"
2491 ;;
2492 xtensa*-*-elf*)
2493 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h xtensa/elf.h"
2494 extra_options="${extra_options} xtensa/elf.opt"
2495 ;;
2496 xtensa*-*-linux*)
2497 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h xtensa/linux.h"
2498 tmake_file="${tmake_file} xtensa/t-xtensa"
2499 ;;
2500 am33_2.0-*-linux*)
2501 tm_file="mn10300/mn10300.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h mn10300/linux.h"
2502 gas=yes gnu_ld=yes
2503 use_collect2=no
2504 ;;
2505 m32c-*-rtems*)
2506 tm_file="dbxelf.h elfos.h ${tm_file} m32c/rtems.h rtems.h newlib-stdint.h"
2507 tmake_file="${tmake_file} t-rtems"
2508 c_target_objs="m32c-pragma.o"
2509 cxx_target_objs="m32c-pragma.o"
2510 ;;
2511 m32c-*-elf*)
2512 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
2513 c_target_objs="m32c-pragma.o"
2514 cxx_target_objs="m32c-pragma.o"
2515 ;;
2516 *)
2517 echo "*** Configuration ${target} not supported" 1>&2
2518 exit 1
2519 ;;
2520 esac
2521
2522 case ${target} in
2523 i[34567]86-*-linux* | x86_64-*-linux*)
2524 tmake_file="${tmake_file} i386/t-pmm_malloc i386/t-i386"
2525 ;;
2526 i[34567]86-*-* | x86_64-*-*)
2527 tmake_file="${tmake_file} i386/t-gmm_malloc i386/t-i386"
2528 ;;
2529 powerpc*-*-* | rs6000-*-*)
2530 tm_file="${tm_file} rs6000/option-defaults.h"
2531 esac
2532
2533 if [ "$target_has_targetcm" = "no" ]; then
2534 c_target_objs="$c_target_objs default-c.o"
2535 cxx_target_objs="$cxx_target_objs default-c.o"
2536 fi
2537
2538 if [ "$common_out_file" = "" ]; then
2539 if [ "$target_has_targetm_common" = "yes" ]; then
2540 common_out_file="$cpu_type/$cpu_type-common.c"
2541 else
2542 common_out_file="default-common.c"
2543 fi
2544 fi
2545
2546 # Support for --with-cpu and related options (and a few unrelated options,
2547 # too).
2548 case ${with_cpu} in
2549 yes | no)
2550 echo "--with-cpu must be passed a value" 1>&2
2551 exit 1
2552 ;;
2553 esac
2554
2555 # Set arch and cpu from ${target} and ${target_noncanonical}. Set cpu
2556 # to generic if there is no processor scheduler model for the target.
2557 arch=
2558 cpu=
2559 arch_without_sse2=no
2560 arch_without_64bit=no
2561 case ${target} in
2562 i386-*-freebsd*)
2563 if test $fbsd_major -ge 6; then
2564 arch=i486
2565 else
2566 arch=i386
2567 fi
2568 cpu=generic
2569 arch_without_sse2=yes
2570 arch_without_64bit=yes
2571 ;;
2572 i386-*-*)
2573 arch=i386
2574 cpu=i386
2575 arch_without_sse2=yes
2576 arch_without_64bit=yes
2577 ;;
2578 i486-*-*)
2579 arch=i486
2580 cpu=i486
2581 arch_without_sse2=yes
2582 arch_without_64bit=yes
2583 ;;
2584 i586-*-*)
2585 arch_without_sse2=yes
2586 arch_without_64bit=yes
2587 case ${target_noncanonical} in
2588 k6_2-*)
2589 arch=k6-2
2590 cpu=k6-2
2591 ;;
2592 k6_3-*)
2593 arch=k6-3
2594 cpu=k6-3
2595 ;;
2596 k6-*)
2597 arch=k6
2598 cpu=k6
2599 ;;
2600 pentium_mmx-*|winchip_c6-*|winchip2-*|c3-*)
2601 arch=pentium-mmx
2602 cpu=pentium-mmx
2603 ;;
2604 *)
2605 arch=pentium
2606 cpu=pentium
2607 ;;
2608 esac
2609 ;;
2610 i686-*-* | i786-*-*)
2611 case ${target_noncanonical} in
2612 bdver2-*)
2613 arch=bdver2
2614 cpu=bdver2
2615 ;;
2616 bdver1-*)
2617 arch=bdver1
2618 cpu=bdver1
2619 ;;
2620 btver1-*)
2621 arch=btver1
2622 cpu=btver1
2623 ;;
2624 amdfam10-*|barcelona-*)
2625 arch=amdfam10
2626 cpu=amdfam10
2627 ;;
2628 k8_sse3-*|opteron_sse3-*|athlon64_sse3-*)
2629 arch=k8-sse3
2630 cpu=k8-sse3
2631 ;;
2632 k8-*|opteron-*|athlon64-*|athlon_fx-*)
2633 arch=k8
2634 cpu=k8
2635 ;;
2636 athlon_xp-*|athlon_mp-*|athlon_4-*)
2637 arch=athlon-4
2638 cpu=athlon-4
2639 arch_without_sse2=yes
2640 arch_without_64bit=yes
2641 ;;
2642 athlon_tbird-*|athlon-*)
2643 arch=athlon
2644 cpu=athlon
2645 arch_without_sse2=yes
2646 ;;
2647 geode-*)
2648 arch=geode
2649 cpu=geode
2650 arch_without_sse2=yes
2651 ;;
2652 pentium2-*)
2653 arch=pentium2
2654 cpu=pentium2
2655 arch_without_sse2=yes
2656 ;;
2657 pentium3-*|pentium3m-*)
2658 arch=pentium3
2659 cpu=pentium3
2660 arch_without_sse2=yes
2661 ;;
2662 pentium4-*|pentium4m-*)
2663 arch=pentium4
2664 cpu=pentium4
2665 ;;
2666 prescott-*)
2667 arch=prescott
2668 cpu=prescott
2669 ;;
2670 nocona-*)
2671 arch=nocona
2672 cpu=nocona
2673 ;;
2674 atom-*)
2675 arch=atom
2676 cpu=atom
2677 ;;
2678 core2-*)
2679 arch=core2
2680 cpu=core2
2681 ;;
2682 corei7-*)
2683 arch=corei7
2684 cpu=corei7
2685 ;;
2686 corei7_avx-*)
2687 arch=corei7-avx
2688 cpu=corei7-avx
2689 ;;
2690 pentium_m-*)
2691 arch=pentium-m
2692 cpu=pentium-m
2693 ;;
2694 pentiumpro-*)
2695 arch=pentiumpro
2696 cpu=pentiumpro
2697 arch_without_sse2=yes
2698 ;;
2699 *)
2700 arch=pentiumpro
2701 cpu=generic
2702 arch_without_sse2=yes
2703 arch_without_64bit=yes
2704 ;;
2705 esac
2706 ;;
2707 x86_64-*-*)
2708 case ${target_noncanonical} in
2709 bdver2-*)
2710 arch=bdver2
2711 cpu=bdver2
2712 ;;
2713 bdver1-*)
2714 arch=bdver1
2715 cpu=bdver1
2716 ;;
2717 btver1-*)
2718 arch=btver1
2719 cpu=btver1
2720 ;;
2721 amdfam10-*|barcelona-*)
2722 arch=amdfam10
2723 cpu=amdfam10
2724 ;;
2725 k8_sse3-*|opteron_sse3-*|athlon64_sse3-*)
2726 arch=k8-sse3
2727 cpu=k8-sse3
2728 ;;
2729 k8-*|opteron-*|athlon_64-*)
2730 arch=k8
2731 cpu=k8
2732 ;;
2733 nocona-*)
2734 arch=nocona
2735 cpu=nocona
2736 ;;
2737 atom-*)
2738 arch=atom
2739 cpu=atom
2740 ;;
2741 core2-*)
2742 arch=core2
2743 cpu=core2
2744 ;;
2745 corei7-*)
2746 arch=corei7
2747 cpu=corei7
2748 ;;
2749 *)
2750 arch=x86-64
2751 cpu=generic
2752 ;;
2753 esac
2754 ;;
2755 esac
2756
2757 # If there is no $with_cpu option, try to infer one from ${target}.
2758 # This block sets nothing except for with_cpu.
2759 if test x$with_cpu = x ; then
2760 case ${target} in
2761 i[34567]86-*-*|x86_64-*-*)
2762 with_cpu=$cpu
2763 ;;
2764 alphaev6[78]*-*-*)
2765 with_cpu=ev67
2766 ;;
2767 alphaev6*-*-*)
2768 with_cpu=ev6
2769 ;;
2770 alphapca56*-*-*)
2771 with_cpu=pca56
2772 ;;
2773 alphaev56*-*-*)
2774 with_cpu=ev56
2775 ;;
2776 alphaev5*-*-*)
2777 with_cpu=ev5
2778 ;;
2779 frv-*-*linux* | frv400-*-*linux*)
2780 with_cpu=fr400
2781 ;;
2782 frv550-*-*linux*)
2783 with_cpu=fr550
2784 ;;
2785 m68k*-*-*)
2786 case "$with_arch" in
2787 "cf")
2788 with_cpu=${default_cf_cpu}
2789 ;;
2790 "" | "m68k")
2791 with_cpu=m${default_m68k_cpu}
2792 ;;
2793 esac
2794 ;;
2795 mips*-*-vxworks)
2796 with_arch=mips2
2797 ;;
2798 sparc-leon*-*)
2799 with_cpu=v8;
2800 ;;
2801 sparc*-*-*)
2802 with_cpu="`echo ${target} | sed 's/-.*$//'`"
2803 ;;
2804 esac
2805
2806 # Avoid overriding --with-cpu-32 and --with-cpu-64 values.
2807 case ${target} in
2808 i[34567]86-*-*|x86_64-*-*)
2809 if test x$with_cpu_32 != x || test x$with_cpu_64 != x; then
2810 if test x$with_cpu_32 = x; then
2811 with_cpu_32=$with_cpu
2812 fi
2813 if test x$with_cpu_64 = x; then
2814 with_cpu_64=$with_cpu
2815 fi
2816 with_cpu=
2817 fi
2818 ;;
2819 esac
2820 fi
2821
2822 # Support for --with-arch and related options (and a few unrelated options,
2823 # too).
2824 case ${with_arch} in
2825 yes | no)
2826 echo "--with-arch must be passed a value" 1>&2
2827 exit 1
2828 ;;
2829 esac
2830
2831 # If there is no $with_arch option, try to infer one from ${target}.
2832 # This block sets nothing except for with_arch.
2833 if test x$with_arch = x ; then
2834 case ${target} in
2835 i[34567]86-*-darwin*|x86_64-*-darwin*)
2836 # Default arch is set via TARGET_SUBTARGET32_ISA_DEFAULT
2837 # and TARGET_SUBTARGET64_ISA_DEFAULT in config/i386/darwin.h.
2838 ;;
2839 i[34567]86-*-*)
2840 # --with-fpmath sets the default ISA to SSE2, which is the same
2841 # ISA supported by Pentium 4.
2842 if test x$with_fpmath = x || test $arch_without_sse2 = no; then
2843 with_arch=$arch
2844 else
2845 with_arch=pentium4
2846 fi
2847 ;;
2848 x86_64-*-*)
2849 with_arch=$arch
2850 ;;
2851 esac
2852
2853 # Avoid overriding --with-arch-32 and --with-arch-64 values.
2854 case ${target} in
2855 i[34567]86-*-darwin*|x86_64-*-darwin*)
2856 # Default arch is set via TARGET_SUBTARGET32_ISA_DEFAULT
2857 # and TARGET_SUBTARGET64_ISA_DEFAULT in config/i386/darwin.h.
2858 ;;
2859 i[34567]86-*-*|x86_64-*-*)
2860 if test x$with_arch_32 != x || test x$with_arch_64 != x; then
2861 if test x$with_arch_32 = x; then
2862 with_arch_32=$with_arch
2863 fi
2864 if test x$with_arch_64 = x; then
2865 if test $arch_without_64bit = yes; then
2866 # Set the default 64bit arch to x86-64 if the default arch
2867 # doesn't support 64bit.
2868 with_arch_64=x86-64
2869 else
2870 with_arch_64=$with_arch
2871 fi
2872 fi
2873 with_arch=
2874 elif test $arch_without_64bit$need_64bit_isa = yesyes; then
2875 # Set the default 64bit arch to x86-64 if the default arch
2876 # doesn't support 64bit and we need 64bit ISA.
2877 with_arch_32=$with_arch
2878 with_arch_64=x86-64
2879 with_arch=
2880 fi
2881 ;;
2882 esac
2883 fi
2884
2885 # Support --with-fpmath.
2886 if test x$with_fpmath != x; then
2887 case ${target} in
2888 i[34567]86-*-* | x86_64-*-*)
2889 case ${with_fpmath} in
2890 avx)
2891 tm_file="${tm_file} i386/avxmath.h"
2892 ;;
2893 sse)
2894 tm_file="${tm_file} i386/ssemath.h"
2895 ;;
2896 *)
2897 echo "Invalid --with-fpmath=$with_fpmath" 1>&2
2898 exit 1
2899 ;;
2900 esac
2901 ;;
2902 *)
2903 echo "--with-fpmath isn't supported for $target." 1>&2
2904 exit 1
2905 ;;
2906 esac
2907 fi
2908
2909 # Similarly for --with-schedule.
2910 if test x$with_schedule = x; then
2911 case ${target} in
2912 hppa1*)
2913 # Override default PA8000 scheduling model.
2914 with_schedule=7100LC
2915 ;;
2916 esac
2917 fi
2918
2919 # Support --enable-initfini-array.
2920 if test x$enable_initfini_array = xyes; then
2921 tm_file="${tm_file} initfini-array.h"
2922 fi
2923
2924 # Validate and mark as valid any --with options supported
2925 # by this target. In order to use a particular --with option
2926 # you must list it in supported_defaults; validating the value
2927 # is optional. This case statement should set nothing besides
2928 # supported_defaults.
2929
2930 supported_defaults=
2931 case "${target}" in
2932 alpha*-*-*)
2933 supported_defaults="cpu tune"
2934 for which in cpu tune; do
2935 eval "val=\$with_$which"
2936 case "$val" in
2937 "" \
2938 | ev4 | ev45 | 21064 | ev5 | 21164 | ev56 | 21164a \
2939 | pca56 | 21164PC | 21164pc | ev6 | 21264 | ev67 \
2940 | 21264a)
2941 ;;
2942 *)
2943 echo "Unknown CPU used in --with-$which=$val" 1>&2
2944 exit 1
2945 ;;
2946 esac
2947 done
2948 ;;
2949
2950 arm*-*-*)
2951 supported_defaults="arch cpu float tune fpu abi mode tls"
2952 for which in cpu tune; do
2953 # See if it matches any of the entries in arm-cores.def
2954 eval "val=\$with_$which"
2955 if [ x"$val" = x ] \
2956 || grep "^ARM_CORE(\"$val\"," \
2957 ${srcdir}/config/arm/arm-cores.def \
2958 > /dev/null; then
2959 # Ok
2960 new_val=`grep "^ARM_CORE(\"$val\"," \
2961 ${srcdir}/config/arm/arm-cores.def | \
2962 sed -e 's/^[^,]*,[ ]*//' | \
2963 sed -e 's/,.*$//'`
2964 eval "target_${which}_cname=$new_val"
2965 echo "For $val real value is $new_val"
2966 true
2967 else
2968 echo "Unknown CPU used in --with-$which=$val" 1>&2
2969 exit 1
2970 fi
2971 done
2972
2973 case "$with_arch" in
2974 "" \
2975 | armv[23456] | armv2a | armv3m | armv4t | armv5t \
2976 | armv5te | armv6j |armv6k | armv6z | armv6zk | armv6-m \
2977 | armv7 | armv7-a | armv7-r | armv7-m \
2978 | iwmmxt | ep9312)
2979 # OK
2980 ;;
2981 *)
2982 echo "Unknown arch used in --with-arch=$with_arch" 1>&2
2983 exit 1
2984 ;;
2985 esac
2986
2987 case "$with_float" in
2988 "" \
2989 | soft | hard | softfp)
2990 # OK
2991 ;;
2992 *)
2993 echo "Unknown floating point type used in --with-float=$with_float" 1>&2
2994 exit 1
2995 ;;
2996 esac
2997
2998 case "$with_fpu" in
2999 "" \
3000 | fpa | fpe2 | fpe3 | maverick | vfp | vfp3 | vfpv3 \
3001 | vfpv3-fp16 | vfpv3-d16 | vfpv3-d16-fp16 | vfpv3xd \
3002 | vfpv3xd-fp16 | neon | neon-fp16 | vfpv4 | vfpv4-d16 \
3003 | fpv4-sp-d16 | neon-vfpv4)
3004 # OK
3005 ;;
3006 *)
3007 echo "Unknown fpu used in --with-fpu=$with_fpu" 2>&1
3008 exit 1
3009 ;;
3010 esac
3011
3012 case "$with_abi" in
3013 "" \
3014 | apcs-gnu | atpcs | aapcs | iwmmxt | aapcs-linux )
3015 #OK
3016 ;;
3017 *)
3018 echo "Unknown ABI used in --with-abi=$with_abi"
3019 exit 1
3020 ;;
3021 esac
3022
3023 case "$with_mode" in
3024 "" \
3025 | arm | thumb )
3026 #OK
3027 ;;
3028 *)
3029 echo "Unknown mode used in --with-mode=$with_mode"
3030 exit 1
3031 ;;
3032 esac
3033
3034 case "$with_tls" in
3035 "" \
3036 | gnu | gnu2)
3037 # OK
3038 ;;
3039 *)
3040 echo "Unknown TLS method used in --with-tls=$with_tls" 1>&2
3041 exit 1
3042 ;;
3043 esac
3044
3045 if test "x$with_arch" != x && test "x$with_cpu" != x; then
3046 echo "Warning: --with-arch overrides --with-cpu=$with_cpu" 1>&2
3047 fi
3048 ;;
3049
3050 fr*-*-*linux*)
3051 supported_defaults=cpu
3052 case "$with_cpu" in
3053 fr400) ;;
3054 fr550) ;;
3055 *)
3056 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2
3057 exit 1
3058 ;;
3059 esac
3060 ;;
3061
3062 fido-*-* | m68k*-*-*)
3063 supported_defaults="arch cpu"
3064 case "$with_arch" in
3065 "" | "m68k"| "cf")
3066 m68k_arch_family="$with_arch"
3067 ;;
3068 *)
3069 echo "Invalid --with-arch=$with_arch" 1>&2
3070 exit 1
3071 ;;
3072 esac
3073
3074 # We always have a $with_cpu setting here.
3075 case "$with_cpu" in
3076 "m68000" | "m68010" | "m68020" | "m68030" | "m68040" | "m68060")
3077 m68k_cpu_ident=$with_cpu
3078 ;;
3079 "m68020-40")
3080 m68k_cpu_ident=m68020
3081 tm_defines="$tm_defines M68K_DEFAULT_TUNE=u68020_40"
3082 ;;
3083 "m68020-60")
3084 m68k_cpu_ident=m68020
3085 tm_defines="$tm_defines M68K_DEFAULT_TUNE=u68020_60"
3086 ;;
3087 *)
3088 # We need the C identifier rather than the string.
3089 m68k_cpu_ident=`awk -v arg="\"$with_cpu\"" \
3090 'BEGIN { FS="[ \t]*[,()][ \t]*" }; \
3091 $1 == "M68K_DEVICE" && $2 == arg { print $3 }' \
3092 ${srcdir}/config/m68k/m68k-devices.def`
3093 if [ x"$m68k_cpu_ident" = x ] ; then
3094 echo "Unknown CPU used in --with-cpu=$with_cpu" 1>&2
3095 exit 1
3096 fi
3097 with_cpu="mcpu=$with_cpu"
3098 ;;
3099 esac
3100 ;;
3101
3102 hppa*-*-*)
3103 supported_defaults="arch schedule"
3104
3105 case "$with_arch" in
3106 "" | 1.0 | 1.1 | 2.0)
3107 # OK
3108 ;;
3109 *)
3110 echo "Unknown architecture used in --with-arch=$with_arch" 1>&2
3111 exit 1
3112 ;;
3113 esac
3114
3115 case "$with_schedule" in
3116 "" | 700 | 7100 | 7100LC | 7200 | 7300 | 8000)
3117 # OK
3118 ;;
3119 *)
3120 echo "Unknown processor used in --with-schedule=$with_schedule." 1>&2
3121 exit 1
3122 ;;
3123 esac
3124 ;;
3125
3126 i[34567]86-*-* | x86_64-*-*)
3127 supported_defaults="arch arch_32 arch_64 cpu cpu_32 cpu_64 tune tune_32 tune_64"
3128 for which in arch arch_32 arch_64 cpu cpu_32 cpu_64 tune tune_32 tune_64; do
3129 eval "val=\$with_$which"
3130 case ${val} in
3131 i386 | i486 \
3132 | i586 | pentium | pentium-mmx | winchip-c6 | winchip2 \
3133 | c3 | c3-2 | i686 | pentiumpro | pentium2 | pentium3 \
3134 | pentium4 | k6 | k6-2 | k6-3 | athlon | athlon-tbird \
3135 | athlon-4 | athlon-xp | athlon-mp | geode \
3136 | prescott | pentium-m | pentium4m | pentium3m)
3137 case "${target}" in
3138 x86_64-*-*)
3139 case "x$which" in
3140 *_32)
3141 ;;
3142 *)
3143 echo "CPU given in --with-$which=$val doesn't support 64bit mode." 1>&2
3144 exit 1
3145 ;;
3146 esac
3147 ;;
3148 esac
3149 # OK
3150 ;;
3151 "" | x86-64 | generic | native \
3152 | k8 | k8-sse3 | athlon64 | athlon64-sse3 | opteron \
3153 | opteron-sse3 | athlon-fx | bdver2 | bdver1 | btver1 \
3154 | amdfam10 | barcelona | nocona | core2 | corei7 \
3155 | corei7-avx | core-avx-i | core-avx2 | atom)
3156 # OK
3157 ;;
3158 *)
3159 echo "Unknown CPU given in --with-$which=$val." 1>&2
3160 exit 1
3161 ;;
3162 esac
3163 done
3164 ;;
3165
3166 mips*-*-*)
3167 supported_defaults="abi arch arch_32 arch_64 float tune tune_32 tune_64 divide llsc mips-plt synci"
3168
3169 case ${with_float} in
3170 "" | soft | hard)
3171 # OK
3172 ;;
3173 *)
3174 echo "Unknown floating point type used in --with-float=$with_float" 1>&2
3175 exit 1
3176 ;;
3177 esac
3178
3179 case ${with_abi} in
3180 "" | 32 | o64 | n32 | 64 | eabi)
3181 # OK
3182 ;;
3183 *)
3184 echo "Unknown ABI used in --with-abi=$with_abi" 1>&2
3185 exit 1
3186 ;;
3187 esac
3188
3189 case ${with_divide} in
3190 "" | breaks | traps)
3191 # OK
3192 ;;
3193 *)
3194 echo "Unknown division check type use in --with-divide=$with_divide" 1>&2
3195 exit 1
3196 ;;
3197 esac
3198
3199 case ${with_llsc} in
3200 yes)
3201 with_llsc=llsc
3202 ;;
3203 no)
3204 with_llsc="no-llsc"
3205 ;;
3206 "")
3207 # OK
3208 ;;
3209 *)
3210 echo "Unknown llsc type used in --with-llsc" 1>&2
3211 exit 1
3212 ;;
3213 esac
3214
3215 case ${with_mips_plt} in
3216 yes)
3217 with_mips_plt=plt
3218 ;;
3219 no)
3220 with_mips_plt=no-plt
3221 ;;
3222 "")
3223 ;;
3224 *)
3225 echo "Unknown --with-mips-plt argument: $with_mips_plt" 1>&2
3226 exit 1
3227 ;;
3228 esac
3229
3230 case ${with_synci} in
3231 yes)
3232 with_synci=synci
3233 ;;
3234 "" | no)
3235 # No is the default.
3236 with_synci=no-synci
3237 ;;
3238 *)
3239 echo "Unknown synci type used in --with-synci" 1>&2
3240 exit 1
3241 ;;
3242 esac
3243 ;;
3244
3245 powerpc*-*-* | rs6000-*-*)
3246 supported_defaults="cpu cpu_32 cpu_64 float tune tune_32 tune_64"
3247
3248 for which in cpu cpu_32 cpu_64 tune tune_32 tune_64; do
3249 eval "val=\$with_$which"
3250 case ${val} in
3251 default32 | default64)
3252 case $which in
3253 cpu | tune)
3254 ;;
3255 *)
3256 echo "$val only valid for --with-cpu and --with-tune." 1>&2
3257 exit 1
3258 ;;
3259 esac
3260 with_which="with_$which"
3261 eval $with_which=
3262 ;;
3263 405cr)
3264 tm_defines="${tm_defines} CONFIG_PPC405CR"
3265 eval "with_$which=405"
3266 ;;
3267 "" | common \
3268 | power | power[234567] | power6x | powerpc | powerpc64 \
3269 | rios | rios1 | rios2 | rsc | rsc1 | rs64a \
3270 | 401 | 403 | 405 | 405fp | 440 | 440fp | 464 | 464fp \
3271 | 476 | 476fp | 505 | 601 | 602 | 603 | 603e | ec603e \
3272 | 604 | 604e | 620 | 630 | 740 | 750 | 7400 | 7450 \
3273 | a2 | e300c[23] | 854[08] | e500mc | e500mc64 | titan\
3274 | 801 | 821 | 823 | 860 | 970 | G3 | G4 | G5 | cell)
3275 # OK
3276 ;;
3277 *)
3278 echo "Unknown cpu used in --with-$which=$val." 1>&2
3279 exit 1
3280 ;;
3281 esac
3282 done
3283 ;;
3284
3285 s390*-*-*)
3286 supported_defaults="arch mode tune"
3287
3288 for which in arch tune; do
3289 eval "val=\$with_$which"
3290 case ${val} in
3291 "" | g5 | g6 | z900 | z990 | z9-109 | z9-ec | z10 | z196)
3292 # OK
3293 ;;
3294 *)
3295 echo "Unknown cpu used in --with-$which=$val." 1>&2
3296 exit 1
3297 ;;
3298 esac
3299 done
3300
3301 case ${with_mode} in
3302 "" | esa | zarch)
3303 # OK
3304 ;;
3305 *)
3306 echo "Unknown architecture mode used in --with-mode=$with_mode." 1>&2
3307 exit 1
3308 ;;
3309 esac
3310 ;;
3311
3312 sh[123456ble]-*-* | sh-*-*)
3313 supported_defaults="cpu"
3314 case "`echo $with_cpu | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ_ abcdefghijklmnopqrstuvwxyz- | sed s/sh/m/`" in
3315 "" | m1 | m2 | m2e | m3 | m3e | m4 | m4-single | m4-single-only | m4-nofpu )
3316 # OK
3317 ;;
3318 m2a | m2a-single | m2a-single-only | m2a-nofpu)
3319 ;;
3320 m4a | m4a-single | m4a-single-only | m4a-nofpu | m4al)
3321 ;;
3322 *)
3323 echo "Unknown CPU used in --with-cpu=$with_cpu, known values:" 1>&2
3324 echo "m1 m2 m2e m3 m3e m4 m4-single m4-single-only m4-nofpu" 1>&2
3325 echo "m4a m4a-single m4a-single-only m4a-nofpu m4al" 1>&2
3326 echo "m2a m2a-single m2a-single-only m2a-nofpu" 1>&2
3327 exit 1
3328 ;;
3329 esac
3330 ;;
3331 sparc*-*-*)
3332 supported_defaults="cpu float tune"
3333
3334 for which in cpu tune; do
3335 eval "val=\$with_$which"
3336 case ${val} in
3337 "" | sparc | sparcv9 | sparc64 \
3338 | v7 | cypress \
3339 | v8 | supersparc | hypersparc | leon \
3340 | sparclite | f930 | f934 | sparclite86x \
3341 | sparclet | tsc701 \
3342 | v9 | ultrasparc | ultrasparc3 | niagara | niagara2 \
3343 | niagara3 | niagara4)
3344 # OK
3345 ;;
3346 *)
3347 echo "Unknown cpu used in --with-$which=$val" 1>&2
3348 exit 1
3349 ;;
3350 esac
3351 done
3352
3353 case ${with_float} in
3354 "" | soft | hard)
3355 # OK
3356 ;;
3357 *)
3358 echo "Unknown floating point type used in --with-float=$with_float" 1>&2
3359 exit 1
3360 ;;
3361 esac
3362 ;;
3363
3364 spu-*-*)
3365 supported_defaults="arch tune"
3366
3367 for which in arch tune; do
3368 eval "val=\$with_$which"
3369 case ${val} in
3370 "" | cell | celledp)
3371 # OK
3372 ;;
3373 *)
3374 echo "Unknown cpu used in --with-$which=$val." 1>&2
3375 exit 1
3376 ;;
3377 esac
3378 done
3379 ;;
3380
3381 tic6x-*-*)
3382 supported_defaults="arch"
3383
3384 case ${with_arch} in
3385 "" | c62x | c64x | c64x+ | c67x | c67x+ | c674x)
3386 # OK
3387 ;;
3388 *)
3389 echo "Unknown arch used in --with-arch=$with_arch." 1>&2
3390 exit 1
3391 ;;
3392 esac
3393 ;;
3394
3395 v850*-*-*)
3396 supported_defaults=cpu
3397 case ${with_cpu} in
3398 "" | v850e | v850e1 | v850e2 | v850es | v850e2v3)
3399 # OK
3400 ;;
3401 *)
3402 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2
3403 exit 1
3404 ;;
3405 esac
3406 ;;
3407 esac
3408
3409 # Set some miscellaneous flags for particular targets.
3410 target_cpu_default2=
3411 case ${target} in
3412 alpha*-*-*)
3413 if test x$gas = xyes
3414 then
3415 target_cpu_default2="MASK_GAS"
3416 fi
3417 ;;
3418
3419 arm*-*-*)
3420 if test x$target_cpu_cname = x
3421 then
3422 target_cpu_default2=TARGET_CPU_generic
3423 else
3424 target_cpu_default2=TARGET_CPU_$target_cpu_cname
3425 fi
3426 ;;
3427
3428 hppa*-*-*)
3429 target_cpu_default2="MASK_BIG_SWITCH"
3430 if test x$gas = xyes
3431 then
3432 target_cpu_default2="${target_cpu_default2}|MASK_GAS|MASK_JUMP_IN_DELAY"
3433 fi
3434 ;;
3435
3436 fido*-*-* | m68k*-*-*)
3437 target_cpu_default2=$m68k_cpu_ident
3438 tmake_file="m68k/t-opts $tmake_file"
3439 if [ x"$m68k_arch_family" != x ]; then
3440 tmake_file="m68k/t-$m68k_arch_family $tmake_file"
3441 fi
3442 ;;
3443
3444 i[34567]86-*-darwin* | x86_64-*-darwin*)
3445 ;;
3446 i[34567]86-*-linux* | x86_64-*-linux* | \
3447 i[34567]86-*-kfreebsd*-gnu | x86_64-*-kfreebsd*-gnu | \
3448 i[34567]86-*-gnu*)
3449 ;;
3450 i[34567]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*)
3451 ;;
3452 i[34567]86-*-cygwin* | i[34567]86-*-mingw* | x86_64-*-mingw*)
3453 ;;
3454 i[34567]86-*-freebsd* | x86_64-*-freebsd*)
3455 ;;
3456 ia64*-*-linux*)
3457 ;;
3458
3459 mips*-*-*)
3460 if test x$gnu_ld = xyes
3461 then
3462 target_cpu_default2="MASK_SPLIT_ADDRESSES"
3463 fi
3464 case ${target} in
3465 mips*el-*-*)
3466 tm_defines="TARGET_ENDIAN_DEFAULT=0 $tm_defines"
3467 ;;
3468 esac
3469 tmake_file="mips/t-mips $tmake_file"
3470 ;;
3471
3472 powerpc*-*-* | rs6000-*-*)
3473 # FIXME: The PowerPC port uses the value set at compile time,
3474 # although it's only cosmetic.
3475 if test "x$with_cpu" != x
3476 then
3477 target_cpu_default2="\\\"$with_cpu\\\""
3478 fi
3479 out_file=rs6000/rs6000.c
3480 c_target_objs="${c_target_objs} rs6000-c.o"
3481 cxx_target_objs="${cxx_target_objs} rs6000-c.o"
3482 tmake_file="rs6000/t-rs6000 ${tmake_file}"
3483
3484 if test x$enable_e500_double = xyes
3485 then
3486 tm_file="$tm_file rs6000/e500-double.h"
3487 fi
3488 ;;
3489
3490 sh[123456ble]*-*-* | sh-*-*)
3491 c_target_objs="${c_target_objs} sh-c.o"
3492 cxx_target_objs="${cxx_target_objs} sh-c.o"
3493 ;;
3494
3495 sparc-leon*-*)
3496 if test x$with_tune = x ; then
3497 with_tune=leon;
3498 fi
3499
3500 # The SPARC port checks this value at compile-time.
3501 target_cpu_default2="TARGET_CPU_$with_cpu"
3502 ;;
3503
3504 sparc*-*-*)
3505 # Some standard aliases.
3506 case x$with_cpu in
3507 xsparc)
3508 with_cpu=v7
3509 ;;
3510 xsparcv9 | xsparc64)
3511 with_cpu=v9
3512 ;;
3513 esac
3514
3515 # The SPARC port checks this value at compile-time.
3516 target_cpu_default2="TARGET_CPU_$with_cpu"
3517 ;;
3518
3519 v850*-*-*)
3520 case "x$with_cpu" in
3521 x)
3522 ;;
3523 xv850e | xv850e1 | xv850e2 | xv850e2v3)
3524 target_cpu_default2="TARGET_CPU_$with_cpu"
3525 ;;
3526 xv850es)
3527 target_cpu_default2="TARGET_CPU_v850e1"
3528 ;;
3529 esac
3530 ;;
3531 esac
3532
3533 t=
3534 all_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 synci tls"
3535 for option in $all_defaults
3536 do
3537 eval "val=\$with_"`echo $option | sed s/-/_/g`
3538 if test -n "$val"; then
3539 case " $supported_defaults " in
3540 *" $option "*)
3541 ;;
3542 *)
3543 echo "This target does not support --with-$option." 2>&1
3544 echo "Valid --with options are: $supported_defaults" 2>&1
3545 exit 1
3546 ;;
3547 esac
3548
3549 if test "x$t" = x
3550 then
3551 t="{ \"$option\", \"$val\" }"
3552 else
3553 t="${t}, { \"$option\", \"$val\" }"
3554 fi
3555 fi
3556 done
3557
3558 if test "x$t" = x
3559 then
3560 configure_default_options="{ { NULL, NULL} }"
3561 else
3562 configure_default_options="{ ${t} }"
3563 fi
3564
3565 if test "$target_cpu_default2" != ""
3566 then
3567 if test "$target_cpu_default" != ""
3568 then
3569 target_cpu_default="(${target_cpu_default}|${target_cpu_default2})"
3570 else
3571 target_cpu_default=$target_cpu_default2
3572 fi
3573 fi