[BACK]Return to config.sub CVS log [TXT][DIR] Up to [local] / src / usr.bin / sudo

Annotation of src/usr.bin/sudo/config.sub, Revision 1.2

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