|
@ -1,7 +1,7 @@ |
|
|
|
|
|
|
|
|
#!/bin/sh - |
|
|
#!/bin/sh - |
|
|
# |
|
|
# |
|
|
# $OpenBSD: MAKEDEV,v 1.5 2001/09/04 19:17:06 todd Exp $ |
|
|
|
|
|
|
|
|
# $OpenBSD: MAKEDEV,v 1.6 2001/09/04 20:16:46 todd Exp $ |
|
|
# |
|
|
# |
|
|
# Copyright (c) 2001 Todd T. Fries <todd@OpenBSD.org> |
|
|
# Copyright (c) 2001 Todd T. Fries <todd@OpenBSD.org> |
|
|
# All rights reserved. |
|
|
# All rights reserved. |
|
@ -81,8 +81,6 @@ |
|
|
# |
|
|
# |
|
|
PATH=/sbin:/usr/sbin:/bin:/usr/bin |
|
|
PATH=/sbin:/usr/sbin:/bin:/usr/bin |
|
|
T=$0 |
|
|
T=$0 |
|
|
|
|
|
|
|
|
# default shell support functions |
|
|
|
|
|
hex() |
|
|
hex() |
|
|
{ |
|
|
{ |
|
|
case $1 in |
|
|
case $1 in |
|
@ -165,11 +163,19 @@ M() { |
|
|
[ "$G" ] && { |
|
|
[ "$G" ] && { |
|
|
[ "$7" ] && { |
|
|
[ "$7" ] && { |
|
|
MKlist="$MKlist;chown $7.$G $1" |
|
|
MKlist="$MKlist;chown $7.$G $1" |
|
|
} || MKlist="$MKlist;chgrp $G $1" |
|
|
|
|
|
|
|
|
} || cgp $G $1 |
|
|
} |
|
|
} |
|
|
return 0 |
|
|
return 0 |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
cgp() { |
|
|
|
|
|
G=$1 |
|
|
|
|
|
[ "${grplist[$G]}" ] && { |
|
|
|
|
|
grplist[$G]="${grplist[$G]} $2" |
|
|
|
|
|
} || { |
|
|
|
|
|
groups="$groups $G" |
|
|
|
|
|
grplist[$G]="chgrp $G $2" |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
R() { |
|
|
R() { |
|
|
for i in "$@" |
|
|
for i in "$@" |
|
|
do |
|
|
do |
|
@ -354,9 +360,7 @@ st*) |
|
|
ses*) |
|
|
ses*) |
|
|
M ses$U c 4 $U 640 operator;; |
|
|
M ses$U c 4 $U 640 operator;; |
|
|
ch*) M ch$U c 19 $U 660 operator;; |
|
|
ch*) M ch$U c 19 $U 660 operator;; |
|
|
lkm) |
|
|
|
|
|
M lkm c 112 0 640 kmem |
|
|
|
|
|
;; |
|
|
|
|
|
|
|
|
lkm)M lkm c 112 0 640 kmem;; |
|
|
xfs*) M xfs$U c 51 $U 600;; |
|
|
xfs*) M xfs$U c 51 $U 600;; |
|
|
*random) |
|
|
*random) |
|
|
n=0 |
|
|
n=0 |
|
@ -397,4 +401,7 @@ $eo eval $RMlist |
|
|
for mode in $modes; do |
|
|
for mode in $modes; do |
|
|
$eo eval ${mklist[$mode]} |
|
|
$eo eval ${mklist[$mode]} |
|
|
done |
|
|
done |
|
|
|
|
|
for group in $groups; do |
|
|
|
|
|
$eo eval ${grplist[$groupl]} |
|
|
|
|
|
done |
|
|
$eo eval $MKlist |
|
|
$eo eval $MKlist |