source: trunk/third/cns/config.sub @ 8789

Revision 8789, 22.5 KB checked in by ghudson, 28 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r8788, which included commits to RCS files with non-trunk default branches.
  • Property svn:executable set to *
Line 
1#! /bin/sh
2# Configuration validation subroutine script, version 1.1.
3#   Copyright (C) 1991, 92, 93, 94, 95, 1996 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., 59 Temple Place - Suite 330,
21# Boston, MA 02111-1307, USA.
22
23# As a special exception to the GNU General Public License, if you
24# distribute this file as part of a program that contains a
25# configuration script generated by Autoconf, you may include it under
26# the same distribution terms that you use for the rest of that program.
27
28# Configuration subroutine to validate and canonicalize a configuration type.
29# Supply the specified configuration type as an argument.
30# If it is invalid, we print an error message on stderr and exit with code 1.
31# Otherwise, we print the canonical config type on stdout and succeed.
32
33# This file is supposed to be the same for all GNU packages
34# and recognize all the CPU types, system types and aliases
35# that are meaningful with *any* GNU software.
36# Each package is responsible for reporting which valid configurations
37# it does not support.  The user should be able to distinguish
38# a failure to support a valid configuration from a meaningless
39# configuration.
40
41# The goal of this file is to map all the various variations of a given
42# machine specification into a single specification in the form:
43#       CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
44# It is wrong to echo any other type of specification.
45
46if [ x$1 = x ]
47then
48        echo Configuration name missing. 1>&2
49        echo "Usage: $0 CPU-MFR-OPSYS" 1>&2
50        echo "or     $0 ALIAS" 1>&2
51        echo where ALIAS is a recognized configuration type. 1>&2
52        exit 1
53fi
54
55# First pass through any local machine types.
56case $1 in
57        *local*)
58                echo $1
59                exit 0
60                ;;
61        *)
62        ;;
63esac
64
65# Separate what the user gave into CPU-COMPANY and OS (if any).
66basic_machine=`echo $1 | sed 's/-[^-]*$//'`
67if [ $basic_machine != $1 ]
68then os=`echo $1 | sed 's/.*-/-/'`
69else os=; fi
70
71### Let's recognize common machines as not being operating systems so
72### that things like config.sub decstation-3100 work.  We also
73### recognize some manufacturers as not being operating systems, so we
74### can provide default operating systems below.
75case $os in
76        -sun*os*)
77                # Prevent following clause from handling this invalid input.
78                ;;
79        -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
80        -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
81        -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
82        -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
83        -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
84        -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp )
85                os=
86                basic_machine=$1
87                ;;
88        -sim | -cisco | -oki | -wec | -winbond )        # CYGNUS LOCAL
89                os=
90                basic_machine=$1
91                ;;
92        -apple*)                                        # CYGNUS LOCAL
93                os=
94                basic_machine=$1
95                ;;
96        -scout)                                         # CYGNUS LOCAL
97                ;;
98        -wrs)                                           # CYGNUS LOCAL
99                os=vxworks
100                basic_machine=$1
101                ;;
102        -hiux*)
103                os=-hiuxwe2
104                ;;
105        -sco5)
106                os=sco3.2v5
107                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
108                ;;
109        -sco4)
110                os=-sco3.2v4
111                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
112                ;;
113        -sco3.2.[4-9]*)
114                os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
115                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
116                ;;
117        -sco3.2v[4-9]*)
118                # Don't forget version if it is 3.2v4 or newer.
119                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
120                ;;
121        -sco*)
122                os=-sco3.2v2
123                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
124                ;;
125        -isc)
126                os=-isc2.2
127                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
128                ;;
129        -clix*)
130                basic_machine=clipper-intergraph
131                ;;
132        -isc*)
133                basic_machine=`echo $1 | sed -e 's/86-.*/86-unknown/'`
134                ;;
135        -lynx*)
136                os=-lynxos
137                ;;
138        -ptx*)
139                basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
140                ;;
141        -windowsnt*)
142                os=`echo $os | sed -e 's/windowsnt/winnt/'`
143                ;;
144        -psos*)
145                os=-psos
146                ;;
147esac
148
149# Decode aliases for certain CPU-COMPANY combinations.
150case $basic_machine in
151        # Recognize the basic CPU types without company name.
152        # Some are omitted here because they have special meanings below.
153        tahoe | i[3456]86 | i860 | m68k | m68000 | m88k | ns32k | arm \
154                | arme[lb] | pyramid \
155                | tron | a29k | 580 | i960 | h8300 | hppa1.0 | hppa1.1 \
156                | alpha | we32k | ns16k | clipper | i370 | sh \
157                | powerpc | powerpcle | 1750a | dsp16xx | mips64 | mipsel \
158                | pdp11 | mips64el | mips64orion | mips64orionel \
159                | sparc | sparclet | sparclite | sparc64)
160                basic_machine=$basic_machine-unknown
161                ;;
162        m88110 | m680[01234]0 | m683?2 | m68360 | z8k | v70 | h8500 | w65) # CYGNUS LOCAL
163                basic_machine=$basic_machine-unknown
164                ;;
165        mips64vr4300 | mips64vr4300el) # CYGNUS LOCAL jsmith/vr4300
166                basic_machine=$basic_machine-unknown
167                ;;
168        mips64vr4100 | mips64vr4100el) # CYGNUS LOCAL jsmith/vr4100
169                basic_machine=$basic_machine-unknown
170                ;;
171        # Object if more than one company name word.
172        *-*-*)
173                echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
174                exit 1
175                ;;
176        # Recognize the basic CPU types with company name.
177        vax-* | tahoe-* | i[3456]86-* | i860-* | m68k-* | m68000-* | m88k-* \
178              | sparc-* | ns32k-* | fx80-* | arm-* | arme[lb]-* | c[123]* \
179              | mips-* | pyramid-* | tron-* | a29k-* | romp-* | rs6000-* | power-* \
180              | none-* | 580-* | cray2-* | h8300-* | i960-* | xmp-* | ymp-* \
181              | hppa1.0-* | hppa1.1-* | alpha-* | we32k-* | cydra-* | ns16k-* \
182              | pn-* | np1-* | xps100-* | clipper-* | orion-* | sparclite-* \
183              | pdp11-* | sh-* | powerpc-* | powerpcle-* | sparc64-* | mips64-* | mipsel-* \
184              | mips64el-* | mips64orion-* | mips64orionel-*)
185                ;;
186        m88110-* | m680[01234]0-* | m683?2-* | m68360-* | z8k-* | h8500-*) # CYGNUS LOCAL
187                ;;
188        mips64vr4300-* | mips64vr4300el-*) # CYGNUS LOCAL jsmith/vr4300
189                ;;
190        mips64vr4100-* | mips64vr4100el-*) # CYGNUS LOCAL jsmith/vr4100
191                ;;
192        # Recognize the various machine names and aliases which stand
193        # for a CPU type and a company and sometimes even an OS.
194        386bsd)                                         # CYGNUS LOCAL
195                basic_machine=i386-unknown
196                os=-bsd
197                ;;
198        3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
199                basic_machine=m68000-att
200                ;;
201        3b*)
202                basic_machine=we32k-att
203                ;;
204        a29khif)                                        # CYGNUS LOCAL
205                basic_machine=a29k-amd
206                os=-udi
207                ;;
208        adobe68k)                                       # CYGNUS LOCAL
209                basic_machine=m68010-adobe
210                os=-scout
211                ;;
212        alliant | fx80)
213                basic_machine=fx80-alliant
214                ;;
215        altos | altos3068)
216                basic_machine=m68k-altos
217                ;;
218        am29k)
219                basic_machine=a29k-none
220                os=-bsd
221                ;;
222        amdahl)
223                basic_machine=580-amdahl
224                os=-sysv
225                ;;
226        amiga | amiga-*)
227                basic_machine=m68k-cbm
228                ;;
229        amigados)
230                basic_machine=m68k-cbm
231                os=-amigados
232                ;;
233        amigaunix | amix)
234                basic_machine=m68k-cbm
235                os=-sysv4
236                ;;
237        apollo68)
238                basic_machine=m68k-apollo
239                os=-sysv
240                ;;
241        apollo68bsd)                                    # CYGNUS LOCAL
242                basic_machine=m68k-apollo
243                os=-bsd
244                ;;
245        arm | armel | armeb)
246                basic_machine=arm-arm
247                os=-aout
248                ;;
249# start-sanitize-arc
250        arc)
251                basic_machine=arc-unknown
252                ;;
253        arc-*)
254                ;;
255# end-sanitize-arc
256        aux)
257                basic_machine=m68k-apple
258                os=-aux
259                ;;
260        balance)
261                basic_machine=ns32k-sequent
262                os=-dynix
263                ;;
264        convex-c1)
265                basic_machine=c1-convex
266                os=-bsd
267                ;;
268        convex-c2)
269                basic_machine=c2-convex
270                os=-bsd
271                ;;
272        convex-c32)
273                basic_machine=c32-convex
274                os=-bsd
275                ;;
276        convex-c34)
277                basic_machine=c34-convex
278                os=-bsd
279                ;;
280        convex-c38)
281                basic_machine=c38-convex
282                os=-bsd
283                ;;
284        cray | ymp)
285                basic_machine=ymp-cray
286                os=-unicos
287                ;;
288        cray2)
289                basic_machine=cray2-cray
290                os=-unicos
291                ;;
292        crds | unos)
293                basic_machine=m68k-crds
294                ;;
295        da30 | da30-*)
296                basic_machine=m68k-da30
297                ;;
298        decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
299                basic_machine=mips-dec
300                ;;
301        delta | 3300 | motorola-3300 | motorola-delta \
302              | 3300-motorola | delta-motorola)
303                basic_machine=m68k-motorola
304                ;;
305        delta88)
306                basic_machine=m88k-motorola
307                os=-sysv3
308                ;;
309        dpx20 | dpx20-*)
310                basic_machine=rs6000-bull
311                os=-bosx
312                ;;
313        dpx2* | dpx2*-bull)
314                basic_machine=m68k-bull
315                os=-sysv3
316                ;;
317        ebmon29k)
318                basic_machine=a29k-amd
319                os=-ebmon
320                ;;
321        elxsi)
322                basic_machine=elxsi-elxsi
323                os=-bsd
324                ;;
325        encore | umax | mmax)
326                basic_machine=ns32k-encore
327                ;;
328        es1800 | OSE68k | ose68k | ose | OSE)           # CYGNUS LOCAL
329                basic_machine=m68k-ericsson
330                os=-ose
331                ;;
332        fx2800)
333                basic_machine=i860-alliant
334                ;;
335        genix)
336                basic_machine=ns32k-ns
337                ;;
338        gmicro)
339                basic_machine=tron-gmicro
340                os=-sysv
341                ;;
342        h3050r* | hiux*)
343                basic_machine=hppa1.1-hitachi
344                os=-hiuxwe2
345                ;;
346        h8300hms)
347                basic_machine=h8300-hitachi
348                os=-hms
349                ;;
350        h8300xray)                                      # CYGNUS LOCAL
351                basic_machine=h8300-hitachi
352                os=-xray
353                ;;
354        h8500hms)                                       # CYGNUS LOCAL
355                basic_machine=h8500-hitachi
356                os=-hms
357                ;;
358        harris)
359                basic_machine=m88k-harris
360                os=-sysv3
361                ;;
362        hp300-*)
363                basic_machine=m68k-hp
364                ;;
365        hp300bsd)
366                basic_machine=m68k-hp
367                os=-bsd
368                ;;
369        hp300hpux)
370                basic_machine=m68k-hp
371                os=-hpux
372                ;;
373        w89k-*)                                         # CYGNUS LOCAL
374                basic_machine=hppa1.1-winbond
375                os=-proelf
376                ;;
377        op50n-*)                                        # CYGNUS LOCAL
378                basic_machine=hppa1.1-oki
379                os=-proelf
380                ;;
381        op60c-*)                                        # CYGNUS LOCAL
382                basic_machine=hppa1.1-oki
383                os=-proelf
384                ;;
385        hppro)                                          # CYGNUS LOCAL
386                basic_machine=hppa1.1-hp
387                os=-proelf
388                ;;
389        hp9k2[0-9][0-9] | hp9k31[0-9])
390                basic_machine=m68000-hp
391                ;;
392        hp9k3[2-9][0-9])
393                basic_machine=m68k-hp
394                ;;
395        hp9k7[0-9][0-9] | hp7[0-9][0-9] | hp9k8[0-9]7 | hp8[0-9]7)
396                basic_machine=hppa1.1-hp
397                ;;
398        hp9k8[0-9][0-9] | hp8[0-9][0-9])
399                basic_machine=hppa1.0-hp
400                ;;
401        hppaosf)                                        # CYGNUS LOCAL
402                basic_machine=hppa1.1-hp
403                os=-osf
404                ;;
405        i370-ibm* | ibm*)
406                basic_machine=i370-ibm
407                os=-mvs
408                ;;
409# I'm not sure what "Sysv32" means.  Should this be sysv3.2?
410        i[3456]86v32)
411                basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
412                os=-sysv32
413                ;;
414        i[3456]86v4*)
415                basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
416                os=-sysv4
417                ;;
418        i[3456]86v)
419                basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
420                os=-sysv
421                ;;
422        i[3456]86sol2)
423                basic_machine=`echo $1 | sed -e 's/86.*/86-unknown/'`
424                os=-solaris2
425                ;;
426        i386mach)                                       # CYGNUS LOCAL
427                basic_machine=i386-mach
428                os=-mach
429                ;;
430        i386-vsta | vsta)                               # CYGNUS LOCAL
431                basic_machine=i386-unknown
432                os=-vsta
433                ;;
434        i386-go32 | go32)                               # CYGNUS LOCAL
435                basic_machine=i386-unknown
436                os=-go32
437                ;;
438        iris | iris4d)
439                basic_machine=mips-sgi
440                case $os in
441                    -irix*)
442                        ;;
443                    *)
444                        os=-irix4
445                        ;;
446                esac
447                ;;
448        isi68 | isi)
449                basic_machine=m68k-isi
450                os=-sysv
451                ;;
452        m88k-omron*)
453                basic_machine=m88k-omron
454                ;;
455        magnum | m3230)
456                basic_machine=mips-mips
457                os=-sysv
458                ;;
459        merlin)
460                basic_machine=ns32k-utek
461                os=-sysv
462                ;;
463        miniframe)
464                basic_machine=m68000-convergent
465                ;;
466        mips3*-*)
467                basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
468                ;;
469        mips3*)
470                basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
471                ;;
472        monitor)                                        # CYGNUS LOCAL
473                basic_machine=m68k-rom68k
474                os=-coff
475                ;;
476        msdos)                                          # CYGNUS LOCAL
477                basic_machine=i386-unknown     
478                os=-msdos
479                ;;
480        ncr3000)
481                basic_machine=i486-ncr
482                os=-sysv4
483                ;;
484        netbsd386)
485                basic_machine=i386-unknown              # CYGNUS LOCAL
486                os=-netbsd
487                ;;
488        news | news700 | news800 | news900)
489                basic_machine=m68k-sony
490                os=-newsos
491                ;;
492        news1000)
493                basic_machine=m68030-sony
494                os=-newsos
495                ;;
496        news-3600 | risc-news)
497                basic_machine=mips-sony
498                os=-newsos
499                ;;
500        necv70)                                         # CYGNUS LOCAL
501                basic_machine=v70-nec
502                os=-sysv
503                ;;
504        next | m*-next )
505                basic_machine=m68k-next
506                case $os in
507                    -nextstep* )
508                        ;;
509                    -ns2*)
510                      os=-nextstep2
511                        ;;
512                    *)
513                      os=-nextstep3
514                        ;;
515                esac
516                ;;
517        nh3000)
518                basic_machine=m68k-harris
519                os=-cxux
520                ;;
521        nh[45]000)
522                basic_machine=m88k-harris
523                os=-cxux
524                ;;
525        nindy960)
526                basic_machine=i960-intel
527                os=-nindy
528                ;;
529        mon960)
530                basic_machine=i960-intel
531                os=-mon960
532                ;;
533        np1)
534                basic_machine=np1-gould
535                ;;
536        OSE68000 | ose68000)                            # CYGNUS LOCAL
537                basic_machine=m68000-ericsson
538                os=-ose
539                ;;
540        os68k)                                          # CYGNUS LOCAL
541                basic_machine=m68k-none
542                os=-os68k
543                ;;
544        pa-hitachi)
545                basic_machine=hppa1.1-hitachi
546                os=-hiuxwe2
547                ;;
548        paragon)
549                basic_machine=i860-intel
550                os=-osf
551                ;;
552        pbd)
553                basic_machine=sparc-tti
554                ;;
555        pbb)
556                basic_machine=m68k-tti
557                ;;
558        pc532 | pc532-*)
559                basic_machine=ns32k-pc532
560                ;;
561        pentium | p5)
562                basic_machine=i586-intel
563                ;;
564        pentiumpro | p6)
565                basic_machine=i686-intel
566                ;;
567        pentium-* | p5-*)
568                basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
569                ;;
570        pentiumpro-* | p6-*)
571                basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
572                ;;
573        k5)
574                # We don't have specific support for AMD's K5 yet, so just call it a Pentium
575                basic_machine=i586-amd
576                ;;
577        nexen)
578                # We don't have specific support for Nexgen yet, so just call it a Pentium
579                basic_machine=i586-nexgen
580                ;;
581        pn)
582                basic_machine=pn-gould
583                ;;
584        power)  basic_machine=rs6000-ibm
585                ;;
586        ppc)    basic_machine=powerpc-unknown
587                ;;
588        ppc-*)  basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
589                ;;
590        ppcle | powerpclittle | ppc-le | powerpc-little)
591                basic_machine=powerpcle-unknown
592                ;;
593        ppcle-* | powerpclittle-*)
594                basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
595                ;;
596        ps2)
597                basic_machine=i386-ibm
598                ;;
599# start-sanitize-rce
600        rce)
601                basic_machine=rce-unknown
602                ;;
603        rce-*)
604                ;;
605# end-sanitize-rce
606        rom68k)                                         # CYGNUS LOCAL
607                basic_machine=m68k-rom68k
608                os=-coff
609                ;;
610        rm[46]00)
611                basic_machine=mips-siemens
612                ;;
613        rtpc | rtpc-*)
614                basic_machine=romp-ibm
615                ;;
616        sa29200)                                        # CYGNUS LOCAL
617                basic_machine=a29k-amd
618                os=-udi
619                ;;
620        sequent)
621                basic_machine=i386-sequent
622                ;;
623        sh)
624                basic_machine=sh-hitachi
625                os=-hms
626                ;;
627        sparclite-wrs)                                  # CYGNUS LOCAL
628                basic_machine=sparclite-wrs
629                os=-vxworks
630                ;;
631        sps7)
632                basic_machine=m68k-bull
633                os=-sysv2
634                ;;
635        spur)
636                basic_machine=spur-unknown
637                ;;
638        st2000)                                         # CYGNUS LOCAL
639                basic_machine=m68k-tandem
640                ;;
641        stratus)                                        # CYGNUS LOCAL
642                basic_machine=i860-stratus
643                os=-sysv4
644                ;;
645        sun2)
646                basic_machine=m68000-sun
647                ;;
648        sun2os3)
649                basic_machine=m68000-sun
650                os=-sunos3
651                ;;
652        sun2os4)
653                basic_machine=m68000-sun
654                os=-sunos4
655                ;;
656        sun3os3)
657                basic_machine=m68k-sun
658                os=-sunos3
659                ;;
660        sun3os4)
661                basic_machine=m68k-sun
662                os=-sunos4
663                ;;
664        sun4os3)
665                basic_machine=sparc-sun
666                os=-sunos3
667                ;;
668        sun4os4)
669                basic_machine=sparc-sun
670                os=-sunos4
671                ;;
672        sun4sol2)
673                basic_machine=sparc-sun
674                os=-solaris2
675                ;;
676        sun3 | sun3-*)
677                basic_machine=m68k-sun
678                ;;
679        sun4)
680                basic_machine=sparc-sun
681                ;;
682        sun386 | sun386i | roadrunner)
683                basic_machine=i386-sun
684                ;;
685        symmetry)
686                basic_machine=i386-sequent
687                os=-dynix
688                ;;
689        tower | tower-32)
690                basic_machine=m68k-ncr
691                ;;
692        udi29k)
693                basic_machine=a29k-amd
694                os=-udi
695                ;;
696        ultra3)
697                basic_machine=a29k-nyu
698                os=-sym1
699                ;;
700        v810 | necv810)                                 # CYGNUS LOCAL
701                basic_machine=v810-nec
702                os=-none
703                ;;
704        vaxv)
705                basic_machine=vax-dec
706                os=-sysv
707                ;;
708        vms)
709                basic_machine=vax-dec
710                os=-vms
711                ;;
712        vxworks960)
713                basic_machine=i960-wrs
714                os=-vxworks
715                ;;
716        vxworks68)
717                basic_machine=m68k-wrs
718                os=-vxworks
719                ;;
720        vxworks29k)
721                basic_machine=a29k-wrs
722                os=-vxworks
723                ;;
724        w65*)                                           # CYGNUS LOCAL
725                basic_machine=w65-wdc
726                os=-none
727                ;;
728        xmp)
729                basic_machine=xmp-cray
730                os=-unicos
731                ;;
732        xps | xps100)
733                basic_machine=xps100-honeywell
734                ;;
735        z8k-*-coff)                                     # CYGNUS LOCAL
736                basic_machine=z8k-unknown
737                os=-sim
738                ;;
739        none)
740                basic_machine=none-none
741                os=-none
742                ;;
743
744# Here we handle the default manufacturer of certain CPU types.  It is in
745# some cases the only manufacturer, in others, it is the most popular.
746        w89k)                                           # CYGNUS LOCAL
747                basic_machine=hppa1.1-winbond
748                ;;
749        op50n)                                          # CYGNUS LOCAL
750                basic_machine=hppa1.1-oki
751                ;;
752        op60c)                                          # CYGNUS LOCAL
753                basic_machine=hppa1.1-oki
754                ;;
755        mips)
756                basic_machine=mips-mips
757                ;;
758        romp)
759                basic_machine=romp-ibm
760                ;;
761        rs6000)
762                basic_machine=rs6000-ibm
763                ;;
764        vax)
765                basic_machine=vax-dec
766                ;;
767        pdp11)
768                basic_machine=pdp11-dec
769                ;;
770        we32k)
771                basic_machine=we32k-att
772                ;;
773        sparc)
774                basic_machine=sparc-sun
775                ;;
776        cydra)
777                basic_machine=cydra-cydrome
778                ;;
779        orion)
780                basic_machine=orion-highlevel
781                ;;
782        orion105)
783                basic_machine=clipper-highlevel
784                ;;
785        mac | mpw | mac-mpw)                            # CYGNUS LOCAL
786                basic_machine=m68k-apple
787                ;;
788        pmac | pmac-mpw)                                # CYGNUS LOCAL
789                basic_machine=powerpc-apple
790                ;;
791        *)
792                echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
793                exit 1
794                ;;
795esac
796
797# Here we canonicalize certain aliases for manufacturers.
798case $basic_machine in
799        *-digital*)
800                basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
801                ;;
802        *-commodore*)
803                basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
804                ;;
805        *)
806                ;;
807esac
808
809# Decode manufacturer-specific aliases for certain operating systems.
810
811if [ x"$os" != x"" ]
812then
813case $os in
814        # -solaris* is a basic system type, with this one exception.
815        -solaris1 | -solaris1.*)
816                os=`echo $os | sed -e 's|solaris1|sunos4|'`
817                ;;
818        -solaris)
819                os=-solaris2
820                ;;
821        -unixware* | svr4*)
822                os=-sysv4
823                ;;
824        -gnu/linux*)
825                os=`echo $os | sed -e 's|gnu/linux|linux|'`
826                ;;
827        # First accept the basic system types.
828        # The portable systems comes first.
829        # Each alternative MUST END IN A *, to match a version number.
830        # -sysv* is not here because it comes later, after sysvr4.
831        -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
832              | -vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[3456]* \
833              | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
834              | -amigados* | -msdos* | -moss* | -newsos* | -unicos* | -aos* | -aof* \
835              | -nindy* | -mon960* | -vxworks* | -ebmon* | -hms* | -mvs* | -clix* \
836              | -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \
837              | -hiux* | -386bsd* | -netbsd* | -freebsd* | -riscix* \
838              | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
839              | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
840              | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
841              | -cygwin32* | -pe* | -psos*)
842        # Remember, each alternative MUST END IN *, to match a version number.
843                ;;
844        # CYGNUS LOCAL
845        -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
846              | -windows* | -osx | -abug |  -netware* | -proelf | -os9* \
847              | -macos* | -mpw* | -magic*)
848                ;;
849        -mac*)
850                os=`echo $os | sed -e 's|mac|macos|'`
851                ;;
852        # END CYGNUS LOCAL
853        -sunos5*)
854                os=`echo $os | sed -e 's|sunos5|solaris2|'`
855                ;;
856        -sunos6*)
857                os=`echo $os | sed -e 's|sunos6|solaris3|'`
858                ;;
859        -osfrose*)
860                os=-osfrose
861                ;;
862        -osf*)
863                os=-osf
864                ;;
865        -utek*)
866                os=-bsd
867                ;;
868        -dynix*)
869                os=-bsd
870                ;;
871        -acis*)
872                os=-aos
873                ;;
874        -386bsd)                                        # CYGNUS LOCAL
875                os=-bsd
876                ;;
877        -ctix* | -uts*)
878                os=-sysv
879                ;;
880        -ns2 )
881                os=-nextstep2
882                ;;
883        # Preserve the version number of sinix5.
884        -sinix5.*)
885                os=`echo $os | sed -e 's|sinix|sysv|'`
886                ;;
887        -sinix*)
888                os=-sysv4
889                ;;
890        -triton*)
891                os=-sysv3
892                ;;
893        -oss*)
894                os=-sysv3
895                ;;
896        -svr4)
897                os=-sysv4
898                ;;
899        -svr3)
900                os=-sysv3
901                ;;
902        -sysvr4)
903                os=-sysv4
904                ;;
905        # This must come after -sysvr4.
906        -sysv*)
907                ;;
908        -ose*)                                          # CYGNUS LOCAL
909                os=-ose
910                ;;
911        -es1800*)                                       # CYGNUS LOCAL
912                os=-ose
913                ;;
914        -xenix)
915                os=-xenix
916                ;;
917        -none)
918                ;;
919        *)
920                # Get rid of the `-' at the beginning of $os.
921                os=`echo $os | sed 's/[^-]*-//'`
922                echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
923                exit 1
924                ;;
925esac
926else
927
928# Here we handle the default operating systems that come with various machines.
929# The value should be what the vendor currently ships out the door with their
930# machine or put another way, the most popular os provided with the machine.
931
932# Note that if you're going to try to match "-MANUFACTURER" here (say,
933# "-sun"), then you have to tell the case statement up towards the top
934# that MANUFACTURER isn't an operating system.  Otherwise, code above
935# will signal an error saying that MANUFACTURER isn't an operating
936# system, and we'll never get to this point.
937
938case $basic_machine in
939        *-acorn)
940                os=-riscix1.2
941                ;;
942        arm*-semi)
943                os=-aout
944                ;;
945        pdp11-*)
946                os=-none
947                ;;
948        *-dec | vax-*)
949                os=-ultrix4.2
950                ;;
951        m68*-apollo)
952                os=-domain
953                ;;
954        i386-sun)
955                os=-sunos4.0.2
956                ;;
957        m68000-sun)
958                os=-sunos3
959                # This also exists in the configure program, but was not the
960                # default.
961                # os=-sunos4
962                ;;
963        m68*-cisco)                                     # CYGNUS LOCAL
964                os=-aout
965                ;;
966        mips*-cisco)                                    # CYGNUS LOCAL
967                os=-elf
968                ;;
969        *-tti)  # must be before sparc entry or we get the wrong os.
970                os=-sysv3
971                ;;
972        sparc-* | *-sun)
973                os=-sunos4.1.1
974                ;;
975        *-ibm)
976                os=-aix
977                ;;
978        *-wec)                                          # CYGNUS LOCAL
979                os=-proelf
980                ;;
981        *-winbond)                                      # CYGNUS LOCAL
982                os=-proelf
983                ;;
984        *-oki)                                          # CYGNUS LOCAL
985                os=-proelf
986                ;;
987        *-hp)
988                os=-hpux
989                ;;
990        *-hitachi)
991                os=-hiux
992                ;;
993        i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
994                os=-sysv
995                ;;
996        *-cbm)
997                os=-amigados
998                ;;
999        *-dg)
1000                os=-dgux
1001                ;;
1002        *-dolphin)
1003                os=-sysv3
1004                ;;
1005        m68k-ccur)
1006                os=-rtu
1007                ;;
1008        m88k-omron*)
1009                os=-luna
1010                ;;
1011        *-next )
1012                os=-nextstep
1013                ;;
1014        *-sequent)
1015                os=-ptx
1016                ;;
1017        *-crds)
1018                os=-unos
1019                ;;
1020        *-ns)
1021                os=-genix
1022                ;;
1023        i370-*)
1024                os=-mvs
1025                ;;
1026        *-next)
1027                os=-nextstep3
1028                ;;
1029        *-gould)
1030                os=-sysv
1031                ;;
1032        *-highlevel)
1033                os=-bsd
1034                ;;
1035        *-encore)
1036                os=-bsd
1037                ;;
1038        *-sgi)
1039                os=-irix
1040                ;;
1041        *-siemens)
1042                os=-sysv4
1043                ;;
1044        *-masscomp)
1045                os=-rtu
1046                ;;
1047        *-rom68k)                                       # CYGNUS LOCAL
1048                os=-coff
1049                ;;
1050        *-*bug)                                         # CYGNUS LOCAL
1051                os=-coff
1052                ;;
1053        *-apple)                                        # CYGNUS LOCAL
1054                os=-macos
1055                ;;
1056        *)
1057                os=-none
1058                ;;
1059esac
1060fi
1061
1062# Here we handle the case where we know the os, and the CPU type, but not the
1063# manufacturer.  We pick the logical manufacturer.
1064vendor=unknown
1065case $basic_machine in
1066        *-unknown)
1067                case $os in
1068                        -riscix*)
1069                                vendor=acorn
1070                                ;;
1071                        -sunos*)
1072                                vendor=sun
1073                                ;;
1074                        -bosx*)                         # CYGNUS LOCAL
1075                                vendor=bull
1076                                ;;
1077                        -lynxos*)
1078                                vendor=lynx
1079                                ;;
1080                        -aix*)
1081                                vendor=ibm
1082                                ;;
1083                        -hpux*)
1084                                vendor=hp
1085                                ;;
1086                        -hiux*)
1087                                vendor=hitachi
1088                                ;;
1089                        -unos*)
1090                                vendor=crds
1091                                ;;
1092                        -dgux*)
1093                                vendor=dg
1094                                ;;
1095                        -luna*)
1096                                vendor=omron
1097                                ;;
1098                        -genix*)
1099                                vendor=ns
1100                                ;;
1101                        -mvs*)
1102                                vendor=ibm
1103                                ;;
1104                        -ptx*)
1105                                vendor=sequent
1106                                ;;
1107                        -vxworks*)
1108                                vendor=wrs
1109                                ;;
1110                        -aux*)
1111                                vendor=apple
1112                                ;;
1113                        -hms*)                          # CYGNUS LOCAL
1114                                vendor=hitachi
1115                                ;;
1116                        -mpw* | -macos*)                # CYGNUS LOCAL
1117                                vendor=apple
1118                                ;;
1119                esac
1120                basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
1121                ;;
1122esac
1123
1124echo $basic_machine$os
Note: See TracBrowser for help on using the repository browser.