1# GCC target-specific configuration file. 2# Copyright (C) 1997-2019 Free Software Foundation, Inc. 3 4#This file is part of GCC. 5 6#GCC is free software; you can redistribute it and/or modify it under 7#the terms of the GNU General Public License as published by the Free 8#Software Foundation; either version 3, or (at your option) any later 9#version. 10 11#GCC is distributed in the hope that it will be useful, but WITHOUT 12#ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13#FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14#for more details. 15 16#You should have received a copy of the GNU General Public License 17#along with GCC; see the file COPYING3. If not see 18#<http://www.gnu.org/licenses/>. 19 20# This is the GCC target-specific configuration file 21# where a configuration type is mapped to different system-specific 22# definitions and files. This is invoked by the autoconf-generated 23# configure script. Putting it in a separate shell file lets us skip 24# running autoconf when modifying target-specific information. 25 26# When you change the cases in the OS or target switches, consider 27# updating ../libgcc/config.host also. 28 29# This file switches on the shell variable ${target}, and also uses the 30# following shell variables: 31# 32# with_* Various variables as set by configure. 33# 34# enable_threads Either the name, yes or no depending on whether 35# threads support was requested. 36# 37# default_use_cxa_atexit 38# The default value for the $enable___cxa_atexit 39# variable. enable___cxa_atexit needs to be set to 40# "yes" for the correct operation of C++ destructors 41# but it relies upon the presence of a non-standard C 42# library function called __cxa_atexit. 43# Since not all C libraries provide __cxa_atexit the 44# default value of $default_use_cxa_atexit is set to 45# "no" except for targets which are known to be OK. 46# 47# default_gnu_indirect_function 48# The default value for the $enable_gnu_indirect_function 49# variable. enable_gnu_indirect_function relies 50# upon the presence of a non-standard gnu ifunc support 51# in the assembler, linker and dynamic linker. 52# Since not all libraries provide the dynamic linking 53# support, the default value of 54# $default_gnu_indirect_function is set to 55# "no" except for targets which are known to be OK. 56# 57# gas_flag Either yes or no depending on whether GNU as was 58# requested. 59# 60# gnu_ld_flag Either yes or no depending on whether GNU ld was 61# requested. 62 63# This file sets the following shell variables for use by the 64# autoconf-generated configure script: 65# 66# cpu_type The name of the cpu, if different from the first 67# chunk of the canonical target name. 68# 69# tm_defines List of target macros to define for all compilations. 70# 71# tm_file A list of target macro files, if different from 72# "$cpu_type/$cpu_type.h". Usually it's constructed 73# per target in a way like this: 74# tm_file="${tm_file} dbxelf.h elfos.h ${cpu_type.h}/elf.h" 75# Note that the preferred order is: 76# - specific target header "${cpu_type}/${cpu_type.h}" 77# - generic headers like dbxelf.h elfos.h, etc. 78# - specializing target headers like ${cpu_type.h}/elf.h 79# This helps to keep OS specific stuff out of the CPU 80# defining header ${cpu_type}/${cpu_type.h}. 81# 82# It is possible to include automatically-generated 83# build-directory files by prefixing them with "./". 84# All other files should relative to $srcdir/config. 85# 86# tm_p_file Location of file with declarations for functions 87# in $out_file. 88# 89# tm_d_file A list of headers with definitions of target hook 90# macros for the D compiler. 91# 92# out_file The name of the machine description C support 93# file, if different from "$cpu_type/$cpu_type.c". 94# 95# common_out_file The name of the source file for code shared between 96# the compiler proper and the driver. 97# 98# md_file The name of the machine-description file, if 99# different from "$cpu_type/$cpu_type.md". 100# 101# tmake_file A list of machine-description-specific 102# makefile-fragments, if different from 103# "$cpu_type/t-$cpu_type". 104# 105# extra_modes The name of the file containing a list of extra 106# machine modes, if necessary and different from 107# "$cpu_type/$cpu_type-modes.def". 108# 109# extra_objs List of extra objects that should be linked into 110# the compiler proper (cc1, cc1obj, cc1plus) 111# depending on target. 112# 113# extra_gcc_objs List of extra objects that should be linked into 114# the compiler driver (gcc) depending on target. 115# 116# extra_headers List of used header files from the directory 117# config/${cpu_type}. 118# 119# user_headers_inc_next_pre 120# List of header file names of internal gcc header 121# files, which should be prefixed by an include_next. 122# user_headers_inc_next_post 123# List of header file names of internal gcc header 124# files, which should be postfixed by an include_next. 125# use_gcc_tgmath If set, add tgmath.h to the list of used header 126# files. 127# 128# use_gcc_stdint If "wrap", install a version of stdint.h that 129# wraps the system's copy for hosted compilations; 130# if "provide", provide a version of systems without 131# such a system header; otherwise "none", do not 132# provide such a header at all. 133# 134# extra_programs List of extra executables compiled for this target 135# machine, 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# d_target_objs List of extra target-dependent objects that be 146# linked into the D compiler only. 147# 148# fortran_target_objs List of extra target-dependent objects that be 149# linked into the fortran compiler only. 150# 151# target_gtfiles List of extra source files with type information. 152# 153# xm_defines List of macros to define when compiling for the 154# target machine. 155# 156# xm_file List of files to include when compiling for the 157# target machine. 158# 159# use_collect2 Set to yes or no, depending on whether collect2 160# will be used. 161# 162# target_cpu_default Set to override the default target model. 163# 164# gdb_needs_out_file_path 165# Set to yes if gdb needs a dir command with 166# `dirname $out_file`. 167# 168# thread_file Set to control which thread package to use. 169# 170# gas Set to yes or no depending on whether the target 171# system normally uses GNU as. 172# 173# configure_default_options 174# Set to an initializer for configure_default_options 175# in configargs.h, based on --with-cpu et cetera. 176# 177# native_system_header_dir 178# Where system header files are found for this 179# target. This defaults to /usr/include. If 180# the --with-sysroot configure option or the 181# --sysroot command line option is used this 182# will be relative to the sysroot. 183# target_type_format_char 184# The default character to be used for formatting 185# the attribute in a 186# .type symbol_name, ${t_t_f_c}<property> 187# directive. 188 189# The following variables are used in each case-construct to build up the 190# outgoing variables: 191# 192# gnu_ld Set to yes or no depending on whether the target 193# system normally uses GNU ld. 194# 195# target_has_targetcm Set to yes or no depending on whether the target 196# has its own definition of targetcm. 197# 198# target_has_targetm_common Set to yes or no depending on whether the 199# target has its own definition of targetm_common. 200# 201# target_has_targetdm Set to yes or no depending on whether the target 202# has its own definition of targetdm. 203 204out_file= 205common_out_file= 206tmake_file= 207extra_headers= 208user_headers_inc_next_pre= 209user_headers_inc_next_post= 210use_gcc_tgmath=yes 211use_gcc_stdint=none 212extra_programs= 213extra_objs= 214extra_gcc_objs= 215extra_options= 216c_target_objs= 217cxx_target_objs= 218d_target_objs= 219fortran_target_objs= 220target_has_targetcm=no 221target_has_targetm_common=yes 222target_has_targetdm=no 223tm_defines= 224xm_defines= 225# Set this to force installation and use of collect2. 226use_collect2= 227# Set this to override the default target model. 228target_cpu_default= 229# Set this if gdb needs a dir command with `dirname $out_file` 230gdb_needs_out_file_path= 231# Set this to control which thread package will be used. 232thread_file= 233# Reinitialize these from the flag values every loop pass, since some 234# configure entries modify them. 235gas="$gas_flag" 236gnu_ld="$gnu_ld_flag" 237default_use_cxa_atexit=no 238default_gnu_indirect_function=no 239target_gtfiles= 240need_64bit_isa= 241native_system_header_dir=/usr/include 242target_type_format_char='@' 243 244# Don't carry these over build->host->target. Please. 245xm_file= 246md_file= 247 248# Obsolete configurations. 249case ${target} in 250 *-*-solaris2.10* \ 251 | spu*-*-* \ 252 | tile*-*-* \ 253 ) 254 if test "x$enable_obsolete" != xyes; then 255 echo "*** Configuration ${target} is obsolete." >&2 256 echo "*** Specify --enable-obsolete to build it anyway." >&2 257 echo "*** Support will be REMOVED in the next major release of GCC," >&2 258 echo "*** unless a maintainer comes forward." >&2 259 exit 1 260 fi;; 261esac 262 263# Unsupported targets list. Do not put an entry in this list unless 264# it would otherwise be caught by a more permissive pattern. The list 265# should be in alphabetical order. 266case ${target} in 267 # Avoid special cases that are not obsolete 268 arm*-*-*eabi* \ 269 ) 270 ;; 271 arm*-wince-pe* \ 272 | arm*-*-ecos-elf \ 273 | arm*-*-elf \ 274 | arm*-*-linux* \ 275 | arm*-*-uclinux* \ 276 | i[34567]86-go32-* \ 277 | i[34567]86-*-go32* \ 278 | m68k-*-uclinuxoldabi* \ 279 | mips64orion*-*-rtems* \ 280 | pdp11-*-bsd \ 281 | powerpc*-*-linux*paired* \ 282 | powerpc*-*-*spe* \ 283 | sparc-hal-solaris2* \ 284 | thumb-*-* \ 285 | *-*-freebsd[12] | *-*-freebsd[1234].* \ 286 | *-*-freebsd*aout* \ 287 | *-*-linux*aout* \ 288 | *-*-linux*coff* \ 289 | *-*-linux*libc1* \ 290 | *-*-linux*oldld* \ 291 | *-*-rtemsaout* \ 292 | *-*-rtemscoff* \ 293 | *-*-solaris2 \ 294 | *-*-solaris2.[0-9] \ 295 | *-*-solaris2.[0-9].* \ 296 | *-*-sysv* \ 297 | vax-*-vms* \ 298 ) 299 echo "*** Configuration ${target} not supported" 1>&2 300 exit 1 301 ;; 302esac 303 304# Set default cpu_type, tm_file, tm_p_file and xm_file so it can be 305# updated in each machine entry. Also set default extra_headers for some 306# machines. 307tm_p_file= 308cpu_type=`echo ${target} | sed 's/-.*$//'` 309cpu_is_64bit= 310case ${target} in 311m32c*-*-*) 312 cpu_type=m32c 313 tmake_file=m32c/t-m32c 314 target_has_targetm_common=no 315 ;; 316aarch64*-*-*) 317 cpu_type=aarch64 318 extra_headers="arm_fp16.h arm_neon.h arm_acle.h" 319 c_target_objs="aarch64-c.o" 320 cxx_target_objs="aarch64-c.o" 321 d_target_objs="aarch64-d.o" 322 extra_objs="aarch64-builtins.o aarch-common.o cortex-a57-fma-steering.o aarch64-speculation.o falkor-tag-collision-avoidance.o aarch64-bti-insert.o" 323 target_gtfiles="\$(srcdir)/config/aarch64/aarch64-builtins.c" 324 target_has_targetm_common=yes 325 ;; 326alpha*-*-*) 327 cpu_type=alpha 328 extra_options="${extra_options} g.opt" 329 ;; 330amdgcn*) 331 cpu_type=gcn 332 use_gcc_stdint=wrap 333 ;; 334am33_2.0-*-linux*) 335 cpu_type=mn10300 336 ;; 337arc*-*-*) 338 cpu_type=arc 339 c_target_objs="arc-c.o" 340 cxx_target_objs="arc-c.o" 341 extra_options="${extra_options} arc/arc-tables.opt g.opt" 342 extra_headers="arc-simd.h" 343 ;; 344arm*-*-*) 345 cpu_type=arm 346 extra_objs="arm-builtins.o aarch-common.o" 347 extra_headers="mmintrin.h arm_neon.h arm_acle.h arm_fp16.h arm_cmse.h" 348 target_type_format_char='%' 349 c_target_objs="arm-c.o" 350 cxx_target_objs="arm-c.o" 351 d_target_objs="arm-d.o" 352 extra_options="${extra_options} arm/arm-tables.opt" 353 target_gtfiles="\$(srcdir)/config/arm/arm-builtins.c" 354 ;; 355avr-*-*) 356 cpu_type=avr 357 c_target_objs="avr-c.o" 358 cxx_target_objs="avr-c.o" 359 ;; 360bfin*-*) 361 cpu_type=bfin 362 ;; 363crisv32-*) 364 cpu_type=cris 365 ;; 366frv*) cpu_type=frv 367 extra_options="${extra_options} g.opt" 368 ;; 369ft32*) cpu_type=ft32 370 target_has_targetm_common=no 371 ;; 372moxie*) cpu_type=moxie 373 target_has_targetm_common=no 374 ;; 375fido-*-*) 376 cpu_type=m68k 377 extra_headers=math-68881.h 378 extra_options="${extra_options} m68k/m68k-tables.opt" 379 ;; 380i[34567]86-*-*) 381 cpu_type=i386 382 c_target_objs="i386-c.o" 383 cxx_target_objs="i386-c.o" 384 d_target_objs="i386-d.o" 385 extra_objs="x86-tune-sched.o x86-tune-sched-bd.o x86-tune-sched-atom.o x86-tune-sched-core.o" 386 extra_options="${extra_options} fused-madd.opt" 387 extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h 388 pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h 389 nmmintrin.h bmmintrin.h fma4intrin.h wmmintrin.h 390 immintrin.h x86intrin.h avxintrin.h xopintrin.h 391 ia32intrin.h cross-stdarg.h lwpintrin.h popcntintrin.h 392 lzcntintrin.h bmiintrin.h bmi2intrin.h tbmintrin.h 393 avx2intrin.h avx512fintrin.h fmaintrin.h f16cintrin.h 394 rtmintrin.h xtestintrin.h rdseedintrin.h prfchwintrin.h 395 adxintrin.h fxsrintrin.h xsaveintrin.h xsaveoptintrin.h 396 avx512cdintrin.h avx512erintrin.h avx512pfintrin.h 397 shaintrin.h clflushoptintrin.h xsavecintrin.h 398 xsavesintrin.h avx512dqintrin.h avx512bwintrin.h 399 avx512vlintrin.h avx512vlbwintrin.h avx512vldqintrin.h 400 avx512ifmaintrin.h avx512ifmavlintrin.h avx512vbmiintrin.h 401 avx512vbmivlintrin.h avx5124fmapsintrin.h avx5124vnniwintrin.h 402 avx512vpopcntdqintrin.h clwbintrin.h mwaitxintrin.h 403 clzerointrin.h pkuintrin.h sgxintrin.h cetintrin.h 404 gfniintrin.h cet.h avx512vbmi2intrin.h 405 avx512vbmi2vlintrin.h avx512vnniintrin.h 406 avx512vnnivlintrin.h vaesintrin.h vpclmulqdqintrin.h 407 avx512vpopcntdqvlintrin.h avx512bitalgintrin.h 408 pconfigintrin.h wbnoinvdintrin.h movdirintrin.h 409 waitpkgintrin.h cldemoteintrin.h" 410 ;; 411x86_64-*-*) 412 cpu_type=i386 413 c_target_objs="i386-c.o" 414 cxx_target_objs="i386-c.o" 415 d_target_objs="i386-d.o" 416 extra_options="${extra_options} fused-madd.opt" 417 extra_objs="x86-tune-sched.o x86-tune-sched-bd.o x86-tune-sched-atom.o x86-tune-sched-core.o" 418 extra_headers="cpuid.h mmintrin.h mm3dnow.h xmmintrin.h emmintrin.h 419 pmmintrin.h tmmintrin.h ammintrin.h smmintrin.h 420 nmmintrin.h bmmintrin.h fma4intrin.h wmmintrin.h 421 immintrin.h x86intrin.h avxintrin.h xopintrin.h 422 ia32intrin.h cross-stdarg.h lwpintrin.h popcntintrin.h 423 lzcntintrin.h bmiintrin.h bmi2intrin.h tbmintrin.h 424 avx2intrin.h avx512fintrin.h fmaintrin.h f16cintrin.h 425 rtmintrin.h xtestintrin.h rdseedintrin.h prfchwintrin.h 426 adxintrin.h fxsrintrin.h xsaveintrin.h xsaveoptintrin.h 427 avx512cdintrin.h avx512erintrin.h avx512pfintrin.h 428 shaintrin.h clflushoptintrin.h xsavecintrin.h 429 xsavesintrin.h avx512dqintrin.h avx512bwintrin.h 430 avx512vlintrin.h avx512vlbwintrin.h avx512vldqintrin.h 431 avx512ifmaintrin.h avx512ifmavlintrin.h avx512vbmiintrin.h 432 avx512vbmivlintrin.h avx5124fmapsintrin.h avx5124vnniwintrin.h 433 avx512vpopcntdqintrin.h clwbintrin.h mwaitxintrin.h 434 clzerointrin.h pkuintrin.h sgxintrin.h cetintrin.h 435 gfniintrin.h cet.h avx512vbmi2intrin.h 436 avx512vbmi2vlintrin.h avx512vnniintrin.h 437 avx512vnnivlintrin.h vaesintrin.h vpclmulqdqintrin.h 438 avx512vpopcntdqvlintrin.h avx512bitalgintrin.h 439 pconfigintrin.h wbnoinvdintrin.h movdirintrin.h 440 waitpkgintrin.h cldemoteintrin.h" 441 ;; 442ia64-*-*) 443 extra_headers=ia64intrin.h 444 extra_options="${extra_options} g.opt fused-madd.opt" 445 ;; 446hppa*-*-*) 447 cpu_type=pa 448 ;; 449lm32*) 450 extra_options="${extra_options} g.opt" 451 ;; 452m32r*-*-*) 453 cpu_type=m32r 454 extra_options="${extra_options} g.opt" 455 ;; 456m5200-*-*|m5407-*-*) 457 cpu_type=m68k 458 extra_headers=math-68881.h 459 extra_options="${extra_options} m68k/m68k-tables.opt" 460 ;; 461m680[012]0-*-*) 462 cpu_type=m68k 463 extra_headers=math-68881.h 464 extra_options="${extra_options} m68k/m68k-tables.opt" 465 ;; 466m68k-*-*) 467 extra_headers=math-68881.h 468 extra_options="${extra_options} m68k/m68k-tables.opt" 469 ;; 470microblaze*-*-*) 471 cpu_type=microblaze 472 extra_options="${extra_options} g.opt" 473 ;; 474mips*-*-*) 475 cpu_type=mips 476 d_target_objs="mips-d.o" 477 extra_headers="loongson.h loongson-mmiintrin.h msa.h" 478 extra_objs="frame-header-opt.o" 479 extra_options="${extra_options} g.opt fused-madd.opt mips/mips-tables.opt" 480 ;; 481nds32*) 482 cpu_type=nds32 483 extra_headers="nds32_intrinsic.h nds32_isr.h nds32_init.inc" 484 case ${target} in 485 nds32*-*-linux*) 486 extra_options="${extra_options} nds32/nds32-linux.opt" 487 ;; 488 nds32*-*-elf*) 489 extra_options="${extra_options} nds32/nds32-elf.opt" 490 ;; 491 *) 492 ;; 493 esac 494 extra_objs="nds32-cost.o nds32-intrinsic.o nds32-isr.o nds32-md-auxiliary.o nds32-pipelines-auxiliary.o nds32-predicates.o nds32-memory-manipulation.o nds32-fp-as-gp.o nds32-relax-opt.o nds32-utils.o" 495 ;; 496nios2-*-*) 497 cpu_type=nios2 498 extra_options="${extra_options} g.opt" 499 ;; 500nvptx-*-*) 501 cpu_type=nvptx 502 ;; 503or1k*-*-*) 504 cpu_type=or1k 505 ;; 506powerpc*-*-*) 507 cpu_type=rs6000 508 extra_objs="rs6000-string.o rs6000-p8swap.o" 509 extra_headers="ppc-asm.h altivec.h htmintrin.h htmxlintrin.h" 510 extra_headers="${extra_headers} bmi2intrin.h bmiintrin.h" 511 extra_headers="${extra_headers} xmmintrin.h mm_malloc.h emmintrin.h" 512 extra_headers="${extra_headers} mmintrin.h x86intrin.h" 513 extra_headers="${extra_headers} pmmintrin.h tmmintrin.h smmintrin.h" 514 extra_headers="${extra_headers} ppu_intrinsics.h spu2vmx.h vec_types.h si2vmx.h" 515 extra_headers="${extra_headers} amo.h" 516 case x$with_cpu in 517 xpowerpc64|xdefault64|x6[23]0|x970|xG5|xpower[3456789]|xpower6x|xrs64a|xcell|xa2|xe500mc64|xe5500|xe6500) 518 cpu_is_64bit=yes 519 ;; 520 esac 521 extra_options="${extra_options} g.opt fused-madd.opt rs6000/rs6000-tables.opt" 522 ;; 523riscv*) 524 cpu_type=riscv 525 extra_objs="riscv-builtins.o riscv-c.o" 526 d_target_objs="riscv-d.o" 527 ;; 528rs6000*-*-*) 529 extra_options="${extra_options} g.opt fused-madd.opt rs6000/rs6000-tables.opt" 530 extra_objs="rs6000-string.o rs6000-p8swap.o" 531 ;; 532sparc*-*-*) 533 cpu_type=sparc 534 c_target_objs="sparc-c.o" 535 cxx_target_objs="sparc-c.o" 536 d_target_objs="sparc-d.o" 537 extra_headers="visintrin.h" 538 ;; 539spu*-*-*) 540 cpu_type=spu 541 ;; 542s390*-*-*) 543 cpu_type=s390 544 d_target_objs="s390-d.o" 545 extra_options="${extra_options} fused-madd.opt" 546 extra_headers="s390intrin.h htmintrin.h htmxlintrin.h vecintrin.h" 547 ;; 548# Note the 'l'; we need to be able to match e.g. "shle" or "shl". 549sh[123456789lbe]*-*-* | sh-*-*) 550 cpu_type=sh 551 extra_options="${extra_options} fused-madd.opt" 552 extra_objs="${extra_objs} sh_treg_combine.o sh-mem.o sh_optimize_sett_clrt.o" 553 ;; 554v850*-*-*) 555 cpu_type=v850 556 ;; 557tic6x-*-*) 558 cpu_type=c6x 559 extra_headers="c6x_intrinsics.h" 560 extra_options="${extra_options} c6x/c6x-tables.opt" 561 ;; 562xtensa*-*-*) 563 extra_options="${extra_options} fused-madd.opt" 564 ;; 565tilegx*-*-*) 566 cpu_type=tilegx 567 ;; 568tilepro*-*-*) 569 cpu_type=tilepro 570 ;; 571esac 572 573tm_file=${cpu_type}/${cpu_type}.h 574tm_d_file=${cpu_type}/${cpu_type}.h 575if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-protos.h 576then 577 tm_p_file=${cpu_type}/${cpu_type}-protos.h 578 tm_d_file="${tm_d_file} ${cpu_type}/${cpu_type}-protos.h" 579fi 580 581extra_modes= 582if test -f ${srcdir}/config/${cpu_type}/${cpu_type}-modes.def 583then 584 extra_modes=${cpu_type}/${cpu_type}-modes.def 585fi 586if test -f ${srcdir}/config/${cpu_type}/${cpu_type}.opt 587then 588 extra_options="${extra_options} ${cpu_type}/${cpu_type}.opt" 589fi 590 591case ${target} in 592aarch64*-*-*) 593 tm_p_file="${tm_p_file} arm/aarch-common-protos.h" 594 case ${with_abi} in 595 "") 596 if test "x$with_multilib_list" = xilp32; then 597 tm_file="aarch64/biarchilp32.h ${tm_file}" 598 else 599 tm_file="aarch64/biarchlp64.h ${tm_file}" 600 fi 601 ;; 602 ilp32) 603 tm_file="aarch64/biarchilp32.h ${tm_file}" 604 ;; 605 lp64) 606 tm_file="aarch64/biarchlp64.h ${tm_file}" 607 ;; 608 *) 609 echo "Unknown ABI used in --with-abi=$with_abi" 610 exit 1 611 esac 612 ;; 613i[34567]86-*-*) 614 if test "x$with_abi" != x; then 615 echo "This target does not support --with-abi." 616 exit 1 617 fi 618 if test "x$enable_cld" = xyes; then 619 tm_defines="${tm_defines} USE_IX86_CLD=1" 620 fi 621 if test "x$enable_frame_pointer" = xyes; then 622 tm_defines="${tm_defines} USE_IX86_FRAME_POINTER=1" 623 fi 624 ;; 625x86_64-*-*) 626 case ${with_abi} in 627 "") 628 if test "x$with_multilib_list" = xmx32; then 629 tm_file="i386/biarchx32.h ${tm_file}" 630 else 631 tm_file="i386/biarch64.h ${tm_file}" 632 fi 633 ;; 634 64 | m64) 635 tm_file="i386/biarch64.h ${tm_file}" 636 ;; 637 x32 | mx32) 638 tm_file="i386/biarchx32.h ${tm_file}" 639 ;; 640 *) 641 echo "Unknown ABI used in --with-abi=$with_abi" 642 exit 1 643 esac 644 if test "x$enable_cld" = xyes; then 645 tm_defines="${tm_defines} USE_IX86_CLD=1" 646 fi 647 if test "x$enable_frame_pointer" = xyes; then 648 tm_defines="${tm_defines} USE_IX86_FRAME_POINTER=1" 649 fi 650 ;; 651arm*-*-*) 652 tm_p_file="arm/arm-flags.h ${tm_p_file} arm/aarch-common-protos.h" 653 ;; 654esac 655 656# On a.out targets, we need to use collect2. 657case ${target} in 658*-*-*aout*) 659 use_collect2=yes 660 ;; 661esac 662 663# Common C libraries. 664tm_defines="$tm_defines LIBC_GLIBC=1 LIBC_UCLIBC=2 LIBC_BIONIC=3 LIBC_MUSL=4" 665 666# 32-bit x86 processors supported by --with-arch=. Each processor 667# MUST be separated by exactly one space. 668x86_archs="athlon athlon-4 athlon-fx athlon-mp athlon-tbird \ 669athlon-xp k6 k6-2 k6-3 geode c3 c3-2 winchip-c6 winchip2 i386 i486 \ 670i586 i686 pentium pentium-m pentium-mmx pentium2 pentium3 pentium3m \ 671pentium4 pentium4m pentiumpro prescott lakemont" 672 673# 64-bit x86 processors supported by --with-arch=. Each processor 674# MUST be separated by exactly one space. 675x86_64_archs="amdfam10 athlon64 athlon64-sse3 barcelona bdver1 bdver2 \ 676bdver3 bdver4 znver1 znver2 btver1 btver2 k8 k8-sse3 opteron \ 677opteron-sse3 nocona core2 corei7 corei7-avx core-avx-i core-avx2 atom \ 678slm nehalem westmere sandybridge ivybridge haswell broadwell bonnell \ 679silvermont knl knm skylake-avx512 cannonlake icelake-client icelake-server \ 680skylake goldmont goldmont-plus tremont cascadelake x86-64 native" 681 682# Additional x86 processors supported by --with-cpu=. Each processor 683# MUST be separated by exactly one space. 684x86_cpus="generic intel" 685 686# Common parts for widely ported systems. 687case ${target} in 688*-*-darwin*) 689 tmake_file="t-darwin " 690 tm_file="${tm_file} darwin.h" 691 case ${target} in 692 *-*-darwin9*) 693 tm_file="${tm_file} darwin9.h" 694 ;; 695 *-*-darwin[1][01]*) 696 tm_file="${tm_file} darwin9.h darwin10.h" 697 ;; 698 *-*-darwin[1][2-9]* | *-*-darwin[2][0-9]*) 699 tm_file="${tm_file} darwin9.h darwin10.h darwin12.h" 700 ;; 701 esac 702 tm_file="${tm_file} ${cpu_type}/darwin.h" 703 tm_p_file="${tm_p_file} darwin-protos.h" 704 target_gtfiles="\$(srcdir)/config/darwin.c" 705 extra_options="${extra_options} darwin.opt" 706 c_target_objs="${c_target_objs} darwin-c.o" 707 cxx_target_objs="${cxx_target_objs} darwin-c.o" 708 fortran_target_objs="darwin-f.o" 709 target_has_targetcm=yes 710 extra_objs="${extra_objs} darwin.o" 711 extra_gcc_objs="darwin-driver.o" 712 default_use_cxa_atexit=yes 713 use_gcc_stdint=wrap 714 case ${enable_threads} in 715 "" | yes | posix) thread_file='posix' ;; 716 esac 717 ;; 718*-*-dragonfly*) 719 gas=yes 720 gnu_ld=yes 721 tmake_file="t-slibgcc" 722 case ${enable_threads} in 723 "" | yes | posix) 724 thread_file='posix' 725 ;; 726 no | single) 727 # Let these non-posix thread selections fall through if requested 728 ;; 729 *) 730 echo 'Unknown thread configuration for DragonFly BSD' 731 exit 1 732 ;; 733 esac 734 extra_options="$extra_options rpath.opt dragonfly.opt" 735 default_use_cxa_atexit=yes 736 use_gcc_stdint=wrap 737 ;; 738*-*-freebsd*) 739 # This is the generic ELF configuration of FreeBSD. Later 740 # machine-specific sections may refine and add to this 741 # configuration. 742 # 743 # Due to tm_file entry ordering issues that vary between cpu 744 # architectures, we only define fbsd_tm_file to allow the 745 # machine-specific section to dictate the final order of all 746 # entries of tm_file with the minor exception that components 747 # of the tm_file set here will always be of the form: 748 # 749 # freebsd<version_number>.h [freebsd-<conf_option>.h ...] freebsd-spec.h freebsd.h 750 # 751 # The machine-specific section should not tamper with this 752 # ordering but may order all other entries of tm_file as it 753 # pleases around the provided core setting. 754 gas=yes 755 gnu_ld=yes 756 fbsd_major=`echo ${target} | sed -e 's/.*freebsd//g' | sed -e 's/\..*//g'` 757 if test "$fbsd_major" = ""; then 758 echo "Specify the major version number of the targeted FreeBSD release" 759 echo "like this: --target=amd64-unknown-freebsd10.1" 760 exit 1 761 fi 762 tm_defines="${tm_defines} FBSD_MAJOR=${fbsd_major}" 763 tmake_file="t-slibgcc" 764 case ${enable_threads} in 765 no) 766 fbsd_tm_file="${fbsd_tm_file} freebsd-nthr.h" 767 ;; 768 "" | yes | posix) 769 thread_file='posix' 770 ;; 771 *) 772 echo 'Unknown thread configuration for FreeBSD' 773 exit 1 774 ;; 775 esac 776 fbsd_tm_file="${fbsd_tm_file} freebsd-spec.h freebsd.h freebsd-stdint.h" 777 extra_options="$extra_options rpath.opt freebsd.opt" 778 case ${target} in 779 *-*-freebsd[345].*) 780 :;; 781 *) 782 default_use_cxa_atexit=yes;; 783 esac 784 use_gcc_stdint=wrap 785 ;; 786*-*-fuchsia*) 787 native_system_header_dir=/include 788 ;; 789*-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-gnu* | *-*-kopensolaris*-gnu) 790 extra_options="$extra_options gnu-user.opt" 791 gas=yes 792 gnu_ld=yes 793 case ${enable_threads} in 794 "" | yes | posix) thread_file='posix' ;; 795 esac 796 tmake_file="t-slibgcc" 797 case $target in 798 *-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-kopensolaris*-gnu) 799 :;; 800 *-*-gnu*) 801 native_system_header_dir=/include 802 ;; 803 esac 804 # Linux C libraries selection switch: glibc / uclibc / bionic. 805 # uclibc and bionic aren't usable for GNU/Hurd and neither for GNU/k*BSD. 806 case $target in 807 *linux*) 808 tm_p_file="${tm_p_file} linux-protos.h" 809 tmake_file="${tmake_file} t-linux" 810 extra_objs="${extra_objs} linux.o" 811 extra_options="${extra_options} linux.opt" 812 ;; 813 esac 814 case $target in 815 *-*-*android*) 816 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_BIONIC" 817 ;; 818 *-*-*uclibc*) 819 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC" 820 ;; 821 *-*-*musl*) 822 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_MUSL" 823 ;; 824 *) 825 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_GLIBC" 826 ;; 827 esac 828 # Assume that glibc or uClibc or Bionic are being used and so __cxa_atexit 829 # is provided. 830 default_use_cxa_atexit=yes 831 use_gcc_tgmath=no 832 use_gcc_stdint=wrap 833 # Enable compilation for Android by default for *android* targets. 834 case $target in 835 *-*-*android*) 836 tm_defines="$tm_defines ANDROID_DEFAULT=1" 837 ;; 838 *) 839 tm_defines="$tm_defines ANDROID_DEFAULT=0" 840 ;; 841 esac 842 c_target_objs="${c_target_objs} glibc-c.o" 843 cxx_target_objs="${cxx_target_objs} glibc-c.o" 844 d_target_objs="${d_target_objs} glibc-d.o" 845 tmake_file="${tmake_file} t-glibc" 846 target_has_targetcm=yes 847 target_has_targetdm=yes 848 ;; 849*-*-netbsd*) 850 tm_p_file="${tm_p_file} netbsd-protos.h" 851 tmake_file="t-netbsd t-slibgcc" 852 extra_objs="${extra_objs} netbsd.o" 853 d_target_objs="${d_target_objs} netbsd-d.o" 854 gas=yes 855 gnu_ld=yes 856 use_gcc_stdint=wrap 857 case ${enable_threads} in 858 "" | yes | posix) thread_file='posix' ;; 859 esac 860 case ${target} in 861 arm*-* | i[34567]86-* | powerpc*-* | sparc*-* | x86_64-*) 862 default_gnu_indirect_function=yes 863 ;; 864 esac 865 nbsd_tm_file="netbsd.h netbsd-stdint.h netbsd-elf.h" 866 default_use_cxa_atexit=yes 867 target_has_targetdm=yes 868 ;; 869*-*-openbsd*) 870 tmake_file="t-openbsd" 871 case ${enable_threads} in 872 yes) 873 thread_file='posix' 874 ;; 875 esac 876 case ${target} in 877 *-*-openbsd4.[3-9]|*-*-openbsd[5-9]*) 878 default_use_cxa_atexit=yes 879 ;; 880 esac 881 ;; 882*-*-phoenix*) 883 gas=yes 884 gnu_ld=yes 885 default_use_cxa_atexit=yes 886 ;; 887*-*-rtems*) 888 case ${enable_threads} in 889 "" | yes | rtems) thread_file='rtems' ;; 890 posix) thread_file='posix' ;; 891 no) ;; 892 *) 893 echo 'Unknown thread configuration for RTEMS' 894 exit 1 895 ;; 896 esac 897 tmake_file="${tmake_file} t-rtems" 898 extra_options="${extra_options} rtems.opt" 899 default_use_cxa_atexit=yes 900 use_gcc_stdint=wrap 901 ;; 902*-*-uclinux*) 903 extra_options="$extra_options gnu-user.opt" 904 use_gcc_stdint=wrap 905 case ${enable_threads} in 906 "" | yes | posix) thread_file='posix' ;; 907 esac 908 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC SINGLE_LIBC" 909 ;; 910*-*-rdos*) 911 use_gcc_stdint=wrap 912 ;; 913*-*-solaris2*) 914 # i?86-*-solaris2* needs to insert headers between cpu default and 915 # Solaris 2 specific ones. 916 sol2_tm_file_head="dbxelf.h elfos.h ${cpu_type}/sysv4.h" 917 sol2_tm_file_tail="${cpu_type}/sol2.h sol2.h" 918 sol2_tm_file="${sol2_tm_file_head} ${sol2_tm_file_tail}" 919 case ${target} in 920 *-*-solaris2.1[1-9]*) 921 # __cxa_atexit was introduced in Solaris 11.4. 922 default_use_cxa_atexit=yes 923 ;; 924 esac 925 use_gcc_stdint=wrap 926 if test x$gnu_ld = xyes; then 927 tm_file="usegld.h ${tm_file}" 928 fi 929 if test x$gas = xyes; then 930 tm_file="usegas.h ${tm_file}" 931 fi 932 tm_p_file="${tm_p_file} sol2-protos.h" 933 tmake_file="${tmake_file} t-sol2 t-slibgcc" 934 c_target_objs="${c_target_objs} sol2-c.o" 935 cxx_target_objs="${cxx_target_objs} sol2-c.o sol2-cxx.o" 936 d_target_objs="${d_target_objs} sol2-d.o" 937 extra_objs="${extra_objs} sol2.o sol2-stubs.o" 938 extra_options="${extra_options} sol2.opt" 939 case ${enable_threads}:${have_pthread_h}:${have_thread_h} in 940 "":yes:* | yes:yes:* ) 941 thread_file=posix 942 ;; 943 esac 944 target_has_targetdm=yes 945 ;; 946*-*-*vms*) 947 extra_options="${extra_options} vms/vms.opt" 948 xmake_file=vms/x-vms 949 tmake_file="vms/t-vms t-slibgcc" 950 extra_objs="vms.o" 951 target_gtfiles="$target_gtfiles \$(srcdir)/config/vms/vms.c" 952 tm_p_file="${tm_p_file} vms/vms-protos.h" 953 xm_file="vms/xm-vms.h" 954 c_target_objs="vms-c.o" 955 cxx_target_objs="vms-c.o" 956 fortran_target_objs="vms-f.o" 957 use_gcc_stdint=provide 958 tm_file="${tm_file} vms/vms-stdint.h" 959 if test x$gnu_ld != xyes; then 960 # Build wrappers for native case. 961 extra_programs="ld\$(exeext) ar\$(exeext)" 962 tmake_file="$tmake_file vms/t-vmsnative" 963 fi 964 ;; 965*-*-vxworks*) 966 tmake_file=t-vxworks 967 xm_defines=POSIX 968 extra_options="${extra_options} vxworks.opt" 969 extra_objs="$extra_objs vxworks.o" 970 use_gcc_stdint=provide 971 tm_file="${tm_file} vxworks-stdint.h" 972 case ${enable_threads} in 973 no) ;; 974 "" | yes | vxworks) thread_file='vxworks' ;; 975 *) echo 'Unknown thread configuration for VxWorks'; exit 1 ;; 976 esac 977 case $target in 978 *-*-vxworks7*) 979 tm_defines="$tm_defines TARGET_VXWORKS7=1" 980 ;; 981 esac 982 case $target in 983 *64-*-vxworks*) 984 tm_defines="$tm_defines TARGET_VXWORKS64=1" 985 ;; 986 esac 987 ;; 988*-*-elf|arc*-*-elf*) 989 # Assume that newlib is being used and so __cxa_atexit is provided. 990 default_use_cxa_atexit=yes 991 use_gcc_stdint=wrap 992 ;; 993esac 994 995case ${target} in 996aarch64*-*-elf | aarch64*-*-fuchsia* | aarch64*-*-rtems*) 997 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h" 998 tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-elf-raw.h" 999 tmake_file="${tmake_file} aarch64/t-aarch64" 1000 case $target in 1001 aarch64-*-elf*) 1002 use_gcc_stdint=wrap 1003 ;; 1004 aarch64-*-fuchsia*) 1005 tm_file="${tm_file} fuchsia.h" 1006 ;; 1007 aarch64-*-rtems*) 1008 tm_file="${tm_file} rtems.h aarch64/rtems.h" 1009 ;; 1010 esac 1011 case $target in 1012 aarch64_be-*) 1013 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 1014 ;; 1015 esac 1016 aarch64_multilibs="${with_multilib_list}" 1017 if test "$aarch64_multilibs" = "default"; then 1018 aarch64_multilibs="lp64,ilp32" 1019 fi 1020 aarch64_multilibs=`echo $aarch64_multilibs | sed -e 's/,/ /g'` 1021 for aarch64_multilib in ${aarch64_multilibs}; do 1022 case ${aarch64_multilib} in 1023 ilp32 | lp64 ) 1024 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${aarch64_multilib}" 1025 ;; 1026 *) 1027 echo "--with-multilib-list=${aarch64_multilib} not supported." 1028 exit 1 1029 esac 1030 done 1031 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'` 1032 ;; 1033aarch64*-*-freebsd*) 1034 tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file}" 1035 tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-freebsd.h" 1036 tmake_file="${tmake_file} aarch64/t-aarch64 aarch64/t-aarch64-freebsd" 1037 tm_defines="${tm_defines} TARGET_DEFAULT_ASYNC_UNWIND_TABLES=1" 1038 ;; 1039aarch64*-*-netbsd*) 1040 tm_file="${tm_file} dbxelf.h elfos.h ${nbsd_tm_file}" 1041 tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-netbsd.h" 1042 tmake_file="${tmake_file} aarch64/t-aarch64 aarch64/t-aarch64-netbsd" 1043 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 1044 case $target in 1045 aarch64_be-*) 1046 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 1047 ;; 1048 esac 1049 ;; 1050aarch64*-*-linux*) 1051 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h" 1052 tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-linux.h" 1053 tmake_file="${tmake_file} aarch64/t-aarch64 aarch64/t-aarch64-linux" 1054 tm_defines="${tm_defines} TARGET_DEFAULT_ASYNC_UNWIND_TABLES=1" 1055 case $target in 1056 aarch64_be-*) 1057 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 1058 ;; 1059 esac 1060 aarch64_multilibs="${with_multilib_list}" 1061 if test "$aarch64_multilibs" = "default"; then 1062 # TODO: turn on ILP32 multilib build after its support is mature. 1063 # aarch64_multilibs="lp64,ilp32" 1064 aarch64_multilibs="lp64" 1065 fi 1066 aarch64_multilibs=`echo $aarch64_multilibs | sed -e 's/,/ /g'` 1067 for aarch64_multilib in ${aarch64_multilibs}; do 1068 case ${aarch64_multilib} in 1069 ilp32 | lp64 ) 1070 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${aarch64_multilib}" 1071 ;; 1072 *) 1073 echo "--with-multilib-list=${aarch64_multilib} not supported." 1074 exit 1 1075 esac 1076 done 1077 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'` 1078 ;; 1079alpha*-*-linux*) 1080 tm_file="elfos.h ${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h glibc-stdint.h" 1081 tmake_file="${tmake_file} alpha/t-linux alpha/t-alpha" 1082 extra_options="${extra_options} alpha/elf.opt" 1083 ;; 1084alpha*-*-netbsd*) 1085 tm_file="elfos.h ${tm_file} ${nbsd_tm_file} alpha/elf.h alpha/netbsd.h" 1086 tmake_file="${tmake_file} alpha/t-alpha" 1087 extra_options="${extra_options} netbsd.opt netbsd-elf.opt \ 1088 alpha/elf.opt" 1089 ;; 1090alpha*-*-openbsd*) 1091 tm_defines="${tm_defines} OBSD_HAS_DECLARE_FUNCTION_NAME OBSD_HAS_DECLARE_FUNCTION_SIZE OBSD_HAS_DECLARE_OBJECT" 1092 tm_file="elfos.h alpha/alpha.h alpha/elf.h openbsd.h openbsd-stdint.h alpha/openbsd.h openbsd-libpthread.h" 1093 tmake_file="${tmake_file} alpha/t-alpha" 1094 extra_options="${extra_options} openbsd.opt alpha/elf.opt" 1095 # default x-alpha is only appropriate for dec-osf. 1096 ;; 1097alpha*-dec-*vms*) 1098 tm_file="${tm_file} vms/vms.h alpha/vms.h" 1099 tmake_file="${tmake_file} alpha/t-vms alpha/t-alpha" 1100 ;; 1101arc*-*-elf*) 1102 tm_file="arc/arc-arch.h dbxelf.h elfos.h newlib-stdint.h arc/elf.h ${tm_file}" 1103 tmake_file="arc/t-multilib arc/t-arc" 1104 extra_gcc_objs="driver-arc.o" 1105 if test "x$with_cpu" != x; then 1106 tm_defines="${tm_defines} TARGET_CPU_BUILD=PROCESSOR_$with_cpu" 1107 fi 1108 if test x${with_endian} = x; then 1109 case ${target} in 1110 arc*be-*-* | arc*eb-*-*) with_endian=big ;; 1111 *) with_endian=little ;; 1112 esac 1113 fi 1114 case ${with_endian} in 1115 big|little) ;; 1116 *) echo "with_endian=${with_endian} not supported."; exit 1 ;; 1117 esac 1118 case ${with_endian} in 1119 big*) tm_file="arc/big.h ${tm_file}" 1120 esac 1121 ;; 1122arc*-*-linux*) 1123 tm_file="arc/arc-arch.h dbxelf.h elfos.h gnu-user.h linux.h linux-android.h glibc-stdint.h arc/linux.h ${tm_file}" 1124 tmake_file="${tmake_file} arc/t-multilib-linux arc/t-arc" 1125 extra_gcc_objs="driver-arc.o" 1126 if test "x$with_cpu" != x; then 1127 tm_defines="${tm_defines} TARGET_CPU_BUILD=PROCESSOR_$with_cpu" 1128 fi 1129 if test x${with_endian} = x; then 1130 case ${target} in 1131 arc*be-*-* | arc*eb-*-*) with_endian=big ;; 1132 *) with_endian=little ;; 1133 esac 1134 fi 1135 case ${with_endian} in 1136 big|little) ;; 1137 *) echo "with_endian=${with_endian} not supported."; exit 1 ;; 1138 esac 1139 case ${with_endian} in 1140 big*) tm_file="arc/big.h ${tm_file}" 1141 esac 1142 # Force .init_array support. The configure script cannot always 1143 # automatically detect that GAS supports it, yet we require it. 1144 gcc_cv_initfini_array=yes 1145 ;; 1146arm-wrs-vxworks|arm-wrs-vxworks7) 1147 extra_options="${extra_options} arm/vxworks.opt" 1148 tmake_file="${tmake_file} arm/t-arm arm/t-vxworks" 1149 case $target in 1150 *-vxworks7) 1151 # VxWorks7 on ARM adheres to the ARM Base Platform ABI 1152 tmake_file="${tmake_file} arm/t-bpabi" 1153 tm_file="arm/bpabi.h ${tm_file}" 1154 # The BPABI long long divmod functions return a 128-bit value in 1155 # registers r0-r3. 1156 need_64bit_hwint=yes 1157 default_use_cxa_atexit=yes 1158 ;; 1159 *) ;; 1160 esac 1161 tm_file="elfos.h arm/elf.h arm/aout.h ${tm_file} vx-common.h vxworks.h arm/vxworks.h" 1162 target_cpu_cname="arm8" 1163 ;; 1164arm*-*-freebsd*) # ARM FreeBSD EABI 1165 tm_file="dbxelf.h elfos.h ${fbsd_tm_file} arm/elf.h" 1166 case $target in 1167 arm*b-*-freebsd*) 1168 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 1169 ;; 1170 esac 1171 tmake_file="${tmake_file} arm/t-arm arm/t-bpabi" 1172 tm_file="${tm_file} arm/bpabi.h arm/freebsd.h arm/aout.h arm/arm.h" 1173 case $target in 1174 armv6*-*-freebsd*) 1175 target_cpu_cname="arm1176jzf-s" 1176 if test $fbsd_major -ge 11; then 1177 tm_defines="${tm_defines} TARGET_FREEBSD_ARM_HARD_FLOAT=1" 1178 fi 1179 ;; 1180 armv7*-*-freebsd*) 1181 target_cpu_cname="generic-armv7-a" 1182 tm_defines="${tm_defines} TARGET_FREEBSD_ARM_HARD_FLOAT=1" 1183 ;; 1184 *) 1185 target_cpu_cname="arm9" 1186 ;; 1187 esac 1188 with_tls=${with_tls:-gnu} 1189 ;; 1190arm*-*-netbsdelf*) 1191 tm_file="dbxelf.h elfos.h ${nbsd_tm_file} arm/elf.h arm/aout.h arm/netbsd-elf.h" 1192 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 1193 tmake_file="${tmake_file} arm/t-arm" 1194 case ${target} in 1195 arm*eb-*) tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" ;; 1196 esac 1197 case ${target} in 1198 arm*-*-netbsdelf-*eabi*) 1199 tm_file="${tm_file} arm/bpabi.h arm/netbsd-eabi.h" 1200 # GCC 7 vs NetBSD/eabi -> avoid arm unwinder 1201 #tmake_file="$tmake_file arm/t-bpabi" 1202 tmake_file="$tmake_file arm/t-netbsdeabi" 1203 # The EABI requires the use of __cxa_atexit. 1204 default_use_cxa_atexit=yes 1205 ;; 1206 *) 1207 tmake_file="$tmake_file arm/t-netbsd" 1208 # NetBSD/arm (non-eabi) is only old platforms 1209 with_cpu=${with_cpu:-strongarm} 1210 ;; 1211 esac 1212 tm_file="${tm_file} arm/arm.h" 1213 case ${target} in 1214 arm*-*-netbsdelf-*eabihf*) 1215 tm_defines="${tm_defines} TARGET_DEFAULT_FLOAT_ABI=ARM_FLOAT_ABI_HARD" 1216 ;; 1217 esac 1218 case ${target} in 1219 armv4*) with_cpu=${with_cpu:-strongarm};; 1220 armv6*) with_cpu=${with_cpu:-arm1176jzf-s};; 1221 armv7*) with_cpu=${with_cpu:-cortex-a8};; 1222 arm*) with_cpu=${with_cpu:-arm9e};; 1223 esac 1224 target_cpu_cname="$with_cpu" 1225 ;; 1226arm*-*-linux-*) # ARM GNU/Linux with ELF 1227 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" 1228 extra_options="${extra_options} linux-android.opt" 1229 case $target in 1230 arm*b-*-linux*) 1231 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 1232 ;; 1233 esac 1234 tmake_file="${tmake_file} arm/t-arm arm/t-arm-elf arm/t-bpabi arm/t-linux-eabi" 1235 tm_file="$tm_file arm/bpabi.h arm/linux-eabi.h arm/aout.h arm/arm.h" 1236 # Generation of floating-point instructions requires at least ARMv5te. 1237 if [ "$with_float" = "hard" -o "$with_float" = "softfp" ] ; then 1238 target_cpu_cname="arm10e" 1239 else 1240 target_cpu_cname="arm10tdmi" 1241 fi 1242 # Define multilib configuration for arm-linux-androideabi. 1243 case ${target} in 1244 *-androideabi) 1245 tmake_file="$tmake_file arm/t-linux-androideabi" 1246 ;; 1247 esac 1248 # The EABI requires the use of __cxa_atexit. 1249 default_use_cxa_atexit=yes 1250 with_tls=${with_tls:-gnu} 1251 ;; 1252arm*-*-uclinux*eabi*) # ARM ucLinux 1253 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/linux-gas.h arm/uclinux-elf.h glibc-stdint.h" 1254 tmake_file="${tmake_file} arm/t-arm arm/t-arm-elf arm/t-bpabi" 1255 tm_file="$tm_file arm/bpabi.h arm/uclinux-eabi.h arm/aout.h arm/arm.h" 1256 target_cpu_cname="arm7tdmi" 1257 # The EABI requires the use of __cxa_atexit. 1258 default_use_cxa_atexit=yes 1259 ;; 1260arm*-*-phoenix*) 1261 tm_file="elfos.h arm/unknown-elf.h arm/elf.h arm/bpabi.h" 1262 tm_file="${tm_file} newlib-stdint.h phoenix.h" 1263 tm_file="${tm_file} arm/aout.h arm/arm.h" 1264 tmake_file="${tmake_file} arm/t-arm arm/t-bpabi arm/t-phoenix" 1265 target_cpu_cname="arm7tdmi" 1266 ;; 1267arm*-*-eabi* | arm*-*-symbianelf* | arm*-*-rtems* | arm*-*-fuchsia*) 1268 case ${target} in 1269 arm*eb-*-eabi*) 1270 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 1271 esac 1272 default_use_cxa_atexit=yes 1273 tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/bpabi.h" 1274 tmake_file="${tmake_file} arm/t-arm arm/t-arm-elf" 1275 target_cpu_cname="arm7tdmi" 1276 case ${target} in 1277 arm*-*-eabi*) 1278 tm_file="$tm_file newlib-stdint.h" 1279 tmake_file="${tmake_file} arm/t-bpabi" 1280 use_gcc_stdint=wrap 1281 ;; 1282 arm*-*-fuchsia*) 1283 tm_file="${tm_file} fuchsia.h arm/fuchsia-elf.h glibc-stdint.h" 1284 tmake_file="${tmake_file} arm/t-bpabi arm/t-fuchsia" 1285 target_cpu_cname="generic-armv7-a" 1286 ;; 1287 arm*-*-rtems*) 1288 tm_file="${tm_file} rtems.h arm/rtems.h newlib-stdint.h" 1289 tmake_file="${tmake_file} arm/t-bpabi arm/t-rtems" 1290 ;; 1291 arm*-*-symbianelf*) 1292 tm_file="${tm_file} arm/symbian.h" 1293 # We do not include t-bpabi for Symbian OS because the system 1294 # provides its own implementation of the BPABI functions. 1295 tmake_file="${tmake_file} arm/t-symbian" 1296 target_cpu_cname="arm10tdmi" 1297 ;; 1298 esac 1299 tm_file="${tm_file} arm/aout.h arm/arm.h" 1300 ;; 1301avr-*-*) 1302 tm_file="elfos.h avr/elf.h avr/avr-arch.h avr/avr.h avr/specs.h dbxelf.h avr/avr-stdint.h" 1303 if test x${with_avrlibc} != xno; then 1304 tm_file="${tm_file} ${cpu_type}/avrlibc.h" 1305 tm_defines="${tm_defines} WITH_AVRLIBC" 1306 fi 1307 tmake_file="${tmake_file} avr/t-avr avr/t-multilib" 1308 use_gcc_stdint=wrap 1309 extra_gcc_objs="driver-avr.o avr-devices.o" 1310 extra_objs="avr-devices.o avr-log.o" 1311 ;; 1312bfin*-elf*) 1313 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h bfin/elf.h" 1314 tmake_file=bfin/t-bfin-elf 1315 use_collect2=no 1316 ;; 1317bfin*-uclinux*) 1318 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h gnu-user.h linux.h glibc-stdint.h bfin/uclinux.h" 1319 tmake_file=bfin/t-bfin-uclinux 1320 use_collect2=no 1321 ;; 1322bfin*-linux-uclibc*) 1323 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" 1324 tmake_file="${tmake_file} bfin/t-bfin-linux" 1325 use_collect2=no 1326 ;; 1327bfin*-rtems*) 1328 tm_file="${tm_file} dbxelf.h elfos.h bfin/elf.h bfin/rtems.h rtems.h newlib-stdint.h" 1329 tmake_file="${tmake_file} bfin/t-rtems" 1330 ;; 1331bfin*-*) 1332 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h bfin/elf.h" 1333 use_collect2=no 1334 use_gcc_stdint=wrap 1335 ;; 1336cr16-*-elf) 1337 tm_file="elfos.h ${tm_file} newlib-stdint.h" 1338 tmake_file="${tmake_file} cr16/t-cr16 " 1339 use_collect2=no 1340 ;; 1341crisv32-*-elf | crisv32-*-none) 1342 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 1343 tmake_file="cris/t-cris" 1344 target_cpu_default=32 1345 gas=yes 1346 extra_options="${extra_options} cris/elf.opt" 1347 use_gcc_stdint=wrap 1348 ;; 1349cris-*-elf | cris-*-none) 1350 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 1351 tmake_file="cris/t-cris cris/t-elfmulti" 1352 gas=yes 1353 extra_options="${extra_options} cris/elf.opt" 1354 use_gcc_stdint=wrap 1355 ;; 1356crisv32-*-linux* | cris-*-linux*) 1357 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h glibc-stdint.h cris/linux.h" 1358 tmake_file="${tmake_file} cris/t-cris cris/t-linux" 1359 extra_options="${extra_options} cris/linux.opt" 1360 case $target in 1361 cris-*-*) 1362 target_cpu_default=10 1363 ;; 1364 crisv32-*-*) 1365 target_cpu_default=32 1366 ;; 1367 esac 1368 ;; 1369csky-*-*) 1370 if test x${with_endian} != x; then 1371 case ${with_endian} in 1372 big|little) ;; 1373 *) 1374 echo "with_endian=${with_endian} not supported." 1375 exit 1 1376 ;; 1377 esac 1378 fi 1379 if test x${with_float} != x; then 1380 case ${with_float} in 1381 soft | hard) ;; 1382 *) echo 1383 "Unknown floating point type used in --with-float=$with_float" 1384 exit 1 1385 ;; 1386 esac 1387 fi 1388 tm_file="csky/csky.h" 1389 md_file="csky/csky.md" 1390 out_file="csky/csky.c" 1391 tm_p_file="${tm_p_file} csky/csky-protos.h" 1392 extra_options="${extra_options} csky/csky_tables.opt" 1393 1394 if test x${enable_tpf_debug} = xyes; then 1395 tm_defines="${tm_defines} ENABLE_TPF_DEBUG" 1396 fi 1397 1398 case ${target} in 1399 csky-*-elf*) 1400 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file} csky/csky-elf.h" 1401 tmake_file="csky/t-csky csky/t-csky-elf" 1402 default_use_cxa_atexit=no 1403 ;; 1404 csky-*-linux*) 1405 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} csky/csky-linux-elf.h" 1406 tmake_file="${tmake_file} csky/t-csky csky/t-csky-linux" 1407 1408 if test "x${enable_multilib}" = xyes ; then 1409 tm_file="$tm_file ./sysroot-suffix.h" 1410 tmake_file="${tmake_file} csky/t-sysroot-suffix" 1411 fi 1412 1413 case ${target} in 1414 csky-*-linux-gnu*) 1415 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_GLIBC" 1416 # Force .init_array support. The configure script cannot always 1417 # automatically detect that GAS supports it, yet we require it. 1418 gcc_cv_initfini_array=yes 1419 ;; 1420 csky-*-linux-uclibc*) 1421 tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC" 1422 default_use_cxa_atexit=no 1423 ;; 1424 *) 1425 echo "Unknown target $target" 1426 exit 1 1427 ;; 1428 esac 1429 ;; 1430 *) 1431 echo "Unknown target $target" 1432 exit 1 1433 ;; 1434 esac 1435 ;; 1436epiphany-*-elf | epiphany-*-rtems*) 1437 tm_file="${tm_file} dbxelf.h elfos.h" 1438 tmake_file="${tmake_file} epiphany/t-epiphany" 1439 case ${target} in 1440 epiphany-*-rtems*) 1441 tm_file="${tm_file} rtems.h epiphany/rtems.h newlib-stdint.h" 1442 ;; 1443 *) 1444 tm_file="${tm_file} newlib-stdint.h" 1445 ;; 1446 esac 1447 extra_options="${extra_options} fused-madd.opt" 1448 extra_objs="${extra_objs} mode-switch-use.o resolve-sw-modes.o" 1449 tm_defines="${tm_defines} EPIPHANY_STACK_OFFSET=${with_stack_offset:-8}" 1450 extra_headers="epiphany_intrinsics.h" 1451 ;; 1452fr30-*-elf) 1453 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 1454 ;; 1455frv-*-elf) 1456 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 1457 tmake_file=frv/t-frv 1458 ;; 1459frv-*-*linux*) 1460 tm_file="dbxelf.h elfos.h ${tm_file} \ 1461 gnu-user.h linux.h glibc-stdint.h frv/linux.h" 1462 tmake_file="${tmake_file} frv/t-frv frv/t-linux" 1463 ;; 1464ft32-*-elf) 1465 gas=yes 1466 gnu_ld=yes 1467 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 1468 tmake_file="${tmake_file} ft32/t-ft32" 1469 ;; 1470amdgcn-*-amdhsa) 1471 tm_file="elfos.h gcn/gcn-hsa.h gcn/gcn.h newlib-stdint.h" 1472 tmake_file="gcn/t-gcn-hsa" 1473 native_system_header_dir=/include 1474 extra_modes=gcn/gcn-modes.def 1475 extra_objs="${extra_objs} gcn-tree.o" 1476 extra_gcc_objs="driver-gcn.o" 1477 case "$host" in 1478 x86_64*-*-linux-gnu ) 1479 if test "$ac_cv_search_dlopen" != no; then 1480 extra_programs="${extra_programs} gcn-run\$(exeext)" 1481 fi 1482 ;; 1483 esac 1484 if test x$enable_as_accelerator = xyes; then 1485 extra_programs="${extra_programs} mkoffload\$(exeext)" 1486 tm_file="${tm_file} gcn/offload.h" 1487 fi 1488 ;; 1489moxie-*-elf) 1490 gas=yes 1491 gnu_ld=yes 1492 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 1493 tmake_file="${tmake_file} moxie/t-moxie" 1494 ;; 1495moxie-*-uclinux*) 1496 gas=yes 1497 gnu_ld=yes 1498 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h glibc-stdint.h moxie/uclinux.h" 1499 tmake_file="${tmake_file} moxie/t-moxie" 1500 ;; 1501moxie-*-rtems*) 1502 tmake_file="${tmake_file} moxie/t-moxie" 1503 tm_file="moxie/moxie.h dbxelf.h elfos.h moxie/rtems.h rtems.h newlib-stdint.h" 1504 ;; 1505moxie-*-moxiebox*) 1506 gas=yes 1507 gnu_ld=yes 1508 tm_file="${tm_file} dbxelf.h elfos.h moxie/moxiebox.h newlib-stdint.h" 1509 tmake_file="${tmake_file} moxie/t-moxiebox" 1510 ;; 1511h8300-*-elf*) 1512 tmake_file="h8300/t-h8300" 1513 tm_file="h8300/h8300.h dbxelf.h elfos.h newlib-stdint.h h8300/elf.h" 1514 ;; 1515h8300-*-linux*) 1516 tmake_file="${tmake_file} h8300/t-h8300 h8300/t-linux" 1517 tm_file="h8300/h8300.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h h8300/linux.h" 1518 ;; 1519hppa*64*-*-linux*) 1520 target_cpu_default="MASK_PA_11|MASK_PA_20" 1521 tm_file="pa/pa64-start.h ${tm_file} dbxelf.h elfos.h gnu-user.h linux.h \ 1522 glibc-stdint.h pa/pa-linux.h pa/pa64-regs.h pa/pa-64.h \ 1523 pa/pa64-linux.h" 1524 tmake_file="${tmake_file} pa/t-pa pa/t-linux" 1525 d_target_objs="${d_target_objs} pa-d.o" 1526 gas=yes gnu_ld=yes 1527 ;; 1528hppa*-*-linux*) 1529 target_cpu_default="MASK_PA_11|MASK_NO_SPACE_REGS|MASK_CALLER_COPIES" 1530 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h pa/pa-linux.h \ 1531 pa/pa32-regs.h pa/pa32-linux.h" 1532 tmake_file="${tmake_file} pa/t-pa pa/t-linux" 1533 d_target_objs="${d_target_objs} pa-d.o" 1534 ;; 1535hppa*-*-openbsd*) 1536 target_cpu_default="MASK_PA_11" 1537 tm_file="${tm_file} dbxelf.h elfos.h openbsd.h openbsd-stdint.h openbsd-libpthread.h \ 1538 pa/pa-openbsd.h pa/pa32-regs.h pa/pa32-openbsd.h" 1539 extra_options="${extra_options} openbsd.opt" 1540 tmake_file="pa/t-pa" 1541 d_target_objs="${d_target_objs} pa-d.o" 1542 gas=yes 1543 gnu_ld=yes 1544 ;; 1545hppa*-*-netbsd* | parisc*-*-netbsd*) 1546 target_cpu_default="MASK_PA_11|MASK_NO_SPACE_REGS" 1547 tm_file="${tm_file} dbxelf.h elfos.h ${nbsd_tm_file} \ 1548 pa/pa-netbsd.h pa/pa32-regs.h pa/pa32-netbsd.h" 1549 tmake_file="${tmake_file} pa/t-netbsd" 1550 tm_defines="${tm_defines} CHAR_FAST8=1 SHORT_FAST16=1" 1551 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 1552 ;; 1553hppa[12]*-*-hpux10*) 1554 case ${target} in 1555 hppa1.1-*-* | hppa2*-*-*) 1556 target_cpu_default="MASK_PA_11" 1557 ;; 1558 esac 1559 tm_file="${tm_file} pa/pa32-regs.h dbxelf.h pa/som.h \ 1560 pa/pa-hpux.h pa/pa-hpux10.h" 1561 extra_options="${extra_options} pa/pa-hpux.opt pa/pa-hpux10.opt" 1562 case ${target} in 1563 *-*-hpux10.[1-9]*) 1564 tm_file="${tm_file} pa/pa-hpux1010.h" 1565 extra_options="${extra_options} pa/pa-hpux1010.opt" 1566 ;; 1567 esac 1568 use_gcc_stdint=provide 1569 tm_file="${tm_file} hpux-stdint.h" 1570 tmake_file="pa/t-pa t-slibgcc" 1571 d_target_objs="${d_target_objs} pa-d.o" 1572 case ${enable_threads} in 1573 "") 1574 if test x$have_pthread_h = xyes ; then 1575 tmake_file="${tmake_file} pa/t-dce-thr" 1576 fi 1577 ;; 1578 yes | dce) 1579 tmake_file="${tmake_file} pa/t-dce-thr" 1580 ;; 1581 esac 1582 use_collect2=yes 1583 gas=yes 1584 if test "x$with_dwarf2" != x; then 1585 echo "Warning: dwarf2 debug format is not supported for this target, --with-dwarf2 ignored" 1>&2 1586 dwarf2=no 1587 fi 1588 ;; 1589hppa*64*-*-hpux11*) 1590 target_cpu_default="MASK_PA_11|MASK_PA_20" 1591 if test x$gnu_ld = xyes 1592 then 1593 target_cpu_default="${target_cpu_default}|MASK_GNU_LD" 1594 fi 1595 tm_file="pa/pa64-start.h ${tm_file} dbxelf.h elfos.h \ 1596 pa/pa64-regs.h pa/pa-hpux.h pa/pa-hpux1010.h \ 1597 pa/pa-hpux11.h" 1598 case ${target} in 1599 *-*-hpux11.[12]*) 1600 tm_file="${tm_file} pa/pa-hpux1111.h pa/pa-64.h pa/pa64-hpux.h" 1601 extra_options="${extra_options} pa/pa-hpux1111.opt" 1602 ;; 1603 *-*-hpux11.[3-9]*) 1604 tm_file="${tm_file} pa/pa-hpux1131.h pa/pa-64.h pa/pa64-hpux.h" 1605 extra_options="${extra_options} pa/pa-hpux1131.opt" 1606 ;; 1607 *) 1608 tm_file="${tm_file} pa/pa-64.h pa/pa64-hpux.h" 1609 ;; 1610 esac 1611 extra_options="${extra_options} pa/pa-hpux.opt \ 1612 pa/pa-hpux1010.opt pa/pa64-hpux.opt hpux11.opt" 1613 tmake_file="pa/t-pa t-slibgcc" 1614 d_target_objs="${d_target_objs} pa-d.o" 1615 case x${enable_threads} in 1616 x | xyes | xposix ) 1617 thread_file=posix 1618 ;; 1619 esac 1620 gas=yes 1621 case ${target} in 1622 *-*-hpux11.[01]*) 1623 use_gcc_stdint=provide 1624 tm_file="${tm_file} hpux-stdint.h" 1625 ;; 1626 *-*-hpux11.[23]*) 1627 use_gcc_stdint=wrap 1628 tm_file="${tm_file} hpux-stdint.h" 1629 ;; 1630 esac 1631 ;; 1632hppa[12]*-*-hpux11*) 1633 case ${target} in 1634 hppa1.1-*-* | hppa2*-*-*) 1635 target_cpu_default="MASK_PA_11" 1636 ;; 1637 esac 1638 tm_file="${tm_file} pa/pa32-regs.h dbxelf.h pa/som.h \ 1639 pa/pa-hpux.h pa/pa-hpux1010.h pa/pa-hpux11.h" 1640 extra_options="${extra_options} pa/pa-hpux.opt pa/pa-hpux1010.opt \ 1641 hpux11.opt" 1642 case ${target} in 1643 *-*-hpux11.[12]*) 1644 tm_file="${tm_file} pa/pa-hpux1111.h" 1645 extra_options="${extra_options} pa/pa-hpux1111.opt" 1646 ;; 1647 *-*-hpux11.[3-9]*) 1648 tm_file="${tm_file} pa/pa-hpux1131.h" 1649 extra_options="${extra_options} pa/pa-hpux1131.opt" 1650 ;; 1651 esac 1652 tmake_file="pa/t-pa t-slibgcc" 1653 d_target_objs="${d_target_objs} pa-d.o" 1654 case x${enable_threads} in 1655 x | xyes | xposix ) 1656 thread_file=posix 1657 ;; 1658 esac 1659 use_collect2=yes 1660 gas=yes 1661 case ${target} in 1662 *-*-hpux11.[01]*) 1663 use_gcc_stdint=provide 1664 tm_file="${tm_file} hpux-stdint.h" 1665 ;; 1666 *-*-hpux11.[23]*) 1667 use_gcc_stdint=wrap 1668 tm_file="${tm_file} hpux-stdint.h" 1669 ;; 1670 esac 1671 if test "x$with_dwarf2" != x; then 1672 echo "Warning: dwarf2 debug format is not supported for this target, --with-dwarf2 ignored" 1>&2 1673 dwarf2=no 1674 fi 1675 ;; 1676i[34567]86-*-darwin1[89]*) 1677 echo "Error: 32bit target is not supported after Darwin17" 1>&2 1678 ;; 1679i[34567]86-*-darwin*) 1680 need_64bit_isa=yes 1681 # Baseline choice for a machine that allows m64 support. 1682 with_cpu=${with_cpu:-core2} 1683 tmake_file="${tmake_file} ${cpu_type}/t-darwin32-biarch t-slibgcc" 1684 tm_file="${tm_file} ${cpu_type}/darwin32-biarch.h" 1685 ;; 1686x86_64-*-darwin1[89]* | x86_64-*-darwin2[01]*) 1687 # Only 64b from now 1688 with_cpu=${with_cpu:-core2} 1689 tmake_file="${tmake_file} t-slibgcc" 1690 ;; 1691x86_64-*-darwin*) 1692 with_cpu=${with_cpu:-core2} 1693 tmake_file="${tmake_file} ${cpu_type}/t-darwin64-biarch t-slibgcc" 1694 tm_file="${tm_file} ${cpu_type}/darwin64-biarch.h" 1695 ;; 1696i[34567]86-*-elfiamcu) 1697 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/iamcu.h" 1698 ;; 1699i[34567]86-*-elf*) 1700 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h" 1701 ;; 1702x86_64-*-elf*) 1703 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h" 1704 ;; 1705x86_64-*-rtems*) 1706 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h i386/rtemself.h rtems.h" 1707 ;; 1708i[34567]86-*-rdos*) 1709 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h i386/rdos.h" 1710 ;; 1711x86_64-*-rdos*) 1712 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h i386/rdos.h i386/rdos64.h" 1713 tmake_file="i386/t-i386elf t-svr4" 1714 ;; 1715i[34567]86-*-dragonfly*) 1716 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h dragonfly.h dragonfly-stdint.h i386/dragonfly.h" 1717 tmake_file="${tmake_file} i386/t-crtstuff" 1718 ;; 1719x86_64-*-dragonfly*) 1720 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h dragonfly.h dragonfly-stdint.h i386/x86-64.h i386/dragonfly.h" 1721 tmake_file="${tmake_file} i386/t-crtstuff" 1722 ;; 1723i[34567]86-*-freebsd*) 1724 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${fbsd_tm_file} i386/freebsd.h" 1725 ;; 1726x86_64-*-freebsd*) 1727 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" 1728 ;; 1729i[34567]86-*-netbsdelf*) 1730 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${nbsd_tm_file} i386/netbsd-elf.h" 1731 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 1732 ;; 1733x86_64-*-netbsd*) 1734 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${nbsd_tm_file} i386/x86-64.h i386/netbsd64.h" 1735 tmake_file="${tmake_file} i386/t-netbsd64" 1736 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 1737 ;; 1738i[34567]86-*-openbsd*) 1739 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h" 1740 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h i386/openbsdelf.h" 1741 extra_options="${extra_options} openbsd.opt" 1742 gas=yes 1743 gnu_ld=yes 1744 ;; 1745x86_64-*-openbsd*) 1746 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h" 1747 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h i386/x86-64.h i386/openbsdelf.h" 1748 extra_options="${extra_options} openbsd.opt" 1749 gas=yes 1750 gnu_ld=yes 1751 ;; 1752i[34567]86-*-linux* | i[34567]86-*-kfreebsd*-gnu | i[34567]86-*-gnu* | i[34567]86-*-kopensolaris*-gnu) 1753 # Intel 80386's running GNU/* 1754 # with ELF format using glibc 2 1755 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h gnu-user.h glibc-stdint.h" 1756 case ${target} in 1757 i[34567]86-*-linux*) 1758 tm_file="${tm_file} linux.h linux-android.h" 1759 extra_options="${extra_options} linux-android.opt" 1760 if test x$enable_targets = xall; then 1761 tm_file="${tm_file} i386/x86-64.h i386/gnu-user-common.h i386/gnu-user64.h i386/linux-common.h i386/linux64.h" 1762 tm_defines="${tm_defines} TARGET_BI_ARCH=1" 1763 tmake_file="${tmake_file} i386/t-linux64" 1764 x86_multilibs="${with_multilib_list}" 1765 if test "$x86_multilibs" = "default"; then 1766 x86_multilibs="m64,m32" 1767 fi 1768 x86_multilibs=`echo $x86_multilibs | sed -e 's/,/ /g'` 1769 for x86_multilib in ${x86_multilibs}; do 1770 case ${x86_multilib} in 1771 m32 | m64 | mx32) 1772 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${x86_multilib}" 1773 ;; 1774 *) 1775 echo "--with-multilib-list=${x86_with_multilib} not supported." 1776 exit 1 1777 esac 1778 done 1779 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'` 1780 need_64bit_isa=yes 1781 if test x$with_cpu = x; then 1782 if test x$with_cpu_64 = x; then 1783 with_cpu_64=generic 1784 fi 1785 else 1786 case " $x86_cpus $x86_archs $x86_64_archs " in 1787 *" $with_cpu "*) 1788 ;; 1789 *) 1790 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2 1791 echo "$x86_cpus $x86_archs $x86_64_archs " 1>&2 1792 exit 1 1793 ;; 1794 esac 1795 fi 1796 else 1797 tm_file="${tm_file} i386/gnu-user-common.h i386/gnu-user.h i386/linux-common.h i386/linux.h" 1798 fi 1799 ;; 1800 i[34567]86-*-kfreebsd*-gnu) 1801 tm_file="${tm_file} i386/gnu-user-common.h i386/gnu-user.h kfreebsd-gnu.h i386/kfreebsd-gnu.h" 1802 ;; 1803 i[34567]86-*-kopensolaris*-gnu) 1804 tm_file="${tm_file} i386/gnu-user-common.h i386/gnu-user.h kopensolaris-gnu.h i386/kopensolaris-gnu.h" 1805 ;; 1806 i[34567]86-*-gnu*) 1807 tm_file="$tm_file i386/gnu-user-common.h i386/gnu-user.h gnu.h i386/gnu.h" 1808 ;; 1809 esac 1810 ;; 1811x86_64-*-linux* | x86_64-*-kfreebsd*-gnu) 1812 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h gnu-user.h glibc-stdint.h \ 1813 i386/x86-64.h i386/gnu-user-common.h i386/gnu-user64.h" 1814 case ${target} in 1815 x86_64-*-linux*) 1816 tm_file="${tm_file} linux.h linux-android.h i386/linux-common.h i386/linux64.h" 1817 extra_options="${extra_options} linux-android.opt" 1818 ;; 1819 x86_64-*-kfreebsd*-gnu) 1820 tm_file="${tm_file} kfreebsd-gnu.h i386/kfreebsd-gnu64.h" 1821 ;; 1822 esac 1823 tmake_file="${tmake_file} i386/t-linux64" 1824 x86_multilibs="${with_multilib_list}" 1825 if test "$x86_multilibs" = "default"; then 1826 case ${with_abi} in 1827 x32 | mx32) 1828 x86_multilibs="mx32" 1829 ;; 1830 *) 1831 x86_multilibs="m64,m32" 1832 ;; 1833 esac 1834 fi 1835 x86_multilibs=`echo $x86_multilibs | sed -e 's/,/ /g'` 1836 for x86_multilib in ${x86_multilibs}; do 1837 case ${x86_multilib} in 1838 m32 | m64 | mx32) 1839 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${x86_multilib}" 1840 ;; 1841 *) 1842 echo "--with-multilib-list=${x86_with_multilib} not supported." 1843 exit 1 1844 esac 1845 done 1846 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'` 1847 ;; 1848i[34567]86-pc-msdosdjgpp*) 1849 xm_file=i386/xm-djgpp.h 1850 tm_file="dbxcoff.h ${tm_file} i386/unix.h i386/bsd.h i386/gas.h i386/djgpp.h i386/djgpp-stdint.h" 1851 native_system_header_dir=/dev/env/DJDIR/include 1852 extra_options="${extra_options} i386/djgpp.opt" 1853 gnu_ld=yes 1854 gas=yes 1855 use_gcc_stdint=wrap 1856 ;; 1857i[34567]86-*-lynxos*) 1858 xm_defines=POSIX 1859 tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/lynx.h lynx.h" 1860 tmake_file="${tmake_file} t-lynx" 1861 extra_options="${extra_options} lynx.opt" 1862 thread_file=lynx 1863 gnu_ld=yes 1864 gas=yes 1865 ;; 1866i[34567]86-*-nto-qnx*) 1867 tm_file="${tm_file} i386/att.h dbxelf.h tm-dwarf2.h elfos.h i386/unix.h i386/nto.h" 1868 extra_options="${extra_options} i386/nto.opt" 1869 gnu_ld=yes 1870 gas=yes 1871 ;; 1872i[34567]86-*-rtems*) 1873 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" 1874 tmake_file="${tmake_file} i386/t-rtems" 1875 ;; 1876i[34567]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*) 1877 # Set default arch_32 to pentium4, tune_32 to generic like the other 1878 # i386 targets, although config.guess defaults to i386-pc-solaris2*. 1879 with_arch_32=${with_arch_32:-pentium4} 1880 with_tune_32=${with_tune_32:-generic} 1881 tm_file="${tm_file} i386/unix.h i386/att.h ${sol2_tm_file_head} i386/x86-64.h ${sol2_tm_file_tail}" 1882 tm_defines="${tm_defines} TARGET_BI_ARCH=1" 1883 tmake_file="$tmake_file i386/t-sol2" 1884 need_64bit_isa=yes 1885 if test x$with_cpu = x; then 1886 if test x$with_cpu_64 = x; then 1887 with_cpu_64=generic 1888 fi 1889 else 1890 case " $x86_cpus $x86_archs $x86_64_archs " in 1891 *" $with_cpu "*) 1892 ;; 1893 *) 1894 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2 1895 echo "$x86_cpus $x86_archs $x86_64_archs" 1>&2 1896 exit 1 1897 ;; 1898 esac 1899 fi 1900 ;; 1901i[4567]86-wrs-vxworks|i[4567]86-wrs-vxworksae|i[4567]86-wrs-vxworks7|x86_64-wrs-vxworks7) 1902 tm_file="${tm_file} i386/unix.h i386/att.h elfos.h" 1903 case ${target} in 1904 x86_64-*) 1905 need_64bit_isa=yes 1906 tm_file="${tm_file} i386/x86-64.h" 1907 ;; 1908 esac 1909 tm_file="${tm_file} vx-common.h" 1910 case ${target} in 1911 *-vxworksae*) 1912 tm_file="${tm_file} vxworksae.h i386/vxworks.h i386/vxworksae.h" 1913 tmake_file="${tmake_file} i386/t-vxworks i386/t-vxworksae" 1914 ;; 1915 *) 1916 tm_file="${tm_file} vxworks.h i386/vxworks.h" 1917 tmake_file="${tmake_file} i386/t-vxworks" 1918 ;; 1919 esac 1920 ;; 1921i[34567]86-*-cygwin*) 1922 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" 1923 xm_file=i386/xm-cygwin.h 1924 tmake_file="${tmake_file} i386/t-cygming t-slibgcc" 1925 target_gtfiles="\$(srcdir)/config/i386/winnt.c" 1926 extra_options="${extra_options} i386/cygming.opt i386/cygwin.opt" 1927 extra_objs="${extra_objs} winnt.o winnt-stubs.o" 1928 c_target_objs="${c_target_objs} msformat-c.o" 1929 cxx_target_objs="${cxx_target_objs} winnt-cxx.o msformat-c.o" 1930 if test x$enable_threads = xyes; then 1931 thread_file='posix' 1932 fi 1933 default_use_cxa_atexit=yes 1934 use_gcc_stdint=wrap 1935 ;; 1936x86_64-*-cygwin*) 1937 need_64bit_isa=yes 1938 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygming.h i386/cygwin.h i386/cygwin-w64.h i386/cygwin-stdint.h" 1939 xm_file=i386/xm-cygwin.h 1940 tmake_file="${tmake_file} i386/t-cygming t-slibgcc i386/t-cygwin-w64" 1941 target_gtfiles="\$(srcdir)/config/i386/winnt.c" 1942 extra_options="${extra_options} i386/cygming.opt i386/cygwin.opt" 1943 extra_objs="${extra_objs} winnt.o winnt-stubs.o" 1944 c_target_objs="${c_target_objs} msformat-c.o" 1945 cxx_target_objs="${cxx_target_objs} winnt-cxx.o msformat-c.o" 1946 if test x$enable_threads = xyes; then 1947 thread_file='posix' 1948 fi 1949 default_use_cxa_atexit=yes 1950 use_gcc_stdint=wrap 1951 tm_defines="${tm_defines} TARGET_CYGWIN64=1" 1952 ;; 1953i[34567]86-*-mingw* | x86_64-*-mingw*) 1954 tm_file="${tm_file} i386/unix.h i386/bsd.h i386/gas.h dbxcoff.h i386/cygming.h" 1955 xm_file=i386/xm-mingw32.h 1956 c_target_objs="${c_target_objs} winnt-c.o" 1957 cxx_target_objs="${cxx_target_objs} winnt-c.o" 1958 target_has_targetcm="yes" 1959 case ${target} in 1960 x86_64-*-* | *-w64-*) 1961 need_64bit_isa=yes 1962 ;; 1963 *) 1964 ;; 1965 esac 1966 if test x$enable_threads = xposix ; then 1967 tm_file="${tm_file} i386/mingw-pthread.h" 1968 fi 1969 tm_file="${tm_file} i386/mingw32.h" 1970 # This makes the logic if mingw's or the w64 feature set has to be used 1971 case ${target} in 1972 *-w64-*) 1973 user_headers_inc_next_post="${user_headers_inc_next_post} float.h" 1974 user_headers_inc_next_pre="${user_headers_inc_next_pre} stddef.h stdarg.h" 1975 tm_file="${tm_file} i386/mingw-w64.h" 1976 if test x$enable_targets = xall; then 1977 tm_defines="${tm_defines} TARGET_BI_ARCH=1" 1978 if test x$with_cpu = x; then 1979 if test x$with_cpu_64 = x; then 1980 with_cpu_64=generic 1981 fi 1982 else 1983 case " $x86_cpus $x86_archs $x86_64_archs " in 1984 *" $with_cpu "*) 1985 ;; 1986 *) 1987 echo "Unsupported CPU used in --with-cpu=$with_cpu, supported values:" 1>&2 1988 echo "$x86_cpus $x86_archs $x86_64_archs" 1>&2 1989 exit 1 1990 ;; 1991 esac 1992 fi 1993 fi 1994 ;; 1995 *) 1996 ;; 1997 esac 1998 tm_file="${tm_file} i386/mingw-stdint.h" 1999 tmake_file="${tmake_file} t-winnt i386/t-cygming t-slibgcc" 2000 case ${target} in 2001 x86_64-w64-*) 2002 tmake_file="${tmake_file} i386/t-mingw-w64" 2003 ;; 2004 i[34567]86-w64-*) 2005 tmake_file="${tmake_file} i386/t-mingw-w32" 2006 ;; 2007 esac 2008 native_system_header_dir=/mingw/include 2009 target_gtfiles="\$(srcdir)/config/i386/winnt.c" 2010 extra_options="${extra_options} i386/cygming.opt i386/mingw.opt" 2011 case ${target} in 2012 *-w64-*) 2013 extra_options="${extra_options} i386/mingw-w64.opt" 2014 ;; 2015 *) 2016 ;; 2017 esac 2018 extra_objs="${extra_objs} winnt.o winnt-stubs.o" 2019 c_target_objs="${c_target_objs} msformat-c.o" 2020 cxx_target_objs="${cxx_target_objs} winnt-cxx.o msformat-c.o" 2021 gas=yes 2022 gnu_ld=yes 2023 default_use_cxa_atexit=yes 2024 use_gcc_stdint=wrap 2025 case ${enable_threads} in 2026 "" | yes | win32) 2027 thread_file='win32' 2028 ;; 2029 posix) 2030 thread_file='posix' 2031 ;; 2032 esac 2033 case ${target} in 2034 *mingw32crt*) 2035 tm_file="${tm_file} i386/crtdll.h" 2036 ;; 2037 *mingw32msv* | *mingw*) 2038 ;; 2039 esac 2040 ;; 2041x86_64-*-fuchsia*) 2042 tmake_file="${tmake_file} i386/t-x86_64-elf" 2043 tm_file="${tm_file} i386/unix.h i386/att.h elfos.h newlib-stdint.h i386/i386elf.h i386/x86-64.h fuchsia.h" 2044 ;; 2045ia64*-*-elf*) 2046 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h ia64/sysv4.h ia64/elf.h" 2047 tmake_file="ia64/t-ia64" 2048 target_cpu_default="0" 2049 if test x$gas = xyes 2050 then 2051 target_cpu_default="${target_cpu_default}|MASK_GNU_AS" 2052 fi 2053 if test x$gnu_ld = xyes 2054 then 2055 target_cpu_default="${target_cpu_default}|MASK_GNU_LD" 2056 fi 2057 ;; 2058ia64*-*-netbsd*) 2059 tm_file="${tm_file} dbxelf.h elfos.h ${nbsd_tm_file} ia64/sysv4.h ia64/netbsd.h" 2060 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD" 2061 tmake_file="${tmake_file} ia64/t-ia64" 2062 if test x$with_system_libunwind != xyes ; then 2063 tmake_file="${tmake_file} t-libunwind-elf ia64/t-glibc-libunwind" 2064 fi 2065 extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtfastmath.o" 2066 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 2067 ;; 2068ia64*-*-freebsd*) 2069 tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} ia64/sysv4.h ia64/freebsd.h" 2070 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD" 2071 tmake_file="${tmake_file} ia64/t-ia64" 2072 ;; 2073ia64*-*-linux*) 2074 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ia64/sysv4.h ia64/linux.h" 2075 tmake_file="${tmake_file} ia64/t-ia64 ia64/t-linux t-libunwind" 2076 target_cpu_default="MASK_GNU_AS|MASK_GNU_LD" 2077 ;; 2078ia64*-*-hpux*) 2079 tm_file="${tm_file} dbxelf.h elfos.h ia64/sysv4.h ia64/hpux.h" 2080 tmake_file="ia64/t-ia64 ia64/t-hpux t-slibgcc" 2081 target_cpu_default="MASK_GNU_AS" 2082 case x$enable_threads in 2083 x | xyes | xposix ) 2084 thread_file=posix 2085 ;; 2086 esac 2087 use_collect2=no 2088 c_target_objs="ia64-c.o" 2089 cxx_target_objs="ia64-c.o" 2090 extra_options="${extra_options} ia64/ilp32.opt hpux11.opt" 2091 use_gcc_stdint=wrap 2092 tm_file="${tm_file} hpux-stdint.h" 2093 case ${target} in 2094 *-*-hpux11.3*) 2095 tm_file="${tm_file} ia64/hpux-unix2003.h" 2096 ;; 2097 esac 2098 ;; 2099ia64-hp-*vms*) 2100 tm_file="${tm_file} elfos.h ia64/sysv4.h vms/vms.h ia64/vms.h" 2101 tmake_file="${tmake_file} ia64/t-ia64" 2102 target_cpu_default="0" 2103 if test x$gas = xyes 2104 then 2105 target_cpu_default="${target_cpu_default}|MASK_GNU_AS" 2106 fi 2107 extra_options="${extra_options} ia64/vms.opt" 2108 ;; 2109iq2000*-*-elf*) 2110 tm_file="elfos.h newlib-stdint.h iq2000/iq2000.h" 2111 out_file=iq2000/iq2000.c 2112 md_file=iq2000/iq2000.md 2113 ;; 2114lm32-*-elf*) 2115 tm_file="dbxelf.h elfos.h ${tm_file} newlib-stdint.h" 2116 tmake_file="${tmake_file} lm32/t-lm32" 2117 ;; 2118lm32-*-rtems*) 2119 tm_file="dbxelf.h elfos.h ${tm_file} lm32/rtems.h rtems.h newlib-stdint.h" 2120 tmake_file="${tmake_file} lm32/t-lm32" 2121 tmake_file="${tmake_file} lm32/t-rtems" 2122 ;; 2123lm32-*-uclinux*) 2124 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h lm32/uclinux-elf.h" 2125 tmake_file="${tmake_file} lm32/t-lm32" 2126 ;; 2127m32r-*-elf*) 2128 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 2129 ;; 2130m32rle-*-elf*) 2131 tm_file="dbxelf.h elfos.h newlib-stdint.h m32r/little.h ${tm_file}" 2132 ;; 2133m32r-*-linux*) 2134 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} m32r/linux.h" 2135 tmake_file="${tmake_file} m32r/t-linux t-slibgcc" 2136 gnu_ld=yes 2137 if test x$enable_threads = xyes; then 2138 thread_file='posix' 2139 fi 2140 ;; 2141m32rle-*-linux*) 2142 tm_file="dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h m32r/little.h ${tm_file} m32r/linux.h" 2143 tmake_file="${tmake_file} m32r/t-linux t-slibgcc" 2144 gnu_ld=yes 2145 if test x$enable_threads = xyes; then 2146 thread_file='posix' 2147 fi 2148 ;; 2149m68k-*-elf* | fido-*-elf*) 2150 case ${target} in 2151 fido-*-elf*) 2152 # Check that $with_cpu makes sense. 2153 case $with_cpu in 2154 "" | "fidoa") 2155 ;; 2156 *) 2157 echo "Cannot accept --with-cpu=$with_cpu" 2158 exit 1 2159 ;; 2160 esac 2161 with_cpu=fidoa 2162 ;; 2163 *) 2164 default_m68k_cpu=68020 2165 default_cf_cpu=5206 2166 ;; 2167 esac 2168 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" 2169 tm_defines="${tm_defines} MOTOROLA=1" 2170 tmake_file="m68k/t-floatlib m68k/t-m68kbare m68k/t-m68kelf" 2171 # Add multilibs for targets other than fido. 2172 case ${target} in 2173 fido-*-elf*) 2174 ;; 2175 *) 2176 tmake_file="$tmake_file m68k/t-mlibs" 2177 ;; 2178 esac 2179 ;; 2180m68010-*-netbsdelf* | m68k-*-netbsdelf* | m5407-*-netbsdelf*) 2181 default_m68k_cpu=68020 2182 case ${target} in 2183 m5407*) 2184 with_arch=${with_arch:-cf} 2185 target_cpu_default="mcf5475" 2186# target="`echo ${target} | sed 's/m68kcf/m68k/'`" 2187 ;; 2188 m68010*) 2189 target_cpu_default="m68010" 2190 tmake_file="${tmake_file} m68k/t-m68kelf m68k/t-m68010-netbsd" 2191 default_m68k_cpu=68010 2192 tmake_file="${tmake_file} m68k/t-floatlib" 2193 ;; 2194 *) 2195 with_arch=${with_arch:-m68k} 2196 tmake_file="${tmake_file} m68k/t-floatlib" 2197 ;; 2198 esac 2199 default_cf_cpu=5475 2200 tm_file="${tm_file} dbxelf.h elfos.h ${nbsd_tm_file} m68k/netbsd-elf.h" 2201 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 2202 tm_defines="${tm_defines} MOTOROLA=1 CHAR_FAST8=1 SHORT_FAST16=1" 2203 ;; 2204m68k*-*-openbsd*) 2205 default_m68k_cpu=68020 2206 default_cf_cpu=5475 2207 # needed to unconfuse gdb 2208 tm_defines="${tm_defines} OBSD_OLD_GAS" 2209 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h m68k/openbsd.h" 2210 extra_options="${extra_options} openbsd.opt" 2211 tmake_file="t-openbsd m68k/t-openbsd" 2212 # we need collect2 until our bug is fixed... 2213 use_collect2=yes 2214 ;; 2215m68k-*-uclinux*) # Motorola m68k/ColdFire running uClinux 2216 # with uClibc, using the new GNU/Linux-style 2217 # ABI. 2218 default_m68k_cpu=68020 2219 default_cf_cpu=5206 2220 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" 2221 extra_options="${extra_options} m68k/uclinux.opt" 2222 tm_defines="${tm_defines} MOTOROLA=1" 2223 tmake_file="m68k/t-floatlib m68k/t-uclinux m68k/t-mlibs" 2224 ;; 2225m68k-*-linux*) # Motorola m68k's running GNU/Linux 2226 # with ELF format using glibc 2 2227 # aka the GNU/Linux C library 6. 2228 default_m68k_cpu=68020 2229 default_cf_cpu=5475 2230 with_arch=${with_arch:-m68k} 2231 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h m68k/linux.h ./sysroot-suffix.h" 2232 extra_options="${extra_options} m68k/ieee.opt" 2233 tm_defines="${tm_defines} MOTOROLA=1" 2234 tmake_file="${tmake_file} m68k/t-floatlib m68k/t-linux m68k/t-mlibs" 2235 ;; 2236m68k-*-rtems*) 2237 default_m68k_cpu=68020 2238 default_cf_cpu=5206 2239 tmake_file="${tmake_file} m68k/t-floatlib m68k/t-m68kbare m68k/t-crtstuff m68k/t-rtems m68k/t-mlibs" 2240 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" 2241 tm_defines="${tm_defines} MOTOROLA=1" 2242 ;; 2243mcore-*-elf) 2244 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file} mcore/mcore-elf.h" 2245 tmake_file=mcore/t-mcore 2246 inhibit_libc=true 2247 ;; 2248microblaze*-linux*) 2249 case $target in 2250 microblazeel-*) 2251 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=0" 2252 ;; 2253 microblaze-*) 2254 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=4321" 2255 ;; 2256 esac 2257 tm_file="${tm_file} dbxelf.h gnu-user.h linux.h microblaze/linux.h" 2258 tm_file="${tm_file} glibc-stdint.h" 2259 c_target_objs="${c_target_objs} microblaze-c.o" 2260 cxx_target_objs="${cxx_target_objs} microblaze-c.o" 2261 tmake_file="${tmake_file} microblaze/t-microblaze" 2262 tmake_file="${tmake_file} microblaze/t-microblaze-linux" 2263 ;; 2264microblaze*-*-rtems*) 2265 case $target in 2266 microblazeel-*) 2267 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=0" 2268 ;; 2269 microblaze-*) 2270 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=4321" 2271 ;; 2272 esac 2273 tm_file="${tm_file} dbxelf.h" 2274 tm_file="${tm_file} microblaze/rtems.h rtems.h newlib-stdint.h" 2275 c_target_objs="${c_target_objs} microblaze-c.o" 2276 cxx_target_objs="${cxx_target_objs} microblaze-c.o" 2277 tmake_file="${tmake_file} microblaze/t-microblaze" 2278 tmake_file="${tmake_file} microblaze/t-rtems" 2279 ;; 2280microblaze*-*-elf) 2281 case $target in 2282 microblazeel-*) 2283 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=0" 2284 ;; 2285 microblaze-*) 2286 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=4321" 2287 ;; 2288 esac 2289 tm_file="${tm_file} dbxelf.h newlib-stdint.h" 2290 c_target_objs="${c_target_objs} microblaze-c.o" 2291 cxx_target_objs="${cxx_target_objs} microblaze-c.o" 2292 tmake_file="${tmake_file} microblaze/t-microblaze" 2293 ;; 2294riscv*-*-linux*) 2295 tm_file="elfos.h gnu-user.h linux.h glibc-stdint.h ${tm_file} riscv/linux.h" 2296 case "x${enable_multilib}" in 2297 xno) ;; 2298 xyes) tmake_file="${tmake_file} riscv/t-linux-multilib" ;; 2299 *) echo "Unknown value for enable_multilib"; exit 1 2300 esac 2301 tmake_file="${tmake_file} riscv/t-riscv riscv/t-linux" 2302 gnu_ld=yes 2303 gas=yes 2304 # Force .init_array support. The configure script cannot always 2305 # automatically detect that GAS supports it, yet we require it. 2306 gcc_cv_initfini_array=yes 2307 ;; 2308riscv*-*-elf* | riscv*-*-rtems*) 2309 tm_file="elfos.h newlib-stdint.h ${tm_file} riscv/elf.h" 2310 case ${target} in 2311 *-*-rtems*) 2312 tm_file="${tm_file} rtems.h riscv/rtems.h" 2313 tmake_file="${tmake_file} riscv/t-rtems" 2314 ;; 2315 *) 2316 case "x${enable_multilib}" in 2317 xno) ;; 2318 xyes) tmake_file="${tmake_file} riscv/t-elf-multilib" ;; 2319 *) echo "Unknown value for enable_multilib"; exit 1 2320 esac 2321 esac 2322 tmake_file="${tmake_file} riscv/t-riscv" 2323 gnu_ld=yes 2324 gas=yes 2325 # Force .init_array support. The configure script cannot always 2326 # automatically detect that GAS supports it, yet we require it. 2327 gcc_cv_initfini_array=yes 2328 ;; 2329riscv*-*-freebsd*) 2330 tm_file="${tm_file} elfos.h ${fbsd_tm_file} riscv/freebsd.h" 2331 tmake_file="${tmake_file} riscv/t-riscv" 2332 gnu_ld=yes 2333 gas=yes 2334 # Force .init_array support. The configure script cannot always 2335 # automatically detect that GAS supports it, yet we require it. 2336 gcc_cv_initfini_array=yes 2337 ;; 2338riscv*-*-netbsd*) # NetBSD RISC-V 2339 tm_file="elfos.h ${tm_file} ${nbsd_tm_file} riscv/netbsd.h" 2340 tm_defines="${tm_defines} CHAR_FAST8=1 SHORT_FAST16=1" 2341 case ${target} in 2342 riscv32*) tm_defines="${tm_defines} TARGET_64BIT_DEFAULT=0" ;; 2343 *) tmake_file="${tmake_file} riscv/t-netbsd64" ;; 2344 esac 2345 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 2346 tmake_file="${tmake_file} riscv/t-riscv" 2347 gnu_ld=yes 2348 gas=yes 2349 gcc_cv_initfini_array=yes 2350 ;; 2351mips64*-*-netbsd*) # NetBSD/mips64, either endian. 2352 target_cpu_default="MASK_ABICALLS|MASK_FLOAT64|MASK_SOFT_FLOAT_ABI" 2353 tm_file="elfos.h ${tm_file} mips/elf.h ${nbsd_tm_file} mips/netbsd.h mips/netbsd64.h" 2354 tmake_file="${tmake_file} mips/t-netbsd64" 2355 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_N32" 2356 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 2357 ;; 2358mips*-*-netbsd*) # NetBSD/mips, either endian. 2359 target_cpu_default="MASK_ABICALLS" 2360 tm_file="elfos.h ${tm_file} mips/elf.h ${nbsd_tm_file} mips/netbsd.h" 2361 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 2362 ;; 2363mips*-img-linux*) 2364 tm_file="dbxelf.h elfos.h gnu-user.h linux.h linux-android.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/linux.h mips/linux-common.h mips/mti-linux.h" 2365 extra_options="${extra_options} linux-android.opt" 2366 tmake_file="${tmake_file} mips/t-img-linux" 2367 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=37 MIPS_ABI_DEFAULT=ABI_32" 2368 with_arch_32="mips32r6" 2369 with_arch_64="mips64r6" 2370 gnu_ld=yes 2371 gas=yes 2372 ;; 2373mips*-mti-linux*) 2374 tm_file="dbxelf.h elfos.h gnu-user.h linux.h linux-android.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/linux.h mips/linux-common.h mips/mti-linux.h" 2375 extra_options="${extra_options} linux-android.opt" 2376 tmake_file="${tmake_file} mips/t-mti-linux" 2377 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33 MIPS_ABI_DEFAULT=ABI_32" 2378 with_arch_32="mips32r2" 2379 with_arch_64="mips64r2" 2380 gnu_ld=yes 2381 gas=yes 2382 ;; 2383mips*-*-linux*) # Linux MIPS, either endian. 2384 tm_file="dbxelf.h elfos.h gnu-user.h linux.h linux-android.h glibc-stdint.h ${tm_file} mips/gnu-user.h mips/linux.h mips/linux-common.h" 2385 extra_options="${extra_options} linux-android.opt" 2386 case ${target} in 2387 mipsisa32r6*) 2388 default_mips_arch=mips32r6 2389 ;; 2390 mipsisa32r2*) 2391 default_mips_arch=mips32r2 2392 ;; 2393 mipsisa32*) 2394 default_mips_arch=mips32 2395 ;; 2396 mips64el-st-linux-gnu) 2397 default_mips_abi=n32 2398 tm_file="${tm_file} mips/st.h" 2399 tmake_file="${tmake_file} mips/t-st" 2400 enable_mips_multilibs="yes" 2401 ;; 2402 mips64octeon*-*-linux*) 2403 default_mips_abi=n32 2404 tm_defines="${tm_defines} MIPS_CPU_STRING_DEFAULT=\\\"octeon\\\"" 2405 target_cpu_default=MASK_SOFT_FLOAT_ABI 2406 enable_mips_multilibs="yes" 2407 ;; 2408 mipsisa64r6*-*-linux*) 2409 default_mips_abi=n32 2410 default_mips_arch=mips64r6 2411 enable_mips_multilibs="yes" 2412 ;; 2413 mipsisa64r2*-*-linux*) 2414 default_mips_abi=n32 2415 default_mips_arch=mips64r2 2416 enable_mips_multilibs="yes" 2417 ;; 2418 mips64*-*-linux* | mipsisa64*-*-linux*) 2419 default_mips_abi=n32 2420 enable_mips_multilibs="yes" 2421 ;; 2422 esac 2423 if test x$enable_targets = xall; then 2424 enable_mips_multilibs="yes" 2425 fi 2426 if test x$enable_mips_multilibs = xyes; then 2427 tmake_file="${tmake_file} mips/t-linux64" 2428 fi 2429 ;; 2430mips*-mti-elf*) 2431 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/n32-elf.h mips/sde.h mips/mti-elf.h" 2432 tmake_file="mips/t-mti-elf" 2433 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33 MIPS_ABI_DEFAULT=ABI_32" 2434 with_arch_32="mips32r2" 2435 with_arch_64="mips64r2" 2436 ;; 2437mips*-img-elf*) 2438 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/n32-elf.h mips/sde.h mips/mti-elf.h" 2439 tmake_file="mips/t-img-elf" 2440 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=37 MIPS_ABI_DEFAULT=ABI_32" 2441 with_arch_32="mips32r6" 2442 with_arch_64="mips64r6" 2443 ;; 2444mips*-sde-elf*) 2445 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/n32-elf.h mips/sde.h" 2446 tmake_file="mips/t-sde" 2447 extra_options="${extra_options} mips/sde.opt" 2448 case "${with_newlib}" in 2449 yes) 2450 # newlib / libgloss. 2451 ;; 2452 *) 2453 # MIPS toolkit libraries. 2454 tm_file="$tm_file mips/sdemtk.h" 2455 tmake_file="$tmake_file mips/t-sdemtk" 2456 case ${enable_threads} in 2457 "" | yes | mipssde) 2458 thread_file='mipssde' 2459 ;; 2460 esac 2461 ;; 2462 esac 2463 case ${target} in 2464 mipsisa32r6*) 2465 tm_defines="MIPS_ISA_DEFAULT=37 MIPS_ABI_DEFAULT=ABI_32" 2466 ;; 2467 mipsisa32r2*) 2468 tm_defines="MIPS_ISA_DEFAULT=33 MIPS_ABI_DEFAULT=ABI_32" 2469 ;; 2470 mipsisa32*) 2471 tm_defines="MIPS_ISA_DEFAULT=32 MIPS_ABI_DEFAULT=ABI_32" 2472 ;; 2473 mipsisa64r6*) 2474 tm_defines="MIPS_ISA_DEFAULT=69 MIPS_ABI_DEFAULT=ABI_N32" 2475 ;; 2476 mipsisa64r2*) 2477 tm_defines="MIPS_ISA_DEFAULT=65 MIPS_ABI_DEFAULT=ABI_N32" 2478 ;; 2479 mipsisa64*) 2480 tm_defines="MIPS_ISA_DEFAULT=64 MIPS_ABI_DEFAULT=ABI_N32" 2481 ;; 2482 esac 2483 ;; 2484mipsisa32-*-elf* | mipsisa32el-*-elf* | \ 2485mipsisa32r2-*-elf* | mipsisa32r2el-*-elf* | \ 2486mipsisa32r6-*-elf* | mipsisa32r6el-*-elf* | \ 2487mipsisa64-*-elf* | mipsisa64el-*-elf* | \ 2488mipsisa64r2-*-elf* | mipsisa64r2el-*-elf* | \ 2489mipsisa64r6-*-elf* | mipsisa64r6el-*-elf*) 2490 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h" 2491 tmake_file="mips/t-isa3264" 2492 case ${target} in 2493 mipsisa32r6*) 2494 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=37" 2495 ;; 2496 mipsisa32r2*) 2497 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=33" 2498 ;; 2499 mipsisa32*) 2500 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=32" 2501 ;; 2502 mipsisa64r6*) 2503 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=69" 2504 ;; 2505 mipsisa64r2*) 2506 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=65" 2507 ;; 2508 mipsisa64*) 2509 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64" 2510 ;; 2511 esac 2512 case ${target} in 2513 mipsisa32*-*-elfoabi*) 2514 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_32" 2515 tm_file="${tm_file} mips/elfoabi.h" 2516 ;; 2517 mipsisa64*-*-elfoabi*) 2518 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_O64" 2519 tm_file="${tm_file} mips/elfoabi.h" 2520 ;; 2521 *-*-elf*) 2522 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_EABI" 2523 ;; 2524 esac 2525 ;; 2526mipsisa64sr71k-*-elf*) 2527 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h" 2528 tmake_file=mips/t-sr71k 2529 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64 MIPS_CPU_STRING_DEFAULT=\\\"sr71000\\\" MIPS_ABI_DEFAULT=ABI_EABI" 2530 ;; 2531mipsisa64sb1-*-elf* | mipsisa64sb1el-*-elf*) 2532 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h" 2533 tmake_file="mips/t-elf mips/t-sb1" 2534 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=64 MIPS_CPU_STRING_DEFAULT=\\\"sb1\\\" MIPS_ABI_DEFAULT=ABI_O64" 2535 ;; 2536mips-*-elf* | mipsel-*-elf* | mipsr5900-*-elf* | mipsr5900el-*-elf*) 2537 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h" 2538 tmake_file="mips/t-elf" 2539 ;; 2540mips64r5900-*-elf* | mips64r5900el-*-elf*) 2541 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/n32-elf.h" 2542 tmake_file="mips/t-elf" 2543 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_N32" 2544 ;; 2545mips64-*-elf* | mips64el-*-elf*) 2546 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h" 2547 tmake_file="mips/t-elf" 2548 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_O64" 2549 ;; 2550mips64vr-*-elf* | mips64vrel-*-elf*) 2551 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/vr.h mips/elf.h" 2552 tmake_file=mips/t-vr 2553 tm_defines="${tm_defines} MIPS_ABI_DEFAULT=ABI_EABI" 2554 ;; 2555mips64orion-*-elf* | mips64orionel-*-elf*) 2556 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elforion.h mips/elf.h" 2557 tmake_file="mips/t-elf" 2558 tm_defines="${tm_defines} MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_O64" 2559 ;; 2560mips*-*-rtems*) 2561 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/elf.h mips/rtems.h rtems.h" 2562 tmake_file="${tmake_file} mips/t-elf mips/t-rtems" 2563 ;; 2564mips-wrs-vxworks) 2565 tm_file="elfos.h ${tm_file} mips/elf.h vx-common.h vxworks.h mips/vxworks.h" 2566 tmake_file="${tmake_file} mips/t-vxworks" 2567 ;; 2568mipstx39-*-elf* | mipstx39el-*-elf*) 2569 tm_file="elfos.h newlib-stdint.h ${tm_file} mips/r3900.h mips/elf.h" 2570 tmake_file="mips/t-r3900" 2571 ;; 2572mmix-knuth-mmixware) 2573 tm_file="${tm_file} newlib-stdint.h" 2574 use_gcc_stdint=wrap 2575 ;; 2576mn10300-*-*) 2577 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 2578 if test x$stabs = xyes 2579 then 2580 tm_file="${tm_file} dbx.h" 2581 fi 2582 use_collect2=no 2583 use_gcc_stdint=wrap 2584 ;; 2585msp430*-*-*) 2586 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 2587 c_target_objs="msp430-c.o" 2588 cxx_target_objs="msp430-c.o" 2589 tmake_file="${tmake_file} msp430/t-msp430" 2590 extra_gcc_objs="driver-msp430.o" 2591 ;; 2592nds32*-*-*) 2593 target_cpu_default="0" 2594 tm_defines="${tm_defines}" 2595 case ${target} in 2596 nds32le*-*-*) 2597 ;; 2598 nds32be-*-*) 2599 target_cpu_default="${target_cpu_default}|MASK_BIG_ENDIAN" 2600 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 2601 ;; 2602 esac 2603 case ${target} in 2604 nds32*-*-elf*) 2605 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file} nds32/elf.h nds32/nds32_intrinsic.h" 2606 tmake_file="nds32/t-nds32 nds32/t-elf" 2607 ;; 2608 nds32*-*-linux*) 2609 tm_file="dbxelf.h elfos.h ${tm_file} gnu-user.h linux.h glibc-stdint.h nds32/linux.h nds32/nds32_intrinsic.h" 2610 tmake_file="${tmake_file} nds32/t-nds32 nds32/t-linux" 2611 gcc_cv_initfini_array=yes 2612 ;; 2613 esac 2614 2615 # Handle --enable-default-relax setting. 2616 if test x${enable_default_relax} = xyes; then 2617 tm_defines="${tm_defines} TARGET_DEFAULT_RELAX=1" 2618 fi 2619 # Handle --with-ext-dsp 2620 if test x${with_ext_dsp} = xyes; then 2621 tm_defines="${tm_defines} TARGET_DEFAULT_EXT_DSP=1" 2622 fi 2623 ;; 2624nios2-*-*) 2625 tm_file="elfos.h ${tm_file}" 2626 tmake_file="${tmake_file} nios2/t-nios2" 2627 case ${target} in 2628 nios2-*-linux*) 2629 tm_file="${tm_file} gnu-user.h linux.h glibc-stdint.h nios2/linux.h " 2630 ;; 2631 nios2-*-elf*) 2632 tm_file="${tm_file} newlib-stdint.h nios2/elf.h" 2633 extra_options="${extra_options} nios2/elf.opt" 2634 ;; 2635 nios2-*-rtems*) 2636 tm_file="${tm_file} newlib-stdint.h nios2/rtems.h rtems.h" 2637 tmake_file="${tmake_file} t-rtems nios2/t-rtems" 2638 ;; 2639 esac 2640 ;; 2641nvptx-*) 2642 tm_file="${tm_file} newlib-stdint.h" 2643 use_gcc_stdint=wrap 2644 tmake_file="nvptx/t-nvptx" 2645 if test x$enable_as_accelerator = xyes; then 2646 extra_programs="${extra_programs} mkoffload\$(exeext)" 2647 tm_file="${tm_file} nvptx/offload.h" 2648 fi 2649 ;; 2650or1k*-*-*) 2651 tm_file="elfos.h ${tm_file}" 2652 tmake_file="${tmake_file} or1k/t-or1k" 2653 # Force .init_array support. The configure script cannot always 2654 # automatically detect that GAS supports it, yet we require it. 2655 gcc_cv_initfini_array=yes 2656 2657 # Handle --with-multilib-list=... 2658 or1k_multilibs="${with_multilib_list}" 2659 if test "$or1k_multilibs" = "default"; then 2660 or1k_multilibs="mcmov,msoft-mul,msoft-div" 2661 fi 2662 or1k_multilibs=`echo $or1k_multilibs | sed -e 's/,/ /g'` 2663 for or1k_multilib in ${or1k_multilibs}; do 2664 case ${or1k_multilib} in 2665 mcmov | msext | msfimm | \ 2666 mhard-div | mhard-mul | \ 2667 msoft-div | msoft-mul ) 2668 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG},${or1k_multilib}" 2669 ;; 2670 *) 2671 echo "--with-multilib-list=${with_multilib_list} not supported." 2672 exit 1 2673 esac 2674 done 2675 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's/^,//'` 2676 2677 case ${target} in 2678 or1k*-*-linux*) 2679 tm_file="${tm_file} gnu-user.h linux.h glibc-stdint.h" 2680 tm_file="${tm_file} or1k/linux.h" 2681 ;; 2682 or1k*-*-elf*) 2683 tm_file="${tm_file} newlib-stdint.h or1k/elf.h" 2684 extra_options="${extra_options} or1k/elf.opt" 2685 ;; 2686 or1k*-*-rtems*) 2687 tm_file="${tm_file} newlib-stdint.h or1k/rtems.h rtems.h" 2688 tmake_file="${tmake_file} or1k/t-rtems" 2689 ;; 2690 esac 2691 ;; 2692pdp11-*-*) 2693 tm_file="${tm_file} newlib-stdint.h" 2694 use_gcc_stdint=wrap 2695 ;; 2696# port not yet contributed 2697#powerpc-*-openbsd*) 2698# tmake_file="${tmake_file} rs6000/t-fprules" 2699# extra_headers= 2700# ;; 2701powerpc-*-darwin*) 2702 extra_options="${extra_options} ${cpu_type}/darwin.opt" 2703 case ${target} in 2704 *-darwin1[0-9]* | *-darwin9*) 2705 tmake_file="${tmake_file} ${cpu_type}/t-darwin32-biarch" 2706 tm_file="${tm_file} ${cpu_type}/darwin32-biarch.h" 2707 ;; 2708 *-darwin8*) 2709 tmake_file="${tmake_file} ${cpu_type}/t-darwin32-biarch" 2710 tm_file="${tm_file} ${cpu_type}/darwin32-biarch.h" 2711 tm_file="${tm_file} ${cpu_type}/darwin8.h" 2712 ;; 2713 *-darwin7*) 2714 tm_file="${tm_file} ${cpu_type}/darwin7.h" 2715 ;; 2716 *-darwin[456]*) 2717 # Earlier - ingle arch, with 32b only 2718 # OS X 10.0, the first edition is Darwin4 2719 ;; 2720 esac 2721 tmake_file="${tmake_file} t-slibgcc" 2722 ;; 2723powerpc64-*-darwin*) 2724 extra_options="${extra_options} ${cpu_type}/darwin.opt" 2725 tmake_file="${tmake_file} ${cpu_type}/t-darwin64-biarch t-slibgcc" 2726 tm_file="${tm_file} ${cpu_type}/darwin64-biarch.h" 2727 ;; 2728powerpc*-*-freebsd*) 2729 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h ${fbsd_tm_file} rs6000/sysv4.h" 2730 extra_options="${extra_options} rs6000/sysv4.opt" 2731 tmake_file="rs6000/t-fprules rs6000/t-ppcos ${tmake_file} rs6000/t-ppccomm" 2732 case ${target} in 2733 powerpc64*) 2734 tm_file="${tm_file} rs6000/default64.h rs6000/freebsd64.h" 2735 tmake_file="${tmake_file} rs6000/t-freebsd64" 2736 extra_options="${extra_options} rs6000/linux64.opt" 2737 ;; 2738 *) 2739 tm_file="${tm_file} rs6000/freebsd.h" 2740 ;; 2741 esac 2742 ;; 2743powerpc*-*-netbsd*) 2744 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h ${nbsd_tm_file} freebsd-spec.h" 2745 case ${target} in 2746 powerpc64*) 2747 tm_file="rs6000/biarch64.h ${tm_file}" 2748 tm_file="${tm_file} rs6000/sysv4.h rs6000/default64.h rs6000/netbsd64.h" 2749 tmake_file="${tmake_file} rs6000/t-netbsd64" 2750 ;; 2751 *) 2752 tm_file="${tm_file} rs6000/sysv4.h rs6000/netbsd.h" 2753 tmake_file="${tmake_file} rs6000/t-netbsd" 2754 ;; 2755 esac 2756 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 2757 extra_options="${extra_options} rs6000/sysv4.opt rs6000/linux64.opt" 2758 if test x${enable_secureplt} != xno; then 2759 tm_file="rs6000/secureplt.h ${tm_file}" 2760 fi 2761 ;; 2762powerpc-*-eabisimaltivec*) 2763 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/eabisim.h rs6000/eabialtivec.h" 2764 extra_options="${extra_options} rs6000/sysv4.opt" 2765 tmake_file="rs6000/t-fprules rs6000/t-ppcendian rs6000/t-ppccomm" 2766 use_gcc_stdint=wrap 2767 ;; 2768powerpc-*-eabisim*) 2769 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/eabisim.h" 2770 extra_options="${extra_options} rs6000/sysv4.opt" 2771 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm" 2772 use_gcc_stdint=wrap 2773 ;; 2774powerpc-*-elf*) 2775 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h" 2776 extra_options="${extra_options} rs6000/sysv4.opt" 2777 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm" 2778 ;; 2779powerpc-*-eabialtivec*) 2780 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/eabialtivec.h" 2781 extra_options="${extra_options} rs6000/sysv4.opt" 2782 tmake_file="rs6000/t-fprules rs6000/t-ppcendian rs6000/t-ppccomm" 2783 use_gcc_stdint=wrap 2784 ;; 2785powerpc-*-eabi*) 2786 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h" 2787 extra_options="${extra_options} rs6000/sysv4.opt" 2788 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm" 2789 use_gcc_stdint=wrap 2790 ;; 2791powerpc-*-rtems*) 2792 tm_file="rs6000/biarch64.h ${tm_file} dbxelf.h elfos.h gnu-user.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/rtems.h rtems.h" 2793 extra_options="${extra_options} rs6000/sysv4.opt rs6000/linux64.opt" 2794 tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-rtems rs6000/t-ppccomm" 2795 ;; 2796powerpc*-*-linux*) 2797 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h freebsd-spec.h rs6000/sysv4.h" 2798 extra_options="${extra_options} rs6000/sysv4.opt" 2799 tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-ppccomm" 2800 extra_objs="$extra_objs rs6000-linux.o" 2801 case ${target} in 2802 powerpc*le-*-*) 2803 tm_file="${tm_file} rs6000/sysv4le.h" ;; 2804 esac 2805 case ${target}:${with_cpu} in 2806 powerpc64*: | powerpc64*:native) cpu_is_64bit=yes ;; 2807 esac 2808 maybe_biarch=${cpu_is_64bit} 2809 case ${enable_targets} in 2810 *powerpc64*) maybe_biarch=yes ;; 2811 all) maybe_biarch=yes ;; 2812 esac 2813 case ${target}:${enable_targets}:${maybe_biarch} in 2814 powerpc64-* | powerpc-*:*:yes | *:*powerpc64-*:yes | *:all:yes \ 2815 | powerpc64le*:*powerpcle* | powerpc64le*:*powerpc-* \ 2816 | powerpcle-*:*powerpc64le*:yes) 2817 if test x$cpu_is_64bit = xyes; then 2818 tm_file="${tm_file} rs6000/default64.h" 2819 fi 2820 tm_file="rs6000/biarch64.h ${tm_file} rs6000/linux64.h glibc-stdint.h" 2821 tmake_file="$tmake_file rs6000/t-linux64" 2822 case ${target} in 2823 powerpc*le-*-*) 2824 tmake_file="$tmake_file rs6000/t-linux64le" 2825 case ${enable_targets} in 2826 all | *powerpc64-* | *powerpc-*) 2827 tmake_file="$tmake_file rs6000/t-linux64lebe" ;; 2828 esac ;; 2829 *) 2830 case ${enable_targets} in 2831 all | *powerpc64le-* | *powerpcle-*) 2832 tmake_file="$tmake_file rs6000/t-linux64bele" ;; 2833 esac ;; 2834 esac 2835 extra_options="${extra_options} rs6000/linux64.opt" 2836 ;; 2837 powerpc64*) 2838 tm_file="${tm_file} rs6000/default64.h rs6000/linux64.h glibc-stdint.h" 2839 extra_options="${extra_options} rs6000/linux64.opt" 2840 tmake_file="${tmake_file} rs6000/t-linux" 2841 ;; 2842 *) 2843 tm_file="${tm_file} rs6000/linux.h glibc-stdint.h" 2844 tmake_file="${tmake_file} rs6000/t-ppcos rs6000/t-linux" 2845 ;; 2846 esac 2847 case ${target} in 2848 powerpc*-*-linux*ppc476*) 2849 tm_file="${tm_file} rs6000/476.h" 2850 extra_options="${extra_options} rs6000/476.opt" ;; 2851 powerpc*-*-linux*altivec*) 2852 tm_file="${tm_file} rs6000/linuxaltivec.h" ;; 2853 esac 2854 case ${target} in 2855 *-linux*-musl*) 2856 enable_secureplt=yes ;; 2857 esac 2858 if test x${enable_secureplt} = xyes; then 2859 tm_file="rs6000/secureplt.h ${tm_file}" 2860 fi 2861 ;; 2862powerpc-wrs-vxworks*) 2863 tm_file="${tm_file} elfos.h gnu-user.h freebsd-spec.h rs6000/sysv4.h" 2864 tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-ppccomm rs6000/t-vxworks" 2865 extra_options="${extra_options} rs6000/sysv4.opt" 2866 extra_headers=ppc-asm.h 2867 case ${target} in 2868 *-vxworksmils*) 2869 tm_file="${tm_file} vx-common.h vxworksae.h rs6000/vxworks.h rs6000/vxworksmils.h" 2870 tmake_file="${tmake_file} rs6000/t-vxworksmils" 2871 ;; 2872 *-vxworksae*) 2873 tm_file="${tm_file} vx-common.h vxworksae.h rs6000/vxworks.h rs6000/vxworksae.h" 2874 tmake_file="${tmake_file} rs6000/t-vxworksae" 2875 ;; 2876 *-vxworks*) 2877 tm_file="${tm_file} vx-common.h vxworks.h rs6000/vxworks.h" 2878 ;; 2879 esac 2880 ;; 2881powerpc-*-lynxos*) 2882 xm_defines=POSIX 2883 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h rs6000/sysv4.h rs6000/lynx.h lynx.h" 2884 tmake_file="t-lynx rs6000/t-lynx" 2885 extra_options="${extra_options} rs6000/sysv4.opt lynx.opt" 2886 thread_file=lynx 2887 gnu_ld=yes 2888 gas=yes 2889 ;; 2890powerpcle-*-elf*) 2891 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/sysv4le.h" 2892 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm" 2893 extra_options="${extra_options} rs6000/sysv4.opt" 2894 ;; 2895powerpcle-*-eabisim*) 2896 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h rs6000/eabisim.h" 2897 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm" 2898 extra_options="${extra_options} rs6000/sysv4.opt" 2899 use_gcc_stdint=wrap 2900 ;; 2901powerpcle-*-eabi*) 2902 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h usegas.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/sysv4le.h rs6000/eabi.h" 2903 tmake_file="rs6000/t-fprules rs6000/t-ppcgas rs6000/t-ppccomm" 2904 extra_options="${extra_options} rs6000/sysv4.opt" 2905 use_gcc_stdint=wrap 2906 ;; 2907rs6000-ibm-aix6.* | powerpc-ibm-aix6.*) 2908 tm_file="${tm_file} rs6000/aix.h rs6000/aix61.h rs6000/xcoff.h rs6000/aix-stdint.h" 2909 tmake_file="rs6000/t-aix52 t-slibgcc" 2910 extra_options="${extra_options} rs6000/aix64.opt" 2911 use_collect2=yes 2912 thread_file='aix' 2913 use_gcc_stdint=wrap 2914 default_use_cxa_atexit=yes 2915 ;; 2916rs6000-ibm-aix7.1.* | powerpc-ibm-aix7.1.*) 2917 tm_file="${tm_file} rs6000/aix.h rs6000/aix71.h rs6000/xcoff.h rs6000/aix-stdint.h" 2918 tmake_file="rs6000/t-aix52 t-slibgcc" 2919 extra_options="${extra_options} rs6000/aix64.opt" 2920 use_collect2=yes 2921 thread_file='aix' 2922 use_gcc_stdint=wrap 2923 default_use_cxa_atexit=yes 2924 ;; 2925rs6000-ibm-aix[789].* | powerpc-ibm-aix[789].*) 2926 tm_file="${tm_file} rs6000/aix.h rs6000/aix72.h rs6000/xcoff.h rs6000/aix-stdint.h" 2927 tmake_file="rs6000/t-aix52 t-slibgcc" 2928 extra_options="${extra_options} rs6000/aix64.opt" 2929 use_collect2=yes 2930 thread_file='aix' 2931 use_gcc_stdint=wrap 2932 default_use_cxa_atexit=yes 2933 ;; 2934rl78-*-elf*) 2935 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 2936 target_has_targetm_common=no 2937 c_target_objs="rl78-c.o" 2938 cxx_target_objs="rl78-c.o" 2939 tmake_file="${tmake_file} rl78/t-rl78" 2940 ;; 2941rx-*-elf*) 2942 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 2943 tmake_file="${tmake_file} rx/t-rx" 2944 ;; 2945s390-*-linux*) 2946 tm_file="s390/s390.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h s390/linux.h" 2947 c_target_objs="${c_target_objs} s390-c.o" 2948 cxx_target_objs="${cxx_target_objs} s390-c.o" 2949 if test x$enable_targets = xall; then 2950 tmake_file="${tmake_file} s390/t-linux64" 2951 fi 2952 tmake_file="${tmake_file} s390/t-s390" 2953 ;; 2954s390x-*-linux*) 2955 tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h s390/linux.h" 2956 tm_p_file="linux-protos.h s390/s390-protos.h" 2957 c_target_objs="${c_target_objs} s390-c.o" 2958 cxx_target_objs="${cxx_target_objs} s390-c.o" 2959 md_file=s390/s390.md 2960 extra_modes=s390/s390-modes.def 2961 out_file=s390/s390.c 2962 tmake_file="${tmake_file} s390/t-linux64 s390/t-s390" 2963 ;; 2964s390x-ibm-tpf*) 2965 tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h s390/tpf.h" 2966 tm_p_file=s390/s390-protos.h 2967 c_target_objs="${c_target_objs} s390-c.o" 2968 cxx_target_objs="${cxx_target_objs} s390-c.o" 2969 md_file=s390/s390.md 2970 extra_modes=s390/s390-modes.def 2971 out_file=s390/s390.c 2972 thread_file='tpf' 2973 extra_options="${extra_options} s390/tpf.opt" 2974 tmake_file="${tmake_file} s390/t-s390" 2975 ;; 2976sh-*-elf* | sh[12346l]*-*-elf* | \ 2977 sh-*-linux* | sh[2346lbe]*-*-linux* | \ 2978 sh-*-netbsdelf* | shl*-*-netbsdelf*) 2979 tmake_file="${tmake_file} sh/t-sh sh/t-elf" 2980 if test x${with_endian} = x; then 2981 case ${target} in 2982 sh[1234]*be-*-* | sh[1234]*eb-*-*) with_endian=big ;; 2983 shbe-*-* | sheb-*-*) with_endian=big,little ;; 2984 sh[1234]l* | sh[34]*-*-linux*) with_endian=little ;; 2985 shl* | sh*-*-linux* | \ 2986 sh-superh-elf) with_endian=little,big ;; 2987 sh[1234]*-*-*) with_endian=big ;; 2988 *) with_endian=big,little ;; 2989 esac 2990 fi 2991 # TM_ENDIAN_CONFIG is used by t-sh to determine multilibs. 2992 # First word : the default endian. 2993 # Second word: the secondary endian (optional). 2994 case ${with_endian} in 2995 big) TM_ENDIAN_CONFIG=mb ;; 2996 little) TM_ENDIAN_CONFIG=ml ;; 2997 big,little) TM_ENDIAN_CONFIG="mb ml" ;; 2998 little,big) TM_ENDIAN_CONFIG="ml mb" ;; 2999 *) echo "with_endian=${with_endian} not supported."; exit 1 ;; 3000 esac 3001 case ${with_endian} in 3002 little*) tm_file="sh/little.h ${tm_file}" ;; 3003 esac 3004 tm_file="${tm_file} dbxelf.h elfos.h sh/elf.h" 3005 case ${target} in 3006 sh*-*-linux*) tmake_file="${tmake_file} sh/t-linux" 3007 if test x$enable_fdpic = xyes; then 3008 tm_defines="$tm_defines FDPIC_DEFAULT=1" 3009 fi 3010 tm_file="${tm_file} gnu-user.h linux.h glibc-stdint.h sh/linux.h" ;; 3011 sh*-*-netbsd*) 3012 tm_file="${tm_file} ${nbsd_tm_file} sh/netbsd-elf.h" 3013 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 3014 3015 ;; 3016 sh*-superh-elf) if test x$with_libgloss != xno; then 3017 with_libgloss=yes 3018 tm_file="${tm_file} sh/newlib.h" 3019 fi 3020 tm_file="${tm_file} sh/embed-elf.h" 3021 tm_file="${tm_file} sh/superh.h" 3022 extra_options="${extra_options} sh/superh.opt" ;; 3023 *) if test x$with_newlib = xyes \ 3024 && test x$with_libgloss = xyes; then 3025 tm_file="${tm_file} sh/newlib.h" 3026 fi 3027 tm_file="${tm_file} sh/embed-elf.h" ;; 3028 esac 3029 case ${target} in 3030 *-*-netbsd) 3031 ;; 3032 *-*-elf*) 3033 tm_file="${tm_file} newlib-stdint.h" 3034 ;; 3035 esac 3036 # sed el/eb endian suffixes away to avoid confusion with sh[23]e 3037 case `echo ${target} | sed 's/e[lb]-/-/'` in 3038 sh4a_single_only*) sh_cpu_target=sh4a-single-only ;; 3039 sh4a_single*) sh_cpu_target=sh4a-single ;; 3040 sh4a_nofpu*) sh_cpu_target=sh4a-nofpu ;; 3041 sh4al) sh_cpu_target=sh4al ;; 3042 sh4a*) sh_cpu_target=sh4a ;; 3043 sh4_single_only*) sh_cpu_target=sh4-single-only ;; 3044 sh4_single*) sh_cpu_target=sh4-single ;; 3045 sh4_nofpu*) sh_cpu_target=sh4-nofpu ;; 3046 sh4* | sh-superh-*) sh_cpu_target=sh4 ;; 3047 sh3e*) sh_cpu_target=sh3e ;; 3048 sh*-*-netbsd* | sh3*) sh_cpu_target=sh3 ;; 3049 sh2a_single_only*) sh_cpu_target=sh2a-single-only ;; 3050 sh2a_single*) sh_cpu_target=sh2a-single ;; 3051 sh2a_nofpu*) sh_cpu_target=sh2a-nofpu ;; 3052 sh2a*) sh_cpu_target=sh2a ;; 3053 sh2e*) sh_cpu_target=sh2e ;; 3054 sh2*) sh_cpu_target=sh2 ;; 3055 *) sh_cpu_target=sh1 ;; 3056 esac 3057 # did the user say --without-fp ? 3058 if test x$with_fp = xno; then 3059 case ${sh_cpu_target} in 3060 sh4al | sh1) ;; 3061 sh4a* ) sh_cpu_target=sh4a-nofpu ;; 3062 sh4*) sh_cpu_target=sh4-nofpu ;; 3063 sh3*) sh_cpu_target=sh3 ;; 3064 sh2a*) sh_cpu_target=sh2a-nofpu ;; 3065 sh2*) sh_cpu_target=sh2 ;; 3066 *) echo --without-fp not available for $target: ignored 3067 esac 3068 tm_defines="$tm_defines STRICT_NOFPU=1" 3069 fi 3070 sh_cpu_default="`echo $with_cpu|sed s/^m/sh/|tr A-Z_ a-z-`" 3071 case $sh_cpu_default in 3072 sh2a-single-only | sh2a-single | sh2a-nofpu | sh2a | \ 3073 sh4a-single-only | sh4a-single | sh4a-nofpu | sh4a | sh4al | \ 3074 sh4-single-only | sh4-single | sh4-nofpu | sh4 | sh4-300 | \ 3075 sh3e | sh3 | sh2e | sh2 | sh1) ;; 3076 "") sh_cpu_default=${sh_cpu_target} ;; 3077 *) echo "with_cpu=$with_cpu not supported"; exit 1 ;; 3078 esac 3079 sh_multilibs=${with_multilib_list} 3080 if test "$sh_multilibs" = "default" ; then 3081 case ${target} in 3082 sh[1234]*) sh_multilibs=${sh_cpu_target} ;; 3083 sh-superh-*) sh_multilibs=m4,m4-single,m4-single-only,m4-nofpu ;; 3084 sh*-*-linux*) sh_multilibs=m1,m2,m2a,m3e,m4 ;; 3085 sh*-*-netbsd*) sh_multilibs=m3,m3e,m4 ;; 3086 *) sh_multilibs=m1,m2,m2e,m4,m4-single,m4-single-only,m2a,m2a-single ;; 3087 esac 3088 if test x$with_fp = xno; then 3089 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`" 3090 fi 3091 fi 3092 target_cpu_default=SELECT_`echo ${sh_cpu_default}|tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_` 3093 tm_defines=${tm_defines}' SH_MULTILIB_CPU_DEFAULT=\"'`echo $sh_cpu_default|sed s/sh/m/`'\"' 3094 tm_defines="$tm_defines SUPPORT_`echo $sh_cpu_default | sed 's/^m/sh/' | tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`=1" 3095 sh_multilibs=`echo $sh_multilibs | sed -e 's/,/ /g' -e 's/^[Ss][Hh]/m/' -e 's/ [Ss][Hh]/ m/g' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ_ abcdefghijklmnopqrstuvwxyz-` 3096 for sh_multilib in ${sh_multilibs}; do 3097 case ${sh_multilib} in 3098 m1 | m2 | m2e | m3 | m3e | \ 3099 m4 | m4-single | m4-single-only | m4-nofpu | m4-300 |\ 3100 m4a | m4a-single | m4a-single-only | m4a-nofpu | m4al | \ 3101 m2a | m2a-single | m2a-single-only | m2a-nofpu) 3102 # TM_MULTILIB_CONFIG is used by t-sh for the non-endian multilib definition 3103 # It is passed to MULTIILIB_OPTIONS verbatim. 3104 TM_MULTILIB_CONFIG="${TM_MULTILIB_CONFIG}/${sh_multilib}" 3105 tm_defines="$tm_defines SUPPORT_`echo $sh_multilib | sed 's/^m/sh/' | tr abcdefghijklmnopqrstuvwxyz- ABCDEFGHIJKLMNOPQRSTUVWXYZ_`=1" 3106 ;; 3107 \!*) # TM_MULTILIB_EXCEPTIONS_CONFIG is used by t-sh 3108 # It is passed the MULTILIB_EXCEPTIONS verbatim. 3109 TM_MULTILIB_EXCEPTIONS_CONFIG="${TM_MULTILIB_EXCEPTIONS_CONFIG} `echo $sh_multilib | sed 's/^!//'`" ;; 3110 *) 3111 echo "with_multilib_list=${sh_multilib} not supported." 3112 exit 1 3113 ;; 3114 esac 3115 done 3116 TM_MULTILIB_CONFIG=`echo $TM_MULTILIB_CONFIG | sed 's:^/::'` 3117 if test x${enable_incomplete_targets} = xyes ; then 3118 tm_defines="$tm_defines SUPPORT_SH1=1 SUPPORT_SH2E=1 SUPPORT_SH4=1 SUPPORT_SH4_SINGLE=1 SUPPORT_SH2A=1 SUPPORT_SH2A_SINGLE=1" 3119 fi 3120 tm_file="$tm_file ./sysroot-suffix.h" 3121 tmake_file="$tmake_file t-sysroot-suffix" 3122 ;; 3123sh-*-rtems*) 3124 tmake_file="${tmake_file} sh/t-sh sh/t-rtems" 3125 tm_file="${tm_file} dbxelf.h elfos.h sh/elf.h sh/embed-elf.h sh/rtemself.h rtems.h newlib-stdint.h" 3126 ;; 3127sh-wrs-vxworks) 3128 tmake_file="$tmake_file sh/t-sh sh/t-vxworks" 3129 tm_file="${tm_file} elfos.h sh/elf.h sh/embed-elf.h vx-common.h vxworks.h sh/vxworks.h" 3130 ;; 3131sparc-*-elf*) 3132 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h sparc/sysv4.h sparc/sp-elf.h" 3133 case ${target} in 3134 *-leon-*) 3135 tmake_file="sparc/t-sparc sparc/t-leon" 3136 ;; 3137 *-leon[3-9]*) 3138 tmake_file="sparc/t-sparc sparc/t-leon3" 3139 ;; 3140 *) 3141 tmake_file="sparc/t-sparc sparc/t-elf" 3142 ;; 3143 esac 3144 ;; 3145sparc-*-rtems*) 3146 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/sp-elf.h sparc/rtemself.h rtems.h newlib-stdint.h" 3147 tmake_file="${tmake_file} sparc/t-sparc sparc/t-rtems" 3148 ;; 3149sparc-*-linux*) 3150 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h gnu-user.h linux.h glibc-stdint.h sparc/tso.h" 3151 extra_options="${extra_options} sparc/long-double-switch.opt" 3152 case ${target} in 3153 *-leon-*) 3154 tmake_file="${tmake_file} sparc/t-sparc sparc/t-leon" 3155 ;; 3156 *-leon[3-9]*) 3157 tmake_file="${tmake_file} sparc/t-sparc sparc/t-leon3" 3158 ;; 3159 *) 3160 tmake_file="${tmake_file} sparc/t-sparc" 3161 ;; 3162 esac 3163 if test x$enable_targets = xall; then 3164 tm_file="sparc/biarch64.h ${tm_file} sparc/linux64.h" 3165 tmake_file="${tmake_file} sparc/t-linux64" 3166 else 3167 tm_file="${tm_file} sparc/linux.h" 3168 tmake_file="${tmake_file} sparc/t-linux" 3169 fi 3170 ;; 3171sparc-*-netbsdelf*) 3172 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h ${nbsd_tm_file} sparc/netbsd-elf.h" 3173 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 3174 extra_options="${extra_options} sparc/long-double-switch.opt" 3175 tmake_file="${tmake_file} sparc/t-sparc" 3176 ;; 3177sparc*-*-solaris2*) 3178 tm_file="sparc/biarch64.h ${tm_file} ${sol2_tm_file} sparc/tso.h" 3179 case ${target} in 3180 sparc64-*-* | sparcv9-*-*) 3181 tm_file="sparc/default64.h ${tm_file}" 3182 ;; 3183 *) 3184 test x$with_cpu != x || with_cpu=v9 3185 ;; 3186 esac 3187 tmake_file="${tmake_file} sparc/t-sparc sparc/t-sol2" 3188 ;; 3189sparc-wrs-vxworks) 3190 tm_file="${tm_file} elfos.h sparc/sysv4.h vx-common.h vxworks.h sparc/vxworks.h" 3191 tmake_file="${tmake_file} sparc/t-sparc sparc/t-vxworks" 3192 ;; 3193sparc64-*-elf*) 3194 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h sparc/sysv4.h sparc/sp64-elf.h" 3195 extra_options="${extra_options}" 3196 tmake_file="${tmake_file} sparc/t-sparc" 3197 ;; 3198sparc64-*-rtems*) 3199 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h sparc/sysv4.h sparc/sp64-elf.h sparc/rtemself.h rtems.h" 3200 extra_options="${extra_options}" 3201 tmake_file="${tmake_file} sparc/t-sparc sparc/t-rtems-64" 3202 ;; 3203sparc64-*-linux*) 3204 tm_file="sparc/biarch64.h ${tm_file} dbxelf.h elfos.h sparc/sysv4.h gnu-user.h linux.h glibc-stdint.h sparc/default64.h sparc/linux64.h sparc/tso.h" 3205 extra_options="${extra_options} sparc/long-double-switch.opt" 3206 tmake_file="${tmake_file} sparc/t-sparc sparc/t-linux64" 3207 ;; 3208sparc64-*-freebsd*|ultrasparc-*-freebsd*) 3209 tm_file="${tm_file} ${fbsd_tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/freebsd.h" 3210 extra_options="${extra_options} sparc/long-double-switch.opt" 3211 case "x$with_cpu" in 3212 xultrasparc) ;; 3213 x) with_cpu=ultrasparc ;; 3214 *) echo "$with_cpu not supported for freebsd target"; exit 1 ;; 3215 esac 3216 tmake_file="${tmake_file} sparc/t-sparc" 3217 ;; 3218sparc64-*-netbsd*) 3219 tm_file="sparc/biarch64.h ${tm_file}" 3220 tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h ${nbsd_tm_file} sparc/netbsd-elf.h" 3221 tm_file="${tm_file} sparc/default64.h" 3222 extra_options="${extra_options} netbsd.opt netbsd-elf.opt" 3223 extra_options="${extra_options} sparc/long-double-switch.opt" 3224 tmake_file="${tmake_file} sparc/t-sparc sparc/t-netbsd64" 3225 with_cpu=ultrasparc 3226 ;; 3227sparc64-*-openbsd*) 3228 tm_file="sparc/openbsd1-64.h ${tm_file} dbxelf.h elfos.h sparc/sysv4.h sparc/sp64-elf.h" 3229 tm_file="${tm_file} openbsd.h openbsd-stdint.h openbsd-libpthread.h sparc/openbsd64.h" 3230 extra_options="${extra_options} openbsd.opt" 3231 extra_options="${extra_options}" 3232 gas=yes gnu_ld=yes 3233 with_cpu=ultrasparc 3234 tmake_file="${tmake_file} sparc/t-sparc" 3235 ;; 3236spu-*-elf*) 3237 tm_file="dbxelf.h elfos.h spu/spu-elf.h spu/spu.h newlib-stdint.h" 3238 tmake_file="spu/t-spu-elf" 3239 native_system_header_dir=/include 3240 extra_headers="spu_intrinsics.h spu_internals.h vmx2spu.h spu_mfcio.h vec_types.h spu_cache.h" 3241 extra_modes=spu/spu-modes.def 3242 c_target_objs="${c_target_objs} spu-c.o" 3243 cxx_target_objs="${cxx_target_objs} spu-c.o" 3244 ;; 3245tic6x-*-elf) 3246 tm_file="elfos.h ${tm_file} c6x/elf-common.h c6x/elf.h" 3247 tm_file="${tm_file} dbxelf.h tm-dwarf2.h newlib-stdint.h" 3248 tmake_file="c6x/t-c6x c6x/t-c6x-elf" 3249 use_collect2=no 3250 ;; 3251tic6x-*-uclinux) 3252 tm_file="elfos.h ${tm_file} gnu-user.h linux.h c6x/elf-common.h c6x/uclinux-elf.h" 3253 tm_file="${tm_file} dbxelf.h tm-dwarf2.h glibc-stdint.h" 3254 tm_file="${tm_file} ./sysroot-suffix.h" 3255 tmake_file="t-sysroot-suffix t-slibgcc" 3256 tmake_file="${tmake_file} c6x/t-c6x c6x/t-c6x-elf c6x/t-c6x-uclinux" 3257 use_collect2=no 3258 ;; 3259tilegx*-*-linux*) 3260 tm_file="elfos.h gnu-user.h linux.h glibc-stdint.h tilegx/linux.h ${tm_file}" 3261 tmake_file="${tmake_file} tilegx/t-tilegx" 3262 extra_objs="${extra_objs} mul-tables.o" 3263 c_target_objs="${c_target_objs} tilegx-c.o" 3264 cxx_target_objs="${cxx_target_objs} tilegx-c.o" 3265 extra_headers="feedback.h" 3266 case $target in 3267 tilegxbe-*) 3268 tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" 3269 ;; 3270 esac 3271 ;; 3272tilepro*-*-linux*) 3273 tm_file="elfos.h gnu-user.h linux.h glibc-stdint.h tilepro/linux.h ${tm_file}" 3274 tmake_file="${tmake_file} tilepro/t-tilepro" 3275 extra_objs="${extra_objs} mul-tables.o" 3276 c_target_objs="${c_target_objs} tilepro-c.o" 3277 cxx_target_objs="${cxx_target_objs} tilepro-c.o" 3278 extra_headers="feedback.h" 3279 ;; 3280v850-*-rtems*) 3281 target_cpu_default="TARGET_CPU_generic" 3282 tm_file="dbxelf.h elfos.h v850/v850.h" 3283 tm_file="${tm_file} rtems.h v850/rtems.h newlib-stdint.h" 3284 tmake_file="${tmake_file} v850/t-v850" 3285 tmake_file="${tmake_file} v850/t-rtems" 3286 use_collect2=no 3287 c_target_objs="v850-c.o" 3288 cxx_target_objs="v850-c.o" 3289 ;; 3290v850*-*-*) 3291 case ${target} in 3292 v850e3v5-*-*) 3293 target_cpu_default="TARGET_CPU_v850e3v5" 3294 ;; 3295 v850e2v3-*-*) 3296 target_cpu_default="TARGET_CPU_v850e2v3" 3297 ;; 3298 v850e2-*-*) 3299 target_cpu_default="TARGET_CPU_v850e2" 3300 ;; 3301 v850e1-*-* | v850es-*-*) 3302 target_cpu_default="TARGET_CPU_v850e1" 3303 ;; 3304 v850e-*-*) 3305 target_cpu_default="TARGET_CPU_v850e" 3306 ;; 3307 v850-*-*) 3308 target_cpu_default="TARGET_CPU_generic" 3309 ;; 3310 esac 3311 tm_file="dbxelf.h elfos.h newlib-stdint.h v850/v850.h" 3312 if test x$stabs = xyes 3313 then 3314 tm_file="${tm_file} dbx.h" 3315 fi 3316 use_collect2=no 3317 c_target_objs="v850-c.o" 3318 cxx_target_objs="v850-c.o" 3319 use_gcc_stdint=wrap 3320 ;; 3321vax-*-linux*) 3322 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h vax/elf.h vax/linux.h" 3323 extra_options="${extra_options} vax/elf.opt" 3324 ;; 3325vax-*-netbsdelf*) 3326 tm_file="${tm_file} elfos.h ${nbsd_tm_file} vax/elf.h vax/netbsd-elf.h" 3327 extra_options="${extra_options} netbsd.opt netbsd-elf.opt vax/elf.opt" 3328 tm_defines="${tm_defines} CHAR_FAST8=1 SHORT_FAST16=1" 3329 ;; 3330vax-*-openbsd*) 3331 tm_file="vax/vax.h vax/openbsd1.h openbsd.h openbsd-stdint.h openbsd-libpthread.h vax/openbsd.h" 3332 extra_options="${extra_options} openbsd.opt" 3333 use_collect2=yes 3334 ;; 3335visium-*-elf*) 3336 tm_file="dbxelf.h elfos.h ${tm_file} visium/elf.h newlib-stdint.h" 3337 tmake_file="visium/t-visium visium/t-crtstuff" 3338 ;; 3339xstormy16-*-elf) 3340 # For historical reasons, the target files omit the 'x'. 3341 tm_file="dbxelf.h elfos.h newlib-stdint.h stormy16/stormy16.h" 3342 tm_p_file=stormy16/stormy16-protos.h 3343 tm_d_file="elfos.h stormy16/stormy16.h" 3344 md_file=stormy16/stormy16.md 3345 out_file=stormy16/stormy16.c 3346 extra_options=stormy16/stormy16.opt 3347 tmake_file="stormy16/t-stormy16" 3348 ;; 3349xtensa*-*-elf*) 3350 tm_file="${tm_file} dbxelf.h elfos.h newlib-stdint.h xtensa/elf.h" 3351 extra_options="${extra_options} xtensa/elf.opt" 3352 ;; 3353xtensa*-*-linux*) 3354 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h xtensa/linux.h" 3355 tmake_file="${tmake_file} xtensa/t-xtensa" 3356 ;; 3357xtensa*-*-uclinux*) 3358 tm_file="${tm_file} dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h xtensa/uclinux.h" 3359 tmake_file="${tmake_file} xtensa/t-xtensa" 3360 extra_options="${extra_options} xtensa/uclinux.opt" 3361 ;; 3362am33_2.0-*-linux*) 3363 tm_file="mn10300/mn10300.h dbxelf.h elfos.h gnu-user.h linux.h glibc-stdint.h mn10300/linux.h" 3364 gas=yes gnu_ld=yes 3365 use_collect2=no 3366 ;; 3367m32c-*-rtems*) 3368 tm_file="dbxelf.h elfos.h ${tm_file} m32c/rtems.h rtems.h newlib-stdint.h" 3369 c_target_objs="m32c-pragma.o" 3370 cxx_target_objs="m32c-pragma.o" 3371 ;; 3372m32c-*-elf*) 3373 tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}" 3374 c_target_objs="m32c-pragma.o" 3375 cxx_target_objs="m32c-pragma.o" 3376 ;; 3377*) 3378 echo "*** Configuration ${target} not supported" 1>&2 3379 exit 1 3380 ;; 3381esac 3382 3383case ${target} in 3384i[34567]86-*-linux* | x86_64-*-linux*) 3385 tmake_file="${tmake_file} i386/t-pmm_malloc i386/t-i386" 3386 ;; 3387i[34567]86-*-* | x86_64-*-*) 3388 tmake_file="${tmake_file} i386/t-gmm_malloc i386/t-i386" 3389 ;; 3390powerpc*-*-* | rs6000-*-*) 3391 tm_file="${tm_file} ${cpu_type}/option-defaults.h" 3392esac 3393 3394# non-glibc systems 3395case ${target} in 3396*-linux-musl*) 3397 tmake_file="${tmake_file} t-musl" 3398 ;; 3399*-linux-uclibc*) 3400 tmake_file="${tmake_file} t-uclibc" 3401 ;; 3402esac 3403 3404# Assume the existence of indirect function support and allow the use of the 3405# resolver attribute. 3406case ${target} in 3407*-*-linux*android*|*-*-linux*uclibc*|*-*-linux*musl*) 3408 ;; 3409*-*-linux*) 3410 case ${target} in 3411 aarch64*-* | arm*-* | i[34567]86-* | powerpc*-* | s390*-* | sparc*-* | x86_64-*) 3412 default_gnu_indirect_function=yes 3413 ;; 3414 esac 3415 ;; 3416esac 3417 3418# Build mkoffload tool 3419case ${target} in 3420*-intelmic-* | *-intelmicemul-*) 3421 tmake_file="${tmake_file} i386/t-intelmic" 3422 tm_file="${tm_file} i386/intelmic-offload.h" 3423 ;; 3424esac 3425 3426if [ "$target_has_targetcm" = "no" ]; then 3427 c_target_objs="$c_target_objs default-c.o" 3428 cxx_target_objs="$cxx_target_objs default-c.o" 3429fi 3430 3431if [ "$common_out_file" = "" ]; then 3432 if [ "$target_has_targetm_common" = "yes" ]; then 3433 common_out_file="$cpu_type/$cpu_type-common.c" 3434 else 3435 common_out_file="default-common.c" 3436 fi 3437fi 3438 3439if [ "$target_has_targetdm" = "no" ]; then 3440 d_target_objs="$d_target_objs default-d.o" 3441fi 3442 3443# Support for --with-cpu and related options (and a few unrelated options, 3444# too). 3445case ${with_cpu} in 3446 yes | no) 3447 echo "--with-cpu must be passed a value" 1>&2 3448 exit 1 3449 ;; 3450esac 3451 3452# Set arch and cpu from ${target} and ${target_noncanonical}. Set cpu 3453# to generic if there is no processor scheduler model for the target. 3454arch= 3455cpu= 3456arch_without_sse2=no 3457arch_without_64bit=no 3458case ${target} in 3459 i386-*-freebsd*) 3460 if test $fbsd_major -ge 6; then 3461 arch=i486 3462 else 3463 arch=i386 3464 fi 3465 cpu=generic 3466 arch_without_sse2=yes 3467 arch_without_64bit=yes 3468 ;; 3469 i386-*-netbsd*) 3470 arch=i486 3471 cpu=generic 3472 arch_without_sse2=yes 3473 arch_without_64bit=yes 3474 ;; 3475 i386-*-*) 3476 arch=i386 3477 cpu=i386 3478 arch_without_sse2=yes 3479 arch_without_64bit=yes 3480 ;; 3481 i486-*-*) 3482 arch=i486 3483 cpu=i486 3484 arch_without_sse2=yes 3485 arch_without_64bit=yes 3486 ;; 3487 i586-*-*) 3488 arch_without_sse2=yes 3489 arch_without_64bit=yes 3490 case ${target_noncanonical} in 3491 k6_2-*) 3492 arch=k6-2 3493 cpu=k6-2 3494 ;; 3495 k6_3-*) 3496 arch=k6-3 3497 cpu=k6-3 3498 ;; 3499 k6-*) 3500 arch=k6 3501 cpu=k6 3502 ;; 3503 pentium_mmx-*|winchip_c6-*|winchip2-*|c3-*) 3504 arch=pentium-mmx 3505 cpu=pentium-mmx 3506 ;; 3507 *) 3508 arch=pentium 3509 cpu=pentium 3510 ;; 3511 esac 3512 ;; 3513 i686-*-* | i786-*-*) 3514 case ${target_noncanonical} in 3515 znver1-*) 3516 arch=znver1 3517 cpu=znver1 3518 ;; 3519 znver2-*) 3520 arch=znver2 3521 cpu=znver2 3522 ;; 3523 bdver4-*) 3524 arch=bdver4 3525 cpu=bdver4 3526 ;; 3527 bdver3-*) 3528 arch=bdver3 3529 cpu=bdver3 3530 ;; 3531 bdver2-*) 3532 arch=bdver2 3533 cpu=bdver2 3534 ;; 3535 bdver1-*) 3536 arch=bdver1 3537 cpu=bdver1 3538 ;; 3539 btver1-*) 3540 arch=btver1 3541 cpu=btver1 3542 ;; 3543 btver2-*) 3544 arch=btver2 3545 cpu=btver2 3546 ;; 3547 amdfam10-*|barcelona-*) 3548 arch=amdfam10 3549 cpu=amdfam10 3550 ;; 3551 k8_sse3-*|opteron_sse3-*|athlon64_sse3-*) 3552 arch=k8-sse3 3553 cpu=k8-sse3 3554 ;; 3555 k8-*|opteron-*|athlon64-*|athlon_fx-*) 3556 arch=k8 3557 cpu=k8 3558 ;; 3559 athlon_xp-*|athlon_mp-*|athlon_4-*) 3560 arch=athlon-4 3561 cpu=athlon-4 3562 arch_without_sse2=yes 3563 arch_without_64bit=yes 3564 ;; 3565 athlon_tbird-*|athlon-*) 3566 arch=athlon 3567 cpu=athlon 3568 arch_without_sse2=yes 3569 ;; 3570 geode-*) 3571 arch=geode 3572 cpu=geode 3573 arch_without_sse2=yes 3574 ;; 3575 pentium2-*) 3576 arch=pentium2 3577 cpu=pentium2 3578 arch_without_sse2=yes 3579 ;; 3580 pentium3-*|pentium3m-*) 3581 arch=pentium3 3582 cpu=pentium3 3583 arch_without_sse2=yes 3584 ;; 3585 pentium4-*|pentium4m-*) 3586 arch=pentium4 3587 cpu=pentium4 3588 ;; 3589 prescott-*) 3590 arch=prescott 3591 cpu=prescott 3592 ;; 3593 nocona-*) 3594 arch=nocona 3595 cpu=nocona 3596 ;; 3597 atom-*) 3598 arch=atom 3599 cpu=atom 3600 ;; 3601 slm-*) 3602 arch=slm 3603 cpu=slm 3604 ;; 3605 core2-*) 3606 arch=core2 3607 cpu=core2 3608 ;; 3609 corei7-*) 3610 arch=corei7 3611 cpu=corei7 3612 ;; 3613 corei7_avx-*) 3614 arch=corei7-avx 3615 cpu=corei7-avx 3616 ;; 3617 pentium_m-*) 3618 arch=pentium-m 3619 cpu=pentium-m 3620 ;; 3621 pentiumpro-*) 3622 arch=pentiumpro 3623 cpu=pentiumpro 3624 arch_without_sse2=yes 3625 ;; 3626 *) 3627 arch=pentiumpro 3628 cpu=generic 3629 arch_without_sse2=yes 3630 arch_without_64bit=yes 3631 ;; 3632 esac 3633 ;; 3634 x86_64-*-*) 3635 case ${target_noncanonical} in 3636 znver1-*) 3637 arch=znver1 3638 cpu=znver1 3639 ;; 3640 znver2-*) 3641 arch=znver2 3642 cpu=znver2 3643 ;; 3644 bdver4-*) 3645 arch=bdver4 3646 cpu=bdver4 3647 ;; 3648 bdver3-*) 3649 arch=bdver3 3650 cpu=bdver3 3651 ;; 3652 bdver2-*) 3653 arch=bdver2 3654 cpu=bdver2 3655 ;; 3656 bdver1-*) 3657 arch=bdver1 3658 cpu=bdver1 3659 ;; 3660 btver1-*) 3661 arch=btver1 3662 cpu=btver1 3663 ;; 3664 btver2-*) 3665 arch=btver2 3666 cpu=btver2 3667 ;; 3668 amdfam10-*|barcelona-*) 3669 arch=amdfam10 3670 cpu=amdfam10 3671 ;; 3672 k8_sse3-*|opteron_sse3-*|athlon64_sse3-*) 3673 arch=k8-sse3 3674 cpu=k8-sse3 3675 ;; 3676 k8-*|opteron-*|athlon_64-*) 3677 arch=k8 3678 cpu=k8 3679 ;; 3680 nocona-*) 3681 arch=nocona 3682 cpu=nocona 3683 ;; 3684 atom-*) 3685 arch=atom 3686 cpu=atom 3687 ;; 3688 slm-*) 3689 arch=slm 3690 cpu=slm 3691 ;; 3692 core2-*) 3693 arch=core2 3694 cpu=core2 3695 ;; 3696 corei7-*) 3697 arch=corei7 3698 cpu=corei7 3699 ;; 3700 *) 3701 arch=x86-64 3702 cpu=generic 3703 ;; 3704 esac 3705 ;; 3706esac 3707 3708# If there is no $with_cpu option, try to infer one from ${target}. 3709# This block sets nothing except for with_cpu. 3710if test x$with_cpu = x ; then 3711 case ${target} in 3712 i[34567]86-*-elfiamcu) 3713 with_cpu=lakemont 3714 ;; 3715 i[34567]86-*-*|x86_64-*-*) 3716 with_cpu=$cpu 3717 ;; 3718 alphaev6[78]*-*-*) 3719 with_cpu=ev67 3720 ;; 3721 alphaev6*-*-*) 3722 with_cpu=ev6 3723 ;; 3724 alphapca56*-*-*) 3725 with_cpu=pca56 3726 ;; 3727 alphaev56*-*-*) 3728 with_cpu=ev56 3729 ;; 3730 alphaev5*-*-*) 3731 with_cpu=ev5 3732 ;; 3733 frv-*-*linux* | frv400-*-*linux*) 3734 with_cpu=fr400 3735 ;; 3736 frv550-*-*linux*) 3737 with_cpu=fr550 3738 ;; 3739 m5200-*-*|m5407-*-*) 3740 with_cpu=${default_cf_cpu} 3741 ;; 3742 m68k*-*-*) 3743 case "$with_arch" in 3744 "cf") 3745 with_cpu=${default_cf_cpu} 3746 ;; 3747 "" | "m68k") 3748 with_cpu=m${default_m68k_cpu} 3749 ;; 3750 esac 3751 ;; 3752 sparc*-*-*) 3753 case ${target} in 3754 *-leon-*) 3755 with_cpu=leon 3756 ;; 3757 *-leon[3-9]*) 3758 with_cpu=leon3 3759 ;; 3760 *-leon[3-9]v7*) 3761 with_cpu=leon3v7 3762 ;; 3763 *) 3764 with_cpu="`echo ${target} | sed 's/-.*$//'`" 3765 ;; 3766 esac 3767 ;; 3768 visium-*-*) 3769 with_cpu=gr5 3770 ;; 3771 esac 3772 3773 # Avoid overriding --with-cpu-32 and --with-cpu-64 values. 3774 case ${target} in 3775 i[34567]86-*-*|x86_64-*-*) 3776 if test x$with_cpu_32 != x || test x$with_cpu_64 != x; then 3777 if test x$with_cpu_32 = x; then 3778 with_cpu_32=$with_cpu 3779 fi 3780 if test x$with_cpu_64 = x; then 3781 with_cpu_64=$with_cpu 3782 fi 3783 with_cpu= 3784 fi 3785 ;; 3786 esac 3787fi 3788 3789# Support for --with-arch and related options (and a few unrelated options, 3790# too). 3791case ${with_arch} in 3792 yes | no) 3793 echo "--with-arch must be passed a value" 1>&2 3794 exit 1 3795 ;; 3796esac 3797 3798# If there is no $with_arch option, try to infer one from ${target}. 3799# This block sets nothing except for with_arch. 3800if test x$with_arch = x ; then 3801 case ${target} in 3802 i[34567]86-*-darwin*|x86_64-*-darwin*) 3803 # Default arch is set via TARGET_SUBTARGET32_ISA_DEFAULT 3804 # and TARGET_SUBTARGET64_ISA_DEFAULT in config/i386/darwin.h. 3805 ;; 3806 i[34567]86-*-elfiamcu) 3807 with_arch=lakemont 3808 ;; 3809 i[34567]86-*-*) 3810 # --with-fpmath sets the default ISA to SSE2, which is the same 3811 # ISA supported by Pentium 4. 3812 if test x$with_fpmath = x || test $arch_without_sse2 = no; then 3813 with_arch=$arch 3814 else 3815 with_arch=pentium4 3816 fi 3817 ;; 3818 x86_64-*-*) 3819 with_arch=$arch 3820 ;; 3821 mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*) 3822 with_arch=r5900 3823 ;; 3824 mips*-*-vxworks) 3825 with_arch=mips2 3826 ;; 3827 esac 3828 3829 # Avoid overriding --with-arch-32 and --with-arch-64 values. 3830 case ${target} in 3831 i[34567]86-*-darwin*|x86_64-*-darwin*) 3832 # Default arch is set via TARGET_SUBTARGET32_ISA_DEFAULT 3833 # and TARGET_SUBTARGET64_ISA_DEFAULT in config/i386/darwin.h. 3834 ;; 3835 i[34567]86-*-*|x86_64-*-*) 3836 if test x$with_arch_32 != x || test x$with_arch_64 != x; then 3837 if test x$with_arch_32 = x; then 3838 with_arch_32=$with_arch 3839 fi 3840 if test x$with_arch_64 = x; then 3841 if test $arch_without_64bit = yes; then 3842 # Set the default 64bit arch to x86-64 if the default arch 3843 # doesn't support 64bit. 3844 with_arch_64=x86-64 3845 else 3846 with_arch_64=$with_arch 3847 fi 3848 fi 3849 with_arch= 3850 elif test $arch_without_64bit$need_64bit_isa = yesyes; then 3851 # Set the default 64bit arch to x86-64 if the default arch 3852 # doesn't support 64bit and we need 64bit ISA. 3853 with_arch_32=$with_arch 3854 with_arch_64=x86-64 3855 with_arch= 3856 fi 3857 ;; 3858 esac 3859fi 3860 3861# Infer a default setting for --with-float. 3862if test x$with_float = x; then 3863 case ${target} in 3864 mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*) 3865 # The R5900 doesn't support 64-bit float. 32-bit float doesn't 3866 # comply with IEEE 754. 3867 with_float=soft 3868 ;; 3869 esac 3870fi 3871 3872# Infer a default setting for --with-fpu. 3873if test x$with_fpu = x; then 3874 case ${target} in 3875 mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*) 3876 # The R5900 FPU only supports single precision. 3877 with_fpu=single 3878 ;; 3879 esac 3880fi 3881 3882# Support --with-fpmath. 3883if test x$with_fpmath != x; then 3884 case ${target} in 3885 i[34567]86-*-* | x86_64-*-*) 3886 case ${with_fpmath} in 3887 avx) 3888 tm_file="${tm_file} i386/avxmath.h" 3889 ;; 3890 sse) 3891 tm_file="${tm_file} i386/ssemath.h" 3892 ;; 3893 *) 3894 echo "Invalid --with-fpmath=$with_fpmath" 1>&2 3895 exit 1 3896 ;; 3897 esac 3898 ;; 3899 *) 3900 echo "--with-fpmath isn't supported for $target." 1>&2 3901 exit 1 3902 ;; 3903 esac 3904fi 3905 3906# Similarly for --with-schedule. 3907if test x$with_schedule = x; then 3908 case ${target} in 3909 hppa1*) 3910 # Override default PA8000 scheduling model. 3911 with_schedule=7100LC 3912 ;; 3913 esac 3914fi 3915 3916# Infer a default setting for --with-llsc. 3917if test x$with_llsc = x; then 3918 case ${target} in 3919 mips*-*-linux*) 3920 # The kernel emulates LL and SC where necessary. 3921 with_llsc=yes 3922 ;; 3923 mips64r5900-*-* | mips64r5900el-*-* | mipsr5900-*-* | mipsr5900el-*-*) 3924 # The R5900 doesn't support LL(D) and SC(D). 3925 with_llsc=no 3926 ;; 3927 esac 3928fi 3929 3930# Validate and mark as valid any --with options supported 3931# by this target. In order to use a particular --with option 3932# you must list it in supported_defaults; validating the value 3933# is optional. This case statement should set nothing besides 3934# supported_defaults. 3935 3936supported_defaults= 3937case "${target}" in 3938 aarch64*-*-*) 3939 supported_defaults="abi cpu arch" 3940 for which in cpu arch; do 3941 3942 eval "val=\$with_$which" 3943 base_val=`echo $val | sed -e 's/\+.*//'` 3944 ext_val=`echo $val | sed -e 's/[a-z0-9.-]\+//'` 3945 3946 if [ $which = arch ]; then 3947 def=aarch64-arches.def 3948 pattern=AARCH64_ARCH 3949 else 3950 def=aarch64-cores.def 3951 pattern=AARCH64_CORE 3952 fi 3953 3954 ext_mask=AARCH64_CPU_DEFAULT_FLAGS 3955 3956 # Find the base CPU or ARCH id in aarch64-cores.def or 3957 # aarch64-arches.def 3958 if [ x"$base_val" = x ] \ 3959 || grep "^$pattern(\"$base_val\"," \ 3960 ${srcdir}/config/aarch64/$def \ 3961 > /dev/null; then 3962 3963 if [ $which = arch ]; then 3964 base_id=`grep "^$pattern(\"$base_val\"," \ 3965 ${srcdir}/config/aarch64/$def | \ 3966 sed -e 's/^[^,]*,[ ]*//' | \ 3967 sed -e 's/,.*$//'` 3968 # Extract the architecture flags from aarch64-arches.def 3969 ext_mask=`grep "^$pattern(\"$base_val\"," \ 3970 ${srcdir}/config/aarch64/$def | \ 3971 sed -e 's/)$//' | \ 3972 sed -e 's/^.*,//'` 3973 else 3974 base_id=`grep "^$pattern(\"$base_val\"," \ 3975 ${srcdir}/config/aarch64/$def | \ 3976 sed -e 's/^[^,]*,[ ]*//' | \ 3977 sed -e 's/,.*$//'` 3978 fi 3979 3980 while [ x"$ext_val" != x ] 3981 do 3982 ext_val=`echo $ext_val | sed -e 's/\+//'` 3983 ext=`echo $ext_val | sed -e 's/\+.*//'` 3984 base_ext=`echo $ext | sed -e 's/^no//'` 3985 3986 if [ x"$base_ext" = x ] \ 3987 || grep "^AARCH64_OPT_EXTENSION(\"$base_ext\"," \ 3988 ${srcdir}/config/aarch64/aarch64-option-extensions.def \ 3989 > /dev/null; then 3990 3991 ext_canon=`grep "^AARCH64_OPT_EXTENSION(\"$base_ext\"," \ 3992 ${srcdir}/config/aarch64/aarch64-option-extensions.def | \ 3993 sed -e 's/^[^,]*,[ ]*//' | \ 3994 sed -e 's/,.*$//'` 3995 ext_on=`grep "^AARCH64_OPT_EXTENSION(\"$base_ext\"," \ 3996 ${srcdir}/config/aarch64/aarch64-option-extensions.def | \ 3997 sed -e 's/^[^,]*,[ ]*[^,]*,[ ]*//' | \ 3998 sed -e 's/,.*$//' | \ 3999 sed -e 's/).*$//'` 4000 ext_off=`grep "^AARCH64_OPT_EXTENSION(\"$base_ext\"," \ 4001 ${srcdir}/config/aarch64/aarch64-option-extensions.def | \ 4002 sed -e 's/^[^,]*,[ ]*[^,]*,[ ]*[^,]*,[ ]*//' | \ 4003 sed -e 's/,.*$//' | \ 4004 sed -e 's/).*$//'` 4005 4006 4007 if [ $ext = $base_ext ]; then 4008 # Adding extension 4009 ext_mask="("$ext_mask") | ("$ext_on" | "$ext_canon")" 4010 else 4011 # Removing extension 4012 ext_mask="("$ext_mask") & ~("$ext_off" | "$ext_canon")" 4013 fi 4014 4015 true 4016 else 4017 echo "Unknown extension used in --with-$which=$val" 1>&2 4018 exit 1 4019 fi 4020 ext_val=`echo $ext_val | sed -e 's/[a-z0-9]\+//'` 4021 done 4022 4023 ext_mask="(("$ext_mask") << 6)" 4024 if [ x"$base_id" != x ]; then 4025 target_cpu_cname="TARGET_CPU_$base_id | $ext_mask" 4026 fi 4027 true 4028 else 4029 echo "Unknown $which used in --with-$which=$val" 1>&2 4030 exit 1 4031 fi 4032 done 4033 ;; 4034 4035 alpha*-*-*) 4036 supported_defaults="cpu tune" 4037 for which in cpu tune; do 4038 eval "val=\$with_$which" 4039 case "$val" in 4040 "" \ 4041 | ev4 | ev45 | 21064 | ev5 | 21164 | ev56 | 21164a \ 4042 | pca56 | 21164PC | 21164pc | ev6 | 21264 | ev67 \ 4043 | 21264a) 4044 ;; 4045 *) 4046 echo "Unknown CPU used in --with-$which=$val" 1>&2 4047 exit 1 4048 ;; 4049 esac 4050 done 4051 ;; 4052 4053 arc*-*-*) 4054 supported_defaults="cpu" 4055 4056 if [ x"$with_cpu" = x ] \ 4057 || grep "^ARC_CPU ($with_cpu," \ 4058 ${srcdir}/config/arc/arc-cpus.def \ 4059 > /dev/null; then 4060 # Ok 4061 true 4062 else 4063 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2 4064 exit 1 4065 fi 4066 ;; 4067 4068 csky-*-*) 4069 supported_defaults="cpu endian float" 4070 ;; 4071 4072 arm*-*-*) 4073 supported_defaults="arch cpu float tune fpu abi mode tls" 4074 for which in cpu tune arch; do 4075 # See if it matches a supported value 4076 eval "val=\$with_$which" 4077 if [ x"$val" != x ]; then 4078 cpu=`awk -f ${srcdir}/config/arm/parsecpu.awk \ 4079 -v cmd="chk$which $val" \ 4080 ${srcdir}/config/arm/arm-cpus.in` 4081 if [ "$cpu" = "error" ]; then 4082 echo "Unknown target in --with-$which=$val" 1>&2 4083 exit 1 4084 else 4085 new_val=$cpu 4086 eval "target_${which}_cname=$new_val" 4087 echo "For $val real value is $new_val" 4088 fi 4089 fi 4090 done 4091 4092 case "$with_float" in 4093 "" \ 4094 | soft | hard | softfp) 4095 # OK 4096 ;; 4097 *) 4098 echo "Unknown floating point type used in --with-float=$with_float" 1>&2 4099 exit 1 4100 ;; 4101 esac 4102 4103 # see if --with-fpu matches any of the supported FPUs 4104 if [ x"$with_fpu" != x ] ; then 4105 fpu=`awk -f ${srcdir}/config/arm/parsecpu.awk \ 4106 -v cmd="chkfpu $with_fpu" \ 4107 ${srcdir}/config/arm/arm-cpus.in` 4108 if [ "$fpu" = "error"] 4109 then 4110 echo "Unknown target in --with-$which=$val" 1>&2 4111 exit 1 4112 fi 4113 fi 4114 4115 case "$with_abi" in 4116 "" \ 4117 | apcs-gnu | atpcs | aapcs | iwmmxt | aapcs-linux ) 4118 #OK 4119 ;; 4120 *) 4121 echo "Unknown ABI used in --with-abi=$with_abi" 4122 exit 1 4123 ;; 4124 esac 4125 4126 case "$with_mode" in 4127 "" \ 4128 | arm | thumb ) 4129 #OK 4130 ;; 4131 *) 4132 echo "Unknown mode used in --with-mode=$with_mode" 4133 exit 1 4134 ;; 4135 esac 4136 4137 case "$with_tls" in 4138 "" \ 4139 | gnu | gnu2) 4140 # OK 4141 ;; 4142 *) 4143 echo "Unknown TLS method used in --with-tls=$with_tls" 1>&2 4144 exit 1 4145 ;; 4146 esac 4147 4148 if test "x$with_arch" != x && test "x$with_cpu" != x; then 4149 echo "Switch \"--with-arch\" may not be used with switch \"--with-cpu\"" 1>&2 4150 exit 1 4151 fi 4152 4153 if test "x$with_cpu" != x && test "x$with_tune" != x; then 4154 echo "Switch \"--with-tune\" may not be used with switch \"--with-cpu\"" 1>&2 4155 exit 1 4156 fi 4157 4158 # Add extra multilibs 4159 if test "x$with_multilib_list" != x; then 4160 ml= 4161 arm_multilibs=`echo $with_multilib_list | sed -e 's/,/ /g'` 4162 if test "x${arm_multilibs}" != xdefault ; then 4163 for arm_multilib in ${arm_multilibs}; do 4164 case ${arm_multilib} in 4165 aprofile|rmprofile) 4166 tmake_profile_file="arm/t-multilib" 4167 ;; 4168 @*) 4169 ml=`echo "X$arm_multilib" | sed '1s,^X@,,'` 4170 if test -f "${srcdir}/config/arm/${ml}"; then 4171 tmake_file="${tmake_file} arm/${ml}" 4172 else 4173 echo "Error: ${ml} does not exist in ${srcdir}/config/arm" >&2 4174 exit 1 4175 fi 4176 ;; 4177 *) 4178 echo "Error: --with-multilib-list=${with_multilib_list} not supported." 1>&2 4179 exit 1 4180 ;; 4181 esac 4182 done 4183 fi 4184 4185 if test "x${tmake_profile_file}" != x ; then 4186 # arm/t-aprofile and arm/t-rmprofile are only 4187 # designed to work without any with-cpu, 4188 # with-arch, with-mode, with-fpu or with-float 4189 # options. 4190 if test "x$with_arch" != x \ 4191 || test "x$with_cpu" != x \ 4192 || test "x$with_float" != x \ 4193 || test "x$with_fpu" != x \ 4194 || test "x$with_mode" != x ; then 4195 echo "Error: You cannot use any of --with-arch/cpu/fpu/float/mode with --with-multilib-list=${with_multilib_list}" 1>&2 4196 exit 1 4197 elif test "x$ml" != x ; then 4198 echo "Error: You cannot use builtin multilib profiles along with custom ones" 1>&2 4199 exit 1 4200 fi 4201 # But pass the default value for float-abi 4202 # through to the multilib selector 4203 with_float="soft" 4204 tmake_file="${tmake_file} ${tmake_profile_file}" 4205 TM_MULTILIB_CONFIG="$with_multilib_list" 4206 fi 4207 fi 4208 target_cpu_cname=${target_cpu_cname:-arm7tdmi} 4209 with_cpu=${with_cpu:-$target_cpu_cname} 4210 ;; 4211 4212 fr*-*-*linux*) 4213 supported_defaults=cpu 4214 case "$with_cpu" in 4215 fr400) ;; 4216 fr550) ;; 4217 *) 4218 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2 4219 exit 1 4220 ;; 4221 esac 4222 ;; 4223 4224 fido-*-* | m68k*-*-* | m5200-*-* | m5407-*-*) 4225 supported_defaults="arch cpu" 4226 case "$with_arch" in 4227 "" | "m68k"| "cf") 4228 m68k_arch_family="$with_arch" 4229 ;; 4230 *) 4231 echo "Invalid --with-arch=$with_arch" 1>&2 4232 exit 1 4233 ;; 4234 esac 4235 4236 # We always have a $with_cpu setting here. 4237 case "$with_cpu" in 4238 "m68000" | "m68010" | "m68020" | "m68030" | "m68040" | "m68060") 4239 m68k_cpu_ident=$with_cpu 4240 ;; 4241 "m68020-40") 4242 m68k_cpu_ident=m68020 4243 tm_defines="$tm_defines M68K_DEFAULT_TUNE=u68020_40" 4244 ;; 4245 "m68020-60") 4246 m68k_cpu_ident=m68020 4247 tm_defines="$tm_defines M68K_DEFAULT_TUNE=u68020_60" 4248 ;; 4249 *) 4250 # We need the C identifier rather than the string. 4251 m68k_cpu_ident=`awk -v arg="\"$with_cpu\"" \ 4252 'BEGIN { FS="[ \t]*[,()][ \t]*" }; \ 4253 $1 == "M68K_DEVICE" && $2 == arg { print $3 }' \ 4254 ${srcdir}/config/m68k/m68k-devices.def` 4255 if [ x"$m68k_cpu_ident" = x ] ; then 4256 echo "Unknown CPU used in --with-cpu=$with_cpu" 1>&2 4257 exit 1 4258 fi 4259 with_cpu="mcpu=$with_cpu" 4260 ;; 4261 esac 4262 ;; 4263 4264 amdgcn-*-*) 4265 supported_defaults="arch tune" 4266 4267 for which in arch tune; do 4268 eval "val=\$with_$which" 4269 case ${val} in 4270 "" | carrizo | fiji | gfx900 ) 4271 # OK 4272 ;; 4273 *) 4274 echo "Unknown cpu used in --with-$which=$val." 1>&2 4275 exit 1 4276 ;; 4277 esac 4278 done 4279 [ "x$with_arch" = x ] && with_arch=fiji 4280 ;; 4281 4282 hppa*-*-*) 4283 supported_defaults="arch schedule" 4284 4285 case "$with_arch" in 4286 "" | 1.0 | 1.1 | 2.0) 4287 # OK 4288 ;; 4289 *) 4290 echo "Unknown architecture used in --with-arch=$with_arch" 1>&2 4291 exit 1 4292 ;; 4293 esac 4294 4295 case "$with_schedule" in 4296 "" | 700 | 7100 | 7100LC | 7200 | 7300 | 8000) 4297 # OK 4298 ;; 4299 *) 4300 echo "Unknown processor used in --with-schedule=$with_schedule." 1>&2 4301 exit 1 4302 ;; 4303 esac 4304 ;; 4305 4306 i[34567]86-*-* | x86_64-*-*) 4307 supported_defaults="abi arch arch_32 arch_64 cpu cpu_32 cpu_64 tune tune_32 tune_64" 4308 for which in arch arch_32 arch_64 cpu cpu_32 cpu_64 tune tune_32 tune_64; do 4309 eval "val=\$with_$which" 4310 case " $x86_archs " in 4311 *" ${val} "*) 4312 case "${target}" in 4313 x86_64-*-*) 4314 case "x$which" in 4315 *_32) 4316 ;; 4317 *) 4318 echo "CPU given in --with-$which=$val doesn't support 64bit mode." 1>&2 4319 exit 1 4320 ;; 4321 esac 4322 ;; 4323 esac 4324 # OK 4325 ;; 4326 *) 4327 if test x${val} != x; then 4328 case " $x86_64_archs " in 4329 *" ${val} "*) 4330 # OK 4331 ;; 4332 *) 4333 # Allow $x86_cpus --with-cpu=/--with-tune= 4334 case "x$which" in 4335 xcpu*|xtune*) 4336 case " $x86_cpus " in 4337 *" ${val} "*) 4338 # OK 4339 ;; 4340 *) 4341 echo "Unknown CPU given in --with-$which=$val." 1>&2 4342 exit 1 4343 ;; 4344 esac 4345 ;; 4346 *) 4347 echo "Unknown CPU given in --with-$which=$val." 1>&2 4348 exit 1 4349 ;; 4350 esac 4351 ;; 4352 esac 4353 fi 4354 ;; 4355 esac 4356 done 4357 ;; 4358 4359 riscv*-*-*) 4360 supported_defaults="abi arch tune riscv_attribute" 4361 4362 case "${target}" in 4363 riscv-* | riscv32*) xlen=32 ;; 4364 riscv64*) xlen=64 ;; 4365 *) echo "Unsupported RISC-V target ${target}" 1>&2; exit 1 ;; 4366 esac 4367 4368 case "${with_riscv_attribute}" in 4369 yes) 4370 tm_defines="${tm_defines} TARGET_RISCV_ATTRIBUTE=1" 4371 ;; 4372 no) 4373 tm_defines="${tm_defines} TARGET_RISCV_ATTRIBUTE=0" 4374 ;; 4375 ""|default) 4376 case "${target}" in 4377 riscv*-*-elf*) 4378 tm_defines="${tm_defines} TARGET_RISCV_ATTRIBUTE=1" 4379 ;; 4380 *) 4381 tm_defines="${tm_defines} TARGET_RISCV_ATTRIBUTE=0" 4382 ;; 4383 esac 4384 ;; 4385 *) 4386 echo "--with-riscv-attribute=${with_riscv_attribute} is not supported. The argument must begin with yes, no or default." 1>&2 4387 exit 1 4388 ;; 4389 esac 4390 4391 4392 # Infer arch from --with-arch, --target, and --with-abi. 4393 case "${with_arch}" in 4394 rv32e* | rv32i* | rv32g* | rv64i* | rv64g*) 4395 # OK. 4396 ;; 4397 "") 4398 # Infer XLEN, but otherwise assume GC. 4399 case "${with_abi}" in 4400 ilp32e) with_arch="rv32e" ;; 4401 ilp32 | ilp32f | ilp32d) with_arch="rv32gc" ;; 4402 lp64 | lp64f | lp64d) with_arch="rv64gc" ;; 4403 *) with_arch="rv${xlen}gc" ;; 4404 esac 4405 ;; 4406 *) 4407 echo "--with-arch=${with_arch} is not supported. The argument must begin with rv32e, rv32i, rv32g, rv64i, or rv64g." 1>&2 4408 exit 1 4409 ;; 4410 esac 4411 4412 # Make sure --with-abi is valid. If it was not specified, 4413 # pick a default based on the ISA, preferring soft-float 4414 # unless the D extension is present. 4415 case "${with_abi}" in 4416 ilp32 | ilp32e | ilp32f | ilp32d | lp64 | lp64f | lp64d) 4417 ;; 4418 "") 4419 case "${with_arch}" in 4420 rv32*d* | rv32g*) with_abi=ilp32d ;; 4421 rv32e*) with_abi=ilp32e ;; 4422 rv32*) with_abi=ilp32 ;; 4423 rv64*d* | rv64g*) with_abi=lp64d ;; 4424 rv64*) with_abi=lp64 ;; 4425 esac 4426 ;; 4427 *) 4428 echo "--with-abi=${with_abi} is not supported" 1>&2 4429 exit 1 4430 ;; 4431 esac 4432 4433 # Make sure ABI and ISA are compatible. 4434 case "${with_abi},${with_arch}" in 4435 ilp32,rv32* | ilp32e,rv32e* \ 4436 | ilp32f,rv32*f* | ilp32f,rv32g* \ 4437 | ilp32d,rv32*d* | ilp32d,rv32g* \ 4438 | lp64,rv64* \ 4439 | lp64f,rv64*f* | lp64f,rv64g* \ 4440 | lp64d,rv64*d* | lp64d,rv64g*) 4441 ;; 4442 *) 4443 echo "--with-abi=${with_abi} is not supported for ISA ${with_arch}" 1>&2 4444 exit 1 4445 ;; 4446 esac 4447 4448 # Handle --with-multilib-list. 4449 if test "x${with_multilib_list}" != xdefault; then 4450 tm_file="${tm_file} riscv/withmultilib.h" 4451 tmake_file="${tmake_file} riscv/t-withmultilib" 4452 4453 case ${with_multilib_list} in 4454 ilp32 | ilp32f | ilp32d \ 4455 | lp64 | lp64f | lp64d ) 4456 TM_MULTILIB_CONFIG="${with_arch},${with_multilib_list}" 4457 ;; 4458 *) 4459 echo "--with-multilib-list=${with_multilib_list} not supported." 4460 exit 1 4461 esac 4462 4463 # Define macros to select the default multilib. 4464 case ${with_arch} in 4465 rv32gc) 4466 tm_defines="${tm_defines} TARGET_MLIB_ARCH=1" 4467 ;; 4468 rv64gc) 4469 tm_defines="${tm_defines} TARGET_MLIB_ARCH=2" 4470 ;; 4471 *) 4472 echo "unsupported --with-arch for --with-multilib-list" 4473 exit 1 4474 esac 4475 case ${with_abi} in 4476 ilp32) 4477 tm_defines="${tm_defines} TARGET_MLIB_ABI=1" 4478 ;; 4479 ilp32f) 4480 tm_defines="${tm_defines} TARGET_MLIB_ABI=2" 4481 ;; 4482 ilp32d) 4483 tm_defines="${tm_defines} TARGET_MLIB_ABI=3" 4484 ;; 4485 lp64) 4486 tm_defines="${tm_defines} TARGET_MLIB_ABI=4" 4487 ;; 4488 lp64f) 4489 tm_defines="${tm_defines} TARGET_MLIB_ABI=5" 4490 ;; 4491 lp64d) 4492 tm_defines="${tm_defines} TARGET_MLIB_ABI=6" 4493 ;; 4494 *) 4495 echo "unsupported --with-abi for --with-multilib" 4496 exit 1 4497 esac 4498 fi 4499 ;; 4500 4501 mips*-*-*) 4502 supported_defaults="abi arch arch_32 arch_64 float fpu nan fp_32 odd_spreg_32 tune tune_32 tune_64 divide llsc mips-plt synci lxc1-sxc1 madd4" 4503 4504 case ${with_float} in 4505 "" | soft | hard) 4506 # OK 4507 ;; 4508 *) 4509 echo "Unknown floating point type used in --with-float=$with_float" 1>&2 4510 exit 1 4511 ;; 4512 esac 4513 4514 case ${with_fpu} in 4515 "" | single | double) 4516 # OK 4517 ;; 4518 *) 4519 echo "Unknown fpu type used in --with-fpu=$with_fpu" 1>&2 4520 exit 1 4521 ;; 4522 esac 4523 4524 case ${with_nan} in 4525 "" | 2008 | legacy) 4526 # OK 4527 ;; 4528 *) 4529 echo "Unknown NaN encoding used in --with-nan=$with_nan" 1>&2 4530 exit 1 4531 ;; 4532 esac 4533 4534 case ${with_fp_32} in 4535 "" | 32 | xx | 64) 4536 # OK 4537 ;; 4538 *) 4539 echo "Unknown FP mode used in --with-fp-32=$with_fp_32" 1>&2 4540 exit 1 4541 ;; 4542 esac 4543 4544 case ${with_odd_spreg_32} in 4545 yes) 4546 with_odd_spreg_32="odd-spreg" 4547 ;; 4548 no) 4549 with_odd_spreg_32="no-odd-spreg" 4550 ;; 4551 "") 4552 # OK 4553 ;; 4554 *) 4555 echo "Unknown odd-spreg-32 type used in --with-odd-spreg-32=$with_odd_spreg_32" 1>&2 4556 exit 1 4557 ;; 4558 esac 4559 4560 case ${with_abi} in 4561 "" | 32 | o64 | n32 | 64 | eabi) 4562 # OK 4563 ;; 4564 *) 4565 echo "Unknown ABI used in --with-abi=$with_abi" 1>&2 4566 exit 1 4567 ;; 4568 esac 4569 4570 case ${with_divide} in 4571 "" | breaks | traps) 4572 # OK 4573 ;; 4574 *) 4575 echo "Unknown division check type use in --with-divide=$with_divide" 1>&2 4576 exit 1 4577 ;; 4578 esac 4579 4580 case ${with_llsc} in 4581 yes) 4582 with_llsc=llsc 4583 ;; 4584 no) 4585 with_llsc="no-llsc" 4586 ;; 4587 "") 4588 # OK 4589 ;; 4590 *) 4591 echo "Unknown llsc type used in --with-llsc" 1>&2 4592 exit 1 4593 ;; 4594 esac 4595 4596 case ${with_mips_plt} in 4597 yes) 4598 with_mips_plt=plt 4599 ;; 4600 no) 4601 with_mips_plt=no-plt 4602 ;; 4603 "") 4604 ;; 4605 *) 4606 echo "Unknown --with-mips-plt argument: $with_mips_plt" 1>&2 4607 exit 1 4608 ;; 4609 esac 4610 4611 case ${with_synci} in 4612 yes) 4613 with_synci=synci 4614 ;; 4615 no) 4616 with_synci=no-synci 4617 ;; 4618 "") 4619 ;; 4620 *) 4621 echo "Unknown synci type used in --with-synci" 1>&2 4622 exit 1 4623 ;; 4624 esac 4625 4626 case ${with_lxc1_sxc1} in 4627 yes) 4628 with_lxc1_sxc1=lxc1-sxc1 4629 ;; 4630 no) 4631 with_lxc1_sxc1=no-lxc1-sxc1 4632 ;; 4633 "") 4634 ;; 4635 *) 4636 echo "Unknown lxc1-sxc1 type used in --with-lxc1-sxc1" 1>&2 4637 exit 1 4638 ;; 4639 esac 4640 4641 case ${with_madd4} in 4642 yes) 4643 with_madd4=madd4 4644 ;; 4645 no) 4646 with_madd4=no-madd4 4647 ;; 4648 "") 4649 ;; 4650 *) 4651 echo "Unknown madd4 type used in --with-madd4" 1>&2 4652 exit 1 4653 ;; 4654 esac 4655 ;; 4656 4657 nds32*-*-*) 4658 supported_defaults="arch cpu nds32_lib float fpu_config" 4659 4660 # process --with-arch 4661 case "${with_arch}" in 4662 "" | v3 ) 4663 tm_defines="${tm_defines} TARGET_ARCH_DEFAULT=0" 4664 ;; 4665 v2 | v2j | v3m) 4666 # OK 4667 tm_defines="${tm_defines} TARGET_ARCH_DEFAULT=0" 4668 ;; 4669 v3f) 4670 tm_defines="${tm_defines} TARGET_ARCH_DEFAULT=1" 4671 ;; 4672 v3s) 4673 tm_defines="${tm_defines} TARGET_ARCH_DEFAULT=2" 4674 4675 ;; 4676 *) 4677 echo "Cannot accept --with-arch=$with_arch, available values are: v2 v2j v3 v3m v3f v3s" 1>&2 4678 exit 1 4679 ;; 4680 esac 4681 4682 case "${with_cpu}" in 4683 "") 4684 with_cpu=n9 4685 ;; 4686 n6 | n7 |n8 | e8 | s8 | n9 | n10 | d10 | n12 | n13 | n15) 4687 # OK 4688 ;; 4689 *) 4690 echo "Cannot accept --with-cpu=$with_cpu, available values are: n6 n7 n8 e8 s8 n9 n10 d10 n12 n13 n15" 1>&2 4691 exit 1 4692 ;; 4693 esac 4694 4695 # process --with-nds32-lib 4696 case "${with_nds32_lib}" in 4697 "") 4698 case ${target} in 4699 *-*-*uclibc*) 4700 with_nds32_lib=ulibc 4701 ;; 4702 *-*-linux*) 4703 with_nds32_lib=glibc 4704 ;; 4705 *) 4706 with_nds32_lib=newlib 4707 tm_defines="${tm_defines} TARGET_DEFAULT_CTOR_DTOR=1" 4708 ;; 4709 esac 4710 ;; 4711 newlib) 4712 # OK 4713 tm_defines="${tm_defines} TARGET_DEFAULT_CTOR_DTOR=1" 4714 ;; 4715 mculib) 4716 # OK 4717 # for the arch=v3f or arch=v3s under mculib toolchain, 4718 # we would like to set -fno-math-errno as default 4719 case "${with_arch}" in 4720 v3f | v3s) 4721 tm_defines="${tm_defines} TARGET_DEFAULT_NO_MATH_ERRNO=1" 4722 ;; 4723 esac 4724 ;; 4725 glibc | uclibc) 4726 # OK 4727 ;; 4728 *) 4729 echo "Cannot accept --with-nds32-lib=$with_nds32_lib, available values are: newlib mculib glibc uclibc" 1>&2 4730 exit 1 4731 ;; 4732 esac 4733 4734 # process --with-float 4735 case "${with_float}" in 4736 "" | soft | hard) 4737 # OK 4738 ;; 4739 *) 4740 echo "Cannot accept --with-float=$with_float, available values are: soft hard" 1>&2 4741 exit 1 4742 ;; 4743 esac 4744 4745 # process --with-config-fpu 4746 case "${with_config_fpu}" in 4747 "" | 0 | 1 | 2 | 3) 4748 # OK 4749 ;; 4750 *) 4751 echo "Cannot accept --with-config-fpu=$with_config_fpu, available values from 0 to 7" 1>&2 4752 exit 1 4753 ;; 4754 esac 4755 4756 4757 ;; 4758 nios2*-*-*) 4759 supported_defaults="arch" 4760 case "$with_arch" in 4761 "" | r1 | r2) 4762 # OK 4763 ;; 4764 *) 4765 echo "Unknown arch used in --with-arch=$with_arch" 1>&2 4766 exit 1 4767 ;; 4768 esac 4769 ;; 4770 4771 powerpc*-*-* | rs6000-*-*) 4772 supported_defaults="abi cpu cpu_32 cpu_64 float tune tune_32 tune_64 advance_toolchain" 4773 4774 for which in cpu cpu_32 cpu_64 tune tune_32 tune_64; do 4775 eval "val=\$with_$which" 4776 case ${val} in 4777 default32 | default64) 4778 case $which in 4779 cpu | tune) 4780 ;; 4781 *) 4782 echo "$val only valid for --with-cpu and --with-tune." 1>&2 4783 exit 1 4784 ;; 4785 esac 4786 with_which="with_$which" 4787 eval $with_which= 4788 ;; 4789 405cr) 4790 tm_defines="${tm_defines} CONFIG_PPC405CR" 4791 eval "with_$which=405" 4792 ;; 4793 "" | common | native \ 4794 | power[3456789] | power5+ | power6x \ 4795 | powerpc | powerpc64 | powerpc64le \ 4796 | rs64 \ 4797 | 401 | 403 | 405 | 405fp | 440 | 440fp | 464 | 464fp \ 4798 | 476 | 476fp | 505 | 601 | 602 | 603 | 603e | ec603e \ 4799 | 604 | 604e | 620 | 630 | 740 | 750 | 7400 | 7450 \ 4800 | a2 | e300c[23] | 854[08] | e500mc | e500mc64 | e5500 | e6500 \ 4801 | titan | 801 | 821 | 823 | 860 | 970 | G3 | G4 | G5 | cell) 4802 # OK 4803 ;; 4804 *) 4805 echo "Unknown cpu used in --with-$which=$val." 1>&2 4806 exit 1 4807 ;; 4808 esac 4809 done 4810 4811 case "$with_abi" in 4812 "" | elfv1 | elfv2 ) 4813 #OK 4814 ;; 4815 *) 4816 echo "Unknown ABI used in --with-abi=$with_abi" 4817 exit 1 4818 ;; 4819 esac 4820 4821 if test "x$with_advance_toolchain" != x; then 4822 if test -d "/opt/$with_advance_toolchain/." -a \ 4823 -d "/opt/$with_advance_toolchain/bin/." -a \ 4824 -d "/opt/$with_advance_toolchain/include/."; then 4825 4826 tm_file="$tm_file ./advance-toolchain.h" 4827 (at="/opt/$with_advance_toolchain" 4828 echo "/* Use Advance Toolchain $at */" 4829 echo 4830 echo "#undef LINK_OS_EXTRA_SPEC32" 4831 echo "#define LINK_OS_EXTRA_SPEC32" \ 4832 "\"%(link_os_new_dtags)" \ 4833 "-rpath $prefix/lib -rpath $at/lib\"" 4834 echo 4835 echo "#undef LINK_OS_EXTRA_SPEC64" 4836 echo "#define LINK_OS_EXTRA_SPEC64" \ 4837 "\"%(link_os_new_dtags)" \ 4838 "-rpath $prefix/lib64 -rpath $at/lib64\"" 4839 echo 4840 echo "#undef LINK_OS_NEW_DTAGS_SPEC" 4841 echo "#define LINK_OS_NEW_DTAGS_SPEC" \ 4842 "\"--enable-new-dtags\"" 4843 echo 4844 echo "#undef DYNAMIC_LINKER_PREFIX" 4845 echo "#define DYNAMIC_LINKER_PREFIX \"$at\"" 4846 echo 4847 echo "#undef MD_EXEC_PREFIX" 4848 echo "#define MD_EXEC_PREFIX \"$at/bin/\"" 4849 echo 4850 echo "#undef MD_STARTFILE_PREFIX" 4851 echo "#define MD_STARTFILE_PREFIX \"$prefix/lib/\"" 4852 echo 4853 echo "#undef MD_STARTFILE_PREFIX_1" 4854 echo "#define MD_STARTFILE_PREFIX_1 \"$at/lib/\"") \ 4855 > advance-toolchain.h 4856 else 4857 echo "Unknown advance-toolchain $with_advance_toolchain" 4858 exit 1 4859 fi 4860 fi 4861 4862 # Set up the default long double format if the user changed it. 4863 if test x$with_long_double_format = xieee; then 4864 tm_defines="${tm_defines} TARGET_IEEEQUAD_DEFAULT=1" 4865 4866 elif test x$with_long_double_format = xibm; then 4867 tm_defines="${tm_defines} TARGET_IEEEQUAD_DEFAULT=0" 4868 fi 4869 ;; 4870 4871 s390*-*-*) 4872 supported_defaults="arch mode tune" 4873 4874 for which in arch tune; do 4875 eval "val=\$with_$which" 4876 case ${val} in 4877 "" | native | z900 | z990 | z9-109 | z9-ec | z10 | z196 | zEC12 | z13 | z14 | z15 | arch5 | arch6 | arch7 | arch8 | arch9 | arch10 | arch11 | arch12 | arch13 ) 4878 # OK 4879 ;; 4880 *) 4881 echo "Unknown cpu used in --with-$which=$val." 1>&2 4882 exit 1 4883 ;; 4884 esac 4885 done 4886 4887 case ${with_mode} in 4888 "" | esa | zarch) 4889 # OK 4890 ;; 4891 *) 4892 echo "Unknown architecture mode used in --with-mode=$with_mode." 1>&2 4893 exit 1 4894 ;; 4895 esac 4896 ;; 4897 4898 sh[123456ble]*-*-* | sh-*-*) 4899 supported_defaults="cpu" 4900 case "`echo $with_cpu | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ_ abcdefghijklmnopqrstuvwxyz- | sed s/sh/m/`" in 4901 "" | m1 | m2 | m2e | m3 | m3e | m4 | m4-single | m4-single-only | m4-nofpu ) 4902 # OK 4903 ;; 4904 m2a | m2a-single | m2a-single-only | m2a-nofpu) 4905 ;; 4906 m4a | m4a-single | m4a-single-only | m4a-nofpu | m4al) 4907 ;; 4908 *) 4909 echo "Unknown CPU used in --with-cpu=$with_cpu, known values:" 1>&2 4910 echo "m1 m2 m2e m3 m3e m4 m4-single m4-single-only m4-nofpu" 1>&2 4911 echo "m4a m4a-single m4a-single-only m4a-nofpu m4al" 1>&2 4912 echo "m2a m2a-single m2a-single-only m2a-nofpu" 1>&2 4913 exit 1 4914 ;; 4915 esac 4916 ;; 4917 sparc*-*-*) 4918 supported_defaults="cpu cpu_32 cpu_64 float tune tune_32 tune_64" 4919 4920 for which in cpu cpu_32 cpu_64 tune tune_32 tune_64; do 4921 eval "val=\$with_$which" 4922 case ${val} in 4923 "" | sparc | sparcv9 | sparc64 \ 4924 | v7 | cypress \ 4925 | v8 | supersparc | hypersparc | leon | leon3 | leon3v7 \ 4926 | sparclite | f930 | f934 | sparclite86x \ 4927 | sparclet | tsc701 \ 4928 | v9 | ultrasparc | ultrasparc3 | niagara | niagara2 \ 4929 | niagara3 | niagara4 | niagara7 | m8) 4930 # OK 4931 ;; 4932 *) 4933 echo "Unknown cpu used in --with-$which=$val" 1>&2 4934 exit 1 4935 ;; 4936 esac 4937 done 4938 4939 case ${with_float} in 4940 "" | soft | hard) 4941 # OK 4942 ;; 4943 *) 4944 echo "Unknown floating point type used in --with-float=$with_float" 1>&2 4945 exit 1 4946 ;; 4947 esac 4948 ;; 4949 4950 spu-*-*) 4951 supported_defaults="arch tune" 4952 4953 for which in arch tune; do 4954 eval "val=\$with_$which" 4955 case ${val} in 4956 "" | cell | celledp) 4957 # OK 4958 ;; 4959 *) 4960 echo "Unknown cpu used in --with-$which=$val." 1>&2 4961 exit 1 4962 ;; 4963 esac 4964 done 4965 ;; 4966 4967 tic6x-*-*) 4968 supported_defaults="arch" 4969 4970 case ${with_arch} in 4971 "" | c62x | c64x | c64x+ | c67x | c67x+ | c674x) 4972 # OK 4973 ;; 4974 *) 4975 echo "Unknown arch used in --with-arch=$with_arch." 1>&2 4976 exit 1 4977 ;; 4978 esac 4979 ;; 4980 4981 v850*-*-*) 4982 supported_defaults=cpu 4983 case ${with_cpu} in 4984 "" | v850e | v850e1 | v850e2 | v850es | v850e2v3 | v850e3v5) 4985 # OK 4986 ;; 4987 *) 4988 echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2 4989 exit 1 4990 ;; 4991 esac 4992 ;; 4993 visium-*-*) 4994 supported_defaults="cpu" 4995 case $with_cpu in 4996 "" | gr5 | gr6) 4997 ;; 4998 *) echo "Unknown cpu used in --with-cpu=$with_cpu" 1>&2 4999 exit 1 5000 ;; 5001 esac 5002 ;; 5003esac 5004 5005# Targets for which there is at least one VxWorks port should include 5006# vxworks-dummy.h to allow safe references to various TARGET_VXWORKS kinds 5007# of markers from other files in the port, including the vxworks*.h files to 5008# distinguish VxWorks variants such as VxWorks 7 or 64). 5009 5010case ${target} in 5011arm*-*-* | i[34567]86-*-* | mips*-*-* | powerpc*-*-* | sh*-*-* \ 5012| sparc*-*-* | x86_64-*-*) 5013 tm_file="vxworks-dummy.h ${tm_file}" 5014 ;; 5015esac 5016 5017# Set some miscellaneous flags for particular targets. 5018target_cpu_default2= 5019case ${target} in 5020 aarch64*-*-*) 5021 if test x"$target_cpu_cname" != x 5022 then 5023 target_cpu_default2=$target_cpu_cname 5024 fi 5025 ;; 5026 5027 arm*-*-*) 5028 if test x$with_cpu = x 5029 then 5030 echo "Don't know the target cpu" 1>&2 5031 exit 1 5032 else 5033 target_cpu_default2="\\\"$with_cpu\\\"" 5034 fi 5035 ;; 5036 5037 hppa*-*-*) 5038 if test x$gas = xyes 5039 then 5040 target_cpu_default2="MASK_GAS" 5041 fi 5042 ;; 5043 5044 fido*-*-* | m68k*-*-*) 5045 target_cpu_default2=$m68k_cpu_ident 5046 tmake_file="m68k/t-opts $tmake_file" 5047 if [ x"$m68k_arch_family" != x ]; then 5048 tmake_file="m68k/t-$m68k_arch_family $tmake_file" 5049 fi 5050 ;; 5051 5052 i[34567]86-*-darwin* | x86_64-*-darwin*) 5053 ;; 5054 i[34567]86-*-linux* | x86_64-*-linux*) 5055 extra_objs="${extra_objs} cet.o" 5056 tmake_file="$tmake_file i386/t-linux i386/t-cet" 5057 ;; 5058 i[34567]86-*-kfreebsd*-gnu | x86_64-*-kfreebsd*-gnu) 5059 tmake_file="$tmake_file i386/t-kfreebsd" 5060 ;; 5061 i[34567]86-*-gnu*) 5062 tmake_file="$tmake_file i386/t-gnu" 5063 ;; 5064 i[34567]86-*-msdosdjgpp*) 5065 tmake_file="${tmake_file} i386/t-djgpp" 5066 ;; 5067 i[34567]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*) 5068 ;; 5069 i[34567]86-*-cygwin* | x86_64-*-cygwin*) 5070 ;; 5071 i[34567]86-*-mingw* | x86_64-*-mingw*) 5072 ;; 5073 i[34567]86-*-dragonfly* | x86_64-*-dragonfly*) 5074 ;; 5075 i[34567]86-*-freebsd*) 5076 ;; 5077 x86_64-*-freebsd*) 5078 tmake_file="${tmake_file} i386/t-freebsd64" 5079 ;; 5080 ia64*-*-linux*) 5081 ;; 5082 5083 mips*-*-*) 5084 if test x$gnu_ld = xyes 5085 then 5086 target_cpu_default2="MASK_SPLIT_ADDRESSES" 5087 fi 5088 case ${target} in 5089 mips*el-*-*) 5090 tm_defines="TARGET_ENDIAN_DEFAULT=0 $tm_defines" 5091 ;; 5092 esac 5093 if test x$with_arch != x; then 5094 default_mips_arch=$with_arch 5095 fi 5096 if test x$with_abi != x; then 5097 default_mips_abi=$with_abi 5098 fi 5099 case ${default_mips_arch} in 5100 mips1) tm_defines="$tm_defines MIPS_ISA_DEFAULT=1" ;; 5101 mips2) tm_defines="$tm_defines MIPS_ISA_DEFAULT=2" ;; 5102 mips3) tm_defines="$tm_defines MIPS_ISA_DEFAULT=3" ;; 5103 mips4) tm_defines="$tm_defines MIPS_ISA_DEFAULT=4" ;; 5104 mips32) tm_defines="$tm_defines MIPS_ISA_DEFAULT=32" ;; 5105 mips32r2) tm_defines="$tm_defines MIPS_ISA_DEFAULT=33" ;; 5106 mips32r6) tm_defines="$tm_defines MIPS_ISA_DEFAULT=37" ;; 5107 mips64) tm_defines="$tm_defines MIPS_ISA_DEFAULT=64" ;; 5108 mips64r2) tm_defines="$tm_defines MIPS_ISA_DEFAULT=65" ;; 5109 mips64r6) tm_defines="$tm_defines MIPS_ISA_DEFAULT=69" ;; 5110 esac 5111 case ${default_mips_abi} in 5112 32) tm_defines="$tm_defines MIPS_ABI_DEFAULT=ABI_32" ;; 5113 o64) tm_defines="$tm_defines MIPS_ABI_DEFAULT=ABI_O64" ;; 5114 n32) tm_defines="$tm_defines MIPS_ABI_DEFAULT=ABI_N32" ;; 5115 64) tm_defines="$tm_defines MIPS_ABI_DEFAULT=ABI_64" ;; 5116 eabi) tm_defines="$tm_defines MIPS_ABI_DEFAULT=ABI_EABI" ;; 5117 esac 5118 tmake_file="mips/t-mips $tmake_file" 5119 ;; 5120 5121 powerpc*-*-* | rs6000-*-*) 5122 # FIXME: The PowerPC port uses the value set at compile time, 5123 # although it's only cosmetic. 5124 if test "x$with_cpu" != x 5125 then 5126 target_cpu_default2="\\\"$with_cpu\\\"" 5127 fi 5128 out_file="${cpu_type}/${cpu_type}.c" 5129 c_target_objs="${c_target_objs} ${cpu_type}-c.o" 5130 cxx_target_objs="${cxx_target_objs} ${cpu_type}-c.o" 5131 d_target_objs="${d_target_objs} ${cpu_type}-d.o" 5132 tmake_file="${cpu_type}/t-${cpu_type} ${tmake_file}" 5133 ;; 5134 5135 sh[123456ble]*-*-* | sh-*-*) 5136 c_target_objs="${c_target_objs} sh-c.o" 5137 cxx_target_objs="${cxx_target_objs} sh-c.o" 5138 ;; 5139 5140 sparc*-*-*) 5141 # Some standard aliases. 5142 case x$with_cpu in 5143 xsparc) 5144 with_cpu=v7 5145 ;; 5146 xsparcv9 | xsparc64) 5147 with_cpu=v9 5148 ;; 5149 esac 5150 5151 if test x$with_tune = x ; then 5152 case ${target} in 5153 *-leon-*) 5154 with_tune=leon 5155 ;; 5156 *-leon[3-9]*) 5157 with_tune=leon3 5158 ;; 5159 esac 5160 fi 5161 5162 # The SPARC port checks this value at compile-time. 5163 target_cpu_default2="TARGET_CPU_$with_cpu" 5164 ;; 5165 5166 v850*-*-*) 5167 case "x$with_cpu" in 5168 x) 5169 ;; 5170 xv850e | xv850e1 | xv850e2 | xv850e2v3 | xv850e3v5) 5171 target_cpu_default2="TARGET_CPU_$with_cpu" 5172 ;; 5173 xv850es) 5174 target_cpu_default2="TARGET_CPU_v850e1" 5175 ;; 5176 esac 5177 ;; 5178 visium-*-*) 5179 target_cpu_default2="TARGET_CPU_$with_cpu" 5180 ;; 5181esac 5182 5183t= 5184all_defaults="abi cpu cpu_32 cpu_64 arch arch_32 arch_64 tune tune_32 tune_64 schedule float mode fpu nan fp_32 odd_spreg_32 divide llsc mips-plt synci tls lxc1-sxc1 madd4" 5185for option in $all_defaults 5186do 5187 eval "val=\$with_"`echo $option | sed s/-/_/g` 5188 if test -n "$val"; then 5189 case " $supported_defaults " in 5190 *" $option "*) 5191 ;; 5192 *) 5193 echo "This target does not support --with-$option." 2>&1 5194 echo "Valid --with options are: $supported_defaults" 2>&1 5195 exit 1 5196 ;; 5197 esac 5198 5199 if test "x$t" = x 5200 then 5201 t="{ \"$option\", \"$val\" }" 5202 else 5203 t="${t}, { \"$option\", \"$val\" }" 5204 fi 5205 fi 5206done 5207 5208if test "x$t" = x 5209then 5210 configure_default_options="{ { NULL, NULL} }" 5211else 5212 configure_default_options="{ ${t} }" 5213fi 5214 5215if test "$target_cpu_default2" != "" 5216then 5217 if test "$target_cpu_default" != "" 5218 then 5219 target_cpu_default="(${target_cpu_default}|${target_cpu_default2})" 5220 else 5221 target_cpu_default=$target_cpu_default2 5222 fi 5223fi 5224 5225case ${target} in 5226i[34567]86-*-* | x86_64-*-*) 5227 if test x$enable_as_accelerator = xyes; then 5228 extra_programs="mkoffload\$(exeext)" 5229 fi 5230 ;; 5231esac 5232