1*bf6039f0SWarner Losh#! /bin/sh 2*bf6039f0SWarner Losh# Configuration validation subroutine script. 3*bf6039f0SWarner Losh# Copyright 1992-2016 Free Software Foundation, Inc. 4*bf6039f0SWarner Losh 5*bf6039f0SWarner Loshtimestamp='2016-11-04' 6*bf6039f0SWarner Losh 7*bf6039f0SWarner Losh# This file is free software; you can redistribute it and/or modify it 8*bf6039f0SWarner Losh# under the terms of the GNU General Public License as published by 9*bf6039f0SWarner Losh# the Free Software Foundation; either version 3 of the License, or 10*bf6039f0SWarner Losh# (at your option) any later version. 11*bf6039f0SWarner Losh# 12*bf6039f0SWarner Losh# This program is distributed in the hope that it will be useful, but 13*bf6039f0SWarner Losh# WITHOUT ANY WARRANTY; without even the implied warranty of 14*bf6039f0SWarner Losh# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15*bf6039f0SWarner Losh# General Public License for more details. 16*bf6039f0SWarner Losh# 17*bf6039f0SWarner Losh# You should have received a copy of the GNU General Public License 18*bf6039f0SWarner Losh# along with this program; if not, see <http://www.gnu.org/licenses/>. 19*bf6039f0SWarner Losh# 20*bf6039f0SWarner Losh# As a special exception to the GNU General Public License, if you 21*bf6039f0SWarner Losh# distribute this file as part of a program that contains a 22*bf6039f0SWarner Losh# configuration script generated by Autoconf, you may include it under 23*bf6039f0SWarner Losh# the same distribution terms that you use for the rest of that 24*bf6039f0SWarner Losh# program. This Exception is an additional permission under section 7 25*bf6039f0SWarner Losh# of the GNU General Public License, version 3 ("GPLv3"). 26*bf6039f0SWarner Losh 27*bf6039f0SWarner Losh 28*bf6039f0SWarner Losh# Please send patches to <config-patches@gnu.org>. 29*bf6039f0SWarner Losh# 30*bf6039f0SWarner Losh# Configuration subroutine to validate and canonicalize a configuration type. 31*bf6039f0SWarner Losh# Supply the specified configuration type as an argument. 32*bf6039f0SWarner Losh# If it is invalid, we print an error message on stderr and exit with code 1. 33*bf6039f0SWarner Losh# Otherwise, we print the canonical config type on stdout and succeed. 34*bf6039f0SWarner Losh 35*bf6039f0SWarner Losh# You can get the latest version of this script from: 36*bf6039f0SWarner Losh# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub 37*bf6039f0SWarner Losh 38*bf6039f0SWarner Losh# This file is supposed to be the same for all GNU packages 39*bf6039f0SWarner Losh# and recognize all the CPU types, system types and aliases 40*bf6039f0SWarner Losh# that are meaningful with *any* GNU software. 41*bf6039f0SWarner Losh# Each package is responsible for reporting which valid configurations 42*bf6039f0SWarner Losh# it does not support. The user should be able to distinguish 43*bf6039f0SWarner Losh# a failure to support a valid configuration from a meaningless 44*bf6039f0SWarner Losh# configuration. 45*bf6039f0SWarner Losh 46*bf6039f0SWarner Losh# The goal of this file is to map all the various variations of a given 47*bf6039f0SWarner Losh# machine specification into a single specification in the form: 48*bf6039f0SWarner Losh# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM 49*bf6039f0SWarner Losh# or in some cases, the newer four-part form: 50*bf6039f0SWarner Losh# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM 51*bf6039f0SWarner Losh# It is wrong to echo any other type of specification. 52*bf6039f0SWarner Losh 53*bf6039f0SWarner Loshme=`echo "$0" | sed -e 's,.*/,,'` 54*bf6039f0SWarner Losh 55*bf6039f0SWarner Loshusage="\ 56*bf6039f0SWarner LoshUsage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS 57*bf6039f0SWarner Losh 58*bf6039f0SWarner LoshCanonicalize a configuration name. 59*bf6039f0SWarner Losh 60*bf6039f0SWarner LoshOperation modes: 61*bf6039f0SWarner Losh -h, --help print this help, then exit 62*bf6039f0SWarner Losh -t, --time-stamp print date of last modification, then exit 63*bf6039f0SWarner Losh -v, --version print version number, then exit 64*bf6039f0SWarner Losh 65*bf6039f0SWarner LoshReport bugs and patches to <config-patches@gnu.org>." 66*bf6039f0SWarner Losh 67*bf6039f0SWarner Loshversion="\ 68*bf6039f0SWarner LoshGNU config.sub ($timestamp) 69*bf6039f0SWarner Losh 70*bf6039f0SWarner LoshCopyright 1992-2016 Free Software Foundation, Inc. 71*bf6039f0SWarner Losh 72*bf6039f0SWarner LoshThis is free software; see the source for copying conditions. There is NO 73*bf6039f0SWarner Loshwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." 74*bf6039f0SWarner Losh 75*bf6039f0SWarner Loshhelp=" 76*bf6039f0SWarner LoshTry \`$me --help' for more information." 77*bf6039f0SWarner Losh 78*bf6039f0SWarner Losh# Parse command line 79*bf6039f0SWarner Loshwhile test $# -gt 0 ; do 80*bf6039f0SWarner Losh case $1 in 81*bf6039f0SWarner Losh --time-stamp | --time* | -t ) 82*bf6039f0SWarner Losh echo "$timestamp" ; exit ;; 83*bf6039f0SWarner Losh --version | -v ) 84*bf6039f0SWarner Losh echo "$version" ; exit ;; 85*bf6039f0SWarner Losh --help | --h* | -h ) 86*bf6039f0SWarner Losh echo "$usage"; exit ;; 87*bf6039f0SWarner Losh -- ) # Stop option processing 88*bf6039f0SWarner Losh shift; break ;; 89*bf6039f0SWarner Losh - ) # Use stdin as input. 90*bf6039f0SWarner Losh break ;; 91*bf6039f0SWarner Losh -* ) 92*bf6039f0SWarner Losh echo "$me: invalid option $1$help" 93*bf6039f0SWarner Losh exit 1 ;; 94*bf6039f0SWarner Losh 95*bf6039f0SWarner Losh *local*) 96*bf6039f0SWarner Losh # First pass through any local machine types. 97*bf6039f0SWarner Losh echo $1 98*bf6039f0SWarner Losh exit ;; 99*bf6039f0SWarner Losh 100*bf6039f0SWarner Losh * ) 101*bf6039f0SWarner Losh break ;; 102*bf6039f0SWarner Losh esac 103*bf6039f0SWarner Loshdone 104*bf6039f0SWarner Losh 105*bf6039f0SWarner Loshcase $# in 106*bf6039f0SWarner Losh 0) echo "$me: missing argument$help" >&2 107*bf6039f0SWarner Losh exit 1;; 108*bf6039f0SWarner Losh 1) ;; 109*bf6039f0SWarner Losh *) echo "$me: too many arguments$help" >&2 110*bf6039f0SWarner Losh exit 1;; 111*bf6039f0SWarner Loshesac 112*bf6039f0SWarner Losh 113*bf6039f0SWarner Losh# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). 114*bf6039f0SWarner Losh# Here we must recognize all the valid KERNEL-OS combinations. 115*bf6039f0SWarner Loshmaybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` 116*bf6039f0SWarner Loshcase $maybe_os in 117*bf6039f0SWarner Losh nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ 118*bf6039f0SWarner Losh linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ 119*bf6039f0SWarner Losh knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \ 120*bf6039f0SWarner Losh kopensolaris*-gnu* | cloudabi*-eabi* | \ 121*bf6039f0SWarner Losh storm-chaos* | os2-emx* | rtmk-nova*) 122*bf6039f0SWarner Losh os=-$maybe_os 123*bf6039f0SWarner Losh basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` 124*bf6039f0SWarner Losh ;; 125*bf6039f0SWarner Losh android-linux) 126*bf6039f0SWarner Losh os=-linux-android 127*bf6039f0SWarner Losh basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown 128*bf6039f0SWarner Losh ;; 129*bf6039f0SWarner Losh *) 130*bf6039f0SWarner Losh basic_machine=`echo $1 | sed 's/-[^-]*$//'` 131*bf6039f0SWarner Losh if [ $basic_machine != $1 ] 132*bf6039f0SWarner Losh then os=`echo $1 | sed 's/.*-/-/'` 133*bf6039f0SWarner Losh else os=; fi 134*bf6039f0SWarner Losh ;; 135*bf6039f0SWarner Loshesac 136*bf6039f0SWarner Losh 137*bf6039f0SWarner Losh### Let's recognize common machines as not being operating systems so 138*bf6039f0SWarner Losh### that things like config.sub decstation-3100 work. We also 139*bf6039f0SWarner Losh### recognize some manufacturers as not being operating systems, so we 140*bf6039f0SWarner Losh### can provide default operating systems below. 141*bf6039f0SWarner Loshcase $os in 142*bf6039f0SWarner Losh -sun*os*) 143*bf6039f0SWarner Losh # Prevent following clause from handling this invalid input. 144*bf6039f0SWarner Losh ;; 145*bf6039f0SWarner Losh -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ 146*bf6039f0SWarner Losh -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ 147*bf6039f0SWarner Losh -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ 148*bf6039f0SWarner Losh -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ 149*bf6039f0SWarner Losh -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ 150*bf6039f0SWarner Losh -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ 151*bf6039f0SWarner Losh -apple | -axis | -knuth | -cray | -microblaze*) 152*bf6039f0SWarner Losh os= 153*bf6039f0SWarner Losh basic_machine=$1 154*bf6039f0SWarner Losh ;; 155*bf6039f0SWarner Losh -bluegene*) 156*bf6039f0SWarner Losh os=-cnk 157*bf6039f0SWarner Losh ;; 158*bf6039f0SWarner Losh -sim | -cisco | -oki | -wec | -winbond) 159*bf6039f0SWarner Losh os= 160*bf6039f0SWarner Losh basic_machine=$1 161*bf6039f0SWarner Losh ;; 162*bf6039f0SWarner Losh -scout) 163*bf6039f0SWarner Losh ;; 164*bf6039f0SWarner Losh -wrs) 165*bf6039f0SWarner Losh os=-vxworks 166*bf6039f0SWarner Losh basic_machine=$1 167*bf6039f0SWarner Losh ;; 168*bf6039f0SWarner Losh -chorusos*) 169*bf6039f0SWarner Losh os=-chorusos 170*bf6039f0SWarner Losh basic_machine=$1 171*bf6039f0SWarner Losh ;; 172*bf6039f0SWarner Losh -chorusrdb) 173*bf6039f0SWarner Losh os=-chorusrdb 174*bf6039f0SWarner Losh basic_machine=$1 175*bf6039f0SWarner Losh ;; 176*bf6039f0SWarner Losh -hiux*) 177*bf6039f0SWarner Losh os=-hiuxwe2 178*bf6039f0SWarner Losh ;; 179*bf6039f0SWarner Losh -sco6) 180*bf6039f0SWarner Losh os=-sco5v6 181*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 182*bf6039f0SWarner Losh ;; 183*bf6039f0SWarner Losh -sco5) 184*bf6039f0SWarner Losh os=-sco3.2v5 185*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 186*bf6039f0SWarner Losh ;; 187*bf6039f0SWarner Losh -sco4) 188*bf6039f0SWarner Losh os=-sco3.2v4 189*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 190*bf6039f0SWarner Losh ;; 191*bf6039f0SWarner Losh -sco3.2.[4-9]*) 192*bf6039f0SWarner Losh os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` 193*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 194*bf6039f0SWarner Losh ;; 195*bf6039f0SWarner Losh -sco3.2v[4-9]*) 196*bf6039f0SWarner Losh # Don't forget version if it is 3.2v4 or newer. 197*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 198*bf6039f0SWarner Losh ;; 199*bf6039f0SWarner Losh -sco5v6*) 200*bf6039f0SWarner Losh # Don't forget version if it is 3.2v4 or newer. 201*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 202*bf6039f0SWarner Losh ;; 203*bf6039f0SWarner Losh -sco*) 204*bf6039f0SWarner Losh os=-sco3.2v2 205*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 206*bf6039f0SWarner Losh ;; 207*bf6039f0SWarner Losh -udk*) 208*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 209*bf6039f0SWarner Losh ;; 210*bf6039f0SWarner Losh -isc) 211*bf6039f0SWarner Losh os=-isc2.2 212*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 213*bf6039f0SWarner Losh ;; 214*bf6039f0SWarner Losh -clix*) 215*bf6039f0SWarner Losh basic_machine=clipper-intergraph 216*bf6039f0SWarner Losh ;; 217*bf6039f0SWarner Losh -isc*) 218*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` 219*bf6039f0SWarner Losh ;; 220*bf6039f0SWarner Losh -lynx*178) 221*bf6039f0SWarner Losh os=-lynxos178 222*bf6039f0SWarner Losh ;; 223*bf6039f0SWarner Losh -lynx*5) 224*bf6039f0SWarner Losh os=-lynxos5 225*bf6039f0SWarner Losh ;; 226*bf6039f0SWarner Losh -lynx*) 227*bf6039f0SWarner Losh os=-lynxos 228*bf6039f0SWarner Losh ;; 229*bf6039f0SWarner Losh -ptx*) 230*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` 231*bf6039f0SWarner Losh ;; 232*bf6039f0SWarner Losh -windowsnt*) 233*bf6039f0SWarner Losh os=`echo $os | sed -e 's/windowsnt/winnt/'` 234*bf6039f0SWarner Losh ;; 235*bf6039f0SWarner Losh -psos*) 236*bf6039f0SWarner Losh os=-psos 237*bf6039f0SWarner Losh ;; 238*bf6039f0SWarner Losh -mint | -mint[0-9]*) 239*bf6039f0SWarner Losh basic_machine=m68k-atari 240*bf6039f0SWarner Losh os=-mint 241*bf6039f0SWarner Losh ;; 242*bf6039f0SWarner Loshesac 243*bf6039f0SWarner Losh 244*bf6039f0SWarner Losh# Decode aliases for certain CPU-COMPANY combinations. 245*bf6039f0SWarner Loshcase $basic_machine in 246*bf6039f0SWarner Losh # Recognize the basic CPU types without company name. 247*bf6039f0SWarner Losh # Some are omitted here because they have special meanings below. 248*bf6039f0SWarner Losh 1750a | 580 \ 249*bf6039f0SWarner Losh | a29k \ 250*bf6039f0SWarner Losh | aarch64 | aarch64_be \ 251*bf6039f0SWarner Losh | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ 252*bf6039f0SWarner Losh | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ 253*bf6039f0SWarner Losh | am33_2.0 \ 254*bf6039f0SWarner Losh | arc | arceb \ 255*bf6039f0SWarner Losh | arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \ 256*bf6039f0SWarner Losh | avr | avr32 \ 257*bf6039f0SWarner Losh | ba \ 258*bf6039f0SWarner Losh | be32 | be64 \ 259*bf6039f0SWarner Losh | bfin \ 260*bf6039f0SWarner Losh | c4x | c8051 | clipper \ 261*bf6039f0SWarner Losh | d10v | d30v | dlx | dsp16xx \ 262*bf6039f0SWarner Losh | e2k | epiphany \ 263*bf6039f0SWarner Losh | fido | fr30 | frv | ft32 \ 264*bf6039f0SWarner Losh | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ 265*bf6039f0SWarner Losh | hexagon \ 266*bf6039f0SWarner Losh | i370 | i860 | i960 | ia64 \ 267*bf6039f0SWarner Losh | ip2k | iq2000 \ 268*bf6039f0SWarner Losh | k1om \ 269*bf6039f0SWarner Losh | le32 | le64 \ 270*bf6039f0SWarner Losh | lm32 \ 271*bf6039f0SWarner Losh | m32c | m32r | m32rle | m68000 | m68k | m88k \ 272*bf6039f0SWarner Losh | maxq | mb | microblaze | microblazeel | mcore | mep | metag \ 273*bf6039f0SWarner Losh | mips | mipsbe | mipseb | mipsel | mipsle \ 274*bf6039f0SWarner Losh | mips16 \ 275*bf6039f0SWarner Losh | mips64 | mips64el \ 276*bf6039f0SWarner Losh | mips64octeon | mips64octeonel \ 277*bf6039f0SWarner Losh | mips64orion | mips64orionel \ 278*bf6039f0SWarner Losh | mips64r5900 | mips64r5900el \ 279*bf6039f0SWarner Losh | mips64vr | mips64vrel \ 280*bf6039f0SWarner Losh | mips64vr4100 | mips64vr4100el \ 281*bf6039f0SWarner Losh | mips64vr4300 | mips64vr4300el \ 282*bf6039f0SWarner Losh | mips64vr5000 | mips64vr5000el \ 283*bf6039f0SWarner Losh | mips64vr5900 | mips64vr5900el \ 284*bf6039f0SWarner Losh | mipsisa32 | mipsisa32el \ 285*bf6039f0SWarner Losh | mipsisa32r2 | mipsisa32r2el \ 286*bf6039f0SWarner Losh | mipsisa32r6 | mipsisa32r6el \ 287*bf6039f0SWarner Losh | mipsisa64 | mipsisa64el \ 288*bf6039f0SWarner Losh | mipsisa64r2 | mipsisa64r2el \ 289*bf6039f0SWarner Losh | mipsisa64r6 | mipsisa64r6el \ 290*bf6039f0SWarner Losh | mipsisa64sb1 | mipsisa64sb1el \ 291*bf6039f0SWarner Losh | mipsisa64sr71k | mipsisa64sr71kel \ 292*bf6039f0SWarner Losh | mipsr5900 | mipsr5900el \ 293*bf6039f0SWarner Losh | mipstx39 | mipstx39el \ 294*bf6039f0SWarner Losh | mn10200 | mn10300 \ 295*bf6039f0SWarner Losh | moxie \ 296*bf6039f0SWarner Losh | mt \ 297*bf6039f0SWarner Losh | msp430 \ 298*bf6039f0SWarner Losh | nds32 | nds32le | nds32be \ 299*bf6039f0SWarner Losh | nios | nios2 | nios2eb | nios2el \ 300*bf6039f0SWarner Losh | ns16k | ns32k \ 301*bf6039f0SWarner Losh | open8 | or1k | or1knd | or32 \ 302*bf6039f0SWarner Losh | pdp10 | pdp11 | pj | pjl \ 303*bf6039f0SWarner Losh | powerpc | powerpc64 | powerpc64le | powerpcle \ 304*bf6039f0SWarner Losh | pru \ 305*bf6039f0SWarner Losh | pyramid \ 306*bf6039f0SWarner Losh | riscv32 | riscv64 \ 307*bf6039f0SWarner Losh | rl78 | rx \ 308*bf6039f0SWarner Losh | score \ 309*bf6039f0SWarner Losh | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[234]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ 310*bf6039f0SWarner Losh | sh64 | sh64le \ 311*bf6039f0SWarner Losh | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ 312*bf6039f0SWarner Losh | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ 313*bf6039f0SWarner Losh | spu \ 314*bf6039f0SWarner Losh | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ 315*bf6039f0SWarner Losh | ubicom32 \ 316*bf6039f0SWarner Losh | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \ 317*bf6039f0SWarner Losh | visium \ 318*bf6039f0SWarner Losh | we32k \ 319*bf6039f0SWarner Losh | x86 | xc16x | xstormy16 | xtensa \ 320*bf6039f0SWarner Losh | z8k | z80) 321*bf6039f0SWarner Losh basic_machine=$basic_machine-unknown 322*bf6039f0SWarner Losh ;; 323*bf6039f0SWarner Losh c54x) 324*bf6039f0SWarner Losh basic_machine=tic54x-unknown 325*bf6039f0SWarner Losh ;; 326*bf6039f0SWarner Losh c55x) 327*bf6039f0SWarner Losh basic_machine=tic55x-unknown 328*bf6039f0SWarner Losh ;; 329*bf6039f0SWarner Losh c6x) 330*bf6039f0SWarner Losh basic_machine=tic6x-unknown 331*bf6039f0SWarner Losh ;; 332*bf6039f0SWarner Losh leon|leon[3-9]) 333*bf6039f0SWarner Losh basic_machine=sparc-$basic_machine 334*bf6039f0SWarner Losh ;; 335*bf6039f0SWarner Losh m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip) 336*bf6039f0SWarner Losh basic_machine=$basic_machine-unknown 337*bf6039f0SWarner Losh os=-none 338*bf6039f0SWarner Losh ;; 339*bf6039f0SWarner Losh m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) 340*bf6039f0SWarner Losh ;; 341*bf6039f0SWarner Losh ms1) 342*bf6039f0SWarner Losh basic_machine=mt-unknown 343*bf6039f0SWarner Losh ;; 344*bf6039f0SWarner Losh 345*bf6039f0SWarner Losh strongarm | thumb | xscale) 346*bf6039f0SWarner Losh basic_machine=arm-unknown 347*bf6039f0SWarner Losh ;; 348*bf6039f0SWarner Losh xgate) 349*bf6039f0SWarner Losh basic_machine=$basic_machine-unknown 350*bf6039f0SWarner Losh os=-none 351*bf6039f0SWarner Losh ;; 352*bf6039f0SWarner Losh xscaleeb) 353*bf6039f0SWarner Losh basic_machine=armeb-unknown 354*bf6039f0SWarner Losh ;; 355*bf6039f0SWarner Losh 356*bf6039f0SWarner Losh xscaleel) 357*bf6039f0SWarner Losh basic_machine=armel-unknown 358*bf6039f0SWarner Losh ;; 359*bf6039f0SWarner Losh 360*bf6039f0SWarner Losh # We use `pc' rather than `unknown' 361*bf6039f0SWarner Losh # because (1) that's what they normally are, and 362*bf6039f0SWarner Losh # (2) the word "unknown" tends to confuse beginning users. 363*bf6039f0SWarner Losh i*86 | x86_64) 364*bf6039f0SWarner Losh basic_machine=$basic_machine-pc 365*bf6039f0SWarner Losh ;; 366*bf6039f0SWarner Losh # Object if more than one company name word. 367*bf6039f0SWarner Losh *-*-*) 368*bf6039f0SWarner Losh echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 369*bf6039f0SWarner Losh exit 1 370*bf6039f0SWarner Losh ;; 371*bf6039f0SWarner Losh # Recognize the basic CPU types with company name. 372*bf6039f0SWarner Losh 580-* \ 373*bf6039f0SWarner Losh | a29k-* \ 374*bf6039f0SWarner Losh | aarch64-* | aarch64_be-* \ 375*bf6039f0SWarner Losh | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ 376*bf6039f0SWarner Losh | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ 377*bf6039f0SWarner Losh | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ 378*bf6039f0SWarner Losh | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ 379*bf6039f0SWarner Losh | avr-* | avr32-* \ 380*bf6039f0SWarner Losh | ba-* \ 381*bf6039f0SWarner Losh | be32-* | be64-* \ 382*bf6039f0SWarner Losh | bfin-* | bs2000-* \ 383*bf6039f0SWarner Losh | c[123]* | c30-* | [cjt]90-* | c4x-* \ 384*bf6039f0SWarner Losh | c8051-* | clipper-* | craynv-* | cydra-* \ 385*bf6039f0SWarner Losh | d10v-* | d30v-* | dlx-* \ 386*bf6039f0SWarner Losh | e2k-* | elxsi-* \ 387*bf6039f0SWarner Losh | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ 388*bf6039f0SWarner Losh | h8300-* | h8500-* \ 389*bf6039f0SWarner Losh | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ 390*bf6039f0SWarner Losh | hexagon-* \ 391*bf6039f0SWarner Losh | i*86-* | i860-* | i960-* | ia64-* \ 392*bf6039f0SWarner Losh | ip2k-* | iq2000-* \ 393*bf6039f0SWarner Losh | k1om-* \ 394*bf6039f0SWarner Losh | le32-* | le64-* \ 395*bf6039f0SWarner Losh | lm32-* \ 396*bf6039f0SWarner Losh | m32c-* | m32r-* | m32rle-* \ 397*bf6039f0SWarner Losh | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ 398*bf6039f0SWarner Losh | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ 399*bf6039f0SWarner Losh | microblaze-* | microblazeel-* \ 400*bf6039f0SWarner Losh | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ 401*bf6039f0SWarner Losh | mips16-* \ 402*bf6039f0SWarner Losh | mips64-* | mips64el-* \ 403*bf6039f0SWarner Losh | mips64octeon-* | mips64octeonel-* \ 404*bf6039f0SWarner Losh | mips64orion-* | mips64orionel-* \ 405*bf6039f0SWarner Losh | mips64r5900-* | mips64r5900el-* \ 406*bf6039f0SWarner Losh | mips64vr-* | mips64vrel-* \ 407*bf6039f0SWarner Losh | mips64vr4100-* | mips64vr4100el-* \ 408*bf6039f0SWarner Losh | mips64vr4300-* | mips64vr4300el-* \ 409*bf6039f0SWarner Losh | mips64vr5000-* | mips64vr5000el-* \ 410*bf6039f0SWarner Losh | mips64vr5900-* | mips64vr5900el-* \ 411*bf6039f0SWarner Losh | mipsisa32-* | mipsisa32el-* \ 412*bf6039f0SWarner Losh | mipsisa32r2-* | mipsisa32r2el-* \ 413*bf6039f0SWarner Losh | mipsisa32r6-* | mipsisa32r6el-* \ 414*bf6039f0SWarner Losh | mipsisa64-* | mipsisa64el-* \ 415*bf6039f0SWarner Losh | mipsisa64r2-* | mipsisa64r2el-* \ 416*bf6039f0SWarner Losh | mipsisa64r6-* | mipsisa64r6el-* \ 417*bf6039f0SWarner Losh | mipsisa64sb1-* | mipsisa64sb1el-* \ 418*bf6039f0SWarner Losh | mipsisa64sr71k-* | mipsisa64sr71kel-* \ 419*bf6039f0SWarner Losh | mipsr5900-* | mipsr5900el-* \ 420*bf6039f0SWarner Losh | mipstx39-* | mipstx39el-* \ 421*bf6039f0SWarner Losh | mmix-* \ 422*bf6039f0SWarner Losh | mt-* \ 423*bf6039f0SWarner Losh | msp430-* \ 424*bf6039f0SWarner Losh | nds32-* | nds32le-* | nds32be-* \ 425*bf6039f0SWarner Losh | nios-* | nios2-* | nios2eb-* | nios2el-* \ 426*bf6039f0SWarner Losh | none-* | np1-* | ns16k-* | ns32k-* \ 427*bf6039f0SWarner Losh | open8-* \ 428*bf6039f0SWarner Losh | or1k*-* \ 429*bf6039f0SWarner Losh | orion-* \ 430*bf6039f0SWarner Losh | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ 431*bf6039f0SWarner Losh | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ 432*bf6039f0SWarner Losh | pru-* \ 433*bf6039f0SWarner Losh | pyramid-* \ 434*bf6039f0SWarner Losh | riscv32-* | riscv64-* \ 435*bf6039f0SWarner Losh | rl78-* | romp-* | rs6000-* | rx-* \ 436*bf6039f0SWarner Losh | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ 437*bf6039f0SWarner Losh | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ 438*bf6039f0SWarner Losh | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ 439*bf6039f0SWarner Losh | sparclite-* \ 440*bf6039f0SWarner Losh | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \ 441*bf6039f0SWarner Losh | tahoe-* \ 442*bf6039f0SWarner Losh | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ 443*bf6039f0SWarner Losh | tile*-* \ 444*bf6039f0SWarner Losh | tron-* \ 445*bf6039f0SWarner Losh | ubicom32-* \ 446*bf6039f0SWarner Losh | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ 447*bf6039f0SWarner Losh | vax-* \ 448*bf6039f0SWarner Losh | visium-* \ 449*bf6039f0SWarner Losh | we32k-* \ 450*bf6039f0SWarner Losh | x86-* | x86_64-* | xc16x-* | xps100-* \ 451*bf6039f0SWarner Losh | xstormy16-* | xtensa*-* \ 452*bf6039f0SWarner Losh | ymp-* \ 453*bf6039f0SWarner Losh | z8k-* | z80-*) 454*bf6039f0SWarner Losh ;; 455*bf6039f0SWarner Losh # Recognize the basic CPU types without company name, with glob match. 456*bf6039f0SWarner Losh xtensa*) 457*bf6039f0SWarner Losh basic_machine=$basic_machine-unknown 458*bf6039f0SWarner Losh ;; 459*bf6039f0SWarner Losh # Recognize the various machine names and aliases which stand 460*bf6039f0SWarner Losh # for a CPU type and a company and sometimes even an OS. 461*bf6039f0SWarner Losh 386bsd) 462*bf6039f0SWarner Losh basic_machine=i386-unknown 463*bf6039f0SWarner Losh os=-bsd 464*bf6039f0SWarner Losh ;; 465*bf6039f0SWarner Losh 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) 466*bf6039f0SWarner Losh basic_machine=m68000-att 467*bf6039f0SWarner Losh ;; 468*bf6039f0SWarner Losh 3b*) 469*bf6039f0SWarner Losh basic_machine=we32k-att 470*bf6039f0SWarner Losh ;; 471*bf6039f0SWarner Losh a29khif) 472*bf6039f0SWarner Losh basic_machine=a29k-amd 473*bf6039f0SWarner Losh os=-udi 474*bf6039f0SWarner Losh ;; 475*bf6039f0SWarner Losh abacus) 476*bf6039f0SWarner Losh basic_machine=abacus-unknown 477*bf6039f0SWarner Losh ;; 478*bf6039f0SWarner Losh adobe68k) 479*bf6039f0SWarner Losh basic_machine=m68010-adobe 480*bf6039f0SWarner Losh os=-scout 481*bf6039f0SWarner Losh ;; 482*bf6039f0SWarner Losh alliant | fx80) 483*bf6039f0SWarner Losh basic_machine=fx80-alliant 484*bf6039f0SWarner Losh ;; 485*bf6039f0SWarner Losh altos | altos3068) 486*bf6039f0SWarner Losh basic_machine=m68k-altos 487*bf6039f0SWarner Losh ;; 488*bf6039f0SWarner Losh am29k) 489*bf6039f0SWarner Losh basic_machine=a29k-none 490*bf6039f0SWarner Losh os=-bsd 491*bf6039f0SWarner Losh ;; 492*bf6039f0SWarner Losh amd64) 493*bf6039f0SWarner Losh basic_machine=x86_64-pc 494*bf6039f0SWarner Losh ;; 495*bf6039f0SWarner Losh amd64-*) 496*bf6039f0SWarner Losh basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` 497*bf6039f0SWarner Losh ;; 498*bf6039f0SWarner Losh amdahl) 499*bf6039f0SWarner Losh basic_machine=580-amdahl 500*bf6039f0SWarner Losh os=-sysv 501*bf6039f0SWarner Losh ;; 502*bf6039f0SWarner Losh amiga | amiga-*) 503*bf6039f0SWarner Losh basic_machine=m68k-unknown 504*bf6039f0SWarner Losh ;; 505*bf6039f0SWarner Losh amigaos | amigados) 506*bf6039f0SWarner Losh basic_machine=m68k-unknown 507*bf6039f0SWarner Losh os=-amigaos 508*bf6039f0SWarner Losh ;; 509*bf6039f0SWarner Losh amigaunix | amix) 510*bf6039f0SWarner Losh basic_machine=m68k-unknown 511*bf6039f0SWarner Losh os=-sysv4 512*bf6039f0SWarner Losh ;; 513*bf6039f0SWarner Losh apollo68) 514*bf6039f0SWarner Losh basic_machine=m68k-apollo 515*bf6039f0SWarner Losh os=-sysv 516*bf6039f0SWarner Losh ;; 517*bf6039f0SWarner Losh apollo68bsd) 518*bf6039f0SWarner Losh basic_machine=m68k-apollo 519*bf6039f0SWarner Losh os=-bsd 520*bf6039f0SWarner Losh ;; 521*bf6039f0SWarner Losh aros) 522*bf6039f0SWarner Losh basic_machine=i386-pc 523*bf6039f0SWarner Losh os=-aros 524*bf6039f0SWarner Losh ;; 525*bf6039f0SWarner Losh asmjs) 526*bf6039f0SWarner Losh basic_machine=asmjs-unknown 527*bf6039f0SWarner Losh ;; 528*bf6039f0SWarner Losh aux) 529*bf6039f0SWarner Losh basic_machine=m68k-apple 530*bf6039f0SWarner Losh os=-aux 531*bf6039f0SWarner Losh ;; 532*bf6039f0SWarner Losh balance) 533*bf6039f0SWarner Losh basic_machine=ns32k-sequent 534*bf6039f0SWarner Losh os=-dynix 535*bf6039f0SWarner Losh ;; 536*bf6039f0SWarner Losh blackfin) 537*bf6039f0SWarner Losh basic_machine=bfin-unknown 538*bf6039f0SWarner Losh os=-linux 539*bf6039f0SWarner Losh ;; 540*bf6039f0SWarner Losh blackfin-*) 541*bf6039f0SWarner Losh basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` 542*bf6039f0SWarner Losh os=-linux 543*bf6039f0SWarner Losh ;; 544*bf6039f0SWarner Losh bluegene*) 545*bf6039f0SWarner Losh basic_machine=powerpc-ibm 546*bf6039f0SWarner Losh os=-cnk 547*bf6039f0SWarner Losh ;; 548*bf6039f0SWarner Losh c54x-*) 549*bf6039f0SWarner Losh basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` 550*bf6039f0SWarner Losh ;; 551*bf6039f0SWarner Losh c55x-*) 552*bf6039f0SWarner Losh basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` 553*bf6039f0SWarner Losh ;; 554*bf6039f0SWarner Losh c6x-*) 555*bf6039f0SWarner Losh basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` 556*bf6039f0SWarner Losh ;; 557*bf6039f0SWarner Losh c90) 558*bf6039f0SWarner Losh basic_machine=c90-cray 559*bf6039f0SWarner Losh os=-unicos 560*bf6039f0SWarner Losh ;; 561*bf6039f0SWarner Losh cegcc) 562*bf6039f0SWarner Losh basic_machine=arm-unknown 563*bf6039f0SWarner Losh os=-cegcc 564*bf6039f0SWarner Losh ;; 565*bf6039f0SWarner Losh convex-c1) 566*bf6039f0SWarner Losh basic_machine=c1-convex 567*bf6039f0SWarner Losh os=-bsd 568*bf6039f0SWarner Losh ;; 569*bf6039f0SWarner Losh convex-c2) 570*bf6039f0SWarner Losh basic_machine=c2-convex 571*bf6039f0SWarner Losh os=-bsd 572*bf6039f0SWarner Losh ;; 573*bf6039f0SWarner Losh convex-c32) 574*bf6039f0SWarner Losh basic_machine=c32-convex 575*bf6039f0SWarner Losh os=-bsd 576*bf6039f0SWarner Losh ;; 577*bf6039f0SWarner Losh convex-c34) 578*bf6039f0SWarner Losh basic_machine=c34-convex 579*bf6039f0SWarner Losh os=-bsd 580*bf6039f0SWarner Losh ;; 581*bf6039f0SWarner Losh convex-c38) 582*bf6039f0SWarner Losh basic_machine=c38-convex 583*bf6039f0SWarner Losh os=-bsd 584*bf6039f0SWarner Losh ;; 585*bf6039f0SWarner Losh cray | j90) 586*bf6039f0SWarner Losh basic_machine=j90-cray 587*bf6039f0SWarner Losh os=-unicos 588*bf6039f0SWarner Losh ;; 589*bf6039f0SWarner Losh craynv) 590*bf6039f0SWarner Losh basic_machine=craynv-cray 591*bf6039f0SWarner Losh os=-unicosmp 592*bf6039f0SWarner Losh ;; 593*bf6039f0SWarner Losh cr16 | cr16-*) 594*bf6039f0SWarner Losh basic_machine=cr16-unknown 595*bf6039f0SWarner Losh os=-elf 596*bf6039f0SWarner Losh ;; 597*bf6039f0SWarner Losh crds | unos) 598*bf6039f0SWarner Losh basic_machine=m68k-crds 599*bf6039f0SWarner Losh ;; 600*bf6039f0SWarner Losh crisv32 | crisv32-* | etraxfs*) 601*bf6039f0SWarner Losh basic_machine=crisv32-axis 602*bf6039f0SWarner Losh ;; 603*bf6039f0SWarner Losh cris | cris-* | etrax*) 604*bf6039f0SWarner Losh basic_machine=cris-axis 605*bf6039f0SWarner Losh ;; 606*bf6039f0SWarner Losh crx) 607*bf6039f0SWarner Losh basic_machine=crx-unknown 608*bf6039f0SWarner Losh os=-elf 609*bf6039f0SWarner Losh ;; 610*bf6039f0SWarner Losh da30 | da30-*) 611*bf6039f0SWarner Losh basic_machine=m68k-da30 612*bf6039f0SWarner Losh ;; 613*bf6039f0SWarner Losh decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) 614*bf6039f0SWarner Losh basic_machine=mips-dec 615*bf6039f0SWarner Losh ;; 616*bf6039f0SWarner Losh decsystem10* | dec10*) 617*bf6039f0SWarner Losh basic_machine=pdp10-dec 618*bf6039f0SWarner Losh os=-tops10 619*bf6039f0SWarner Losh ;; 620*bf6039f0SWarner Losh decsystem20* | dec20*) 621*bf6039f0SWarner Losh basic_machine=pdp10-dec 622*bf6039f0SWarner Losh os=-tops20 623*bf6039f0SWarner Losh ;; 624*bf6039f0SWarner Losh delta | 3300 | motorola-3300 | motorola-delta \ 625*bf6039f0SWarner Losh | 3300-motorola | delta-motorola) 626*bf6039f0SWarner Losh basic_machine=m68k-motorola 627*bf6039f0SWarner Losh ;; 628*bf6039f0SWarner Losh delta88) 629*bf6039f0SWarner Losh basic_machine=m88k-motorola 630*bf6039f0SWarner Losh os=-sysv3 631*bf6039f0SWarner Losh ;; 632*bf6039f0SWarner Losh dicos) 633*bf6039f0SWarner Losh basic_machine=i686-pc 634*bf6039f0SWarner Losh os=-dicos 635*bf6039f0SWarner Losh ;; 636*bf6039f0SWarner Losh djgpp) 637*bf6039f0SWarner Losh basic_machine=i586-pc 638*bf6039f0SWarner Losh os=-msdosdjgpp 639*bf6039f0SWarner Losh ;; 640*bf6039f0SWarner Losh dpx20 | dpx20-*) 641*bf6039f0SWarner Losh basic_machine=rs6000-bull 642*bf6039f0SWarner Losh os=-bosx 643*bf6039f0SWarner Losh ;; 644*bf6039f0SWarner Losh dpx2* | dpx2*-bull) 645*bf6039f0SWarner Losh basic_machine=m68k-bull 646*bf6039f0SWarner Losh os=-sysv3 647*bf6039f0SWarner Losh ;; 648*bf6039f0SWarner Losh e500v[12]) 649*bf6039f0SWarner Losh basic_machine=powerpc-unknown 650*bf6039f0SWarner Losh os=$os"spe" 651*bf6039f0SWarner Losh ;; 652*bf6039f0SWarner Losh e500v[12]-*) 653*bf6039f0SWarner Losh basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` 654*bf6039f0SWarner Losh os=$os"spe" 655*bf6039f0SWarner Losh ;; 656*bf6039f0SWarner Losh ebmon29k) 657*bf6039f0SWarner Losh basic_machine=a29k-amd 658*bf6039f0SWarner Losh os=-ebmon 659*bf6039f0SWarner Losh ;; 660*bf6039f0SWarner Losh elxsi) 661*bf6039f0SWarner Losh basic_machine=elxsi-elxsi 662*bf6039f0SWarner Losh os=-bsd 663*bf6039f0SWarner Losh ;; 664*bf6039f0SWarner Losh encore | umax | mmax) 665*bf6039f0SWarner Losh basic_machine=ns32k-encore 666*bf6039f0SWarner Losh ;; 667*bf6039f0SWarner Losh es1800 | OSE68k | ose68k | ose | OSE) 668*bf6039f0SWarner Losh basic_machine=m68k-ericsson 669*bf6039f0SWarner Losh os=-ose 670*bf6039f0SWarner Losh ;; 671*bf6039f0SWarner Losh fx2800) 672*bf6039f0SWarner Losh basic_machine=i860-alliant 673*bf6039f0SWarner Losh ;; 674*bf6039f0SWarner Losh genix) 675*bf6039f0SWarner Losh basic_machine=ns32k-ns 676*bf6039f0SWarner Losh ;; 677*bf6039f0SWarner Losh gmicro) 678*bf6039f0SWarner Losh basic_machine=tron-gmicro 679*bf6039f0SWarner Losh os=-sysv 680*bf6039f0SWarner Losh ;; 681*bf6039f0SWarner Losh go32) 682*bf6039f0SWarner Losh basic_machine=i386-pc 683*bf6039f0SWarner Losh os=-go32 684*bf6039f0SWarner Losh ;; 685*bf6039f0SWarner Losh h3050r* | hiux*) 686*bf6039f0SWarner Losh basic_machine=hppa1.1-hitachi 687*bf6039f0SWarner Losh os=-hiuxwe2 688*bf6039f0SWarner Losh ;; 689*bf6039f0SWarner Losh h8300hms) 690*bf6039f0SWarner Losh basic_machine=h8300-hitachi 691*bf6039f0SWarner Losh os=-hms 692*bf6039f0SWarner Losh ;; 693*bf6039f0SWarner Losh h8300xray) 694*bf6039f0SWarner Losh basic_machine=h8300-hitachi 695*bf6039f0SWarner Losh os=-xray 696*bf6039f0SWarner Losh ;; 697*bf6039f0SWarner Losh h8500hms) 698*bf6039f0SWarner Losh basic_machine=h8500-hitachi 699*bf6039f0SWarner Losh os=-hms 700*bf6039f0SWarner Losh ;; 701*bf6039f0SWarner Losh harris) 702*bf6039f0SWarner Losh basic_machine=m88k-harris 703*bf6039f0SWarner Losh os=-sysv3 704*bf6039f0SWarner Losh ;; 705*bf6039f0SWarner Losh hp300-*) 706*bf6039f0SWarner Losh basic_machine=m68k-hp 707*bf6039f0SWarner Losh ;; 708*bf6039f0SWarner Losh hp300bsd) 709*bf6039f0SWarner Losh basic_machine=m68k-hp 710*bf6039f0SWarner Losh os=-bsd 711*bf6039f0SWarner Losh ;; 712*bf6039f0SWarner Losh hp300hpux) 713*bf6039f0SWarner Losh basic_machine=m68k-hp 714*bf6039f0SWarner Losh os=-hpux 715*bf6039f0SWarner Losh ;; 716*bf6039f0SWarner Losh hp3k9[0-9][0-9] | hp9[0-9][0-9]) 717*bf6039f0SWarner Losh basic_machine=hppa1.0-hp 718*bf6039f0SWarner Losh ;; 719*bf6039f0SWarner Losh hp9k2[0-9][0-9] | hp9k31[0-9]) 720*bf6039f0SWarner Losh basic_machine=m68000-hp 721*bf6039f0SWarner Losh ;; 722*bf6039f0SWarner Losh hp9k3[2-9][0-9]) 723*bf6039f0SWarner Losh basic_machine=m68k-hp 724*bf6039f0SWarner Losh ;; 725*bf6039f0SWarner Losh hp9k6[0-9][0-9] | hp6[0-9][0-9]) 726*bf6039f0SWarner Losh basic_machine=hppa1.0-hp 727*bf6039f0SWarner Losh ;; 728*bf6039f0SWarner Losh hp9k7[0-79][0-9] | hp7[0-79][0-9]) 729*bf6039f0SWarner Losh basic_machine=hppa1.1-hp 730*bf6039f0SWarner Losh ;; 731*bf6039f0SWarner Losh hp9k78[0-9] | hp78[0-9]) 732*bf6039f0SWarner Losh # FIXME: really hppa2.0-hp 733*bf6039f0SWarner Losh basic_machine=hppa1.1-hp 734*bf6039f0SWarner Losh ;; 735*bf6039f0SWarner Losh hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) 736*bf6039f0SWarner Losh # FIXME: really hppa2.0-hp 737*bf6039f0SWarner Losh basic_machine=hppa1.1-hp 738*bf6039f0SWarner Losh ;; 739*bf6039f0SWarner Losh hp9k8[0-9][13679] | hp8[0-9][13679]) 740*bf6039f0SWarner Losh basic_machine=hppa1.1-hp 741*bf6039f0SWarner Losh ;; 742*bf6039f0SWarner Losh hp9k8[0-9][0-9] | hp8[0-9][0-9]) 743*bf6039f0SWarner Losh basic_machine=hppa1.0-hp 744*bf6039f0SWarner Losh ;; 745*bf6039f0SWarner Losh hppa-next) 746*bf6039f0SWarner Losh os=-nextstep3 747*bf6039f0SWarner Losh ;; 748*bf6039f0SWarner Losh hppaosf) 749*bf6039f0SWarner Losh basic_machine=hppa1.1-hp 750*bf6039f0SWarner Losh os=-osf 751*bf6039f0SWarner Losh ;; 752*bf6039f0SWarner Losh hppro) 753*bf6039f0SWarner Losh basic_machine=hppa1.1-hp 754*bf6039f0SWarner Losh os=-proelf 755*bf6039f0SWarner Losh ;; 756*bf6039f0SWarner Losh i370-ibm* | ibm*) 757*bf6039f0SWarner Losh basic_machine=i370-ibm 758*bf6039f0SWarner Losh ;; 759*bf6039f0SWarner Losh i*86v32) 760*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` 761*bf6039f0SWarner Losh os=-sysv32 762*bf6039f0SWarner Losh ;; 763*bf6039f0SWarner Losh i*86v4*) 764*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` 765*bf6039f0SWarner Losh os=-sysv4 766*bf6039f0SWarner Losh ;; 767*bf6039f0SWarner Losh i*86v) 768*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` 769*bf6039f0SWarner Losh os=-sysv 770*bf6039f0SWarner Losh ;; 771*bf6039f0SWarner Losh i*86sol2) 772*bf6039f0SWarner Losh basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` 773*bf6039f0SWarner Losh os=-solaris2 774*bf6039f0SWarner Losh ;; 775*bf6039f0SWarner Losh i386mach) 776*bf6039f0SWarner Losh basic_machine=i386-mach 777*bf6039f0SWarner Losh os=-mach 778*bf6039f0SWarner Losh ;; 779*bf6039f0SWarner Losh i386-vsta | vsta) 780*bf6039f0SWarner Losh basic_machine=i386-unknown 781*bf6039f0SWarner Losh os=-vsta 782*bf6039f0SWarner Losh ;; 783*bf6039f0SWarner Losh iris | iris4d) 784*bf6039f0SWarner Losh basic_machine=mips-sgi 785*bf6039f0SWarner Losh case $os in 786*bf6039f0SWarner Losh -irix*) 787*bf6039f0SWarner Losh ;; 788*bf6039f0SWarner Losh *) 789*bf6039f0SWarner Losh os=-irix4 790*bf6039f0SWarner Losh ;; 791*bf6039f0SWarner Losh esac 792*bf6039f0SWarner Losh ;; 793*bf6039f0SWarner Losh isi68 | isi) 794*bf6039f0SWarner Losh basic_machine=m68k-isi 795*bf6039f0SWarner Losh os=-sysv 796*bf6039f0SWarner Losh ;; 797*bf6039f0SWarner Losh leon-*|leon[3-9]-*) 798*bf6039f0SWarner Losh basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'` 799*bf6039f0SWarner Losh ;; 800*bf6039f0SWarner Losh m68knommu) 801*bf6039f0SWarner Losh basic_machine=m68k-unknown 802*bf6039f0SWarner Losh os=-linux 803*bf6039f0SWarner Losh ;; 804*bf6039f0SWarner Losh m68knommu-*) 805*bf6039f0SWarner Losh basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` 806*bf6039f0SWarner Losh os=-linux 807*bf6039f0SWarner Losh ;; 808*bf6039f0SWarner Losh m88k-omron*) 809*bf6039f0SWarner Losh basic_machine=m88k-omron 810*bf6039f0SWarner Losh ;; 811*bf6039f0SWarner Losh magnum | m3230) 812*bf6039f0SWarner Losh basic_machine=mips-mips 813*bf6039f0SWarner Losh os=-sysv 814*bf6039f0SWarner Losh ;; 815*bf6039f0SWarner Losh merlin) 816*bf6039f0SWarner Losh basic_machine=ns32k-utek 817*bf6039f0SWarner Losh os=-sysv 818*bf6039f0SWarner Losh ;; 819*bf6039f0SWarner Losh microblaze*) 820*bf6039f0SWarner Losh basic_machine=microblaze-xilinx 821*bf6039f0SWarner Losh ;; 822*bf6039f0SWarner Losh mingw64) 823*bf6039f0SWarner Losh basic_machine=x86_64-pc 824*bf6039f0SWarner Losh os=-mingw64 825*bf6039f0SWarner Losh ;; 826*bf6039f0SWarner Losh mingw32) 827*bf6039f0SWarner Losh basic_machine=i686-pc 828*bf6039f0SWarner Losh os=-mingw32 829*bf6039f0SWarner Losh ;; 830*bf6039f0SWarner Losh mingw32ce) 831*bf6039f0SWarner Losh basic_machine=arm-unknown 832*bf6039f0SWarner Losh os=-mingw32ce 833*bf6039f0SWarner Losh ;; 834*bf6039f0SWarner Losh miniframe) 835*bf6039f0SWarner Losh basic_machine=m68000-convergent 836*bf6039f0SWarner Losh ;; 837*bf6039f0SWarner Losh *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) 838*bf6039f0SWarner Losh basic_machine=m68k-atari 839*bf6039f0SWarner Losh os=-mint 840*bf6039f0SWarner Losh ;; 841*bf6039f0SWarner Losh mips3*-*) 842*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` 843*bf6039f0SWarner Losh ;; 844*bf6039f0SWarner Losh mips3*) 845*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown 846*bf6039f0SWarner Losh ;; 847*bf6039f0SWarner Losh monitor) 848*bf6039f0SWarner Losh basic_machine=m68k-rom68k 849*bf6039f0SWarner Losh os=-coff 850*bf6039f0SWarner Losh ;; 851*bf6039f0SWarner Losh morphos) 852*bf6039f0SWarner Losh basic_machine=powerpc-unknown 853*bf6039f0SWarner Losh os=-morphos 854*bf6039f0SWarner Losh ;; 855*bf6039f0SWarner Losh moxiebox) 856*bf6039f0SWarner Losh basic_machine=moxie-unknown 857*bf6039f0SWarner Losh os=-moxiebox 858*bf6039f0SWarner Losh ;; 859*bf6039f0SWarner Losh msdos) 860*bf6039f0SWarner Losh basic_machine=i386-pc 861*bf6039f0SWarner Losh os=-msdos 862*bf6039f0SWarner Losh ;; 863*bf6039f0SWarner Losh ms1-*) 864*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` 865*bf6039f0SWarner Losh ;; 866*bf6039f0SWarner Losh msys) 867*bf6039f0SWarner Losh basic_machine=i686-pc 868*bf6039f0SWarner Losh os=-msys 869*bf6039f0SWarner Losh ;; 870*bf6039f0SWarner Losh mvs) 871*bf6039f0SWarner Losh basic_machine=i370-ibm 872*bf6039f0SWarner Losh os=-mvs 873*bf6039f0SWarner Losh ;; 874*bf6039f0SWarner Losh nacl) 875*bf6039f0SWarner Losh basic_machine=le32-unknown 876*bf6039f0SWarner Losh os=-nacl 877*bf6039f0SWarner Losh ;; 878*bf6039f0SWarner Losh ncr3000) 879*bf6039f0SWarner Losh basic_machine=i486-ncr 880*bf6039f0SWarner Losh os=-sysv4 881*bf6039f0SWarner Losh ;; 882*bf6039f0SWarner Losh netbsd386) 883*bf6039f0SWarner Losh basic_machine=i386-unknown 884*bf6039f0SWarner Losh os=-netbsd 885*bf6039f0SWarner Losh ;; 886*bf6039f0SWarner Losh netwinder) 887*bf6039f0SWarner Losh basic_machine=armv4l-rebel 888*bf6039f0SWarner Losh os=-linux 889*bf6039f0SWarner Losh ;; 890*bf6039f0SWarner Losh news | news700 | news800 | news900) 891*bf6039f0SWarner Losh basic_machine=m68k-sony 892*bf6039f0SWarner Losh os=-newsos 893*bf6039f0SWarner Losh ;; 894*bf6039f0SWarner Losh news1000) 895*bf6039f0SWarner Losh basic_machine=m68030-sony 896*bf6039f0SWarner Losh os=-newsos 897*bf6039f0SWarner Losh ;; 898*bf6039f0SWarner Losh news-3600 | risc-news) 899*bf6039f0SWarner Losh basic_machine=mips-sony 900*bf6039f0SWarner Losh os=-newsos 901*bf6039f0SWarner Losh ;; 902*bf6039f0SWarner Losh necv70) 903*bf6039f0SWarner Losh basic_machine=v70-nec 904*bf6039f0SWarner Losh os=-sysv 905*bf6039f0SWarner Losh ;; 906*bf6039f0SWarner Losh next | m*-next ) 907*bf6039f0SWarner Losh basic_machine=m68k-next 908*bf6039f0SWarner Losh case $os in 909*bf6039f0SWarner Losh -nextstep* ) 910*bf6039f0SWarner Losh ;; 911*bf6039f0SWarner Losh -ns2*) 912*bf6039f0SWarner Losh os=-nextstep2 913*bf6039f0SWarner Losh ;; 914*bf6039f0SWarner Losh *) 915*bf6039f0SWarner Losh os=-nextstep3 916*bf6039f0SWarner Losh ;; 917*bf6039f0SWarner Losh esac 918*bf6039f0SWarner Losh ;; 919*bf6039f0SWarner Losh nh3000) 920*bf6039f0SWarner Losh basic_machine=m68k-harris 921*bf6039f0SWarner Losh os=-cxux 922*bf6039f0SWarner Losh ;; 923*bf6039f0SWarner Losh nh[45]000) 924*bf6039f0SWarner Losh basic_machine=m88k-harris 925*bf6039f0SWarner Losh os=-cxux 926*bf6039f0SWarner Losh ;; 927*bf6039f0SWarner Losh nindy960) 928*bf6039f0SWarner Losh basic_machine=i960-intel 929*bf6039f0SWarner Losh os=-nindy 930*bf6039f0SWarner Losh ;; 931*bf6039f0SWarner Losh mon960) 932*bf6039f0SWarner Losh basic_machine=i960-intel 933*bf6039f0SWarner Losh os=-mon960 934*bf6039f0SWarner Losh ;; 935*bf6039f0SWarner Losh nonstopux) 936*bf6039f0SWarner Losh basic_machine=mips-compaq 937*bf6039f0SWarner Losh os=-nonstopux 938*bf6039f0SWarner Losh ;; 939*bf6039f0SWarner Losh np1) 940*bf6039f0SWarner Losh basic_machine=np1-gould 941*bf6039f0SWarner Losh ;; 942*bf6039f0SWarner Losh neo-tandem) 943*bf6039f0SWarner Losh basic_machine=neo-tandem 944*bf6039f0SWarner Losh ;; 945*bf6039f0SWarner Losh nse-tandem) 946*bf6039f0SWarner Losh basic_machine=nse-tandem 947*bf6039f0SWarner Losh ;; 948*bf6039f0SWarner Losh nsr-tandem) 949*bf6039f0SWarner Losh basic_machine=nsr-tandem 950*bf6039f0SWarner Losh ;; 951*bf6039f0SWarner Losh op50n-* | op60c-*) 952*bf6039f0SWarner Losh basic_machine=hppa1.1-oki 953*bf6039f0SWarner Losh os=-proelf 954*bf6039f0SWarner Losh ;; 955*bf6039f0SWarner Losh openrisc | openrisc-*) 956*bf6039f0SWarner Losh basic_machine=or32-unknown 957*bf6039f0SWarner Losh ;; 958*bf6039f0SWarner Losh os400) 959*bf6039f0SWarner Losh basic_machine=powerpc-ibm 960*bf6039f0SWarner Losh os=-os400 961*bf6039f0SWarner Losh ;; 962*bf6039f0SWarner Losh OSE68000 | ose68000) 963*bf6039f0SWarner Losh basic_machine=m68000-ericsson 964*bf6039f0SWarner Losh os=-ose 965*bf6039f0SWarner Losh ;; 966*bf6039f0SWarner Losh os68k) 967*bf6039f0SWarner Losh basic_machine=m68k-none 968*bf6039f0SWarner Losh os=-os68k 969*bf6039f0SWarner Losh ;; 970*bf6039f0SWarner Losh pa-hitachi) 971*bf6039f0SWarner Losh basic_machine=hppa1.1-hitachi 972*bf6039f0SWarner Losh os=-hiuxwe2 973*bf6039f0SWarner Losh ;; 974*bf6039f0SWarner Losh paragon) 975*bf6039f0SWarner Losh basic_machine=i860-intel 976*bf6039f0SWarner Losh os=-osf 977*bf6039f0SWarner Losh ;; 978*bf6039f0SWarner Losh parisc) 979*bf6039f0SWarner Losh basic_machine=hppa-unknown 980*bf6039f0SWarner Losh os=-linux 981*bf6039f0SWarner Losh ;; 982*bf6039f0SWarner Losh parisc-*) 983*bf6039f0SWarner Losh basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` 984*bf6039f0SWarner Losh os=-linux 985*bf6039f0SWarner Losh ;; 986*bf6039f0SWarner Losh pbd) 987*bf6039f0SWarner Losh basic_machine=sparc-tti 988*bf6039f0SWarner Losh ;; 989*bf6039f0SWarner Losh pbb) 990*bf6039f0SWarner Losh basic_machine=m68k-tti 991*bf6039f0SWarner Losh ;; 992*bf6039f0SWarner Losh pc532 | pc532-*) 993*bf6039f0SWarner Losh basic_machine=ns32k-pc532 994*bf6039f0SWarner Losh ;; 995*bf6039f0SWarner Losh pc98) 996*bf6039f0SWarner Losh basic_machine=i386-pc 997*bf6039f0SWarner Losh ;; 998*bf6039f0SWarner Losh pc98-*) 999*bf6039f0SWarner Losh basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` 1000*bf6039f0SWarner Losh ;; 1001*bf6039f0SWarner Losh pentium | p5 | k5 | k6 | nexgen | viac3) 1002*bf6039f0SWarner Losh basic_machine=i586-pc 1003*bf6039f0SWarner Losh ;; 1004*bf6039f0SWarner Losh pentiumpro | p6 | 6x86 | athlon | athlon_*) 1005*bf6039f0SWarner Losh basic_machine=i686-pc 1006*bf6039f0SWarner Losh ;; 1007*bf6039f0SWarner Losh pentiumii | pentium2 | pentiumiii | pentium3) 1008*bf6039f0SWarner Losh basic_machine=i686-pc 1009*bf6039f0SWarner Losh ;; 1010*bf6039f0SWarner Losh pentium4) 1011*bf6039f0SWarner Losh basic_machine=i786-pc 1012*bf6039f0SWarner Losh ;; 1013*bf6039f0SWarner Losh pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) 1014*bf6039f0SWarner Losh basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` 1015*bf6039f0SWarner Losh ;; 1016*bf6039f0SWarner Losh pentiumpro-* | p6-* | 6x86-* | athlon-*) 1017*bf6039f0SWarner Losh basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` 1018*bf6039f0SWarner Losh ;; 1019*bf6039f0SWarner Losh pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) 1020*bf6039f0SWarner Losh basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` 1021*bf6039f0SWarner Losh ;; 1022*bf6039f0SWarner Losh pentium4-*) 1023*bf6039f0SWarner Losh basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` 1024*bf6039f0SWarner Losh ;; 1025*bf6039f0SWarner Losh pn) 1026*bf6039f0SWarner Losh basic_machine=pn-gould 1027*bf6039f0SWarner Losh ;; 1028*bf6039f0SWarner Losh power) basic_machine=power-ibm 1029*bf6039f0SWarner Losh ;; 1030*bf6039f0SWarner Losh ppc | ppcbe) basic_machine=powerpc-unknown 1031*bf6039f0SWarner Losh ;; 1032*bf6039f0SWarner Losh ppc-* | ppcbe-*) 1033*bf6039f0SWarner Losh basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` 1034*bf6039f0SWarner Losh ;; 1035*bf6039f0SWarner Losh ppcle | powerpclittle) 1036*bf6039f0SWarner Losh basic_machine=powerpcle-unknown 1037*bf6039f0SWarner Losh ;; 1038*bf6039f0SWarner Losh ppcle-* | powerpclittle-*) 1039*bf6039f0SWarner Losh basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` 1040*bf6039f0SWarner Losh ;; 1041*bf6039f0SWarner Losh ppc64) basic_machine=powerpc64-unknown 1042*bf6039f0SWarner Losh ;; 1043*bf6039f0SWarner Losh ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` 1044*bf6039f0SWarner Losh ;; 1045*bf6039f0SWarner Losh ppc64le | powerpc64little) 1046*bf6039f0SWarner Losh basic_machine=powerpc64le-unknown 1047*bf6039f0SWarner Losh ;; 1048*bf6039f0SWarner Losh ppc64le-* | powerpc64little-*) 1049*bf6039f0SWarner Losh basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` 1050*bf6039f0SWarner Losh ;; 1051*bf6039f0SWarner Losh ps2) 1052*bf6039f0SWarner Losh basic_machine=i386-ibm 1053*bf6039f0SWarner Losh ;; 1054*bf6039f0SWarner Losh pw32) 1055*bf6039f0SWarner Losh basic_machine=i586-unknown 1056*bf6039f0SWarner Losh os=-pw32 1057*bf6039f0SWarner Losh ;; 1058*bf6039f0SWarner Losh rdos | rdos64) 1059*bf6039f0SWarner Losh basic_machine=x86_64-pc 1060*bf6039f0SWarner Losh os=-rdos 1061*bf6039f0SWarner Losh ;; 1062*bf6039f0SWarner Losh rdos32) 1063*bf6039f0SWarner Losh basic_machine=i386-pc 1064*bf6039f0SWarner Losh os=-rdos 1065*bf6039f0SWarner Losh ;; 1066*bf6039f0SWarner Losh rom68k) 1067*bf6039f0SWarner Losh basic_machine=m68k-rom68k 1068*bf6039f0SWarner Losh os=-coff 1069*bf6039f0SWarner Losh ;; 1070*bf6039f0SWarner Losh rm[46]00) 1071*bf6039f0SWarner Losh basic_machine=mips-siemens 1072*bf6039f0SWarner Losh ;; 1073*bf6039f0SWarner Losh rtpc | rtpc-*) 1074*bf6039f0SWarner Losh basic_machine=romp-ibm 1075*bf6039f0SWarner Losh ;; 1076*bf6039f0SWarner Losh s390 | s390-*) 1077*bf6039f0SWarner Losh basic_machine=s390-ibm 1078*bf6039f0SWarner Losh ;; 1079*bf6039f0SWarner Losh s390x | s390x-*) 1080*bf6039f0SWarner Losh basic_machine=s390x-ibm 1081*bf6039f0SWarner Losh ;; 1082*bf6039f0SWarner Losh sa29200) 1083*bf6039f0SWarner Losh basic_machine=a29k-amd 1084*bf6039f0SWarner Losh os=-udi 1085*bf6039f0SWarner Losh ;; 1086*bf6039f0SWarner Losh sb1) 1087*bf6039f0SWarner Losh basic_machine=mipsisa64sb1-unknown 1088*bf6039f0SWarner Losh ;; 1089*bf6039f0SWarner Losh sb1el) 1090*bf6039f0SWarner Losh basic_machine=mipsisa64sb1el-unknown 1091*bf6039f0SWarner Losh ;; 1092*bf6039f0SWarner Losh sde) 1093*bf6039f0SWarner Losh basic_machine=mipsisa32-sde 1094*bf6039f0SWarner Losh os=-elf 1095*bf6039f0SWarner Losh ;; 1096*bf6039f0SWarner Losh sei) 1097*bf6039f0SWarner Losh basic_machine=mips-sei 1098*bf6039f0SWarner Losh os=-seiux 1099*bf6039f0SWarner Losh ;; 1100*bf6039f0SWarner Losh sequent) 1101*bf6039f0SWarner Losh basic_machine=i386-sequent 1102*bf6039f0SWarner Losh ;; 1103*bf6039f0SWarner Losh sh) 1104*bf6039f0SWarner Losh basic_machine=sh-hitachi 1105*bf6039f0SWarner Losh os=-hms 1106*bf6039f0SWarner Losh ;; 1107*bf6039f0SWarner Losh sh5el) 1108*bf6039f0SWarner Losh basic_machine=sh5le-unknown 1109*bf6039f0SWarner Losh ;; 1110*bf6039f0SWarner Losh sh64) 1111*bf6039f0SWarner Losh basic_machine=sh64-unknown 1112*bf6039f0SWarner Losh ;; 1113*bf6039f0SWarner Losh sparclite-wrs | simso-wrs) 1114*bf6039f0SWarner Losh basic_machine=sparclite-wrs 1115*bf6039f0SWarner Losh os=-vxworks 1116*bf6039f0SWarner Losh ;; 1117*bf6039f0SWarner Losh sps7) 1118*bf6039f0SWarner Losh basic_machine=m68k-bull 1119*bf6039f0SWarner Losh os=-sysv2 1120*bf6039f0SWarner Losh ;; 1121*bf6039f0SWarner Losh spur) 1122*bf6039f0SWarner Losh basic_machine=spur-unknown 1123*bf6039f0SWarner Losh ;; 1124*bf6039f0SWarner Losh st2000) 1125*bf6039f0SWarner Losh basic_machine=m68k-tandem 1126*bf6039f0SWarner Losh ;; 1127*bf6039f0SWarner Losh stratus) 1128*bf6039f0SWarner Losh basic_machine=i860-stratus 1129*bf6039f0SWarner Losh os=-sysv4 1130*bf6039f0SWarner Losh ;; 1131*bf6039f0SWarner Losh strongarm-* | thumb-*) 1132*bf6039f0SWarner Losh basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'` 1133*bf6039f0SWarner Losh ;; 1134*bf6039f0SWarner Losh sun2) 1135*bf6039f0SWarner Losh basic_machine=m68000-sun 1136*bf6039f0SWarner Losh ;; 1137*bf6039f0SWarner Losh sun2os3) 1138*bf6039f0SWarner Losh basic_machine=m68000-sun 1139*bf6039f0SWarner Losh os=-sunos3 1140*bf6039f0SWarner Losh ;; 1141*bf6039f0SWarner Losh sun2os4) 1142*bf6039f0SWarner Losh basic_machine=m68000-sun 1143*bf6039f0SWarner Losh os=-sunos4 1144*bf6039f0SWarner Losh ;; 1145*bf6039f0SWarner Losh sun3os3) 1146*bf6039f0SWarner Losh basic_machine=m68k-sun 1147*bf6039f0SWarner Losh os=-sunos3 1148*bf6039f0SWarner Losh ;; 1149*bf6039f0SWarner Losh sun3os4) 1150*bf6039f0SWarner Losh basic_machine=m68k-sun 1151*bf6039f0SWarner Losh os=-sunos4 1152*bf6039f0SWarner Losh ;; 1153*bf6039f0SWarner Losh sun4os3) 1154*bf6039f0SWarner Losh basic_machine=sparc-sun 1155*bf6039f0SWarner Losh os=-sunos3 1156*bf6039f0SWarner Losh ;; 1157*bf6039f0SWarner Losh sun4os4) 1158*bf6039f0SWarner Losh basic_machine=sparc-sun 1159*bf6039f0SWarner Losh os=-sunos4 1160*bf6039f0SWarner Losh ;; 1161*bf6039f0SWarner Losh sun4sol2) 1162*bf6039f0SWarner Losh basic_machine=sparc-sun 1163*bf6039f0SWarner Losh os=-solaris2 1164*bf6039f0SWarner Losh ;; 1165*bf6039f0SWarner Losh sun3 | sun3-*) 1166*bf6039f0SWarner Losh basic_machine=m68k-sun 1167*bf6039f0SWarner Losh ;; 1168*bf6039f0SWarner Losh sun4) 1169*bf6039f0SWarner Losh basic_machine=sparc-sun 1170*bf6039f0SWarner Losh ;; 1171*bf6039f0SWarner Losh sun386 | sun386i | roadrunner) 1172*bf6039f0SWarner Losh basic_machine=i386-sun 1173*bf6039f0SWarner Losh ;; 1174*bf6039f0SWarner Losh sv1) 1175*bf6039f0SWarner Losh basic_machine=sv1-cray 1176*bf6039f0SWarner Losh os=-unicos 1177*bf6039f0SWarner Losh ;; 1178*bf6039f0SWarner Losh symmetry) 1179*bf6039f0SWarner Losh basic_machine=i386-sequent 1180*bf6039f0SWarner Losh os=-dynix 1181*bf6039f0SWarner Losh ;; 1182*bf6039f0SWarner Losh t3e) 1183*bf6039f0SWarner Losh basic_machine=alphaev5-cray 1184*bf6039f0SWarner Losh os=-unicos 1185*bf6039f0SWarner Losh ;; 1186*bf6039f0SWarner Losh t90) 1187*bf6039f0SWarner Losh basic_machine=t90-cray 1188*bf6039f0SWarner Losh os=-unicos 1189*bf6039f0SWarner Losh ;; 1190*bf6039f0SWarner Losh tile*) 1191*bf6039f0SWarner Losh basic_machine=$basic_machine-unknown 1192*bf6039f0SWarner Losh os=-linux-gnu 1193*bf6039f0SWarner Losh ;; 1194*bf6039f0SWarner Losh tx39) 1195*bf6039f0SWarner Losh basic_machine=mipstx39-unknown 1196*bf6039f0SWarner Losh ;; 1197*bf6039f0SWarner Losh tx39el) 1198*bf6039f0SWarner Losh basic_machine=mipstx39el-unknown 1199*bf6039f0SWarner Losh ;; 1200*bf6039f0SWarner Losh toad1) 1201*bf6039f0SWarner Losh basic_machine=pdp10-xkl 1202*bf6039f0SWarner Losh os=-tops20 1203*bf6039f0SWarner Losh ;; 1204*bf6039f0SWarner Losh tower | tower-32) 1205*bf6039f0SWarner Losh basic_machine=m68k-ncr 1206*bf6039f0SWarner Losh ;; 1207*bf6039f0SWarner Losh tpf) 1208*bf6039f0SWarner Losh basic_machine=s390x-ibm 1209*bf6039f0SWarner Losh os=-tpf 1210*bf6039f0SWarner Losh ;; 1211*bf6039f0SWarner Losh udi29k) 1212*bf6039f0SWarner Losh basic_machine=a29k-amd 1213*bf6039f0SWarner Losh os=-udi 1214*bf6039f0SWarner Losh ;; 1215*bf6039f0SWarner Losh ultra3) 1216*bf6039f0SWarner Losh basic_machine=a29k-nyu 1217*bf6039f0SWarner Losh os=-sym1 1218*bf6039f0SWarner Losh ;; 1219*bf6039f0SWarner Losh v810 | necv810) 1220*bf6039f0SWarner Losh basic_machine=v810-nec 1221*bf6039f0SWarner Losh os=-none 1222*bf6039f0SWarner Losh ;; 1223*bf6039f0SWarner Losh vaxv) 1224*bf6039f0SWarner Losh basic_machine=vax-dec 1225*bf6039f0SWarner Losh os=-sysv 1226*bf6039f0SWarner Losh ;; 1227*bf6039f0SWarner Losh vms) 1228*bf6039f0SWarner Losh basic_machine=vax-dec 1229*bf6039f0SWarner Losh os=-vms 1230*bf6039f0SWarner Losh ;; 1231*bf6039f0SWarner Losh vpp*|vx|vx-*) 1232*bf6039f0SWarner Losh basic_machine=f301-fujitsu 1233*bf6039f0SWarner Losh ;; 1234*bf6039f0SWarner Losh vxworks960) 1235*bf6039f0SWarner Losh basic_machine=i960-wrs 1236*bf6039f0SWarner Losh os=-vxworks 1237*bf6039f0SWarner Losh ;; 1238*bf6039f0SWarner Losh vxworks68) 1239*bf6039f0SWarner Losh basic_machine=m68k-wrs 1240*bf6039f0SWarner Losh os=-vxworks 1241*bf6039f0SWarner Losh ;; 1242*bf6039f0SWarner Losh vxworks29k) 1243*bf6039f0SWarner Losh basic_machine=a29k-wrs 1244*bf6039f0SWarner Losh os=-vxworks 1245*bf6039f0SWarner Losh ;; 1246*bf6039f0SWarner Losh w65*) 1247*bf6039f0SWarner Losh basic_machine=w65-wdc 1248*bf6039f0SWarner Losh os=-none 1249*bf6039f0SWarner Losh ;; 1250*bf6039f0SWarner Losh w89k-*) 1251*bf6039f0SWarner Losh basic_machine=hppa1.1-winbond 1252*bf6039f0SWarner Losh os=-proelf 1253*bf6039f0SWarner Losh ;; 1254*bf6039f0SWarner Losh xbox) 1255*bf6039f0SWarner Losh basic_machine=i686-pc 1256*bf6039f0SWarner Losh os=-mingw32 1257*bf6039f0SWarner Losh ;; 1258*bf6039f0SWarner Losh xps | xps100) 1259*bf6039f0SWarner Losh basic_machine=xps100-honeywell 1260*bf6039f0SWarner Losh ;; 1261*bf6039f0SWarner Losh xscale-* | xscalee[bl]-*) 1262*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'` 1263*bf6039f0SWarner Losh ;; 1264*bf6039f0SWarner Losh ymp) 1265*bf6039f0SWarner Losh basic_machine=ymp-cray 1266*bf6039f0SWarner Losh os=-unicos 1267*bf6039f0SWarner Losh ;; 1268*bf6039f0SWarner Losh z8k-*-coff) 1269*bf6039f0SWarner Losh basic_machine=z8k-unknown 1270*bf6039f0SWarner Losh os=-sim 1271*bf6039f0SWarner Losh ;; 1272*bf6039f0SWarner Losh z80-*-coff) 1273*bf6039f0SWarner Losh basic_machine=z80-unknown 1274*bf6039f0SWarner Losh os=-sim 1275*bf6039f0SWarner Losh ;; 1276*bf6039f0SWarner Losh none) 1277*bf6039f0SWarner Losh basic_machine=none-none 1278*bf6039f0SWarner Losh os=-none 1279*bf6039f0SWarner Losh ;; 1280*bf6039f0SWarner Losh 1281*bf6039f0SWarner Losh# Here we handle the default manufacturer of certain CPU types. It is in 1282*bf6039f0SWarner Losh# some cases the only manufacturer, in others, it is the most popular. 1283*bf6039f0SWarner Losh w89k) 1284*bf6039f0SWarner Losh basic_machine=hppa1.1-winbond 1285*bf6039f0SWarner Losh ;; 1286*bf6039f0SWarner Losh op50n) 1287*bf6039f0SWarner Losh basic_machine=hppa1.1-oki 1288*bf6039f0SWarner Losh ;; 1289*bf6039f0SWarner Losh op60c) 1290*bf6039f0SWarner Losh basic_machine=hppa1.1-oki 1291*bf6039f0SWarner Losh ;; 1292*bf6039f0SWarner Losh romp) 1293*bf6039f0SWarner Losh basic_machine=romp-ibm 1294*bf6039f0SWarner Losh ;; 1295*bf6039f0SWarner Losh mmix) 1296*bf6039f0SWarner Losh basic_machine=mmix-knuth 1297*bf6039f0SWarner Losh ;; 1298*bf6039f0SWarner Losh rs6000) 1299*bf6039f0SWarner Losh basic_machine=rs6000-ibm 1300*bf6039f0SWarner Losh ;; 1301*bf6039f0SWarner Losh vax) 1302*bf6039f0SWarner Losh basic_machine=vax-dec 1303*bf6039f0SWarner Losh ;; 1304*bf6039f0SWarner Losh pdp10) 1305*bf6039f0SWarner Losh # there are many clones, so DEC is not a safe bet 1306*bf6039f0SWarner Losh basic_machine=pdp10-unknown 1307*bf6039f0SWarner Losh ;; 1308*bf6039f0SWarner Losh pdp11) 1309*bf6039f0SWarner Losh basic_machine=pdp11-dec 1310*bf6039f0SWarner Losh ;; 1311*bf6039f0SWarner Losh we32k) 1312*bf6039f0SWarner Losh basic_machine=we32k-att 1313*bf6039f0SWarner Losh ;; 1314*bf6039f0SWarner Losh sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) 1315*bf6039f0SWarner Losh basic_machine=sh-unknown 1316*bf6039f0SWarner Losh ;; 1317*bf6039f0SWarner Losh sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) 1318*bf6039f0SWarner Losh basic_machine=sparc-sun 1319*bf6039f0SWarner Losh ;; 1320*bf6039f0SWarner Losh cydra) 1321*bf6039f0SWarner Losh basic_machine=cydra-cydrome 1322*bf6039f0SWarner Losh ;; 1323*bf6039f0SWarner Losh orion) 1324*bf6039f0SWarner Losh basic_machine=orion-highlevel 1325*bf6039f0SWarner Losh ;; 1326*bf6039f0SWarner Losh orion105) 1327*bf6039f0SWarner Losh basic_machine=clipper-highlevel 1328*bf6039f0SWarner Losh ;; 1329*bf6039f0SWarner Losh mac | mpw | mac-mpw) 1330*bf6039f0SWarner Losh basic_machine=m68k-apple 1331*bf6039f0SWarner Losh ;; 1332*bf6039f0SWarner Losh pmac | pmac-mpw) 1333*bf6039f0SWarner Losh basic_machine=powerpc-apple 1334*bf6039f0SWarner Losh ;; 1335*bf6039f0SWarner Losh *-unknown) 1336*bf6039f0SWarner Losh # Make sure to match an already-canonicalized machine name. 1337*bf6039f0SWarner Losh ;; 1338*bf6039f0SWarner Losh *) 1339*bf6039f0SWarner Losh echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 1340*bf6039f0SWarner Losh exit 1 1341*bf6039f0SWarner Losh ;; 1342*bf6039f0SWarner Loshesac 1343*bf6039f0SWarner Losh 1344*bf6039f0SWarner Losh# Here we canonicalize certain aliases for manufacturers. 1345*bf6039f0SWarner Loshcase $basic_machine in 1346*bf6039f0SWarner Losh *-digital*) 1347*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` 1348*bf6039f0SWarner Losh ;; 1349*bf6039f0SWarner Losh *-commodore*) 1350*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` 1351*bf6039f0SWarner Losh ;; 1352*bf6039f0SWarner Losh *) 1353*bf6039f0SWarner Losh ;; 1354*bf6039f0SWarner Loshesac 1355*bf6039f0SWarner Losh 1356*bf6039f0SWarner Losh# Decode manufacturer-specific aliases for certain operating systems. 1357*bf6039f0SWarner Losh 1358*bf6039f0SWarner Loshif [ x"$os" != x"" ] 1359*bf6039f0SWarner Loshthen 1360*bf6039f0SWarner Loshcase $os in 1361*bf6039f0SWarner Losh # First match some system type aliases 1362*bf6039f0SWarner Losh # that might get confused with valid system types. 1363*bf6039f0SWarner Losh # -solaris* is a basic system type, with this one exception. 1364*bf6039f0SWarner Losh -auroraux) 1365*bf6039f0SWarner Losh os=-auroraux 1366*bf6039f0SWarner Losh ;; 1367*bf6039f0SWarner Losh -solaris1 | -solaris1.*) 1368*bf6039f0SWarner Losh os=`echo $os | sed -e 's|solaris1|sunos4|'` 1369*bf6039f0SWarner Losh ;; 1370*bf6039f0SWarner Losh -solaris) 1371*bf6039f0SWarner Losh os=-solaris2 1372*bf6039f0SWarner Losh ;; 1373*bf6039f0SWarner Losh -svr4*) 1374*bf6039f0SWarner Losh os=-sysv4 1375*bf6039f0SWarner Losh ;; 1376*bf6039f0SWarner Losh -unixware*) 1377*bf6039f0SWarner Losh os=-sysv4.2uw 1378*bf6039f0SWarner Losh ;; 1379*bf6039f0SWarner Losh -gnu/linux*) 1380*bf6039f0SWarner Losh os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` 1381*bf6039f0SWarner Losh ;; 1382*bf6039f0SWarner Losh # First accept the basic system types. 1383*bf6039f0SWarner Losh # The portable systems comes first. 1384*bf6039f0SWarner Losh # Each alternative MUST END IN A *, to match a version number. 1385*bf6039f0SWarner Losh # -sysv* is not here because it comes later, after sysvr4. 1386*bf6039f0SWarner Losh -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ 1387*bf6039f0SWarner Losh | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ 1388*bf6039f0SWarner Losh | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ 1389*bf6039f0SWarner Losh | -sym* | -kopensolaris* | -plan9* \ 1390*bf6039f0SWarner Losh | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ 1391*bf6039f0SWarner Losh | -aos* | -aros* | -cloudabi* | -sortix* \ 1392*bf6039f0SWarner Losh | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ 1393*bf6039f0SWarner Losh | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ 1394*bf6039f0SWarner Losh | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ 1395*bf6039f0SWarner Losh | -bitrig* | -openbsd* | -solidbsd* | -libertybsd* \ 1396*bf6039f0SWarner Losh | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ 1397*bf6039f0SWarner Losh | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ 1398*bf6039f0SWarner Losh | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ 1399*bf6039f0SWarner Losh | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ 1400*bf6039f0SWarner Losh | -chorusos* | -chorusrdb* | -cegcc* \ 1401*bf6039f0SWarner Losh | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ 1402*bf6039f0SWarner Losh | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ 1403*bf6039f0SWarner Losh | -linux-newlib* | -linux-musl* | -linux-uclibc* \ 1404*bf6039f0SWarner Losh | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \ 1405*bf6039f0SWarner Losh | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ 1406*bf6039f0SWarner Losh | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ 1407*bf6039f0SWarner Losh | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ 1408*bf6039f0SWarner Losh | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ 1409*bf6039f0SWarner Losh | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ 1410*bf6039f0SWarner Losh | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ 1411*bf6039f0SWarner Losh | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \ 1412*bf6039f0SWarner Losh | -onefs* | -tirtos* | -phoenix* | -fuchsia*) 1413*bf6039f0SWarner Losh # Remember, each alternative MUST END IN *, to match a version number. 1414*bf6039f0SWarner Losh ;; 1415*bf6039f0SWarner Losh -qnx*) 1416*bf6039f0SWarner Losh case $basic_machine in 1417*bf6039f0SWarner Losh x86-* | i*86-*) 1418*bf6039f0SWarner Losh ;; 1419*bf6039f0SWarner Losh *) 1420*bf6039f0SWarner Losh os=-nto$os 1421*bf6039f0SWarner Losh ;; 1422*bf6039f0SWarner Losh esac 1423*bf6039f0SWarner Losh ;; 1424*bf6039f0SWarner Losh -nto-qnx*) 1425*bf6039f0SWarner Losh ;; 1426*bf6039f0SWarner Losh -nto*) 1427*bf6039f0SWarner Losh os=`echo $os | sed -e 's|nto|nto-qnx|'` 1428*bf6039f0SWarner Losh ;; 1429*bf6039f0SWarner Losh -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ 1430*bf6039f0SWarner Losh | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ 1431*bf6039f0SWarner Losh | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) 1432*bf6039f0SWarner Losh ;; 1433*bf6039f0SWarner Losh -mac*) 1434*bf6039f0SWarner Losh os=`echo $os | sed -e 's|mac|macos|'` 1435*bf6039f0SWarner Losh ;; 1436*bf6039f0SWarner Losh -linux-dietlibc) 1437*bf6039f0SWarner Losh os=-linux-dietlibc 1438*bf6039f0SWarner Losh ;; 1439*bf6039f0SWarner Losh -linux*) 1440*bf6039f0SWarner Losh os=`echo $os | sed -e 's|linux|linux-gnu|'` 1441*bf6039f0SWarner Losh ;; 1442*bf6039f0SWarner Losh -sunos5*) 1443*bf6039f0SWarner Losh os=`echo $os | sed -e 's|sunos5|solaris2|'` 1444*bf6039f0SWarner Losh ;; 1445*bf6039f0SWarner Losh -sunos6*) 1446*bf6039f0SWarner Losh os=`echo $os | sed -e 's|sunos6|solaris3|'` 1447*bf6039f0SWarner Losh ;; 1448*bf6039f0SWarner Losh -opened*) 1449*bf6039f0SWarner Losh os=-openedition 1450*bf6039f0SWarner Losh ;; 1451*bf6039f0SWarner Losh -os400*) 1452*bf6039f0SWarner Losh os=-os400 1453*bf6039f0SWarner Losh ;; 1454*bf6039f0SWarner Losh -wince*) 1455*bf6039f0SWarner Losh os=-wince 1456*bf6039f0SWarner Losh ;; 1457*bf6039f0SWarner Losh -osfrose*) 1458*bf6039f0SWarner Losh os=-osfrose 1459*bf6039f0SWarner Losh ;; 1460*bf6039f0SWarner Losh -osf*) 1461*bf6039f0SWarner Losh os=-osf 1462*bf6039f0SWarner Losh ;; 1463*bf6039f0SWarner Losh -utek*) 1464*bf6039f0SWarner Losh os=-bsd 1465*bf6039f0SWarner Losh ;; 1466*bf6039f0SWarner Losh -dynix*) 1467*bf6039f0SWarner Losh os=-bsd 1468*bf6039f0SWarner Losh ;; 1469*bf6039f0SWarner Losh -acis*) 1470*bf6039f0SWarner Losh os=-aos 1471*bf6039f0SWarner Losh ;; 1472*bf6039f0SWarner Losh -atheos*) 1473*bf6039f0SWarner Losh os=-atheos 1474*bf6039f0SWarner Losh ;; 1475*bf6039f0SWarner Losh -syllable*) 1476*bf6039f0SWarner Losh os=-syllable 1477*bf6039f0SWarner Losh ;; 1478*bf6039f0SWarner Losh -386bsd) 1479*bf6039f0SWarner Losh os=-bsd 1480*bf6039f0SWarner Losh ;; 1481*bf6039f0SWarner Losh -ctix* | -uts*) 1482*bf6039f0SWarner Losh os=-sysv 1483*bf6039f0SWarner Losh ;; 1484*bf6039f0SWarner Losh -nova*) 1485*bf6039f0SWarner Losh os=-rtmk-nova 1486*bf6039f0SWarner Losh ;; 1487*bf6039f0SWarner Losh -ns2 ) 1488*bf6039f0SWarner Losh os=-nextstep2 1489*bf6039f0SWarner Losh ;; 1490*bf6039f0SWarner Losh -nsk*) 1491*bf6039f0SWarner Losh os=-nsk 1492*bf6039f0SWarner Losh ;; 1493*bf6039f0SWarner Losh # Preserve the version number of sinix5. 1494*bf6039f0SWarner Losh -sinix5.*) 1495*bf6039f0SWarner Losh os=`echo $os | sed -e 's|sinix|sysv|'` 1496*bf6039f0SWarner Losh ;; 1497*bf6039f0SWarner Losh -sinix*) 1498*bf6039f0SWarner Losh os=-sysv4 1499*bf6039f0SWarner Losh ;; 1500*bf6039f0SWarner Losh -tpf*) 1501*bf6039f0SWarner Losh os=-tpf 1502*bf6039f0SWarner Losh ;; 1503*bf6039f0SWarner Losh -triton*) 1504*bf6039f0SWarner Losh os=-sysv3 1505*bf6039f0SWarner Losh ;; 1506*bf6039f0SWarner Losh -oss*) 1507*bf6039f0SWarner Losh os=-sysv3 1508*bf6039f0SWarner Losh ;; 1509*bf6039f0SWarner Losh -svr4) 1510*bf6039f0SWarner Losh os=-sysv4 1511*bf6039f0SWarner Losh ;; 1512*bf6039f0SWarner Losh -svr3) 1513*bf6039f0SWarner Losh os=-sysv3 1514*bf6039f0SWarner Losh ;; 1515*bf6039f0SWarner Losh -sysvr4) 1516*bf6039f0SWarner Losh os=-sysv4 1517*bf6039f0SWarner Losh ;; 1518*bf6039f0SWarner Losh # This must come after -sysvr4. 1519*bf6039f0SWarner Losh -sysv*) 1520*bf6039f0SWarner Losh ;; 1521*bf6039f0SWarner Losh -ose*) 1522*bf6039f0SWarner Losh os=-ose 1523*bf6039f0SWarner Losh ;; 1524*bf6039f0SWarner Losh -es1800*) 1525*bf6039f0SWarner Losh os=-ose 1526*bf6039f0SWarner Losh ;; 1527*bf6039f0SWarner Losh -xenix) 1528*bf6039f0SWarner Losh os=-xenix 1529*bf6039f0SWarner Losh ;; 1530*bf6039f0SWarner Losh -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) 1531*bf6039f0SWarner Losh os=-mint 1532*bf6039f0SWarner Losh ;; 1533*bf6039f0SWarner Losh -aros*) 1534*bf6039f0SWarner Losh os=-aros 1535*bf6039f0SWarner Losh ;; 1536*bf6039f0SWarner Losh -zvmoe) 1537*bf6039f0SWarner Losh os=-zvmoe 1538*bf6039f0SWarner Losh ;; 1539*bf6039f0SWarner Losh -dicos*) 1540*bf6039f0SWarner Losh os=-dicos 1541*bf6039f0SWarner Losh ;; 1542*bf6039f0SWarner Losh -nacl*) 1543*bf6039f0SWarner Losh ;; 1544*bf6039f0SWarner Losh -ios) 1545*bf6039f0SWarner Losh ;; 1546*bf6039f0SWarner Losh -none) 1547*bf6039f0SWarner Losh ;; 1548*bf6039f0SWarner Losh *) 1549*bf6039f0SWarner Losh # Get rid of the `-' at the beginning of $os. 1550*bf6039f0SWarner Losh os=`echo $os | sed 's/[^-]*-//'` 1551*bf6039f0SWarner Losh echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 1552*bf6039f0SWarner Losh exit 1 1553*bf6039f0SWarner Losh ;; 1554*bf6039f0SWarner Loshesac 1555*bf6039f0SWarner Loshelse 1556*bf6039f0SWarner Losh 1557*bf6039f0SWarner Losh# Here we handle the default operating systems that come with various machines. 1558*bf6039f0SWarner Losh# The value should be what the vendor currently ships out the door with their 1559*bf6039f0SWarner Losh# machine or put another way, the most popular os provided with the machine. 1560*bf6039f0SWarner Losh 1561*bf6039f0SWarner Losh# Note that if you're going to try to match "-MANUFACTURER" here (say, 1562*bf6039f0SWarner Losh# "-sun"), then you have to tell the case statement up towards the top 1563*bf6039f0SWarner Losh# that MANUFACTURER isn't an operating system. Otherwise, code above 1564*bf6039f0SWarner Losh# will signal an error saying that MANUFACTURER isn't an operating 1565*bf6039f0SWarner Losh# system, and we'll never get to this point. 1566*bf6039f0SWarner Losh 1567*bf6039f0SWarner Loshcase $basic_machine in 1568*bf6039f0SWarner Losh score-*) 1569*bf6039f0SWarner Losh os=-elf 1570*bf6039f0SWarner Losh ;; 1571*bf6039f0SWarner Losh spu-*) 1572*bf6039f0SWarner Losh os=-elf 1573*bf6039f0SWarner Losh ;; 1574*bf6039f0SWarner Losh *-acorn) 1575*bf6039f0SWarner Losh os=-riscix1.2 1576*bf6039f0SWarner Losh ;; 1577*bf6039f0SWarner Losh arm*-rebel) 1578*bf6039f0SWarner Losh os=-linux 1579*bf6039f0SWarner Losh ;; 1580*bf6039f0SWarner Losh arm*-semi) 1581*bf6039f0SWarner Losh os=-aout 1582*bf6039f0SWarner Losh ;; 1583*bf6039f0SWarner Losh c4x-* | tic4x-*) 1584*bf6039f0SWarner Losh os=-coff 1585*bf6039f0SWarner Losh ;; 1586*bf6039f0SWarner Losh c8051-*) 1587*bf6039f0SWarner Losh os=-elf 1588*bf6039f0SWarner Losh ;; 1589*bf6039f0SWarner Losh hexagon-*) 1590*bf6039f0SWarner Losh os=-elf 1591*bf6039f0SWarner Losh ;; 1592*bf6039f0SWarner Losh tic54x-*) 1593*bf6039f0SWarner Losh os=-coff 1594*bf6039f0SWarner Losh ;; 1595*bf6039f0SWarner Losh tic55x-*) 1596*bf6039f0SWarner Losh os=-coff 1597*bf6039f0SWarner Losh ;; 1598*bf6039f0SWarner Losh tic6x-*) 1599*bf6039f0SWarner Losh os=-coff 1600*bf6039f0SWarner Losh ;; 1601*bf6039f0SWarner Losh # This must come before the *-dec entry. 1602*bf6039f0SWarner Losh pdp10-*) 1603*bf6039f0SWarner Losh os=-tops20 1604*bf6039f0SWarner Losh ;; 1605*bf6039f0SWarner Losh pdp11-*) 1606*bf6039f0SWarner Losh os=-none 1607*bf6039f0SWarner Losh ;; 1608*bf6039f0SWarner Losh *-dec | vax-*) 1609*bf6039f0SWarner Losh os=-ultrix4.2 1610*bf6039f0SWarner Losh ;; 1611*bf6039f0SWarner Losh m68*-apollo) 1612*bf6039f0SWarner Losh os=-domain 1613*bf6039f0SWarner Losh ;; 1614*bf6039f0SWarner Losh i386-sun) 1615*bf6039f0SWarner Losh os=-sunos4.0.2 1616*bf6039f0SWarner Losh ;; 1617*bf6039f0SWarner Losh m68000-sun) 1618*bf6039f0SWarner Losh os=-sunos3 1619*bf6039f0SWarner Losh ;; 1620*bf6039f0SWarner Losh m68*-cisco) 1621*bf6039f0SWarner Losh os=-aout 1622*bf6039f0SWarner Losh ;; 1623*bf6039f0SWarner Losh mep-*) 1624*bf6039f0SWarner Losh os=-elf 1625*bf6039f0SWarner Losh ;; 1626*bf6039f0SWarner Losh mips*-cisco) 1627*bf6039f0SWarner Losh os=-elf 1628*bf6039f0SWarner Losh ;; 1629*bf6039f0SWarner Losh mips*-*) 1630*bf6039f0SWarner Losh os=-elf 1631*bf6039f0SWarner Losh ;; 1632*bf6039f0SWarner Losh or32-*) 1633*bf6039f0SWarner Losh os=-coff 1634*bf6039f0SWarner Losh ;; 1635*bf6039f0SWarner Losh *-tti) # must be before sparc entry or we get the wrong os. 1636*bf6039f0SWarner Losh os=-sysv3 1637*bf6039f0SWarner Losh ;; 1638*bf6039f0SWarner Losh sparc-* | *-sun) 1639*bf6039f0SWarner Losh os=-sunos4.1.1 1640*bf6039f0SWarner Losh ;; 1641*bf6039f0SWarner Losh *-be) 1642*bf6039f0SWarner Losh os=-beos 1643*bf6039f0SWarner Losh ;; 1644*bf6039f0SWarner Losh *-haiku) 1645*bf6039f0SWarner Losh os=-haiku 1646*bf6039f0SWarner Losh ;; 1647*bf6039f0SWarner Losh *-ibm) 1648*bf6039f0SWarner Losh os=-aix 1649*bf6039f0SWarner Losh ;; 1650*bf6039f0SWarner Losh *-knuth) 1651*bf6039f0SWarner Losh os=-mmixware 1652*bf6039f0SWarner Losh ;; 1653*bf6039f0SWarner Losh *-wec) 1654*bf6039f0SWarner Losh os=-proelf 1655*bf6039f0SWarner Losh ;; 1656*bf6039f0SWarner Losh *-winbond) 1657*bf6039f0SWarner Losh os=-proelf 1658*bf6039f0SWarner Losh ;; 1659*bf6039f0SWarner Losh *-oki) 1660*bf6039f0SWarner Losh os=-proelf 1661*bf6039f0SWarner Losh ;; 1662*bf6039f0SWarner Losh *-hp) 1663*bf6039f0SWarner Losh os=-hpux 1664*bf6039f0SWarner Losh ;; 1665*bf6039f0SWarner Losh *-hitachi) 1666*bf6039f0SWarner Losh os=-hiux 1667*bf6039f0SWarner Losh ;; 1668*bf6039f0SWarner Losh i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) 1669*bf6039f0SWarner Losh os=-sysv 1670*bf6039f0SWarner Losh ;; 1671*bf6039f0SWarner Losh *-cbm) 1672*bf6039f0SWarner Losh os=-amigaos 1673*bf6039f0SWarner Losh ;; 1674*bf6039f0SWarner Losh *-dg) 1675*bf6039f0SWarner Losh os=-dgux 1676*bf6039f0SWarner Losh ;; 1677*bf6039f0SWarner Losh *-dolphin) 1678*bf6039f0SWarner Losh os=-sysv3 1679*bf6039f0SWarner Losh ;; 1680*bf6039f0SWarner Losh m68k-ccur) 1681*bf6039f0SWarner Losh os=-rtu 1682*bf6039f0SWarner Losh ;; 1683*bf6039f0SWarner Losh m88k-omron*) 1684*bf6039f0SWarner Losh os=-luna 1685*bf6039f0SWarner Losh ;; 1686*bf6039f0SWarner Losh *-next ) 1687*bf6039f0SWarner Losh os=-nextstep 1688*bf6039f0SWarner Losh ;; 1689*bf6039f0SWarner Losh *-sequent) 1690*bf6039f0SWarner Losh os=-ptx 1691*bf6039f0SWarner Losh ;; 1692*bf6039f0SWarner Losh *-crds) 1693*bf6039f0SWarner Losh os=-unos 1694*bf6039f0SWarner Losh ;; 1695*bf6039f0SWarner Losh *-ns) 1696*bf6039f0SWarner Losh os=-genix 1697*bf6039f0SWarner Losh ;; 1698*bf6039f0SWarner Losh i370-*) 1699*bf6039f0SWarner Losh os=-mvs 1700*bf6039f0SWarner Losh ;; 1701*bf6039f0SWarner Losh *-next) 1702*bf6039f0SWarner Losh os=-nextstep3 1703*bf6039f0SWarner Losh ;; 1704*bf6039f0SWarner Losh *-gould) 1705*bf6039f0SWarner Losh os=-sysv 1706*bf6039f0SWarner Losh ;; 1707*bf6039f0SWarner Losh *-highlevel) 1708*bf6039f0SWarner Losh os=-bsd 1709*bf6039f0SWarner Losh ;; 1710*bf6039f0SWarner Losh *-encore) 1711*bf6039f0SWarner Losh os=-bsd 1712*bf6039f0SWarner Losh ;; 1713*bf6039f0SWarner Losh *-sgi) 1714*bf6039f0SWarner Losh os=-irix 1715*bf6039f0SWarner Losh ;; 1716*bf6039f0SWarner Losh *-siemens) 1717*bf6039f0SWarner Losh os=-sysv4 1718*bf6039f0SWarner Losh ;; 1719*bf6039f0SWarner Losh *-masscomp) 1720*bf6039f0SWarner Losh os=-rtu 1721*bf6039f0SWarner Losh ;; 1722*bf6039f0SWarner Losh f30[01]-fujitsu | f700-fujitsu) 1723*bf6039f0SWarner Losh os=-uxpv 1724*bf6039f0SWarner Losh ;; 1725*bf6039f0SWarner Losh *-rom68k) 1726*bf6039f0SWarner Losh os=-coff 1727*bf6039f0SWarner Losh ;; 1728*bf6039f0SWarner Losh *-*bug) 1729*bf6039f0SWarner Losh os=-coff 1730*bf6039f0SWarner Losh ;; 1731*bf6039f0SWarner Losh *-apple) 1732*bf6039f0SWarner Losh os=-macos 1733*bf6039f0SWarner Losh ;; 1734*bf6039f0SWarner Losh *-atari*) 1735*bf6039f0SWarner Losh os=-mint 1736*bf6039f0SWarner Losh ;; 1737*bf6039f0SWarner Losh *) 1738*bf6039f0SWarner Losh os=-none 1739*bf6039f0SWarner Losh ;; 1740*bf6039f0SWarner Loshesac 1741*bf6039f0SWarner Loshfi 1742*bf6039f0SWarner Losh 1743*bf6039f0SWarner Losh# Here we handle the case where we know the os, and the CPU type, but not the 1744*bf6039f0SWarner Losh# manufacturer. We pick the logical manufacturer. 1745*bf6039f0SWarner Loshvendor=unknown 1746*bf6039f0SWarner Loshcase $basic_machine in 1747*bf6039f0SWarner Losh *-unknown) 1748*bf6039f0SWarner Losh case $os in 1749*bf6039f0SWarner Losh -riscix*) 1750*bf6039f0SWarner Losh vendor=acorn 1751*bf6039f0SWarner Losh ;; 1752*bf6039f0SWarner Losh -sunos*) 1753*bf6039f0SWarner Losh vendor=sun 1754*bf6039f0SWarner Losh ;; 1755*bf6039f0SWarner Losh -cnk*|-aix*) 1756*bf6039f0SWarner Losh vendor=ibm 1757*bf6039f0SWarner Losh ;; 1758*bf6039f0SWarner Losh -beos*) 1759*bf6039f0SWarner Losh vendor=be 1760*bf6039f0SWarner Losh ;; 1761*bf6039f0SWarner Losh -hpux*) 1762*bf6039f0SWarner Losh vendor=hp 1763*bf6039f0SWarner Losh ;; 1764*bf6039f0SWarner Losh -mpeix*) 1765*bf6039f0SWarner Losh vendor=hp 1766*bf6039f0SWarner Losh ;; 1767*bf6039f0SWarner Losh -hiux*) 1768*bf6039f0SWarner Losh vendor=hitachi 1769*bf6039f0SWarner Losh ;; 1770*bf6039f0SWarner Losh -unos*) 1771*bf6039f0SWarner Losh vendor=crds 1772*bf6039f0SWarner Losh ;; 1773*bf6039f0SWarner Losh -dgux*) 1774*bf6039f0SWarner Losh vendor=dg 1775*bf6039f0SWarner Losh ;; 1776*bf6039f0SWarner Losh -luna*) 1777*bf6039f0SWarner Losh vendor=omron 1778*bf6039f0SWarner Losh ;; 1779*bf6039f0SWarner Losh -genix*) 1780*bf6039f0SWarner Losh vendor=ns 1781*bf6039f0SWarner Losh ;; 1782*bf6039f0SWarner Losh -mvs* | -opened*) 1783*bf6039f0SWarner Losh vendor=ibm 1784*bf6039f0SWarner Losh ;; 1785*bf6039f0SWarner Losh -os400*) 1786*bf6039f0SWarner Losh vendor=ibm 1787*bf6039f0SWarner Losh ;; 1788*bf6039f0SWarner Losh -ptx*) 1789*bf6039f0SWarner Losh vendor=sequent 1790*bf6039f0SWarner Losh ;; 1791*bf6039f0SWarner Losh -tpf*) 1792*bf6039f0SWarner Losh vendor=ibm 1793*bf6039f0SWarner Losh ;; 1794*bf6039f0SWarner Losh -vxsim* | -vxworks* | -windiss*) 1795*bf6039f0SWarner Losh vendor=wrs 1796*bf6039f0SWarner Losh ;; 1797*bf6039f0SWarner Losh -aux*) 1798*bf6039f0SWarner Losh vendor=apple 1799*bf6039f0SWarner Losh ;; 1800*bf6039f0SWarner Losh -hms*) 1801*bf6039f0SWarner Losh vendor=hitachi 1802*bf6039f0SWarner Losh ;; 1803*bf6039f0SWarner Losh -mpw* | -macos*) 1804*bf6039f0SWarner Losh vendor=apple 1805*bf6039f0SWarner Losh ;; 1806*bf6039f0SWarner Losh -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) 1807*bf6039f0SWarner Losh vendor=atari 1808*bf6039f0SWarner Losh ;; 1809*bf6039f0SWarner Losh -vos*) 1810*bf6039f0SWarner Losh vendor=stratus 1811*bf6039f0SWarner Losh ;; 1812*bf6039f0SWarner Losh esac 1813*bf6039f0SWarner Losh basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` 1814*bf6039f0SWarner Losh ;; 1815*bf6039f0SWarner Loshesac 1816*bf6039f0SWarner Losh 1817*bf6039f0SWarner Loshecho $basic_machine$os 1818*bf6039f0SWarner Loshexit 1819*bf6039f0SWarner Losh 1820*bf6039f0SWarner Losh# Local variables: 1821*bf6039f0SWarner Losh# eval: (add-hook 'write-file-hooks 'time-stamp) 1822*bf6039f0SWarner Losh# time-stamp-start: "timestamp='" 1823*bf6039f0SWarner Losh# time-stamp-format: "%:y-%02m-%02d" 1824*bf6039f0SWarner Losh# time-stamp-end: "'" 1825*bf6039f0SWarner Losh# End: 1826