comparison autoconf/config.sub @ 3:9ad51c7bc036

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