bcbae34226
Several ports had rc.d scripts with hardcoded command_interpreter string as /usr/bin/perl. This symlink is not guaranteed to be in place, and it isn't even an option for perl 5.20. For affected ports, the interpreter was changed to localbase. In one case, the interpreter was correct, but it wasn't surround by quotes. Since the rc.d script would break if a space was contained in ${PREFIX}, quotes were added in that case.
61 lines
1.8 KiB
Makefile
61 lines
1.8 KiB
Makefile
# Created by: Xavier Beaudouin <kiwi@oav.net>
|
|
# $FreeBSD$
|
|
|
|
PORTNAME= couriergraph
|
|
PORTVERSION= 20060202
|
|
PORTREVISION= 5
|
|
CATEGORIES= mail
|
|
MASTER_SITES= http://www.arschkrebs.de/postfix/${PORTNAME}/
|
|
DISTNAME= ${PORTNAME}
|
|
|
|
MAINTAINER= ports@FreeBSD.org
|
|
COMMENT= RRDtool frontend for Courier statistics
|
|
|
|
RUN_DEPENDS= rrdtool>=0:${PORTSDIR}/databases/rrdtool \
|
|
p5-File-Tail>=0:${PORTSDIR}/devel/p5-File-Tail
|
|
|
|
USES= perl5 shebangfix
|
|
USE_PERL5= run
|
|
SHEBANG_FILES= couriergraph.cgi couriergraph.pl
|
|
USE_RC_SUBR= ${PORTNAME}
|
|
NO_BUILD= yes
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
|
|
|
|
DATADIR?= /var/db/couriergraph
|
|
COURIERGRAPH_USER?= ${WWWOWN}
|
|
COURIERGRAPH_GROUP?= ${WWWGRP}
|
|
|
|
PLIST_SUB= COURIERGRAPH_USER=${COURIERGRAPH_USER} \
|
|
COURIERGRAPH_GROUP=${COURIERGRAPH_GROUP}
|
|
SUB_LIST= COURIERGRAPH_USER=${COURIERGRAPH_USER} \
|
|
COURIERGRAPH_GROUP=${COURIERGRAPH_GROUP}
|
|
STARTUP_FILE= ${PREFIX}/etc/rc.d/couriergraph.sh
|
|
|
|
SUB_FILES= pkg-message
|
|
|
|
pre-everything::
|
|
@${ECHO_MSG}
|
|
@${ECHO_MSG} "You may set the following options:"
|
|
@${ECHO_MSG}
|
|
@${ECHO_MSG} "DATADIR=/var/db/couriergraph Where do you put RRD databases?"
|
|
@${ECHO_MSG} "COURIERGRAPH_USER=www User to run couriergraph (default: ${WWWOWN})"
|
|
@${ECHO_MSG} "COURIERGRAPH_GROUP=www Group to run couriergraph (default: ${WWWGRP})"
|
|
@${ECHO_MSG}
|
|
|
|
# To avoid conflict between default WRKSRC and RC_SUBR file being the same
|
|
post-extract:
|
|
@${MV} ${WRKDIR}/${PORTNAME} ${WRKSRC}
|
|
|
|
post-patch:
|
|
@${REINPLACE_CMD} -e "s,%%DATADIR%%,${DATADIR}," \
|
|
${WRKSRC}/couriergraph.cgi ${WRKSRC}/couriergraph.pl
|
|
|
|
do-install:
|
|
@${MKDIR} ${STAGEDIR}${PREFIX}/www/cgi-bin
|
|
@${MKDIR} ${STAGEDIR}${DATADIR}
|
|
${INSTALL_SCRIPT} ${WRKSRC}/couriergraph.pl \
|
|
${STAGEDIR}${PREFIX}/sbin
|
|
${INSTALL_SCRIPT} ${WRKSRC}/couriergraph.cgi \
|
|
${STAGEDIR}${PREFIX}/www/cgi-bin
|
|
|
|
.include <bsd.port.mk>
|