#!/bin/csh -f
#
# SYSTEM-ID - print a hopefully unique system identifier
#           - which is concise (short) and specifies the
#           - hardware (CPU), operarting system, and OS release
#           - NOTE: this is too slow for anything but boot strapping
#

set OS = `uname -s | tr "[A-Z]" "[a-z]"`
set RL = `uname -r`

switch ($OS[1])
   case "hp-ux" :
        echo "hpux-$RL"
        breaksw

   case "riscos" :
	echo "risc-$RL"
        breaksw

   case "linux" :
        echo "lnx-$RL"
        breaksw

   case "sunos" :
        set HW = `uname -m`
        if (`expr $HW : '.*3.*'`) then
           echo "sun3-$RL"
        else if (`expr $HW : '.*4.*'`) then
           echo "sparc-$RL"
        else if (`expr $HW : '.*sparc.*'`) then
           echo "sparc-$RL"
        else
           echo "sun-$RL"
        endif
        breaksw

   default :

        if ($OS[1] != "") then
           echo "$OS[1]-$RL"
        else
           echo "$RL"
        endif
        breaksw

endsw

exit($status)


