Annotation of 43BSDReno/usr.sbin/amd/config/arch, revision 1.1

1.1     ! root        1: #! /bin/sh
        !             2: #
        !             3: # $Id: arch,v 5.2 90/06/23 22:21:22 jsp Rel $
        !             4: #
        !             5: # Copyright (c) 1989 Jan-Simon Pendry
        !             6: # Copyright (c) 1989 Imperial College of Science, Technology & Medicine
        !             7: # Copyright (c) 1989 The Regents of the University of California.
        !             8: # All rights reserved.
        !             9: #
        !            10: # This code is derived from software contributed to Berkeley by
        !            11: # Jan-Simon Pendry at Imperial College, London.
        !            12: #
        !            13: # Redistribution and use in source and binary forms are permitted provided
        !            14: # that: (1) source distributions retain this entire copyright notice and
        !            15: # comment, and (2) distributions including binaries display the following
        !            16: # acknowledgement:  ``This product includes software developed by the
        !            17: # University of California, Berkeley and its contributors'' in the
        !            18: # documentation or other materials provided with the distribution and in
        !            19: # all advertising materials mentioning features or use of this software.
        !            20: # Neither the name of the University nor the names of its contributors may
        !            21: # be used to endorse or promote products derived from this software without
        !            22: # specific prior written permission.
        !            23: # THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
        !            24: # WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
        !            25: # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
        !            26: LAR PURPOSE.
        !            27: #
        !            28: #      @(#)arch        5.1 (Berkeley) 6/29/90
        !            29: #
        !            30: # Figure out machine architecture
        !            31: #
        !            32: 
        !            33: PATH=/bin:/usr/bin:/usr/ucb:/etc:/usr/local/bin:${PATH} export PATH
        !            34: 
        !            35: #
        !            36: # First try to find a standard command
        !            37: #
        !            38: a=arch         # Sun compat
        !            39: m=machine      # BSD compat
        !            40: u=uname                # Sys5 compat
        !            41: 
        !            42: if [ -f /etc/$a -o -f /bin/$a -o -f /usr/bin/$a -o -f /usr/local/bin/$a ]
        !            43: then
        !            44:        exec $a
        !            45: elif [ -f /etc/$m -o -f /bin/$m -o -f /usr/bin/$m -o -f /usr/ucb/$m -o -f /usr/local/bin/$m ]
        !            46: then
        !            47:        exec $m
        !            48: elif [ -f /etc/$u -o -f /bin/$u -o -f /usr/bin/$u -o -f /usr/local/bin/$u ]
        !            49: then
        !            50:        ARCH="`uname`"
        !            51:        case "$ARCH" in
        !            52:                "HP-UX") echo hp9000; exit 0;;
        !            53:                AIX*) MACH="`uname -m`"
        !            54:                        case "$MACH" in
        !            55:                        00*) echo ibm6000; exit 0;;
        !            56:                        10*) echo ibm032; exit 0;;
        !            57:                        20*) echo ibm032; exit 0;;
        !            58:                        esac
        !            59:                        ;;
        !            60:                A/UX) echo macII ; exit 0 ;;
        !            61:                *) ;;
        !            62:        esac
        !            63: fi
        !            64: 
        !            65: #
        !            66: # Take a pot-shot at your machine architecture
        !            67: #
        !            68: echo " ... No ARCH= option specified; dynamically determining architecture" >&2
        !            69: 
        !            70: case "`exec 2>/dev/null; head -2 /etc/motd`" in
        !            71: *"HP-UX"*)             ARCH=hp9000;;
        !            72: *"Ultrix"*)            ARCH=vax;;
        !            73: *"RISC iX"*)           ARCH=arm;;
        !            74: *"Umax 4.2"*)          ARCH=encore;;
        !            75: *"Alliant Concentrix"*)        ARCH=alliant;;
        !            76: *"FPS Model 500"*)     ARCH=fps500;;
        !            77: *)                     ARCH=unknown;
        !            78:                        if [ -d /usr/include/caif ]; then
        !            79:                                ARCH=ibm032
        !            80:                        elif [ -f /bin/pyr ]; then
        !            81:                                if /bin/pyr; then
        !            82:                                        echo pyr; exit 0
        !            83:                                fi
        !            84:                        fi
        !            85:                        ;;
        !            86: fi
        !            87: 
        !            88: esac
        !            89: 
        !            90: echo " ... architecture appears to be \"${ARCH}\"" >&2
        !            91: echo $ARCH
        !            92: 
        !            93: case "$ARCH" in
        !            94: unknown) exit 1
        !            95: esac
        !            96: 
        !            97: exit 0

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.