diff --git a/net-mgmt/pmacct/Makefile b/net-mgmt/pmacct/Makefile index 314230e3e2d4..15b98614f119 100644 --- a/net-mgmt/pmacct/Makefile +++ b/net-mgmt/pmacct/Makefile @@ -1,88 +1,89 @@ # Created by: Kirill Ponomarew PORTNAME= pmacct DISTVERSION= 1.7.5 +PORTREVISION= 1 CATEGORIES= net-mgmt MASTER_SITES= http://www.pmacct.net/ MAINTAINER= pi@FreeBSD.org COMMENT= Accounting and aggregation tool for IPv4 and IPv6 traffic LICENSE= GPLv2 USES= libtool pkgconfig localbase USE_RC_SUBR= pmacctd nfacctd sfacctd SUB_FILES= pkg-message GNU_CONFIGURE= yes OPTIONS_DEFINE= MYSQL PGSQL SQLITE3 LAYER2 DEBUG GEOIP2 \ DOCS PLABEL RABBITMQ REDIS KAFKA AVRO EXAMPLES OPTIONS_DEFAULT=LAYER2 OPTIONS_SUB= yes AVRO_DESC= Enable avro support GEOIP2_DESC= Enable GeoIPv2 (libmaxminddb) support KAFKA_DESC= Enable Kafka support LAYER2_DESC= Enable Layer-2 support: MAC addresses and VLANs PLABEL_DESC= Enable IP prefix labels RABBITMQ_DESC= Enable RabbitMQ/AMQP support REDIS_DESC= Enable Redis support SQLITE3_DESC= Enable SQLite3 support SQLDOC= "@comment " MYSQL_USES= mysql MYSQL_CONFIGURE_ENABLE= mysql MYSQL_VARS+= SQLDOC="" PGSQL_USES= pgsql PGSQL_CONFIGURE_ENABLE= pgsql PGSQL_VARS+= WANT_PGSQL=client PGSQL_VARS+= SQLDOC="" SQLITE3_USES= sqlite SQLITE3_CONFIGURE_ENABLE= sqlite3 SQLITE3_VARS= SQLDOC="" LAYER2_CONFIGURE_ENABLE= l2 PLABEL_CONFIGURE_ENABLE= plabel DEBUG_CONFIGURE_ENABLE= debug RABBITMQ_LIB_DEPENDS= librabbitmq.so:net/rabbitmq-c-devel RABBITMQ_CONFIGURE_ENABLE= rabbitmq REDIS_LIB_DEPENDS= libhiredis.so:databases/hiredis REDIS_CONFIGURE_ENABLE= redis KAFKA_LIB_DEPENDS= librdkafka.so:net/librdkafka KAFKA_CONFIGURE_ENABLE= kafka AVRO_LIB_DEPENDS= libavro.so:devel/avro-c AVRO_CONFIGURE_ENABLE= avro GEOIP2_LIB_DEPENDS= libmaxminddb.so:net/libmaxminddb GEOIP2_CONFIGURE_ENABLE= geoipv2 .include PLIST_SUB+= SQLDOC=${SQLDOC} .if ${PORT_OPTIONS:MRABBITMQ} || ${PORT_OPTIONS:MKAFKA} LIB_DEPENDS+= libjansson.so:devel/jansson CONFIGURE_ARGS+=--enable-jansson .endif post-patch: @${REINPLACE_CMD} -e 's|-O2||g' ${WRKSRC}/configure post-install: ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} (cd ${WRKSRC}/examples && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR}) ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/docs/[A-Z]* ${STAGEDIR}${DOCSDIR} .for i in AUTHORS CONFIG-KEYS COPYING ChangeLog FAQS INSTALL QUICKSTART UPGRADE ${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DOCSDIR} .endfor ${MKDIR} ${STAGEDIR}${DATADIR} .include diff --git a/net-mgmt/pmacct/files/patch-src_nfprobe__plugin_netflow9.c b/net-mgmt/pmacct/files/patch-src_nfprobe__plugin_netflow9.c new file mode 100644 index 000000000000..6ba07373eba9 --- /dev/null +++ b/net-mgmt/pmacct/files/patch-src_nfprobe__plugin_netflow9.c @@ -0,0 +1,11 @@ +--- src/nfprobe_plugin/netflow9.c.orig 2020-05-10 13:57:54 UTC ++++ src/nfprobe_plugin/netflow9.c +@@ -2233,7 +2233,7 @@ send_netflow_v9(struct FLOW **flows, int num_flows, in + + /* Refresh template headers if we need to */ + if (nf9_pkts_until_template <= 0) { +- u_int16_t flows = 0, tot_len = 0; ++ u_int16_t flows = 0, tot_len __attribute__((unused)) = 0; + + memcpy(packet + offset, &v4_template, v4_template.tot_len); + offset += v4_template.tot_len; diff --git a/net-mgmt/pmacct/files/patch-src_sflow.c b/net-mgmt/pmacct/files/patch-src_sflow.c new file mode 100644 index 000000000000..8a8df0620e6c --- /dev/null +++ b/net-mgmt/pmacct/files/patch-src_sflow.c @@ -0,0 +1,11 @@ +--- src/sflow.c.orig 2020-05-10 13:57:54 UTC ++++ src/sflow.c +@@ -306,7 +306,7 @@ void decodeIPV4(SFSample *sample) + + void decodeIPV6(SFSample *sample) + { +- u_int32_t label; ++ u_int32_t label __attribute__((unused)); + u_int32_t nextHeader; + u_char *end = sample->header + sample->headerLen; +