freebsd-ports/net-mgmt/cflowd/Makefile
Baptiste Daroussin 9250d94365 Convert USE_BISON to USES= bison
It brings bison as a build dependency in case it is set the following way:
USES= bison or USES= bison:build

it brings bison as a run dependency in case it is set the following way:
USES= bison:run

it brings bison both as a run and build dependency in case it the set the following way:
USES= bison:both

While here trim some headers
Convert some USE_GNOME= gnomehack to USES= pathfix
2013-03-08 11:32:11 +00:00

60 lines
1.7 KiB
Makefile

# Created by: Andreas Klemm <andreas@klemm.gtn.com>
# $FreeBSD$
PORTNAME= cflowd
PORTVERSION= 2.1.b1
PORTREVISION= 10
PORTEPOCH= 1
CATEGORIES= net-mgmt
MASTER_SITES= http://www.caida.org/tools/measurement/cflowd/download/
DISTNAME= ${PORTNAME}-${PORTVERSION:S|.|-|g}
MAINTAINER= ports@FreeBSD.org
COMMENT= Flow analysis tool used for analyzing Cisco's NetFlow switching
LIB_DEPENDS= Arts:${PORTSDIR}/net-mgmt/arts++
USE_AUTOTOOLS= libtool
USE_GMAKE= yes
USES= bison
USE_LDCONFIG= yes
CONFIGURE_ARGS= --enable-shared --with-artspp=${LOCALBASE}
MANL= cfdases.l cfdifmatrix.l cfdnets.l cfdnexthops.l \
cfdportmatrix.l cfdprotos.l cfdtos.l flowdump.l flowwatch.l
OPTIONS_DEFINE= FLOWSCAN
FLOWSCAN_DESC= FlowScan patch
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MFLOWSCAN}
PATCH_SITES+= http://net.doit.wisc.edu/~plonka/cflowd/
PATCHFILES+= cflowd-${PORTVERSION:S|.|-|g}-djp.patch
.endif
post-extract:
${CHMOD} -R u+w ${WRKSRC}
post-patch:
@${FIND} ${WRKSRC} -type f | ${XARGS} \
${REINPLACE_CMD} -e 's|iostream.h>|iostream>|;s|strstream.h|sstream|'
@${FIND} ${WRKSRC} -name Makefile.in | ${XARGS} \
${REINPLACE_CMD} -e '/^LIBTOOL =/s^\$$(top_builddir)/libtool^${LIBTOOL}^' \
-e '/LIBTOOL/ { ;\
N ;\
/ -o / s|$${LIBTOOL} $${CXX}|$${LIBTOOL} --mode=link $${CXX}| ;\
P ;\
D ;\
}';
@${FIND} ${WRKSRC} -name Makefile.in | ${XARGS} ${REINPLACE_CMD} \
-e 's|$${LIBTOOL} $$(CXX)|$${LIBTOOL} --mode=compile $$(CXX)|' \
-e 's|$${LIBTOOL} $${CXX}|$${LIBTOOL} --mode=compile $${CXX}|' \
-e 's|$${LIBTOOL} \.\.|$${LIBTOOL} --mode=install ..|'
post-install:
${INSTALL_SCRIPT} ${FILESDIR}/cflowd.sh \
${PREFIX}/etc/rc.d/cflowd-base.sh.sample
.include <bsd.port.mk>