aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjgh <jgh@FreeBSD.org>2012-03-29 05:10:24 +0800
committerjgh <jgh@FreeBSD.org>2012-03-29 05:10:24 +0800
commit73ebf8a8f148cc0bd1e2771436c627bc1d9aab91 (patch)
tree1788aac28db30d1e02a9d52a6389e5976ca858d0
parent3a7ddc3fe4b1895f0a51d6e9a0af9ebdc9d9ba0c (diff)
downloadfreebsd-ports-gnome-73ebf8a8f148cc0bd1e2771436c627bc1d9aab91.tar.gz
freebsd-ports-gnome-73ebf8a8f148cc0bd1e2771436c627bc1d9aab91.tar.zst
freebsd-ports-gnome-73ebf8a8f148cc0bd1e2771436c627bc1d9aab91.zip
- drop invalid post-deinstall target, and add pkg-deinstall script
- while here adjust install scripts PR: ports/166094 Submitted by: jgh Approved by: maintainer timeout ( 14 days ) Feature safe: yes
-rw-r--r--www/abyssws/Makefile6
-rw-r--r--www/abyssws/pkg-deinstall35
-rw-r--r--www/abyssws/pkg-install25
3 files changed, 36 insertions, 30 deletions
diff --git a/www/abyssws/Makefile b/www/abyssws/Makefile
index 0ab4096da2cc..202f0bcd7b44 100644
--- a/www/abyssws/Makefile
+++ b/www/abyssws/Makefile
@@ -7,6 +7,7 @@
PORTNAME= abyssws
PORTVERSION= 2.6
+PORTREVISION= 1
CATEGORIES= www
MASTER_SITES= http://www.aprelium.com/data/
DISTNAME= abwsx1-freebsd
@@ -18,7 +19,6 @@ COMMENT= Abyss Web Server is a compact and easy to use web server
WRKSRC= ${WRKDIR}/abyssws
ONLY_FOR_ARCHS= i386
NO_BUILD= yes
-PKGDEINSTALL= ${PKGINSTALL}
USE_RC_SUBR= abyssws.sh
@@ -50,8 +50,4 @@ post-install:
@${SETENV} PKG_PREFIX=${PREFIX} \
${SH} ${PKGINSTALL} ${PORTNAME} POST-INSTALL
-post-deinstall:
- @${SETENV} PKG_PREFIX=${PREFIX} \
- ${SH} ${PKGDEINSTALL} ${PORTNAME} POST-DEINSTALL
-
.include <bsd.port.post.mk>
diff --git a/www/abyssws/pkg-deinstall b/www/abyssws/pkg-deinstall
new file mode 100644
index 000000000000..662608c66780
--- /dev/null
+++ b/www/abyssws/pkg-deinstall
@@ -0,0 +1,35 @@
+#!/bin/sh
+
+PATH=/bin:/usr/sbin
+WSHOME=${PREFIX}/lib/abyssws
+
+USER=abyssws
+GROUP=${USER}
+
+if [ "$2" = "DEINSTALL" ]; then
+
+ if ! [ -x ${WSHOME} ] ; then
+ if pw group show "${GROUP}" 2>/dev/null; then
+ if pw groupdel ${GROUP}; then
+ echo "Removed group \"${GROUP}\"."
+ else
+ echo "Removing group \"${GROUP}\" failed..."
+ exit 1
+ fi
+ else
+ echo "Group \"${GROUP}\" doesn't exist!"
+ fi
+
+ if pw user show "${USER}" 2>/dev/null; then
+ if pw userdel ${USER}; then
+ echo "Removed user \"${USER}\"."
+ else
+ echo "Removing user \"${USER}\" failed..."
+ exit 1
+ fi
+ else
+ echo "User \"${USER}\" doesn't exist!"
+ fi
+ fi
+
+fi
diff --git a/www/abyssws/pkg-install b/www/abyssws/pkg-install
index 6197af7277fa..738341e4f1d6 100644
--- a/www/abyssws/pkg-install
+++ b/www/abyssws/pkg-install
@@ -49,30 +49,5 @@ POST-INSTALL)
;;
-POST-DEINSTALL)
- if ! [ -x ${WSHOME} ] ; then
- if pw group show "${GROUP}" 2>/dev/null; then
- if pw groupdel ${GROUP}; then
- echo "Removed group \"${GROUP}\"."
- else
- echo "Removing group \"${GROUP}\" failed..."
- exit 1
- fi
- else
- echo "Group \"${GROUP}\" doesn't exist!"
- fi
-
- if pw user show "${USER}" 2>/dev/null; then
- if pw userdel ${USER}; then
- echo "Removed user \"${USER}\"."
- else
- echo "Removing user \"${USER}\" failed..."
- exit 1
- fi
- else
- echo "User \"${USER}\" doesn't exist!"
- fi
- fi
- ;;
esac