* valprint.c (val_print_string): If errcode is set, always print
[deliverable/binutils-gdb.git] / config.sub
1 #!/bin/sh
2 # Configuration validation subroutine script, version 1.1.
3 # Copyright (C) 1991, 1992, 1993 Free Software Foundation, Inc.
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.
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
39 # It is wrong to echo any other type of specification.
40
41 if [ x$1 = x ]
42 then
43 echo Configuration name missing. 1>&2
44 echo "Usage: $0 CPU-MFR-OPSYS" 1>&2
45 echo "or $0 ALIAS" 1>&2
46 echo where ALIAS is a recognized configuration type. 1>&2
47 exit 1
48 fi
49
50 # First pass through any local machine types.
51 case $1 in
52 *local*)
53 echo $1
54 exit 0
55 ;;
56 *)
57 ;;
58 esac
59
60 # Separate what the user gave into CPU-COMPANY and OS (if any).
61 basic_machine=`echo $1 | sed 's/-[^-]*$//'`
62 if [ $basic_machine != $1 ]
63 then os=`echo $1 | sed 's/.*-/-/'`
64 else os=; fi
65
66 ### Let's recognize common machines as not being operating systems so
67 ### that things like config.sub decstation-3100 work. We also
68 ### recognize some manufacturers as not being operating systems, so we
69 ### can provide default operating systems below.
70 case $os in
71 -sun*os*)
72 # Prevent following clause from handling this invalid input.
73 ;;
74 -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
75 -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
76 -unicom* | -ibm* | -next* | -hp | -isi* | -apollo | -altos* | \
77 -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
78 -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
79 -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
80 -sim) # CYGNUS LOCAL
81 os=
82 basic_machine=$1
83 ;;
84 -scout) # CYGNUS LOCAL
85 ;;
86 -wrs) # CYGNUS LOCAL
87 os=vxworks
88 basic_machine=$1
89 ;;
90 -unixware) # CYGNUS LOCAL
91 os=-sysv4
92 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
93 ;;
94 -hiux*)
95 os=hiuxwe2
96 ;;
97 -sco4)
98 os=-sco3.2v4
99 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
100 ;;
101 -sco3.2.[4-9]*)
102 os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
103 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
104 ;;
105 -sco3.2v[4-9]*)
106 # Don't forget version if it is 3.2v4 or newer.
107 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
108 ;;
109 -sco*)
110 os=-sco3.2v2
111 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
112 ;;
113 -isc)
114 os=-isc2.2
115 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
116 ;;
117 -clix*)
118 basic_machine=clipper-intergraph
119 ;;
120 -isc*)
121 basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
122 ;;
123 -lynx)
124 os=-lynxos
125 ;;
126 esac
127
128 # Decode aliases for certain CPU-COMPANY combinations.
129 case $basic_machine in
130 # Recognize the basic CPU types without company name.
131 # Some are omitted here because they have special meanings below.
132 tahoe | i[34]86 | i860 | m68k | m68000 | m88k | ns32k | arm | pyramid \
133 | tron | a29k | 580 | i960 | hppa1.0 | hppa1.1 \
134 | alpha | we32k | ns16k | clipper | sparclite | i370 \
135 | powerpc \
136 | h8300 | h8300h | sh \
137 | m88110 | sparc | m680[01234]0 | m683?2 | z8k | v70 \
138 | h8500 | mips64 | mipsel | mips64el) # CYGNUS LOCAL
139 basic_machine=$basic_machine-unknown
140 ;;
141 # Object if more than one company name word.
142 *-*-*)
143 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
144 exit 1
145 ;;
146 # Recognize the basic CPU types with company name.
147 vax-* | tahoe-* | i[34]86-* | i860-* | m68k-* | m68000-* | m88k-* \
148 | sparc-* | ns32k-* | fx80-* | arm-* | c[123]* \
149 | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* \
150 | none-* | 580-* | cray2-* | i960-* | xmp-* | ymp-* \
151 | hppa1.0-* | hppa1.1-* | alpha-* | we32k-* | cydra-* | ns16k-* \
152 | pn-* | np1-* | xps100-* | clipper-* | orion-* | sparclite-* \
153 | powerpc \
154 | h8300-* | h8300h-* | sh-* \
155 | m88110-* | m680[01234]0-* | m683?2-* | z8k-* | h8500-* \
156 | mips64-* | mipsel-* | mips64el-*) # CYGNUS LOCAL
157 ;;
158 # Recognize the various machine names and aliases which stand
159 # for a CPU type and a company and sometimes even an OS.
160 # start-sanitize-v9
161 sparc64) # CYGNUS LOCAL
162 basic_machine=sparc64-sun
163 os=-elf64i64p
164 ;;
165 sparc64-*) # CYGNUS LOCAL
166 ;;
167 # end-sanitize-v9
168
169 mips3-*) # CYGNUS LOCAL
170 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
171 ;;
172 mips3) # CYGNUS LOCAL
173 basic_machine=mips64-unknown
174 ;;
175 dpx20 | dpx20-*) # CYGNUS LOCAL
176 basic_machine=rs6000-bull
177 os=-bosx
178 ;;
179 unixware) # CYGNUS LOCAL
180 os=-sysv4
181 basic_machine=i386-unknown
182 ;;
183 vaxv)
184 basic_machine=vax-dec
185 os=-sysv
186 ;;
187 vms)
188 basic_machine=vax-dec
189 os=-vms
190 ;;
191 i370-ibm* | ibm*)
192 basic_machine=i370-ibm
193 os=-mvs
194 ;;
195 i386mach) # CYGNUS LOCAL
196 basic_machine=i386-mach
197 os=-mach
198 ;;
199 i[34]86v32)
200 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
201 os=-sysv32
202 ;;
203 i[34]86v4*)
204 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
205 os=-sysv4
206 ;;
207 i[34]86v)
208 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
209 os=-sysv
210 ;;
211 i[34]86sol2)
212 basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
213 os=-solaris2
214 ;;
215 vsta | i386-vsta) # CYGNUS LOCAL
216 basic_machine=i386-unknown
217 os=-vsta
218 ;;
219 go32 | i386-go32) # CYGNUS LOCAL
220 basic_machine=i386-unknown
221 os=-go32
222 ;;
223 i386-linux* | linux) # CYGNUS LOCAL
224 basic_machine=i386-unknown
225 os=-linux
226 ;;
227 i386-linux*coff | linuxcoff) # CYGNUS LOCAL
228 basic_machine=i386-unknown
229 os=-linuxcoff
230 ;;
231 i386-linux*elf | linuxelf) # CYGNUS LOCAL
232 basic_machine=i386-unknown
233 os=-linuxelf
234 ;;
235 386bsd) # CYGNUS LOCAL
236 basic_machine=i386-unknown
237 os=-bsd
238 ;;
239 netbsd386)
240 basic_machine=i386-unknown # CYGNUS LOCAL
241 os=-netbsd
242 ;;
243 spur)
244 basic_machine=spur-unknown
245 ;;
246 paragon)
247 basic_machine=i860-intel
248 os=-osf
249 ;;
250 alliant | fx80)
251 basic_machine=fx80-alliant
252 ;;
253 convex-c1)
254 basic_machine=c1-convex
255 os=-bsd
256 ;;
257 convex-c2)
258 basic_machine=c2-convex
259 os=-bsd
260 ;;
261 convex-c32)
262 basic_machine=c32-convex
263 os=-bsd
264 ;;
265 convex-c34)
266 basic_machine=c34-convex
267 os=-bsd
268 ;;
269 convex-c38)
270 basic_machine=c38-convex
271 os=-bsd
272 ;;
273 m88k-omron*)
274 basic_machine=m88k-omron
275 ;;
276 merlin)
277 basic_machine=ns32k-utek
278 os=-sysv
279 ;;
280 crds | unos)
281 basic_machine=m68k-crds
282 ;;
283 elxsi)
284 basic_machine=elxsi-elxsi
285 os=-bsd
286 ;;
287 encore | umax | mmax)
288 basic_machine=ns32k-encore
289 ;;
290 genix)
291 basic_machine=ns32k-ns
292 ;;
293 iris | iris4d | \
294 iris3 | iris4) # CYGNUS LOCAL
295 basic_machine=mips-sgi
296 case $os in
297 -irix*)
298 ;;
299 *)
300 os=-irix4
301 ;;
302 esac
303 ;;
304 news | news700 | news800 | news900)
305 basic_machine=m68k-sony
306 os=-newsos
307 ;;
308 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
309 basic_machine=m68000-att
310 ;;
311 3b*)
312 basic_machine=we32k-att
313 ;;
314 delta | 3300 | motorola-3300 | motorola-delta \
315 | 3300-motorola | delta-motorola)
316 basic_machine=m68k-motorola
317 ;;
318 balance)
319 basic_machine=ns32k-sequent
320 os=-dynix
321 ;;
322 pc532)
323 basic_machine=ns32k-pc532
324 ;;
325 symmetry)
326 basic_machine=i386-sequent
327 os=-dynix
328 ;;
329 sun2)
330 basic_machine=m68000-sun
331 ;;
332 sun2os3)
333 basic_machine=m68000-sun
334 os=-sunos3
335 ;;
336 sun2os4)
337 basic_machine=m68000-sun
338 os=-sunos4
339 ;;
340 sun3os3)
341 basic_machine=m68k-sun
342 os=-sunos3
343 ;;
344 sun3os4)
345 basic_machine=m68k-sun
346 os=-sunos4
347 ;;
348 sun4os3)
349 basic_machine=sparc-sun
350 os=-sunos3
351 ;;
352 sun4os4)
353 basic_machine=sparc-sun
354 os=-sunos4
355 ;;
356 sun4sol2) # CYGNUS LOCAL
357 basic_machine=sparc-sun
358 os=-solaris2
359 ;;
360 z8ksim) # CYGNUS LOCAL
361 basic_machine=z8k-zilog
362 os=-sim
363 ;;
364 z8k) # CYGNUS LOCAL
365 basic_machine=z8k-zilog
366 ;;
367 sun3)
368 basic_machine=m68k-sun
369 ;;
370 sun4)
371 basic_machine=sparc-sun
372 ;;
373 msdos) # CYGNUS LOCAL
374 basic_machine=i386-unknown
375 os=-msdos
376 ;;
377 pbd)
378 basic_machine=sparc-tti
379 ;;
380 pbb)
381 basic_machine=m68k-tti
382 ;;
383 sun386 | sun386i | roadrunner)
384 basic_machine=i386-sun
385 ;;
386 ps2)
387 basic_machine=i386-ibm
388 ;;
389 fx2800)
390 basic_machine=i860-alliant
391 ;;
392 next)
393 basic_machine=m68k-next
394 os=-bsd
395 ;;
396 amiga)
397 basic_machine=m68k-cbm
398 ;;
399 amigados)
400 basic_machine=m68k-cbm
401 os=-amigados
402 ;;
403 amigaunix | amix)
404 basic_machine=m68k-cbm
405 os=-sysv4
406 ;;
407 hp9k3[2-9][0-9])
408 basic_machine=m68k-hp
409 ;;
410 hp9k31[0-9] | hp9k2[0-9][0-9])
411 basic_machine=m68000-hp
412 ;;
413 hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
414 basic_machine=hppa1.1-hp
415 ;;
416 hp9k8[0-9][0-9] | hp8[0-9][0-9])
417 basic_machine=hppa1.0-hp
418 ;;
419 h3050r* | hppahitachi)
420 basic_machine=hppa1.1-hitachi
421 ;;
422 isi68 | isi)
423 basic_machine=m68k-isi
424 os=-sysv
425 ;;
426 apollo68)
427 basic_machine=m68k-apollo
428 os=-sysv
429 ;;
430 apollo68bsd) # CYGNUS LOCAL
431 basic_machine=m68k-apollo
432 os=-bsd
433 ;;
434 altos | altos3068)
435 basic_machine=m68k-altos
436 ;;
437 miniframe)
438 basic_machine=m68010-convergent
439 ;;
440 tower | tower-32)
441 basic_machine=m68k-ncr
442 ;;
443 news-3600 | risc-news)
444 basic_machine=mips-sony
445 os=-newsos
446 ;;
447 st2000) # CYGNUS LOCAL
448 basic_machine=m68k-tandem
449 ;;
450 m6*bug) # CYGNUS LOCAL
451 basic_machine=m68k-bug
452 os=-coff
453 ;;
454 rom68k) # CYGNUS LOCAL
455 basic_machine=m68k-rom68k
456 os=-coff
457 ;;
458 monitor) # CYGNUS LOCAL
459 basic_machine=m68k-rom68k
460 os=-coff
461 ;;
462 decstation | decstation-3100 | pmax | pmin | dec3100 | decstatn)
463 basic_machine=mips-dec
464 ;;
465 magnum | m3230)
466 basic_machine=mips-mips
467 os=-sysv
468 ;;
469 gmicro)
470 basic_machine=tron-gmicro
471 os=-sysv
472 ;;
473 rtpc | rtpc-*)
474 basic_machine=romp-ibm
475 ;;
476 am29k)
477 basic_machine=a29k-none
478 os=-bsd
479 ;;
480 amdahl)
481 basic_machine=580-amdahl
482 os=-sysv
483 ;;
484 stratus) # CYGNUS LOCAL
485 basic_machine=i860-stratus
486 os=-sysv4
487 ;;
488 cray | ymp)
489 basic_machine=ymp-cray
490 os=-unicos
491 ;;
492 cray2)
493 basic_machine=cray2-cray
494 os=-unicos
495 ;;
496 xmp)
497 basic_machine=xmp-cray
498 os=-unicos
499 ;;
500 delta88)
501 basic_machine=m88k-motorola
502 os=-sysv3
503 ;;
504 dpx2* | dpx2*-bull)
505 basic_machine=m68k-bull
506 os=-sysv3
507 ;;
508 ebmon29k)
509 basic_machine=a29k-amd
510 os=-ebmon
511 ;;
512 h8300hms) # CYGNUS LOCAL
513 basic_machine=h8300-hitachi
514 os=-hms
515 ;;
516 sh*) # CYGNUS LOCAL
517 basic_machine=sh-hitachi
518 os=-hms
519 ;;
520
521 h8500hms) # CYGNUS LOCAL
522 basic_machine=h8500-hitachi
523 os=-hms
524 ;;
525 h8300xray) # CYGNUS LOCAL
526 basic_machine=h8300-hitachi
527 os=-xray
528 ;;
529 h8300hds)
530 basic_machine=h8300-hitachi
531 os=-hds
532 ;;
533 udi29k) # CYGNUS LOCAL
534 basic_machine=a29k-amd
535 os=-udi
536 ;;
537 a29khif) # CYGNUS LOCAL
538 basic_machine=a29k-amd
539 os=-udi
540 ;;
541 sa29200) # CYGNUS LOCAL
542 basic_machine=a29k-amd
543 os=-udi
544 ;;
545 harris)
546 basic_machine=m88k-harris
547 os=-sysv3
548 ;;
549 hp300bsd)
550 basic_machine=m68k-hp
551 os=-bsd
552 ;;
553 hp300hpux)
554 basic_machine=m68k-hp
555 os=-hpux
556 ;;
557 hppaosf)
558 basic_machine=hppa1.1-hp
559 os=-osf
560 ;;
561 ncr3000)
562 basic_machine=i486-ncr
563 os=-sysv4
564 ;;
565 necv70) # CYGNUS LOCAL
566 basic_machine=v70-nec
567 os=-sysv
568 ;;
569 news1000)
570 basic_machine=m68030-sony
571 os=-newsos
572 ;;
573 nindy960)
574 basic_machine=i960-intel
575 os=-nindy
576 ;;
577 pn)
578 basic_machine=pn-gould
579 ;;
580 np1)
581 basic_machine=np1-gould
582 ;;
583 ultra3)
584 basic_machine=a29k-nyu
585 os=-sym1
586 ;;
587 vxworks960)
588 basic_machine=i960-wrs
589 os=-vxworks
590 ;;
591 vxworks68)
592 basic_machine=m68k-wrs
593 os=-vxworks
594 ;;
595 es1800 | OSE68k | ose68k | ose | OSE) # CYGNUS LOCAL
596 basic_machine=m68k-ericsson
597 os=-ose
598 ;;
599 OSE68000 | ose68000) # CYGNUS LOCAL
600 basic_machine=m68000-ericsson
601 os=-ose
602 ;;
603 os68k) # CYGNUS LOCAL
604 basic_machine=m68k-none
605 os=-os68k
606 ;;
607 sparclite-wrs) # CYGNUS LOCAL
608 basic_machine=sparclite-wrs
609 os=-vxworks
610 ;;
611 sparcfrw) # CYGNUS LOCAL
612 basic_machine=sparcfrw-sun
613 os=-sunos4
614 ;;
615 sparcfrwcompat) # CYGNUS LOCAL
616 basic_machine=sparcfrwcompat-sun
617 os=-sunos4
618 ;;
619 sparclitefrw) # CYGNUS LOCAL
620 basic_machine=sparclitefrw-fujitsu
621 os=-none
622 ;;
623 sparclitefrwcompat) # CYGNUS LOCAL
624 basic_machine=sparclitefrwcompat-fujitsu
625 os=-none
626 ;;
627 adobe68k) # CYGNUS LOCAL
628 basic_machine=m68010-adobe
629 os=-scout
630 ;;
631
632 xps | xps100)
633 basic_machine=xps100-honeywell
634 ;;
635 none)
636 basic_machine=none-none
637 os=-none
638 ;;
639
640 # Here we handle the default manufacturer of certain CPU types. It is in
641 # some cases the only manufacturer, in others, it is the most popular.
642 mips)
643 basic_machine=mips-mips
644 ;;
645 romp)
646 basic_machine=romp-ibm
647 ;;
648 rs6000)
649 basic_machine=rs6000-ibm
650 ;;
651 vax)
652 basic_machine=vax-dec
653 ;;
654 we32k)
655 basic_machine=we32k-att
656 ;;
657 sparc)
658 basic_machine=sparc-sun
659 ;;
660 cydra)
661 basic_machine=cydra-cydrome
662 ;;
663 orion)
664 basic_machine=orion-highlevel
665 ;;
666 orion105)
667 basic_machine=clipper-highlevel
668 ;;
669 ## start-sanitize-mpw
670 mac) # CYGNUS LOCAL
671 basic_machine=m68k-apple
672 ;;
673 mpw) # CYGNUS LOCAL
674 basic_machine=m68k-apple
675 ;;
676 ## end-sanitize-mpw
677 *)
678 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
679 exit 1
680 ;;
681 esac
682
683 # Here we canonicalize certain aliases for manufacturers.
684 case $basic_machine in
685 *-digital*)
686 basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
687 ;;
688 *-commodore*)
689 basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
690 ;;
691 *)
692 ;;
693 esac
694
695 # Decode manufacturer-specific aliases for certain operating systems.
696
697 if [ x"$os" != x"" ]
698 then
699 case $os in
700 # -solaris* is a basic system type, with this one exception.
701 -solaris1 | -solaris1.*)
702 os=`echo $os | sed -e 's|solaris1|sunos4|'`
703 ;;
704 -solaris)
705 os=-solaris2
706 ;;
707 # First accept the basic system types.
708 # The portable systems comes first.
709 # Each alternative must end in a *, to match a version number.
710 # -sysv* is not here because it comes later, after sysvr4.
711 -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
712 | -vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]* | -hpux* \
713 | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
714 | -amigados* | -msdos* | -newsos* | -unicos* | -aos* \
715 | -nindy* | -vxworks* | -ebmon* | -hms* | -mvs* | -clix* \
716 | -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \
717 | -hiux* | -386bsd* | -netbsd* | -riscix* | -lynxos* \
718 | -go32 | -vsta | -sim | -es1800* | -udi | -hms* | -xray | -hds* \
719 | -os68k* | -none* | -v88r* | -aout* | -coff | -elf* | -bosx* \
720 | -abug | -ecoff* | -netware* )
721 # The last three lines above are CYGNUS LOCAL
722 ;;
723 -sunos5*)
724 os=`echo $os | sed -e 's|sunos5|solaris2|'`
725 ;;
726 -sunos6*)
727 os=`echo $os | sed -e 's|sunos6|solaris3|'`
728 ;;
729 -osfrose*)
730 os=-osfrose
731 ;;
732 -osf*)
733 os=-osf
734 ;;
735 -utek*)
736 os=-bsd
737 ;;
738 -dynix*)
739 os=-bsd
740 ;;
741 -acis*)
742 os=-aos
743 ;;
744 -386bsd) # CYGNUS LOCAL
745 os=-bsd
746 ;;
747 -ctix* | -uts*)
748 os=-sysv
749 ;;
750 -triton*)
751 os=-sysv3
752 ;;
753 -oss*)
754 os=-sysv3
755 ;;
756 -svr4)
757 os=-sysv4
758 ;;
759 -unixware)
760 os=-sysv4
761 ;;
762 -svr3)
763 os=-sysv3
764 ;;
765 -sysvr4)
766 os=-sysv4
767 ;;
768 # This must come after -sysvr4.
769 -sysv*)
770 ;;
771 -ose*) # CYGNUS LOCAL
772 os=-ose
773 ;;
774 -es1800*) # CYGNUS LOCAL
775 os=-ose
776 ;;
777 -xenix)
778 os=-xenix
779 ;;
780 -none)
781 ;;
782 *)
783 # Get rid of the `-' at the beginning of $os.
784 os=`echo $1 | sed 's/[^-]*-//'`
785 echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
786 exit 1
787 ;;
788 esac
789 else
790
791 # Here we handle the default operating systems that come with various machines.
792 # The value should be what the vendor currently ships out the door with their
793 # machine or put another way, the most popular os provided with the machine.
794
795 # Note that if you're going to try to match "-MANUFACTURER" here (say,
796 # "-sun"), then you have to tell the case statement up towards the top
797 # that MANUFACTURER isn't an operating system. Otherwise, code above
798 # will signal an error saying that MANUFACTURER isn't an operating
799 # system, and we'll never get to this point.
800
801 case $basic_machine in
802 *-acorn)
803 os=-riscix1.2
804 ;;
805 *-dec | vax-*)
806 os=-ultrix4.2
807 ;;
808 i386-sun)
809 os=-sunos4.0.2
810 ;;
811 m68000-sun)
812 os=-sunos3
813 # This also exists in the configure program, but was not the
814 # default.
815 # os=-sunos4
816 ;;
817 *-tti) # must be before sparc entry or we get the wrong os.
818 os=-sysv3
819 ;;
820 sparc-* | *-sun)
821 os=-sunos4.1.1
822 ;;
823 *-ibm)
824 os=-aix
825 ;;
826 *-hp)
827 os=-hpux
828 ;;
829 *-hitachi)
830 os=-hiux
831 ;;
832 i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
833 os=-sysv
834 ;;
835 *-cbm)
836 os=-amigados
837 ;;
838 *-dg)
839 os=-dgux
840 ;;
841 *-dolphin)
842 os=-sysv3
843 ;;
844 m88k-omron*)
845 os=-luna
846 ;;
847 *-sequent)
848 os=-bsd
849 ;;
850 *-crds)
851 os=-unos
852 ;;
853 *-ns)
854 os=-genix
855 ;;
856 i370-*)
857 os=-mvs
858 ;;
859 *-next)
860 os=-bsd
861 ;;
862 i[34]86-*)
863 os=-sco3.2v2
864 ;;
865 *-gould)
866 os=-sysv
867 ;;
868 *-highlevel)
869 os=-bsd
870 ;;
871 *-encore)
872 os=-bsd
873 ;;
874 *-sgi)
875 os=-irix
876 ;;
877 *-masscomp)
878 os=-rtu
879 ;;
880 *-rom68k) # CYGNUS LOCAL
881 os=-coff
882 ;;
883 *-*bug) # CYGNUS LOCAL
884 os=-coff
885 ;;
886 ## start-sanitize-mpw
887 *-apple) # CYGNUS LOCAL
888 os=-mpw
889 ;;
890 ## end-sanitize-mpw
891 *)
892 os=-none
893 ;;
894 esac
895 fi
896
897 # Here we handle the case where we know the os, and the CPU type, but not the
898 # manufacturer. We pick the logical manufacturer.
899 vendor=unknown
900 case $basic_machine in
901 *-unknown)
902 case $os in
903 -riscix*)
904 vendor=acorn
905 ;;
906 -sunos*)
907 vendor=sun
908 ;;
909 -bosx*) # CYGNUS LOCAL
910 vendor=bull
911 ;;
912 -lynxos*)
913 vendor=lynx
914 ;;
915 -aix*)
916 vendor=ibm
917 ;;
918 -hpux*)
919 vendor=hp
920 ;;
921 -hiux*)
922 vendor=hitachi
923 ;;
924 -unos*)
925 vendor=crds
926 ;;
927 -dgux*)
928 vendor=dg
929 ;;
930 -luna*)
931 vendor=omron
932 ;;
933 -genix*)
934 vendor=ns
935 ;;
936 -mvs*)
937 vendor=ibm
938 ;;
939 -vxworks*)
940 vendor=wrs # CYGNUS LOCAL
941 ;;
942 -hms*) # CYGNUS LOCAL
943 vendor=hitachi
944 ;;
945 ## start-sanitize-mpw
946 -mpw*) # CYGNUS LOCAL
947 vendor=apple
948 ;;
949 ## end-sanitize-mpw
950 esac
951 basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
952 ;;
953 esac
954
955 echo $basic_machine$os
This page took 0.064376 seconds and 4 git commands to generate.