summaryrefslogtreecommitdiff
path: root/mail/postfix/files/pkg-install.in
diff options
context:
space:
mode:
Diffstat (limited to 'mail/postfix/files/pkg-install.in')
-rw-r--r--mail/postfix/files/pkg-install.in14
1 files changed, 9 insertions, 5 deletions
diff --git a/mail/postfix/files/pkg-install.in b/mail/postfix/files/pkg-install.in
index f8d9a47206fc..92185a153fc7 100644
--- a/mail/postfix/files/pkg-install.in
+++ b/mail/postfix/files/pkg-install.in
@@ -65,11 +65,15 @@ if [ "$2" = "POST-INSTALL" ]; then
fi
done
- /bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
- daemon_directory=${DAEMONDIR} \
- html_directory=${READMEDIR} \
- readme_directory=${READMEDIR} \
- upgrade-package
+ cmp ${DAEMONDIR}/main.cf ${ETCDIR}/main.cf >/dev/null 2>&1 \
+ && POSTARG="set-permissions" \
+ || POSTARG="upgrade-package"
+
+ /bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
+ daemon_directory=${DAEMONDIR} \
+ html_directory=${READMEDIR} \
+ readme_directory=${READMEDIR} \
+ ${POSTARG}
fi
if [ "$2" = "POST-INSTALL" -a -z "${PACKAGE_BUILDING}" -a -f "${MC}" ]; then