(mail-bury-selects-summary): New variable.
[bpt/emacs.git] / config.sub
CommitLineData
fb955dfa 1#!/bin/sh
fc5546c7 2# Configuration validation subroutine script, version 1.1.
d699cb47 3# Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
955e036a
RS
4# This file is (in principle) common to ALL GNU software.
5# The presence of a machine in this file suggests that SOME GNU software
6# can handle that machine. It does not imply ALL GNU software can.
fb955dfa
RS
7
8#This file is free software; you can redistribute it and/or modify
9#it under the terms of the GNU General Public License as published by
10#the Free Software Foundation; either version 2 of the License, or
11#(at your option) any later version.
12
13#This program is distributed in the hope that it will be useful,
14#but WITHOUT ANY WARRANTY; without even the implied warranty of
15#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16#GNU General Public License for more details.
17
18#You should have received a copy of the GNU General Public License
19#along with this program; if not, write to the Free Software
20#Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21
22
23# Configuration subroutine to validate and canonicalize a configuration type.
24# Supply the specified configuration type as an argument.
25# If it is invalid, we print an error message on stderr and exit with code 1.
26# Otherwise, we print the canonical config type on stdout and succeed.
27
28# This file is supposed to be the same for all GNU packages
29# and recognize all the CPU types, system types and aliases
30# that are meaningful with *any* GNU software.
31# Each package is responsible for reporting which valid configurations
32# it does not support. The user should be able to distinguish
33# a failure to support a valid configuration from a meaningless
34# configuration.
35
36# The goal of this file is to map all the various variations of a given
37# machine specification into a single specification in the form:
38# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
efc3fd67 39# It is wrong to echo any other type of specification.
fb955dfa
RS
40
41# First pass through any local machine types.
42case $1 in
43 *local*)
44 echo $1
45 exit 0
46 ;;
47 *)
48 ;;
49esac
50
51# Separate what the user gave into CPU-COMPANY and OS (if any).
52basic_machine=`echo $1 | sed 's/-[^-]*$//'`
53if [ $basic_machine != $1 ]
54then os=`echo $1 | sed 's/.*-/-/'`
55else os=; fi
56
efc3fd67
JB
57### Let's recognize common machines as not being operating systems so
58### that things like config.sub decstation-3100 work. We also
59### recognize some manufacturers as not being operating systems, so we
60### can provide default operating systems below.
fb955dfa 61case $os in
1f532861
RS
62 -sun*os*)
63 # Prevent following clause from handling this invalid input.
64 ;;
fb955dfa
RS
65 -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
66 -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
a975e06d 67 -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
867c43c4 68 -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
fb955dfa 69 -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
efc3fd67 70 -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp )
fb955dfa
RS
71 os=
72 basic_machine=$1
73 ;;
9e976cfa 74 -hiux*)
d699cb47 75 os=-hiuxwe2
9e976cfa 76 ;;
d05b1883
RS
77 -sco4)
78 os=-sco3.2v4
79 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
80 ;;
81 -sco3.2.[4-9]*)
82 os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
83 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
84 ;;
cf7a78db
RS
85 -sco3.2v[4-9]*)
86 # Don't forget version if it is 3.2v4 or newer.
7617f113 87 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
cf7a78db 88 ;;
fb955dfa 89 -sco*)
f9f15513 90 os=-sco3.2v2
7617f113 91 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
fb955dfa 92 ;;
efc3fd67
JB
93 -isc)
94 os=-isc2.2
7617f113 95 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
efc3fd67 96 ;;
de025efd
RS
97 -clix*)
98 basic_machine=clipper-intergraph
99 ;;
fb955dfa 100 -isc*)
7617f113 101 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
fb955dfa 102 ;;
4c934a4d
JW
103 -lynx)
104 os=-lynxos
105 ;;
b7f0280f
RK
106 -ptx*)
107 basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
108 ;;
fb955dfa
RS
109esac
110
111# Decode aliases for certain CPU-COMPANY combinations.
112case $basic_machine in
665eef22 113 # Recognize the basic CPU types without company name.
fb955dfa 114 # Some are omitted here because they have special meanings below.
535cca31 115 tahoe | i[345]86 | i860 | m68k | m68000 | m88k | ns32k | arm | pyramid \
6ca8e64c 116 | tron | a29k | 580 | i960 | h8300 | hppa1.0 | hppa1.1 \
7090d1e6 117 | alpha | we32k | ns16k | clipper | sparclite | i370 | sh \
35ed0ce0 118 | powerpc | sparc64 | 1750a | dsp16xx)
fb955dfa
RS
119 basic_machine=$basic_machine-unknown
120 ;;
1f532861
RS
121 # Object if more than one company name word.
122 *-*-*)
123 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
124 exit 1
125 ;;
665eef22 126 # Recognize the basic CPU types with company name.
535cca31 127 vax-* | tahoe-* | i[345]86-* | i860-* | m68k-* | m68000-* | m88k-* \
fb955dfa
RS
128 | sparc-* | ns32k-* | fx80-* | arm-* | c[123]* \
129 | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \
130 | none-* | 580-* | cray2-* | h8300-* | i960-* | xmp-* | ymp-* \
efc3fd67 131 | hppa1.0-* | hppa1.1-* | alpha-* | we32k-* | cydra-* | ns16k-* \
d63887ad 132 | pn-* | np1-* | xps100-* | clipper-* | orion-* | sparclite-* \
f9d2d9c0 133 | sh-* | powerpc-* | sparc64-*)
fb955dfa 134 ;;
f8710542
DE
135 # Recognize the various machine names and aliases which stand
136 # for a CPU type and a company and sometimes even an OS.
e65767df
RS
137 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
138 basic_machine=m68000-att
fb955dfa 139 ;;
e65767df
RS
140 3b*)
141 basic_machine=we32k-att
fb955dfa 142 ;;
e65767df
RS
143 alliant | fx80)
144 basic_machine=fx80-alliant
f449890c 145 ;;
e65767df
RS
146 altos | altos3068)
147 basic_machine=m68k-altos
fb955dfa 148 ;;
e65767df
RS
149 am29k)
150 basic_machine=a29k-none
151 os=-bsd
d019125e 152 ;;
e65767df
RS
153 amdahl)
154 basic_machine=580-amdahl
ad6023b3
RS
155 os=-sysv
156 ;;
275cb364 157 amiga | amiga-*)
e65767df 158 basic_machine=m68k-cbm
096fbe81 159 ;;
e65767df
RS
160 amigados)
161 basic_machine=m68k-cbm
162 os=-amigados
fb955dfa 163 ;;
e65767df
RS
164 amigaunix | amix)
165 basic_machine=m68k-cbm
166 os=-sysv4
281f8b09 167 ;;
e65767df
RS
168 apollo68)
169 basic_machine=m68k-apollo
170 os=-sysv
171 ;;
172 balance)
173 basic_machine=ns32k-sequent
174 os=-dynix
fb955dfa
RS
175 ;;
176 convex-c1)
177 basic_machine=c1-convex
178 os=-bsd
179 ;;
180 convex-c2)
181 basic_machine=c2-convex
182 os=-bsd
183 ;;
184 convex-c32)
185 basic_machine=c32-convex
186 os=-bsd
187 ;;
188 convex-c34)
189 basic_machine=c34-convex
190 os=-bsd
191 ;;
192 convex-c38)
193 basic_machine=c38-convex
194 os=-bsd
195 ;;
e65767df
RS
196 cray | ymp)
197 basic_machine=ymp-cray
198 os=-unicos
fb955dfa 199 ;;
e65767df
RS
200 cray2)
201 basic_machine=cray2-cray
202 os=-unicos
fb955dfa
RS
203 ;;
204 crds | unos)
205 basic_machine=m68k-crds
206 ;;
275cb364
CH
207 da30 | da30-*)
208 basic_machine=m68k-da30
209 ;;
210 decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
e65767df 211 basic_machine=mips-dec
51cbdde3 212 ;;
fb955dfa
RS
213 delta | 3300 | motorola-3300 | motorola-delta \
214 | 3300-motorola | delta-motorola)
215 basic_machine=m68k-motorola
216 ;;
e65767df
RS
217 delta88)
218 basic_machine=m88k-motorola
219 os=-sysv3
fb955dfa 220 ;;
253bce3d
RK
221 dpx20 | dpx20-*)
222 basic_machine=rs6000-bull
223 os=-bosx
224 ;;
e65767df
RS
225 dpx2* | dpx2*-bull)
226 basic_machine=m68k-bull
227 os=-sysv3
fb955dfa 228 ;;
e65767df
RS
229 ebmon29k)
230 basic_machine=a29k-amd
231 os=-ebmon
fb955dfa 232 ;;
e65767df
RS
233 elxsi)
234 basic_machine=elxsi-elxsi
235 os=-bsd
fb955dfa 236 ;;
e65767df
RS
237 encore | umax | mmax)
238 basic_machine=ns32k-encore
fb955dfa 239 ;;
e65767df
RS
240 fx2800)
241 basic_machine=i860-alliant
fb955dfa 242 ;;
e65767df
RS
243 genix)
244 basic_machine=ns32k-ns
fb955dfa 245 ;;
e65767df
RS
246 gmicro)
247 basic_machine=tron-gmicro
248 os=-sysv
fb955dfa 249 ;;
e65767df
RS
250 h3050r* | hiux*)
251 basic_machine=hppa1.1-hitachi
252 os=-hiuxwe2
fb955dfa 253 ;;
e65767df
RS
254 h8300hms)
255 basic_machine=h8300-hitachi
256 os=-hms
fb955dfa 257 ;;
e65767df
RS
258 harris)
259 basic_machine=m88k-harris
260 os=-sysv3
3c9da312 261 ;;
275cb364
CH
262 hp300-*)
263 basic_machine=m68k-hp
264 ;;
e65767df
RS
265 hp300bsd)
266 basic_machine=m68k-hp
6e280b45 267 os=-bsd
fb955dfa 268 ;;
e65767df
RS
269 hp300hpux)
270 basic_machine=m68k-hp
271 os=-hpux
efc3fd67 272 ;;
e65767df
RS
273 hp9k2[0-9][0-9] | hp9k31[0-9])
274 basic_machine=m68000-hp
efc3fd67 275 ;;
fb955dfa
RS
276 hp9k3[2-9][0-9])
277 basic_machine=m68k-hp
278 ;;
3c701376
TG
279 hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
280 basic_machine=hppa1.1-hp
fb955dfa 281 ;;
3c701376
TG
282 hp9k8[0-9][0-9] | hp8[0-9][0-9])
283 basic_machine=hppa1.0-hp
d019125e 284 ;;
e65767df
RS
285 i370-ibm* | ibm*)
286 basic_machine=i370-ibm
287 os=-mvs
9e976cfa 288 ;;
e65767df 289# I'm not sure what "Sysv32" means. Should this be sysv3.2?
535cca31 290 i[345]86v32)
e65767df
RS
291 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
292 os=-sysv32
293 ;;
535cca31 294 i[345]86v4*)
e65767df
RS
295 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
296 os=-sysv4
297 ;;
535cca31 298 i[345]86v)
e65767df
RS
299 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
300 os=-sysv
301 ;;
535cca31 302 i[345]86sol2)
e65767df
RS
303 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
304 os=-solaris2
305 ;;
306 iris | iris4d)
307 basic_machine=mips-sgi
308 case $os in
309 -irix*)
310 ;;
311 *)
312 os=-irix4
313 ;;
314 esac
9e976cfa 315 ;;
fb955dfa
RS
316 isi68 | isi)
317 basic_machine=m68k-isi
318 os=-sysv
319 ;;
e65767df
RS
320 m88k-omron*)
321 basic_machine=m88k-omron
322 ;;
323 magnum | m3230)
324 basic_machine=mips-mips
fb955dfa
RS
325 os=-sysv
326 ;;
e65767df
RS
327 merlin)
328 basic_machine=ns32k-utek
329 os=-sysv
fb955dfa
RS
330 ;;
331 miniframe)
332 basic_machine=m68000-convergent
333 ;;
e65767df
RS
334 ncr3000)
335 basic_machine=i486-ncr
336 os=-sysv4
337 ;;
338 news | news700 | news800 | news900)
339 basic_machine=m68k-sony
340 os=-newsos
341 ;;
342 news1000)
343 basic_machine=m68030-sony
344 os=-newsos
fb955dfa
RS
345 ;;
346 news-3600 | risc-news)
347 basic_machine=mips-sony
348 os=-newsos
349 ;;
a975e06d 350 next | m*-next )
e65767df 351 basic_machine=m68k-next
2ff52571 352 case $os in
a975e06d
PB
353 -nextstep* )
354 ;;
2ff52571 355 -ns2*)
a975e06d 356 os=-nextstep2
2ff52571
RK
357 ;;
358 *)
a975e06d 359 os=-nextstep3
2ff52571
RK
360 ;;
361 esac
fb955dfa 362 ;;
e65767df
RS
363 nh3000)
364 basic_machine=m68k-harris
365 os=-cxux
fb955dfa 366 ;;
e65767df
RS
367 nh[45]000)
368 basic_machine=m88k-harris
369 os=-cxux
fb955dfa 370 ;;
e65767df
RS
371 nindy960)
372 basic_machine=i960-intel
373 os=-nindy
fb955dfa 374 ;;
e65767df
RS
375 np1)
376 basic_machine=np1-gould
fb955dfa 377 ;;
e65767df
RS
378 pa-hitachi)
379 basic_machine=hppa1.1-hitachi
380 os=-hiuxwe2
fb955dfa 381 ;;
e65767df
RS
382 paragon)
383 basic_machine=i860-intel
384 os=-osf
fb955dfa 385 ;;
e65767df
RS
386 pbd)
387 basic_machine=sparc-tti
fb955dfa 388 ;;
e65767df
RS
389 pbb)
390 basic_machine=m68k-tti
fb955dfa 391 ;;
d73a2260
CH
392 pc532 | pc532-*)
393 basic_machine=ns32k-pc532
fb955dfa 394 ;;
1ee245eb
RS
395 pentium-*)
396 # We will change tis to say i586 once there has been
397 # time for various packages to start to recognize that.
398 basic_machine=i486-`echo $basic_machine | sed 's/^[^-]*-//'`
399 ;;
e65767df
RS
400 pn)
401 basic_machine=pn-gould
402 ;;
403 ps2)
404 basic_machine=i386-ibm
405 ;;
406 rtpc | rtpc-*)
407 basic_machine=romp-ibm
408 ;;
b7f0280f
RK
409 sequent)
410 basic_machine=i386-sequent
411 ;;
e65767df
RS
412 sh)
413 basic_machine=sh-hitachi
414 os=-hms
ac1e607f
JB
415 ;;
416 sps7)
417 basic_machine=m68k-bull
418 os=-sysv2
fb955dfa 419 ;;
e65767df
RS
420 spur)
421 basic_machine=spur-unknown
fb955dfa 422 ;;
e65767df
RS
423 sun2)
424 basic_machine=m68000-sun
d63887ad 425 ;;
e65767df
RS
426 sun2os3)
427 basic_machine=m68000-sun
428 os=-sunos3
fb955dfa 429 ;;
e65767df
RS
430 sun2os4)
431 basic_machine=m68000-sun
432 os=-sunos4
fb955dfa 433 ;;
e65767df
RS
434 sun3os3)
435 basic_machine=m68k-sun
436 os=-sunos3
fb955dfa 437 ;;
e65767df
RS
438 sun3os4)
439 basic_machine=m68k-sun
440 os=-sunos4
fb955dfa 441 ;;
e65767df
RS
442 sun4os3)
443 basic_machine=sparc-sun
444 os=-sunos3
fb955dfa 445 ;;
e65767df
RS
446 sun4os4)
447 basic_machine=sparc-sun
448 os=-sunos4
fb955dfa 449 ;;
275cb364 450 sun3 | sun3-*)
e65767df 451 basic_machine=m68k-sun
fb955dfa 452 ;;
e65767df
RS
453 sun4)
454 basic_machine=sparc-sun
fb955dfa 455 ;;
e65767df
RS
456 sun386 | sun386i | roadrunner)
457 basic_machine=i386-sun
fb955dfa 458 ;;
e65767df
RS
459 symmetry)
460 basic_machine=i386-sequent
461 os=-dynix
fb955dfa 462 ;;
e65767df
RS
463 tower | tower-32)
464 basic_machine=m68k-ncr
fb955dfa
RS
465 ;;
466 ultra3)
467 basic_machine=a29k-nyu
468 os=-sym1
469 ;;
e65767df
RS
470 vaxv)
471 basic_machine=vax-dec
472 os=-sysv
473 ;;
474 vms)
475 basic_machine=vax-dec
476 os=-vms
477 ;;
fb955dfa
RS
478 vxworks960)
479 basic_machine=i960-wrs
480 os=-vxworks
481 ;;
482 vxworks68)
483 basic_machine=m68k-wrs
484 os=-vxworks
485 ;;
e65767df
RS
486 xmp)
487 basic_machine=xmp-cray
488 os=-unicos
489 ;;
efc3fd67
JB
490 xps | xps100)
491 basic_machine=xps100-honeywell
492 ;;
fb955dfa
RS
493 none)
494 basic_machine=none-none
495 os=-none
496 ;;
497
498# Here we handle the default manufacturer of certain CPU types. It is in
499# some cases the only manufacturer, in others, it is the most popular.
500 mips)
501 basic_machine=mips-mips
502 ;;
503 romp)
504 basic_machine=romp-ibm
505 ;;
506 rs6000)
507 basic_machine=rs6000-ibm
508 ;;
509 vax)
510 basic_machine=vax-dec
511 ;;
3c9da312
RS
512 we32k)
513 basic_machine=we32k-att
514 ;;
fb955dfa
RS
515 sparc)
516 basic_machine=sparc-sun
517 ;;
efc3fd67
JB
518 cydra)
519 basic_machine=cydra-cydrome
520 ;;
521 orion)
522 basic_machine=orion-highlevel
523 ;;
524 orion105)
525 basic_machine=clipper-highlevel
526 ;;
fb955dfa
RS
527 *)
528 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
529 exit 1
530 ;;
531esac
532
533# Here we canonicalize certain aliases for manufacturers.
534case $basic_machine in
535 *-digital*)
536 basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
537 ;;
538 *-commodore*)
539 basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
540 ;;
541 *)
542 ;;
543esac
544
545# Decode manufacturer-specific aliases for certain operating systems.
546
51b3c82f 547if [ x"$os" != x"" ]
fb955dfa
RS
548then
549case $os in
ca8efa98
RS
550 # -solaris* is a basic system type, with this one exception.
551 -solaris1 | -solaris1.*)
552 os=`echo $os | sed -e 's|solaris1|sunos4|'`
553 ;;
f920529b
DE
554 -solaris)
555 os=-solaris2
556 ;;
fb955dfa
RS
557 # First accept the basic system types.
558 # The portable systems comes first.
559 # Each alternative must end in a *, to match a version number.
74da8749 560 # -sysv* is not here because it comes later, after sysvr4.
c2efa566 561 -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
535cca31 562 | -vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[345]* \
bacafaf1 563 | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
3c701376 564 | -amigados* | -msdos* | -newsos* | -unicos* | -aos* \
a5d117a3 565 | -nindy* | -vxworks* | -ebmon* | -hms* | -mvs* | -clix* \
49ee70e2 566 | -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \
253bce3d 567 | -hiux* | -386bsd* | -netbsd* | -freebsd* | -riscix* \
b7f0280f
RK
568 | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
569 | -ptx*)
fb955dfa 570 ;;
ca8efa98
RS
571 -sunos5*)
572 os=`echo $os | sed -e 's|sunos5|solaris2|'`
573 ;;
574 -sunos6*)
575 os=`echo $os | sed -e 's|sunos6|solaris3|'`
576 ;;
fb955dfa 577 -osfrose*)
6d95ff37 578 os=-osfrose
fb955dfa
RS
579 ;;
580 -osf*)
6d95ff37 581 os=-osf
fb955dfa 582 ;;
24616137
CH
583 -utek*)
584 os=-bsd
585 ;;
fb955dfa
RS
586 -dynix*)
587 os=-bsd
588 ;;
589 -acis*)
590 os=-aos
591 ;;
592 -ctix* | -uts*)
593 os=-sysv
594 ;;
595 -triton*)
596 os=-sysv3
597 ;;
598 -oss*)
599 os=-sysv3
600 ;;
601 -svr4)
602 os=-sysv4
603 ;;
74da8749
RS
604 -svr3)
605 os=-sysv3
606 ;;
e294d0c3
RS
607 -sysvr4)
608 os=-sysv4
609 ;;
74da8749
RS
610 # This must come after -sysvr4.
611 -sysv*)
fb955dfa 612 ;;
c809458b
JB
613 -xenix)
614 os=-xenix
615 ;;
955e036a
RS
616 -none)
617 ;;
fb955dfa
RS
618 *)
619 # Get rid of the `-' at the beginning of $os.
9f5aed1b 620 os=`echo $os | sed 's/[^-]*-//'`
fb955dfa
RS
621 echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
622 exit 1
623 ;;
624esac
625else
626
627# Here we handle the default operating systems that come with various machines.
628# The value should be what the vendor currently ships out the door with their
629# machine or put another way, the most popular os provided with the machine.
efc3fd67
JB
630
631# Note that if you're going to try to match "-MANUFACTURER" here (say,
632# "-sun"), then you have to tell the case statement up towards the top
633# that MANUFACTURER isn't an operating system. Otherwise, code above
634# will signal an error saying that MANUFACTURER isn't an operating
635# system, and we'll never get to this point.
636
fb955dfa 637case $basic_machine in
77ba1f30
ESB
638 *-acorn)
639 os=-riscix1.2
640 ;;
fb955dfa 641 *-dec | vax-*)
60597872 642 os=-ultrix4.2
fb955dfa
RS
643 ;;
644 i386-sun)
60597872 645 os=-sunos4.0.2
fb955dfa
RS
646 ;;
647 m68000-sun)
648 os=-sunos3
649 # This also exists in the configure program, but was not the
650 # default.
651 # os=-sunos4
652 ;;
653 *-tti) # must be before sparc entry or we get the wrong os.
654 os=-sysv3
655 ;;
656 sparc-* | *-sun)
60597872 657 os=-sunos4.1.1
fb955dfa
RS
658 ;;
659 *-ibm)
660 os=-aix
661 ;;
662 *-hp)
663 os=-hpux
664 ;;
9e976cfa
RK
665 *-hitachi)
666 os=-hiux
667 ;;
efc3fd67 668 i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
fb955dfa
RS
669 os=-sysv
670 ;;
671 *-cbm)
672 os=-amigados
673 ;;
674 *-dg)
675 os=-dgux
676 ;;
677 *-dolphin)
678 os=-sysv3
679 ;;
1ee245eb
RS
680 m68k-ccur)
681 os=-rtu
682 ;;
fb955dfa
RS
683 m88k-omron*)
684 os=-luna
685 ;;
9ac65684 686 *-sequent)
b7f0280f 687 os=-ptx
9ac65684 688 ;;
fb955dfa
RS
689 *-crds)
690 os=-unos
691 ;;
692 *-ns)
693 os=-genix
694 ;;
f449890c
RS
695 i370-*)
696 os=-mvs
697 ;;
88013905 698 *-next)
a975e06d 699 os=-nextstep3
88013905 700 ;;
efc3fd67
JB
701 *-gould)
702 os=-sysv
703 ;;
704 *-highlevel)
705 os=-bsd
706 ;;
707 *-encore)
708 os=-bsd
709 ;;
710 *-sgi)
711 os=-irix
712 ;;
713 *-masscomp)
714 os=-rtu
715 ;;
fb955dfa
RS
716 *)
717 os=-none
718 ;;
719esac
720fi
721
722# Here we handle the case where we know the os, and the CPU type, but not the
723# manufacturer. We pick the logical manufacturer.
724vendor=unknown
725case $basic_machine in
726 *-unknown)
727 case $os in
77ba1f30
ESB
728 -riscix*)
729 vendor=acorn
730 ;;
fb955dfa
RS
731 -sunos*)
732 vendor=sun
733 ;;
4c934a4d
JW
734 -lynxos*)
735 vendor=lynx
736 ;;
fb955dfa
RS
737 -aix*)
738 vendor=ibm
739 ;;
740 -hpux*)
741 vendor=hp
742 ;;
9e976cfa
RK
743 -hiux*)
744 vendor=hitachi
745 ;;
fb955dfa
RS
746 -unos*)
747 vendor=crds
748 ;;
749 -dgux*)
750 vendor=dg
751 ;;
752 -luna*)
753 vendor=omron
754 ;;
755 -genix*)
756 vendor=ns
757 ;;
f449890c
RS
758 -mvs*)
759 vendor=ibm
760 ;;
b7f0280f
RK
761 -ptx*)
762 vendor=sequent
763 ;;
fb955dfa
RS
764 esac
765 basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
766 ;;
767esac
768
769echo $basic_machine$os