aboutsummaryrefslogtreecommitdiffstats
path: root/Mk
diff options
context:
space:
mode:
authorbdrewery <bdrewery@FreeBSD.org>2014-04-02 23:33:18 +0800
committerbdrewery <bdrewery@FreeBSD.org>2014-04-02 23:33:18 +0800
commit966bbc4ca732205c6bcc6d5bf01ef5cb83ce210c (patch)
tree4f916b6c195885ce329f08fce8f4a00025b1007f /Mk
parentd565bd0bc07c4eb0abec62c2b06f4a1032c6d24c (diff)
downloadfreebsd-ports-gnome-966bbc4ca732205c6bcc6d5bf01ef5cb83ce210c.tar.gz
freebsd-ports-gnome-966bbc4ca732205c6bcc6d5bf01ef5cb83ce210c.tar.zst
freebsd-ports-gnome-966bbc4ca732205c6bcc6d5bf01ef5cb83ce210c.zip
- Add NO_PREFIX_RMDIR to allow not removing PREFIX at deinstall if it does
not match LOCALBASE. This is needed for qmail ports where they install to a different PREFIX (/var/qmail), but only the main qmail port should remove and own the dir. Otherwise permissions are incorrectly set when using staging. With hat: portmgr
Diffstat (limited to 'Mk')
-rw-r--r--Mk/bsd.port.mk3
1 files changed, 2 insertions, 1 deletions
diff --git a/Mk/bsd.port.mk b/Mk/bsd.port.mk
index b1e1cf6dd89f..a3cb25d68409 100644
--- a/Mk/bsd.port.mk
+++ b/Mk/bsd.port.mk
@@ -5702,7 +5702,8 @@ add-plist-info:
# If we're installing into a non-standard PREFIX, we need to remove that directory at
# deinstall-time
.if !target(add-plist-post)
-.if (${PREFIX} != ${LOCALBASE} && ${PREFIX} != ${LINUXBASE} && ${PREFIX} != "/usr")
+.if (${PREFIX} != ${LOCALBASE} && ${PREFIX} != ${LINUXBASE} && \
+ ${PREFIX} != "/usr" && !defined(NO_PREFIX_RMDIR))
add-plist-post:
@${ECHO_CMD} "@unexec rmdir %D 2> /dev/null || true" >> ${TMPPLIST}
.endif