summaryrefslogtreecommitdiff
path: root/emulators/suse100_base/files/linux-mkpwd.sh
diff options
context:
space:
mode:
Diffstat (limited to 'emulators/suse100_base/files/linux-mkpwd.sh')
-rw-r--r--emulators/suse100_base/files/linux-mkpwd.sh24
1 files changed, 21 insertions, 3 deletions
diff --git a/emulators/suse100_base/files/linux-mkpwd.sh b/emulators/suse100_base/files/linux-mkpwd.sh
index d751a771b8d..24409a0fc7c 100644
--- a/emulators/suse100_base/files/linux-mkpwd.sh
+++ b/emulators/suse100_base/files/linux-mkpwd.sh
@@ -1,13 +1,31 @@
#!/bin/sh
#
-# $NetBSD: linux-mkpwd.sh,v 1.1.1.1 2006/03/09 20:34:10 tonio Exp $
+# $NetBSD: linux-mkpwd.sh,v 1.2 2007/07/29 05:18:40 jlam Exp $
+#
+
+######################################################################
+#
+# NAME
+# @LINUX_BASE@-mkpwd -- create passwd/group files for COMPAT_LINUX
+#
+# SYNOPSYS
+# @LINUX_BASE@-mkpwd
+#
+# DESCRIPTION
+# @LINUX_BASE@-mkpwd creates passwd and group files and databases
+# for a COMPAT_LINUX installation based on the files found in
+# /etc, e.g. /etc/passwd, /etc/master.passwd, /etc/group, etc.
+#
+######################################################################
SRCDIR=/etc
-DESTDIR=@@EMULDIR@@/etc
+DESTDIR=@EMULDIR@/etc
+
+[ -d $DESTDIR ] || exit 1
umask 22
cd $DESTDIR
-cp $SRCDIR/passwd .
+cp -f $SRCDIR/passwd .
sed s/^wheel:/root:/ <$SRCDIR/group >group
umask 77