diff options
Diffstat (limited to 'net/trafd/Makefile')
-rw-r--r-- | net/trafd/Makefile | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/net/trafd/Makefile b/net/trafd/Makefile index 6e2181b92ca2..69b43254f901 100644 --- a/net/trafd/Makefile +++ b/net/trafd/Makefile @@ -7,7 +7,7 @@ PORTNAME= trafd PORTVERSION= 3.0.1 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= net MASTER_SITES= ftp://ftp.riss-telecom.ru/pub/dev/trafd/ EXTRACT_SUFX= .tgz @@ -17,6 +17,17 @@ COMMENT= The BPF Traffic Collector CONFLICTS= bpft-4.* +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 500000 +RUN_DEPENDS= ${LOCALBASE}/etc/rc.subr:${PORTSDIR}/sysutils/rc_subr +RCSUBRBASE= ${LOCALBASE}/etc +.else +RCSUBRBASE= /etc +.endif + +USE_REINPLACE= yes + do-install: ${INSTALL_PROGRAM} ${WRKSRC}/trafd/trafd ${PREFIX}/bin ${INSTALL_SCRIPT} ${WRKSRC}/trafd/trafstart ${PREFIX}/bin @@ -27,6 +38,10 @@ do-install: ${INSTALL_PROGRAM} ${WRKSRC}/trafstatd/trafstatd ${PREFIX}/bin ${INSTALL_PROGRAM} ${WRKSRC}/traflog/traflog ${PREFIX}/bin ${INSTALL_DATA} ${WRKSRC}/traflog/traflog.format ${PREFIX}/etc + ${CP} ${FILESDIR}/trafd.sh.sample ${WRKDIR} + ${REINPLACE_CMD} -e "s|%%RC_SUBR%%|${RCSUBRBASE}/rc.subr|g;" \ + ${WRKDIR}/trafd.sh.sample + ${INSTALL_SCRIPT} ${WRKDIR}/trafd.sh.sample ${PREFIX}/etc/rc.d @${MKDIR} ${PREFIX}/var/trafd @${MKDIR} ${PREFIX}/var/log .if !defined(NOPORTDOCS) @@ -34,4 +49,4 @@ do-install: @${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR} .endif -.include <bsd.port.mk> +.include <bsd.port.post.mk> |