aboutsummaryrefslogtreecommitdiffstats
path: root/security/cyrus-sasl2-saslauthd/pkg-deinstall
diff options
context:
space:
mode:
Diffstat (limited to 'security/cyrus-sasl2-saslauthd/pkg-deinstall')
-rw-r--r--security/cyrus-sasl2-saslauthd/pkg-deinstall31
1 files changed, 31 insertions, 0 deletions
diff --git a/security/cyrus-sasl2-saslauthd/pkg-deinstall b/security/cyrus-sasl2-saslauthd/pkg-deinstall
new file mode 100644
index 000000000000..db4488ed1b72
--- /dev/null
+++ b/security/cyrus-sasl2-saslauthd/pkg-deinstall
@@ -0,0 +1,31 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+PKG_BATCH=${BATCH:=NO}
+PKG_PREFIX=${PKG_PREFIX:=/usr/local}
+
+remove_file()
+{
+ file=$1
+
+ if cmp -s ${file} ${file}.tmp; then
+ rm -f ${file}
+ fi
+ rm -f ${file}.tmp
+}
+
+# This should really be uninstalled by Sendmail
+sendmail_conf() {
+ if [ -f ${PKG_PREFIX}/lib/sasl2/Sendmail.conf ]; then
+ echo "pwcheck_method: saslauthd" > ${PKG_PREFIX}/lib/sasl2/Sendmail.conf.tmp
+ remove_file ${PKG_PREFIX}/lib/sasl2/Sendmail.conf
+ fi
+}
+
+case $2 in
+DEINSTALL)
+ sendmail_conf
+ ;;
+esac