- Cleanup pkg-install script to handle documentation installation correctly.
This resulted in a bizarre case where making a backup package after an upgrade would fail (ports/135051). - Don't install obsolete files by adding them to ${WRKSRC}/conf/postfix-files. - Whitespace cleanup. - Define and pass DAEMONDIR to the pkg-install script. PR: ports/135051 Submitted by: Takefu Kenji <takefu@airport.fm>, Yarema <yds@CoolRat.org> Approved by: sahil@tandon.net (maintainer)
This commit is contained in:
parent
a6299e5d25
commit
befbdedefe
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=235559
15 changed files with 170 additions and 65 deletions
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= postfix
|
||||
PORTVERSION= 2.6.2
|
||||
PORTREVISION= 1
|
||||
PORTEPOCH= 1
|
||||
CATEGORIES= mail ipv6
|
||||
MASTER_SITES= ftp://ftp.porcupine.org/mirrors/postfix-release/official/ \
|
||||
|
@ -77,6 +78,9 @@ MLINKS= sendmail.1 mailq.1 \
|
|||
bounce.8 trace.8 \
|
||||
smtp.8 lmtp.8
|
||||
|
||||
HTML1= SOHO_README.html body_checks.5.html bounce.5.html postfix-power.png \
|
||||
scache.8.html tlsmgr.8.html
|
||||
|
||||
.if !defined(DEBUG)
|
||||
MAKEFILEFLAGS+= DEBUG=
|
||||
.endif
|
||||
|
@ -86,7 +90,7 @@ MAKEFILEFLAGS+= CC="${CC}" OPT="${CFLAGS}"
|
|||
.include <bsd.port.pre.mk>
|
||||
|
||||
POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${PREFIX}/libexec/postfix\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${DAEMONDIR}\\\" \
|
||||
-DDEF_COMMAND_DIR=\\\"${PREFIX}/sbin\\\" \
|
||||
-DDEF_SENDMAIL_PATH=\\\"${PREFIX}/sbin/sendmail\\\" \
|
||||
-DDEF_NEWALIAS_PATH=\\\"${PREFIX}/bin/newaliases\\\" \
|
||||
|
@ -211,12 +215,14 @@ PLIST_SUB+= TEST="@comment "
|
|||
.endif
|
||||
|
||||
.if defined(NOPORTDOCS)
|
||||
READMEDIR=no
|
||||
READMEDIR= no
|
||||
.else
|
||||
READMEDIR=${DOCSDIR}
|
||||
READMEDIR= ${DOCSDIR}
|
||||
.endif
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}"
|
||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}" DAEMONDIR="${DAEMONDIR}"
|
||||
SUB_FILES+= pkg-install pkg-message
|
||||
|
||||
# sed script for files in ${WRKSRC}/README_FILES ${WRKSRC}/conf ${WRKSRC}/man
|
||||
|
@ -274,6 +280,12 @@ pre-patch:
|
|||
${REINPLACE_CMD} -E -e '${REINPLACE}'
|
||||
|
||||
post-patch:
|
||||
@${ECHO} '$$readme_directory/SOHO_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.for f in ${HTML1}
|
||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.endfor
|
||||
.if defined(WITH_VDA)
|
||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
|
@ -290,7 +302,10 @@ pre-su-install:
|
|||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
|
||||
|
||||
do-install:
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
||||
|
@ -300,16 +315,11 @@ do-install:
|
|||
.for f in ${MANTEST}
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
||||
.endfor
|
||||
.if !defined(NOPORTDOCS)
|
||||
${INSTALL} -o ${DOCOWN} -g ${DOCGRP} -m 555 -d ${DOCSDIR}
|
||||
@cd ${WRKSRC}/html && ${INSTALL_DATA} *.html *.jpg *.png ${DOCSDIR} && \
|
||||
${ECHO_MSG} "Installed HTML documentation in ${DOCSDIR}"
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
# Fix compressed man pages
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${PREFIX}/libexec/postfix/postfix-files
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${DAEMONDIR}/postfix-files
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix/files/pkg-install.in,v 1.2 2009-06-04 07:45:27 mm Exp $
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix/files/pkg-install.in,v 1.3 2009-06-11 01:42:24 wxs Exp $
|
||||
#
|
||||
|
||||
# If the POSTFIX_DEFAULT_MTA environment variable is set to YES, it
|
||||
|
@ -9,7 +9,7 @@
|
|||
|
||||
PREFIX=${PKG_PREFIX:=%%PREFIX%%}
|
||||
ETCDIR=${ETCDIR:=%%ETCDIR%%}
|
||||
DAEMONDIR=${DAEMONDIR:=${PREFIX}/libexec/postfix}
|
||||
DAEMONDIR=${DAEMONDIR:=%%DAEMONDIR%%}
|
||||
READMEDIR=${READMEDIR:=%%READMEDIR%%}
|
||||
BATCH=${BATCH:=no}
|
||||
POSTFIX_DEFAULT_MTA=${POSTFIX_DEFAULT_MTA:=no}
|
||||
|
@ -114,8 +114,18 @@ if [ "$2" = "PRE-INSTALL" ]; then
|
|||
fi
|
||||
|
||||
if [ "$2" = "POST-INSTALL" ]; then
|
||||
SAMPLES="main.cf master.cf"
|
||||
for file in $SAMPLES
|
||||
do
|
||||
if [ ! -f ${ETCDIR}/$file ]; then
|
||||
cp ${DAEMONDIR}/$file ${ETCDIR}/
|
||||
fi
|
||||
done
|
||||
|
||||
/bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR} \
|
||||
upgrade-package
|
||||
fi
|
||||
|
||||
|
|
|
@ -136,6 +136,7 @@ sbin/sendmail
|
|||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_POLICY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README.html
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= postfix
|
||||
PORTVERSION= 2.6.2
|
||||
PORTREVISION= 1
|
||||
PORTEPOCH= 1
|
||||
CATEGORIES= mail ipv6
|
||||
MASTER_SITES= ftp://ftp.porcupine.org/mirrors/postfix-release/official/ \
|
||||
|
@ -77,6 +78,9 @@ MLINKS= sendmail.1 mailq.1 \
|
|||
bounce.8 trace.8 \
|
||||
smtp.8 lmtp.8
|
||||
|
||||
HTML1= SOHO_README.html body_checks.5.html bounce.5.html postfix-power.png \
|
||||
scache.8.html tlsmgr.8.html
|
||||
|
||||
.if !defined(DEBUG)
|
||||
MAKEFILEFLAGS+= DEBUG=
|
||||
.endif
|
||||
|
@ -86,7 +90,7 @@ MAKEFILEFLAGS+= CC="${CC}" OPT="${CFLAGS}"
|
|||
.include <bsd.port.pre.mk>
|
||||
|
||||
POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${PREFIX}/libexec/postfix\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${DAEMONDIR}\\\" \
|
||||
-DDEF_COMMAND_DIR=\\\"${PREFIX}/sbin\\\" \
|
||||
-DDEF_SENDMAIL_PATH=\\\"${PREFIX}/sbin/sendmail\\\" \
|
||||
-DDEF_NEWALIAS_PATH=\\\"${PREFIX}/bin/newaliases\\\" \
|
||||
|
@ -211,12 +215,14 @@ PLIST_SUB+= TEST="@comment "
|
|||
.endif
|
||||
|
||||
.if defined(NOPORTDOCS)
|
||||
READMEDIR=no
|
||||
READMEDIR= no
|
||||
.else
|
||||
READMEDIR=${DOCSDIR}
|
||||
READMEDIR= ${DOCSDIR}
|
||||
.endif
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}"
|
||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}" DAEMONDIR="${DAEMONDIR}"
|
||||
SUB_FILES+= pkg-install pkg-message
|
||||
|
||||
# sed script for files in ${WRKSRC}/README_FILES ${WRKSRC}/conf ${WRKSRC}/man
|
||||
|
@ -274,6 +280,12 @@ pre-patch:
|
|||
${REINPLACE_CMD} -E -e '${REINPLACE}'
|
||||
|
||||
post-patch:
|
||||
@${ECHO} '$$readme_directory/SOHO_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.for f in ${HTML1}
|
||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.endfor
|
||||
.if defined(WITH_VDA)
|
||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
|
@ -290,7 +302,10 @@ pre-su-install:
|
|||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
|
||||
|
||||
do-install:
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
||||
|
@ -300,16 +315,11 @@ do-install:
|
|||
.for f in ${MANTEST}
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
||||
.endfor
|
||||
.if !defined(NOPORTDOCS)
|
||||
${INSTALL} -o ${DOCOWN} -g ${DOCGRP} -m 555 -d ${DOCSDIR}
|
||||
@cd ${WRKSRC}/html && ${INSTALL_DATA} *.html *.jpg *.png ${DOCSDIR} && \
|
||||
${ECHO_MSG} "Installed HTML documentation in ${DOCSDIR}"
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
# Fix compressed man pages
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${PREFIX}/libexec/postfix/postfix-files
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${DAEMONDIR}/postfix-files
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix25/files/Attic/pkg-install.in,v 1.2 2009-06-04 07:45:27 mm Exp $
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix25/files/Attic/pkg-install.in,v 1.3 2009-06-11 01:42:24 wxs Exp $
|
||||
#
|
||||
|
||||
# If the POSTFIX_DEFAULT_MTA environment variable is set to YES, it
|
||||
|
@ -9,7 +9,7 @@
|
|||
|
||||
PREFIX=${PKG_PREFIX:=%%PREFIX%%}
|
||||
ETCDIR=${ETCDIR:=%%ETCDIR%%}
|
||||
DAEMONDIR=${DAEMONDIR:=${PREFIX}/libexec/postfix}
|
||||
DAEMONDIR=${DAEMONDIR:=%%DAEMONDIR%%}
|
||||
READMEDIR=${READMEDIR:=%%READMEDIR%%}
|
||||
BATCH=${BATCH:=no}
|
||||
POSTFIX_DEFAULT_MTA=${POSTFIX_DEFAULT_MTA:=no}
|
||||
|
@ -114,8 +114,18 @@ if [ "$2" = "PRE-INSTALL" ]; then
|
|||
fi
|
||||
|
||||
if [ "$2" = "POST-INSTALL" ]; then
|
||||
SAMPLES="main.cf master.cf"
|
||||
for file in $SAMPLES
|
||||
do
|
||||
if [ ! -f ${ETCDIR}/$file ]; then
|
||||
cp ${DAEMONDIR}/$file ${ETCDIR}/
|
||||
fi
|
||||
done
|
||||
|
||||
/bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR} \
|
||||
upgrade-package
|
||||
fi
|
||||
|
||||
|
|
|
@ -136,6 +136,7 @@ sbin/sendmail
|
|||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_POLICY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README.html
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= postfix
|
||||
PORTVERSION= 2.6.2
|
||||
PORTREVISION= 1
|
||||
PORTEPOCH= 1
|
||||
CATEGORIES= mail ipv6
|
||||
MASTER_SITES= ftp://ftp.porcupine.org/mirrors/postfix-release/official/ \
|
||||
|
@ -77,6 +78,9 @@ MLINKS= sendmail.1 mailq.1 \
|
|||
bounce.8 trace.8 \
|
||||
smtp.8 lmtp.8
|
||||
|
||||
HTML1= SOHO_README.html body_checks.5.html bounce.5.html postfix-power.png \
|
||||
scache.8.html tlsmgr.8.html
|
||||
|
||||
.if !defined(DEBUG)
|
||||
MAKEFILEFLAGS+= DEBUG=
|
||||
.endif
|
||||
|
@ -86,7 +90,7 @@ MAKEFILEFLAGS+= CC="${CC}" OPT="${CFLAGS}"
|
|||
.include <bsd.port.pre.mk>
|
||||
|
||||
POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${PREFIX}/libexec/postfix\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${DAEMONDIR}\\\" \
|
||||
-DDEF_COMMAND_DIR=\\\"${PREFIX}/sbin\\\" \
|
||||
-DDEF_SENDMAIL_PATH=\\\"${PREFIX}/sbin/sendmail\\\" \
|
||||
-DDEF_NEWALIAS_PATH=\\\"${PREFIX}/bin/newaliases\\\" \
|
||||
|
@ -211,12 +215,14 @@ PLIST_SUB+= TEST="@comment "
|
|||
.endif
|
||||
|
||||
.if defined(NOPORTDOCS)
|
||||
READMEDIR=no
|
||||
READMEDIR= no
|
||||
.else
|
||||
READMEDIR=${DOCSDIR}
|
||||
READMEDIR= ${DOCSDIR}
|
||||
.endif
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}"
|
||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}" DAEMONDIR="${DAEMONDIR}"
|
||||
SUB_FILES+= pkg-install pkg-message
|
||||
|
||||
# sed script for files in ${WRKSRC}/README_FILES ${WRKSRC}/conf ${WRKSRC}/man
|
||||
|
@ -274,6 +280,12 @@ pre-patch:
|
|||
${REINPLACE_CMD} -E -e '${REINPLACE}'
|
||||
|
||||
post-patch:
|
||||
@${ECHO} '$$readme_directory/SOHO_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.for f in ${HTML1}
|
||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.endfor
|
||||
.if defined(WITH_VDA)
|
||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
|
@ -290,7 +302,10 @@ pre-su-install:
|
|||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
|
||||
|
||||
do-install:
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
||||
|
@ -300,16 +315,11 @@ do-install:
|
|||
.for f in ${MANTEST}
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
||||
.endfor
|
||||
.if !defined(NOPORTDOCS)
|
||||
${INSTALL} -o ${DOCOWN} -g ${DOCGRP} -m 555 -d ${DOCSDIR}
|
||||
@cd ${WRKSRC}/html && ${INSTALL_DATA} *.html *.jpg *.png ${DOCSDIR} && \
|
||||
${ECHO_MSG} "Installed HTML documentation in ${DOCSDIR}"
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
# Fix compressed man pages
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${PREFIX}/libexec/postfix/postfix-files
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${DAEMONDIR}/postfix-files
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix26/files/pkg-install.in,v 1.2 2009-06-04 07:45:27 mm Exp $
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix26/files/pkg-install.in,v 1.3 2009-06-11 01:42:24 wxs Exp $
|
||||
#
|
||||
|
||||
# If the POSTFIX_DEFAULT_MTA environment variable is set to YES, it
|
||||
|
@ -9,7 +9,7 @@
|
|||
|
||||
PREFIX=${PKG_PREFIX:=%%PREFIX%%}
|
||||
ETCDIR=${ETCDIR:=%%ETCDIR%%}
|
||||
DAEMONDIR=${DAEMONDIR:=${PREFIX}/libexec/postfix}
|
||||
DAEMONDIR=${DAEMONDIR:=%%DAEMONDIR%%}
|
||||
READMEDIR=${READMEDIR:=%%READMEDIR%%}
|
||||
BATCH=${BATCH:=no}
|
||||
POSTFIX_DEFAULT_MTA=${POSTFIX_DEFAULT_MTA:=no}
|
||||
|
@ -114,8 +114,18 @@ if [ "$2" = "PRE-INSTALL" ]; then
|
|||
fi
|
||||
|
||||
if [ "$2" = "POST-INSTALL" ]; then
|
||||
SAMPLES="main.cf master.cf"
|
||||
for file in $SAMPLES
|
||||
do
|
||||
if [ ! -f ${ETCDIR}/$file ]; then
|
||||
cp ${DAEMONDIR}/$file ${ETCDIR}/
|
||||
fi
|
||||
done
|
||||
|
||||
/bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR} \
|
||||
upgrade-package
|
||||
fi
|
||||
|
||||
|
|
|
@ -136,6 +136,7 @@ sbin/sendmail
|
|||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_POLICY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README.html
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= postfix
|
||||
PORTVERSION= 2.6.2
|
||||
PORTREVISION= 1
|
||||
PORTEPOCH= 1
|
||||
CATEGORIES= mail ipv6
|
||||
MASTER_SITES= ftp://ftp.porcupine.org/mirrors/postfix-release/official/ \
|
||||
|
@ -77,6 +78,9 @@ MLINKS= sendmail.1 mailq.1 \
|
|||
bounce.8 trace.8 \
|
||||
smtp.8 lmtp.8
|
||||
|
||||
HTML1= SOHO_README.html body_checks.5.html bounce.5.html postfix-power.png \
|
||||
scache.8.html tlsmgr.8.html
|
||||
|
||||
.if !defined(DEBUG)
|
||||
MAKEFILEFLAGS+= DEBUG=
|
||||
.endif
|
||||
|
@ -86,7 +90,7 @@ MAKEFILEFLAGS+= CC="${CC}" OPT="${CFLAGS}"
|
|||
.include <bsd.port.pre.mk>
|
||||
|
||||
POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${PREFIX}/libexec/postfix\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${DAEMONDIR}\\\" \
|
||||
-DDEF_COMMAND_DIR=\\\"${PREFIX}/sbin\\\" \
|
||||
-DDEF_SENDMAIL_PATH=\\\"${PREFIX}/sbin/sendmail\\\" \
|
||||
-DDEF_NEWALIAS_PATH=\\\"${PREFIX}/bin/newaliases\\\" \
|
||||
|
@ -211,12 +215,14 @@ PLIST_SUB+= TEST="@comment "
|
|||
.endif
|
||||
|
||||
.if defined(NOPORTDOCS)
|
||||
READMEDIR=no
|
||||
READMEDIR= no
|
||||
.else
|
||||
READMEDIR=${DOCSDIR}
|
||||
READMEDIR= ${DOCSDIR}
|
||||
.endif
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}"
|
||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}" DAEMONDIR="${DAEMONDIR}"
|
||||
SUB_FILES+= pkg-install pkg-message
|
||||
|
||||
# sed script for files in ${WRKSRC}/README_FILES ${WRKSRC}/conf ${WRKSRC}/man
|
||||
|
@ -274,6 +280,12 @@ pre-patch:
|
|||
${REINPLACE_CMD} -E -e '${REINPLACE}'
|
||||
|
||||
post-patch:
|
||||
@${ECHO} '$$readme_directory/SOHO_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.for f in ${HTML1}
|
||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.endfor
|
||||
.if defined(WITH_VDA)
|
||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
|
@ -290,7 +302,10 @@ pre-su-install:
|
|||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
|
||||
|
||||
do-install:
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
||||
|
@ -300,16 +315,11 @@ do-install:
|
|||
.for f in ${MANTEST}
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
||||
.endfor
|
||||
.if !defined(NOPORTDOCS)
|
||||
${INSTALL} -o ${DOCOWN} -g ${DOCGRP} -m 555 -d ${DOCSDIR}
|
||||
@cd ${WRKSRC}/html && ${INSTALL_DATA} *.html *.jpg *.png ${DOCSDIR} && \
|
||||
${ECHO_MSG} "Installed HTML documentation in ${DOCSDIR}"
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
# Fix compressed man pages
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${PREFIX}/libexec/postfix/postfix-files
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${DAEMONDIR}/postfix-files
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix27/files/pkg-install.in,v 1.2 2009-06-04 07:45:27 mm Exp $
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix27/files/pkg-install.in,v 1.3 2009-06-11 01:42:24 wxs Exp $
|
||||
#
|
||||
|
||||
# If the POSTFIX_DEFAULT_MTA environment variable is set to YES, it
|
||||
|
@ -9,7 +9,7 @@
|
|||
|
||||
PREFIX=${PKG_PREFIX:=%%PREFIX%%}
|
||||
ETCDIR=${ETCDIR:=%%ETCDIR%%}
|
||||
DAEMONDIR=${DAEMONDIR:=${PREFIX}/libexec/postfix}
|
||||
DAEMONDIR=${DAEMONDIR:=%%DAEMONDIR%%}
|
||||
READMEDIR=${READMEDIR:=%%READMEDIR%%}
|
||||
BATCH=${BATCH:=no}
|
||||
POSTFIX_DEFAULT_MTA=${POSTFIX_DEFAULT_MTA:=no}
|
||||
|
@ -114,8 +114,18 @@ if [ "$2" = "PRE-INSTALL" ]; then
|
|||
fi
|
||||
|
||||
if [ "$2" = "POST-INSTALL" ]; then
|
||||
SAMPLES="main.cf master.cf"
|
||||
for file in $SAMPLES
|
||||
do
|
||||
if [ ! -f ${ETCDIR}/$file ]; then
|
||||
cp ${DAEMONDIR}/$file ${ETCDIR}/
|
||||
fi
|
||||
done
|
||||
|
||||
/bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR} \
|
||||
upgrade-package
|
||||
fi
|
||||
|
||||
|
|
|
@ -136,6 +136,7 @@ sbin/sendmail
|
|||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_POLICY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README.html
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= postfix
|
||||
PORTVERSION= 2.6.2
|
||||
PORTREVISION= 1
|
||||
PORTEPOCH= 1
|
||||
CATEGORIES= mail ipv6
|
||||
MASTER_SITES= ftp://ftp.porcupine.org/mirrors/postfix-release/official/ \
|
||||
|
@ -77,6 +78,9 @@ MLINKS= sendmail.1 mailq.1 \
|
|||
bounce.8 trace.8 \
|
||||
smtp.8 lmtp.8
|
||||
|
||||
HTML1= SOHO_README.html body_checks.5.html bounce.5.html postfix-power.png \
|
||||
scache.8.html tlsmgr.8.html
|
||||
|
||||
.if !defined(DEBUG)
|
||||
MAKEFILEFLAGS+= DEBUG=
|
||||
.endif
|
||||
|
@ -86,7 +90,7 @@ MAKEFILEFLAGS+= CC="${CC}" OPT="${CFLAGS}"
|
|||
.include <bsd.port.pre.mk>
|
||||
|
||||
POSTFIX_CCARGS+= -DDEF_CONFIG_DIR=\\\"${ETCDIR}\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${PREFIX}/libexec/postfix\\\" \
|
||||
-DDEF_DAEMON_DIR=\\\"${DAEMONDIR}\\\" \
|
||||
-DDEF_COMMAND_DIR=\\\"${PREFIX}/sbin\\\" \
|
||||
-DDEF_SENDMAIL_PATH=\\\"${PREFIX}/sbin/sendmail\\\" \
|
||||
-DDEF_NEWALIAS_PATH=\\\"${PREFIX}/bin/newaliases\\\" \
|
||||
|
@ -211,12 +215,14 @@ PLIST_SUB+= TEST="@comment "
|
|||
.endif
|
||||
|
||||
.if defined(NOPORTDOCS)
|
||||
READMEDIR=no
|
||||
READMEDIR= no
|
||||
.else
|
||||
READMEDIR=${DOCSDIR}
|
||||
READMEDIR= ${DOCSDIR}
|
||||
.endif
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}"
|
||||
DAEMONDIR= ${PREFIX}/libexec/postfix
|
||||
|
||||
SUB_LIST+= REQUIRE="${_REQUIRE}" READMEDIR="${READMEDIR}" DAEMONDIR="${DAEMONDIR}"
|
||||
SUB_FILES+= pkg-install pkg-message
|
||||
|
||||
# sed script for files in ${WRKSRC}/README_FILES ${WRKSRC}/conf ${WRKSRC}/man
|
||||
|
@ -274,6 +280,12 @@ pre-patch:
|
|||
${REINPLACE_CMD} -E -e '${REINPLACE}'
|
||||
|
||||
post-patch:
|
||||
@${ECHO} '$$readme_directory/SOHO_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.for f in ${HTML1}
|
||||
@${ECHO} '$$html_directory/$f:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
.endfor
|
||||
.if defined(WITH_VDA)
|
||||
@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
|
||||
>> ${WRKSRC}/conf/postfix-files
|
||||
|
@ -290,7 +302,10 @@ pre-su-install:
|
|||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
|
||||
|
||||
do-install:
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp
|
||||
@cd ${WRKSRC} && ${SH} postfix-install -non-interactive install_root=/ tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/rmail/rmail ${PREFIX}/bin/rmail
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/auxiliary/qshape/qshape.pl ${PREFIX}/bin/qshape
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/qshape.1 ${MANPREFIX}/man/man1
|
||||
|
@ -300,16 +315,11 @@ do-install:
|
|||
.for f in ${MANTEST}
|
||||
${INSTALL_MAN} ${WRKSRC}/man/man1/${f} ${MANPREFIX}/man/man1
|
||||
.endfor
|
||||
.if !defined(NOPORTDOCS)
|
||||
${INSTALL} -o ${DOCOWN} -g ${DOCGRP} -m 555 -d ${DOCSDIR}
|
||||
@cd ${WRKSRC}/html && ${INSTALL_DATA} *.html *.jpg *.png ${DOCSDIR} && \
|
||||
${ECHO_MSG} "Installed HTML documentation in ${DOCSDIR}"
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
@${SETENV} ${SCRIPTS_ENV} PKG_PREFIX="${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
|
||||
# Fix compressed man pages
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${PREFIX}/libexec/postfix/postfix-files
|
||||
@${REINPLACE_CMD} -i '' -E -e "s|(man[158]/.*.[158]):|\1.gz:|g" ${DAEMONDIR}/postfix-files
|
||||
@${CAT} ${PKGMESSAGE}
|
||||
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix28/files/pkg-install.in,v 1.2 2009-06-04 07:45:27 mm Exp $
|
||||
# $FreeBSD: /tmp/pcvs/ports/mail/postfix28/files/pkg-install.in,v 1.3 2009-06-11 01:42:24 wxs Exp $
|
||||
#
|
||||
|
||||
# If the POSTFIX_DEFAULT_MTA environment variable is set to YES, it
|
||||
|
@ -9,7 +9,7 @@
|
|||
|
||||
PREFIX=${PKG_PREFIX:=%%PREFIX%%}
|
||||
ETCDIR=${ETCDIR:=%%ETCDIR%%}
|
||||
DAEMONDIR=${DAEMONDIR:=${PREFIX}/libexec/postfix}
|
||||
DAEMONDIR=${DAEMONDIR:=%%DAEMONDIR%%}
|
||||
READMEDIR=${READMEDIR:=%%READMEDIR%%}
|
||||
BATCH=${BATCH:=no}
|
||||
POSTFIX_DEFAULT_MTA=${POSTFIX_DEFAULT_MTA:=no}
|
||||
|
@ -114,8 +114,18 @@ if [ "$2" = "PRE-INSTALL" ]; then
|
|||
fi
|
||||
|
||||
if [ "$2" = "POST-INSTALL" ]; then
|
||||
SAMPLES="main.cf master.cf"
|
||||
for file in $SAMPLES
|
||||
do
|
||||
if [ ! -f ${ETCDIR}/$file ]; then
|
||||
cp ${DAEMONDIR}/$file ${ETCDIR}/
|
||||
fi
|
||||
done
|
||||
|
||||
/bin/sh ${DAEMONDIR}/post-install tempdir=/tmp \
|
||||
daemon_directory=${DAEMONDIR} \
|
||||
html_directory=${READMEDIR} \
|
||||
readme_directory=${READMEDIR} \
|
||||
upgrade-package
|
||||
fi
|
||||
|
||||
|
|
|
@ -136,6 +136,7 @@ sbin/sendmail
|
|||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_POLICY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SOHO_README.html
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README.html
|
||||
|
|
Loading…
Reference in a new issue