mirror of
https://github.com/dreamlayers/netbsd-mopd.git
synced 2026-04-25 19:51:29 +00:00
Commit of original mopd-2.5.3 source, downloaded from:
ftp://ftp.linux-mips.org/pub/linux/mips/people/macro/mopd/mopd-2.5.3.tar.gz SHA256 = 6876cf56a763fea8db1f7d76723689bcf00b76edd4124052155f74f64e2b4ed3
This commit is contained in:
51
otherOS/mdtype
Executable file
51
otherOS/mdtype
Executable file
@@ -0,0 +1,51 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# @(#) $Id: mdtype,v 1.3 1996/08/06 12:16:45 moj Exp $
|
||||
#
|
||||
# Determine machine type.
|
||||
#
|
||||
machine="UNKNOWN"
|
||||
|
||||
if [ -f /usr/bin/uname ]; then
|
||||
|
||||
os=`/usr/bin/uname`
|
||||
|
||||
if [ $os = "AIX" ]; then
|
||||
if [ "`/usr/bin/uname -v`" = "3" ]; then
|
||||
machine="rs6000"
|
||||
fi
|
||||
if [ "`/usr/bin/uname -v`" = "4" ]; then
|
||||
hw="`/usr/sbin/lsattr -l proc0 -E -a type | /usr/bin/cut -d\ -f2`"
|
||||
if [ $hw = "PowerPC_601" ]; then
|
||||
machine="rs6000"
|
||||
fi
|
||||
if [ $hw = "POWER" ]; then
|
||||
machine="rs6000"
|
||||
fi
|
||||
if [ $hw = "POWER2" ]; then
|
||||
machine="rs6000"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ $os = "SunOS" ]; then
|
||||
machine="`/usr/bin/uname -m |/usr/bin/cut -c1-4 `"
|
||||
fi
|
||||
|
||||
if [ $os = "NetBSD" ]; then
|
||||
machine="`/usr/bin/uname -m`"
|
||||
fi
|
||||
|
||||
if [ $machine = "sparc" ]; then
|
||||
machine="sun4"
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
echo $machine
|
||||
|
||||
if [ $machine = "UNKNOWN" ]; then
|
||||
exit 1
|
||||
else
|
||||
exit 0
|
||||
fi
|
||||
Reference in New Issue
Block a user