summaryrefslogtreecommitdiff
path: root/etc/etc.mvme88k/MAKEDEV
diff options
context:
space:
mode:
authorTodd T. Fries <todd@cvs.openbsd.org>2002-02-14 04:58:37 +0000
committerTodd T. Fries <todd@cvs.openbsd.org>2002-02-14 04:58:37 +0000
commit55208f690a02dec226532ae7c0c407c18e769a9b (patch)
tree9c71f5f8208eb45c1c460da1dd1a452a9b22169b /etc/etc.mvme88k/MAKEDEV
parent15afbfd288bd8c5ee751174049da7bfeb4f0f834 (diff)
escapees; it is not yet time (but soon)
Diffstat (limited to 'etc/etc.mvme88k/MAKEDEV')
-rw-r--r--etc/etc.mvme88k/MAKEDEV190
1 files changed, 1 insertions, 189 deletions
diff --git a/etc/etc.mvme88k/MAKEDEV b/etc/etc.mvme88k/MAKEDEV
index ed195aaac80..71c910ec6c5 100644
--- a/etc/etc.mvme88k/MAKEDEV
+++ b/etc/etc.mvme88k/MAKEDEV
@@ -1,38 +1,6 @@
#!/bin/sh -
#
-# THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT.
-# generated from:
-#
-# OpenBSD: MAKEDEV.mi,v 1.26 2002/02/10 21:52:30 deraadt Exp
-# OpenBSD: MAKEDEV.sub,v 1.5 2002/01/23 06:02:19 todd Exp
-#
-# $OpenBSD: MAKEDEV,v 1.17 2002/02/14 04:39:56 todd Exp $
-#
-# Copyright (c) 2001 Todd T. Fries <todd@OpenBSD.org>
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms, with or without
-# modification, are permitted provided that the following conditions
-# are met:
-# 1. Redistributions of source code must retain the above copyright
-# notice, this list of conditions and the following disclaimer.
-# 2. The name of the author may not be used to endorse or promote products
-# derived from this software without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
-# INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
-# AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
-# THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
-# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
-# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
-# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-#
-#!/bin/sh -
-#
-# $OpenBSD: MAKEDEV,v 1.17 2002/02/14 04:39:56 todd Exp $
+# $OpenBSD: MAKEDEV,v 1.18 2002/02/14 04:58:36 todd Exp $
# $NetBSD: MAKEDEV,v 1.5 1997/01/01 23:46:23 pk Exp $
#
# Copyright (c) 1990 The Regents of the University of California.
@@ -391,159 +359,3 @@ local)
esac
done
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-T=$0
-
-# set this to echo for Echo-Only debugging
-[ "$eo" ] || eo=
-
-hex()
-{
- case $1 in
- [0-9]) echo -n $1;;
- 10) echo -n a;;
- 11) echo -n b;;
- 12) echo -n c;;
- 13) echo -n d;;
- 14) echo -n e;;
- 15) echo -n f;;
- esac
-}
-
-trunc()
-{
- # XXX pdksh can't seem to deal with locally scoped variables
- # in ${foo#$bar} expansions
- arg1="$1"
- arg2="$2"
- case $3 in
- l) echo ${arg2#$arg1} ;;
- r|*) echo ${arg1#$arg2} ;;
- esac
-}
-
-unt()
-{
- # XXX pdksh can't seem to deal with locally scoped variables
- # in ${foo#$bar} expansions
- arg="$1"
- tmp="${arg#[a-zA-Z]*}"
- tmp="${tmp%*[a-zA-Z]}"
- while [ "$tmp" != "$arg" ]
- do
- arg=$tmp
- tmp="${arg#[a-zA-Z]*}"
- tmp="${tmp%*[a-zA-Z]}"
- done
- echo $arg
-}
-
-dodisk()
-{
- [ "$DEBUG" ] && set -x
- n=$(($((${5}*${7:-16}))+${6})) count=0
- RMlist="$RMlist $1$2? r$1$2?"
- [ 0$7 -ne 8 ] && l="i j k l m n o p"
- for d in a b c d e f g h $l
- do
- M $1$2$d b $3 $(($n+$count)) 640
- M r$1$2$d c $4 $(($n+$count)) 640
- let count=count+1
- done
- MKlist="$MKlist;chown root.operator $1$2? r$1$2?"
-}
-
-dodisk2()
-{
- n=$(($(($5*${7:-16}))+$6))
- M $1$2a b $3 $n 640 operator
- M r$1$2a c $4 $n 640 operator
- n=$(($n+2))
- M $1$2c b $3 $n 640 operator
- M r$1$2c c $4 $n 640 operator
-}
-
-# M name b/c major minor [mode] [group]
-RMlist="rm -f"
-MKlist=":"
-
-mkl() {
- [ "${mklist[$1]}" ] && {
- mklist[$1]="${mklist[$1]};mknod -m $1 $2 $3 $4 $5"
- } || {
- mklist[$1]="mknod -m $1 $2 $3 $4 $5"
- modes="$modes $1"
- }
-}
-
-M() {
- RMlist="$RMlist $1"
- mkl ${5-666} $1 $2 $3 $4
- mklist="$mklist $1"
- G=${6:-wheel}
- [ "$7" ] && {
- MKlist="$MKlist;chown $7.$G $1"
- } || {
- case $G in
- wheel)g=0;;kmem)g=2;;operator)g=5;;tty)g=4;;dialer)g=117;;
- esac
- [ "${grplist[$g]}" ] && {
- grplist[$g]="${grplist[$g]} $1"
- } || {
- groups="$groups $g"
- grplist[$g]="chgrp $G $1"
- }
- }
- return 0
-}
-
-R() {
-[ "$DEBUG" ] && set -x
-for i in "$@"
-do
-U=`unt $i`
-[ "$U" ] || U=0
-
-case $i in
-
-)
- case $i in
- esac
- ;;
-
-*)
- echo $i: unknown device
- ;;
-esac
-done
-}
-R "$@"
-if [ "$os" = "SunOS" ]; then
- eo=transform
- transform() {
- case $mode in
- 600) mask=077;;
- 640) mask=027;;
- 660) mask=007;;
- 644) mask=022;;
- 666) mask=0;;
- 440) mask=227;;
- esac
- echo `echo "$@"|sed \
- 's/mknod -m \([0-9]*\) /umask '$mask';mknod /;s/-m [0-9]* //g;\
- s/operator/5/g;s/root.kmem/root.2/g;s/root\./root:/g'`
- }
-fi
-list="$RMlist"
-for mode in $modes; do
- list="$list;${mklist[$mode]}"
-done
-for group in $groups; do
- list="$list;${grplist[$group]}"
-done
-list="$list;$MKlist"
-if [ "$eo" = "echo" -o "$eo" = "transform" ]; then
- $eo "$list"
-else
- echo "$list" | sh
-fi