1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-23 04:23:08 +00:00

- support stage

This commit is contained in:
Yen-Ming Lee 2014-07-08 16:36:50 +00:00
parent 45eb02aedb
commit d2ce52745c
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=361269
2 changed files with 18 additions and 20 deletions

View File

@ -7,7 +7,7 @@ CATEGORIES= mail
MASTER_SITES= SF/logreporters/${PORTNAME}/release/${PORTVERSION}
EXTRACT_SUFX= .tgz
MAINTAINER= ports@FreeBSD.org
MAINTAINER= ports@FreeBSD.org
COMMENT= Amavisd-new log parser
LICENSE= MIT
@ -16,36 +16,35 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
PORTDOCS= Bugs Changes README
PORTEXAMPLES= ${PORTNAME}.conf
MAN1= ${PORTNAME}.1
USES= perl5
USES= perl5 shebangfix
USE_PERL5= run
NO_BUILD= yes
SHEBANG_FILES= amavis-logwatch
OPTIONS_DEFINE= EXAMPLES DOCS
OPTIONS_DEFAULT=EXAMPLES DOCS
.include <bsd.port.options.mk>
NO_STAGE= yes
post-patch:
@cd ${WRKSRC} && ${REINPLACE_CMD} -e '\
s!/usr/local/etc!${ETCDIR}! \
' ${PORTNAME} ${PORTNAME}.1 README
do-install:
${INSTALL_SCRIPT} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin
${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${MAN1PREFIX}/man/man1
${INSTALL_SCRIPT} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
${INSTALL_MAN} ${WRKSRC}/${PORTNAME}.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
@${CP} ${WRKSRC}/${PORTNAME}.conf ${WRKSRC}/${PORTNAME}.conf.sample
@${MKDIR} ${ETCDIR}
${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.conf.sample ${ETCDIR}
@${MKDIR} ${STAGEDIR}${ETCDIR}
${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.conf.sample ${STAGEDIR}${ETCDIR}
post-install:
@if [ ! -f ${ETCDIR}/${PORTNAME}.conf ]; then \
${CP} -p ${ETCDIR}/${PORTNAME}.conf.sample ${ETCDIR}/${PORTNAME}.conf; \
fi
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
cd ${WRKSRC} && ${INSTALL_MAN} ${PORTDOCS} ${DOCSDIR}
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${STAGEDIR}${DOCSDIR}
cd ${WRKSRC} && ${INSTALL_MAN} ${PORTDOCS} ${STAGEDIR}${DOCSDIR}
.endif
.if !defined(NOPORTEXAMPLES)
@${MKDIR} ${EXAMPLESDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${PORTEXAMPLES} ${EXAMPLESDIR}
.if ${PORT_OPTIONS:MEXAMPLES}
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${PORTEXAMPLES} ${STAGEDIR}${EXAMPLESDIR}
.endif
.include <bsd.port.mk>

View File

@ -1,5 +1,4 @@
@unexec if cmp -s %D/%%ETCDIR%%/amavis-logwatch.conf.sample %D/%%ETCDIR%%/amavis-logwatch.conf; then rm -f %D/%%ETCDIR%%/amavis-logwatch.conf; fi
%%ETCDIR%%/amavis-logwatch.conf.sample
@exec if [ ! -f %B/amavis-logwatch.conf ] ; then cp -p %B/%f %B/amavis-logwatch.conf; fi
man/man1/amavis-logwatch.1.gz
@dirrmtry %%ETCDIR%%
bin/amavis-logwatch