config.sub 35 KB

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