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