summaryrefslogtreecommitdiff
path: root/comms
diff options
context:
space:
mode:
authorjlam <jlam>2003-08-30 20:22:49 +0000
committerjlam <jlam>2003-08-30 20:22:49 +0000
commit20b85a151292d1c2495d2fba787ca26293c7a9e2 (patch)
treed334e2fd95050def4488e848ea48612e6f9103a4 /comms
parent1c9f4e0bdcaa144f30d977697cd5fdfe70963ce1 (diff)
downloadpkgsrc-20b85a151292d1c2495d2fba787ca26293c7a9e2.tar.gz
Prepare for pkgviews by making sure that passing VIEW-INSTALL or
VIEW-DEINSTALL to the INSTALL/DEINSTALL scripts don't cause errors.
Diffstat (limited to 'comms')
-rw-r--r--comms/mgetty+sendfax/DEINSTALL17
-rwxr-xr-xcomms/mgetty+sendfax/INSTALL22
2 files changed, 21 insertions, 18 deletions
diff --git a/comms/mgetty+sendfax/DEINSTALL b/comms/mgetty+sendfax/DEINSTALL
index 5c99803b1ba..0b86b3699ee 100644
--- a/comms/mgetty+sendfax/DEINSTALL
+++ b/comms/mgetty+sendfax/DEINSTALL
@@ -1,10 +1,15 @@
#!/bin/sh
#
+# $NetBSD: DEINSTALL,v 1.4 2003/08/30 20:22:50 jlam Exp $
-if [ -d /var/spool/fax ]; then
- filecount="`find /var/spool/fax -type f 2>/dev/null | wc -l`"
- if [ $filecount -eq 0 ]; then
- echo "Removing empty fax spool directories..."
- rm -r /var/spool/fax
+case ${STAGE} in
+DEINSTALL)
+ if [ -d /var/spool/fax ]; then
+ filecount="`${FIND} /var/spool/fax -type f 2>/dev/null | wc -l`"
+ if [ $filecount -eq 0 ]; then
+ ${ECHO} "Removing empty fax spool directories..."
+ ${RM} -r /var/spool/fax
+ fi
fi
-fi
+ ;;
+esac
diff --git a/comms/mgetty+sendfax/INSTALL b/comms/mgetty+sendfax/INSTALL
index 46b7b1387ba..c549a1bbfc1 100755
--- a/comms/mgetty+sendfax/INSTALL
+++ b/comms/mgetty+sendfax/INSTALL
@@ -1,27 +1,25 @@
#!/bin/sh
#
+# $NetBSD: INSTALL,v 1.4 2003/08/30 20:22:50 jlam Exp $
-if [ x"$2" = xPOST-INSTALL ]
-then
- if [ ! -d /var/spool/fax ]
- then
- echo "Creating fax spool directories..."
+case ${STAGE} in
+POST-INSTALL)
+ if [ ! -d /var/spool/fax ]; then
+ ${ECHO} "Creating fax spool directories..."
${MKDIR} /var/spool/fax
${CHMOD} 755 /var/spool/fax
fi
- if [ ! -d /var/spool/fax/incoming ]
- then
+ if [ ! -d /var/spool/fax/incoming ]; then
${MKDIR} /var/spool/fax/incoming
${CHMOD} 755 /var/spool/fax/incoming
fi
- if [ ! -d /var/spool/fax/outgoing ]
- then
+ if [ ! -d /var/spool/fax/outgoing ]; then
${MKDIR} /var/spool/fax/outgoing
${CHMOD} 1777 /var/spool/fax/outgoing
fi
- if [ ! -d /var/spool/fax/outgoing/locks ]
- then
+ if [ ! -d /var/spool/fax/outgoing/locks ]; then
${MKDIR} /var/spool/fax/outgoing/locks
${CHMOD} 777 /var/spool/fax/outgoing/locks
fi
-fi
+ ;;
+esac