public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2017-12-11 20:37 Jeroen Roovers
  0 siblings, 0 replies; 7+ messages in thread
From: Jeroen Roovers @ 2017-12-11 20:37 UTC (permalink / raw
  To: gentoo-commits

commit:     5c5fff74a0a578405bde38b9ccde33a23b2c0369
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Mon Dec 11 20:37:22 2017 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Mon Dec 11 20:37:22 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5c5fff74

net-analyzer/nfdump: Version bump.

Package-Manager: Portage-2.3.18, Repoman-2.3.6

 net-analyzer/nfdump/Manifest                       |  1 +
 .../nfdump/files/nfdump-1.6.16-libnfdump.patch     | 10 ++++
 net-analyzer/nfdump/nfdump-1.6.16.ebuild           | 64 ++++++++++++++++++++++
 3 files changed, 75 insertions(+)

diff --git a/net-analyzer/nfdump/Manifest b/net-analyzer/nfdump/Manifest
index 31403c24762..24d54d76b77 100644
--- a/net-analyzer/nfdump/Manifest
+++ b/net-analyzer/nfdump/Manifest
@@ -1,3 +1,4 @@
 DIST nfdump-1.6.14-security.patch 31579 BLAKE2B d747526f46837e99193bf761bceb853bb44ea54bc6ca2a9977565742e1485b706f3f33370005ccf5c854429635de01f5cf594fd43122d4a6f8912e2a457d8caf SHA512 ee3b82f1283f3dceb36cf60abcee7f5a8fb6c8fe257e2233c3fbb9a34b3c5608dfa101fd473c8b839356a9d1c294a37b9e65657ff1b2d5c015015ff90b2d2c97
 DIST nfdump-1.6.14.tar.gz 1834355 BLAKE2B be92ec6c6eb60c883863a21e7d203c487f176e862f6227bf21d17ade2a04815095c5c119719a18c106401519d7976a2b82e46a11b7f207494abef3e0f73d2716 SHA512 c5e5540526dfce3798728930576e4c7930c3ff80893a94d7f9e65c7c577d1e78bdc47a99c47cee837327ad202197afc378d2408b1b9b847044d0110146055ffe
 DIST nfdump-1.6.15.tar.gz 1834855 BLAKE2B 1892cfbd1d1299c44b14a39b55c766d3dd411d7410a66b8ecbebe590c9da595c79764966ef1c91adb91b936ee3c052ad14bca27c6bcb98472011eb2c67dff60f SHA512 a6bb4f2293ad85d8f16025e7272b889d3814cea2e9255dbd315ee92754675e4ee925c3ebe4e1350f2d5452d69d1d3c13ddeb656324a409c4744da1d4927fe1f2
+DIST nfdump-1.6.16.tar.gz 1814857 BLAKE2B cd50680adbb6023915232bb780daf2bcc4319348444a28c89fc4fdfd19225bdf243bb42179a6bd545c06ab6fafa50091401b7a286527d1863c888a96c0b0a2eb SHA512 c1af3cf984c7eaaf1012c71c061e00f12dbcdf276306096436eb707552932c65b9f03e7a22b4cc0989d951c433f32c5c927600a8248826227f10b4fb2d906a32

diff --git a/net-analyzer/nfdump/files/nfdump-1.6.16-libnfdump.patch b/net-analyzer/nfdump/files/nfdump-1.6.16-libnfdump.patch
new file mode 100644
index 00000000000..a748969da2e
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfdump-1.6.16-libnfdump.patch
@@ -0,0 +1,10 @@
+--- a/bin/Makefile.am
++++ b/bin/Makefile.am
+@@ -30,7 +30,6 @@
+ LDADD = $(DEPS_LIBS)
+ 
+ #Add extra debug info for gdb
+-AM_CFLAGS = -ggdb 
+ 
+ # libnfdump sources
+ common =  nf_common.c nf_common.h 

diff --git a/net-analyzer/nfdump/nfdump-1.6.16.ebuild b/net-analyzer/nfdump/nfdump-1.6.16.ebuild
new file mode 100644
index 00000000000..4c9925d973e
--- /dev/null
+++ b/net-analyzer/nfdump/nfdump-1.6.16.ebuild
@@ -0,0 +1,64 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+inherit autotools eutils
+
+DESCRIPTION="A set of tools to collect and process netflow data"
+HOMEPAGE="https://github.com/phaag/nfdump"
+SRC_URI="
+	${HOMEPAGE}/archive/v${PV}.tar.gz -> ${P}.tar.gz
+"
+
+LICENSE="BSD"
+SLOT="0/1.6.15"
+KEYWORDS="~amd64 ~x86"
+IUSE="compat15 debug ftconv nfprofile nftrack readpcap sflow static-libs"
+
+COMMON_DEPEND="
+	app-arch/bzip2
+	sys-libs/zlib
+	ftconv? ( sys-libs/zlib net-analyzer/flow-tools )
+	nfprofile? ( net-analyzer/rrdtool )
+	nftrack? ( net-analyzer/rrdtool )
+	readpcap? ( net-libs/libpcap )
+"
+DEPEND="
+	${COMMON_DEPEND}
+	sys-devel/flex
+	virtual/yacc
+"
+RDEPEND="
+	${COMMON_DEPEND}
+	dev-lang/perl
+"
+DOCS=( AUTHORS ChangeLog NEWS README )
+PATCHES=(
+	"${FILESDIR}"/${PN}-1.6.14-libft.patch
+	"${FILESDIR}"/${PN}-1.6.16-libnfdump.patch
+)
+
+src_prepare() {
+	default
+
+	eautoreconf
+}
+
+src_configure() {
+	# --without-ftconf is not handled well #322201
+	econf \
+		$(use ftconv && echo "--enable-ftconv --with-ftpath=/usr") \
+		$(use nfprofile && echo --enable-nfprofile) \
+		$(use nftrack && echo --enable-nftrack) \
+		$(use_enable compat15) \
+		$(use_enable debug devel) \
+		$(use_enable readpcap) \
+		$(use_enable sflow) \
+		$(use_enable static-libs static)
+}
+
+src_install() {
+	default
+
+	prune_libtool_files
+}


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2017-12-12 15:36 Jeroen Roovers
  0 siblings, 0 replies; 7+ messages in thread
From: Jeroen Roovers @ 2017-12-12 15:36 UTC (permalink / raw
  To: gentoo-commits

commit:     65b9e956aecf309c5b57b61699c3ee4e6180b439
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Tue Dec 12 15:36:12 2017 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Tue Dec 12 15:36:29 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=65b9e956

net-analyzer/nfdump: Fix USE=sflow. Install README.md by Hanno Boeck (bug #611998).

Package-Manager: Portage-2.3.18, Repoman-2.3.6

 .../nfdump/files/nfdump-1.6.16-DEVEL.patch         | 104 +++++++++++++++++++++
 ...fdump-1.6.15.ebuild => nfdump-1.6.15-r1.ebuild} |   4 +-
 ...fdump-1.6.16.ebuild => nfdump-1.6.16-r1.ebuild} |   3 +-
 3 files changed, 108 insertions(+), 3 deletions(-)

diff --git a/net-analyzer/nfdump/files/nfdump-1.6.16-DEVEL.patch b/net-analyzer/nfdump/files/nfdump-1.6.16-DEVEL.patch
new file mode 100644
index 00000000000..21aeb6f0e34
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfdump-1.6.16-DEVEL.patch
@@ -0,0 +1,104 @@
+--- a/bin/flowtree.c
++++ b/bin/flowtree.c
+@@ -467,9 +467,8 @@ void Push_Node(NodeList_t *NodeList, struct FlowNode *node) {
+ 	NodeList->last = node;
+ 	NodeList->length++;
+ #ifdef DEVEL
+-	int proto = node->proto;
+ 	printf("pushed node 0x%llx proto: %u, length: %u first: %llx, last: %llx\n", 
+-		(unsigned long long)node, proto, NodeList->length, (unsigned long long)NodeList->list, (unsigned long long)NodeList->last);
++		(unsigned long long)node, node->proto, NodeList->length, (unsigned long long)NodeList->list, (unsigned long long)NodeList->last);
+ 	ListCheck(NodeList);
+ #endif
+ 	if ( NodeList->waiting ) {
+@@ -483,7 +482,6 @@ void Push_Node(NodeList_t *NodeList, struct FlowNode *node) {
+ 
+ struct FlowNode *Pop_Node(NodeList_t *NodeList, int *done) {
+ struct FlowNode *node;
+-int proto;
+ 
+ 	GetTreeLock(NodeList);
+     while ( NodeList->length == 0 && !*done ) {
+@@ -522,12 +520,11 @@ int proto;
+ 
+ 	node->left = NULL;
+ 	node->right = NULL;
+-	proto = node->proto;
+ 
+ 	NodeList->length--;
+ #ifdef DEVEL
+ 	printf("popped node 0x%llx proto: %u, length: %u first: %llx, last: %llx\n", 
+-		(unsigned long long)node, proto, NodeList->length, (unsigned long long)NodeList->list, (unsigned long long)NodeList->last);
++		(unsigned long long)node, node->proto, NodeList->length, (unsigned long long)NodeList->list, (unsigned long long)NodeList->last);
+ 
+ 	ListCheck(NodeList);
+ #endif
+--- a/bin/nfexpire.c
++++ b/bin/nfexpire.c
+@@ -212,12 +212,12 @@ int main( int argc, char **argv ) {
+ struct stat fstat;
+ int 		c, err, maxsize_set, maxlife_set;
+ int			do_rescan, do_expire, do_list, print_stat, do_update_param, print_books, is_profile, nfsen_format;
+-char		*maxsize_string, *lifetime_string, *datadir;
++char		*lifetime_string, *datadir;
+ uint64_t	maxsize, lifetime, low_water;
+ uint32_t	runtime;
+ channel_t	*channel, *current_channel;
+ 
+-	maxsize_string = lifetime_string = NULL;
++	lifetime_string = NULL;
+ 	datadir = NULL;
+ 	maxsize = lifetime = 0;
+ 	do_rescan  		= 0;
+--- a/bin/nfstat.c
++++ b/bin/nfstat.c
+@@ -1670,7 +1670,7 @@ uint32_t			maxindex, c;
+ 					else
+ 						printf("Top flows ordered by %s:\n", order_mode[order_index].string);
+ 				}
+-				if ( !record_header ) 
++				if ( record_header ) 
+ 					printf("%s\n", record_header);
+ 			}
+ 			PrintSortedFlowcache(SortList, maxindex, topN, 0, print_record, tag, DESCENDING, extension_map_list);
+--- a/bin/sflow.c
++++ b/bin/sflow.c
+@@ -515,11 +515,17 @@ static inline void readCountersSample_v2v4(SFSample *sample, FlowSource_t *fs);
+ 
+ static inline void StoreSflowRecord(SFSample *sample, FlowSource_t *fs);
+ 
++extern int verbose;
++
+ #ifdef DEVEL
+ static inline char *printTag(uint32_t tag, char *buf, int bufLen);
+-#endif
+ 
+-extern int verbose;
++static inline char *printTag(uint32_t tag, char *buf, int bufLen) {
++    snprintf(buf, bufLen, "%u:%u", (tag >> 12), (tag & 0x00000FFF));
++    return buf;
++} // End of printTag
++
++#endif
+ 
+ 
+ /*_________________---------------------------__________________
+@@ -1410,15 +1416,11 @@ static inline uint32_t getAddress(SFSample *sample, SFLAddress *address) {
+ static inline void skipTLVRecord(SFSample *sample, uint32_t tag, uint32_t len, char *description) {
+ 
+ #ifdef DEVEL
+-static inline char *printTag(uint32_t tag, char *buf, int bufLen) {
+-	snprintf(buf, bufLen, "%u:%u", (tag >> 12), (tag & 0x00000FFF));
+-	return buf;
+-} // End of printTag
+-
+-char buf[51];
++	char buf[51];
++	snprintf(buf, 50, "%u:%u", (tag >> 12), (tag & 0x00000FFF));
++	printf("skipping unknown %s: 0x%x, %s len=%d\n", description, tag, buf, len);
+ #endif
+ 
+-	dbg_printf("skipping unknown %s: 0x%x, %s len=%d\n", description, tag, printTag(tag, buf, 50), len);
+ 	skipBytes(sample, len);
+ } // End of skipTLVRecord
+ 

diff --git a/net-analyzer/nfdump/nfdump-1.6.15.ebuild b/net-analyzer/nfdump/nfdump-1.6.15-r1.ebuild
similarity index 94%
rename from net-analyzer/nfdump/nfdump-1.6.15.ebuild
rename to net-analyzer/nfdump/nfdump-1.6.15-r1.ebuild
index baa417bf417..86fcde96ecd 100644
--- a/net-analyzer/nfdump/nfdump-1.6.15.ebuild
+++ b/net-analyzer/nfdump/nfdump-1.6.15-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
@@ -33,7 +33,7 @@ RDEPEND="
 	dev-lang/perl
 "
 
-DOCS=( AUTHORS ChangeLog NEWS README )
+DOCS=( AUTHORS ChangeLog README.md )
 
 src_prepare() {
 	eapply \

diff --git a/net-analyzer/nfdump/nfdump-1.6.16.ebuild b/net-analyzer/nfdump/nfdump-1.6.16-r1.ebuild
similarity index 94%
rename from net-analyzer/nfdump/nfdump-1.6.16.ebuild
rename to net-analyzer/nfdump/nfdump-1.6.16-r1.ebuild
index 4c9925d973e..f76dd9f58c5 100644
--- a/net-analyzer/nfdump/nfdump-1.6.16.ebuild
+++ b/net-analyzer/nfdump/nfdump-1.6.16-r1.ebuild
@@ -32,10 +32,11 @@ RDEPEND="
 	${COMMON_DEPEND}
 	dev-lang/perl
 "
-DOCS=( AUTHORS ChangeLog NEWS README )
+DOCS=( AUTHORS ChangeLog README.md )
 PATCHES=(
 	"${FILESDIR}"/${PN}-1.6.14-libft.patch
 	"${FILESDIR}"/${PN}-1.6.16-libnfdump.patch
+	"${FILESDIR}"/${PN}-1.6.16-DEVEL.patch
 )
 
 src_prepare() {


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2021-03-15 21:09 Sam James
  0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2021-03-15 21:09 UTC (permalink / raw
  To: gentoo-commits

commit:     b436d3c2ada1caf225f72520c8b5dce4c7ba9aac
Author:     Vjaceslavs Klimovs <vklimovs <AT> gmail <DOT> com>
AuthorDate: Sun Aug 23 22:58:00 2020 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Mar 15 21:03:38 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b436d3c2

net-analyzer/nfdump: fix upstream issue #241 and prevent always building nfpcapd

Closes: https://github.com/gentoo/gentoo/pull/17119
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...mp-1.6.21-remove-strict-rfc-7011-handling.patch | 49 ++++++++++++++++++++++
 net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild        |  3 +-
 2 files changed, 51 insertions(+), 1 deletion(-)

diff --git a/net-analyzer/nfdump/files/nfdump-1.6.21-remove-strict-rfc-7011-handling.patch b/net-analyzer/nfdump/files/nfdump-1.6.21-remove-strict-rfc-7011-handling.patch
new file mode 100644
index 00000000000..a36af2242d4
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfdump-1.6.21-remove-strict-rfc-7011-handling.patch
@@ -0,0 +1,49 @@
+From f5ae2b821c22ebe0c96f3516d4e90f4255633828 Mon Sep 17 00:00:00 2001
+From: Peter Haag <peter@people.ops-trust.net>
+Date: Sat, 8 Aug 2020 16:46:04 +0200
+Subject: [PATCH] Re-address issue #231 - remove strict rule rfc 7011
+
+---
+ ChangeLog   | 3 +++
+ bin/ipfix.c | 3 ---
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/ChangeLog b/ChangeLog
+index a0b2b67..8b92e58 100755
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,6 @@
++2020-08-02
++- Re-address issue #231 - remove strict rule rfc 7011
++
+ 2020-08-02
+ - Release 1.6.21
+ - Address issue #159. Implement rfc 7011 and include sender UDP port into unique template identification
+diff --git a/bin/ipfix.c b/bin/ipfix.c
+index a730a8b..19c9d63 100644
+--- a/bin/ipfix.c
++++ b/bin/ipfix.c
+@@ -158,7 +158,6 @@ typedef struct exporterDomain_s {
+ 
+ 	// exporter information
+ 	exporter_info_record_t info;
+-	in_port_t	port;				// follow rfc 7011 - matching src port
+ 
+ 	uint64_t	packets;			// number of packets sent by this exporter
+ 	uint64_t	flows;				// number of flow records sent by this exporter
+@@ -383,7 +382,6 @@ uint32_t ObservationDomain = ntohl(ipfix_header->ObservationDomain);
+ 
+ 	while ( *e ) {
+ 		if ( (*e)->info.id == ObservationDomain && (*e)->info.version == 10 && 
+-			 (*e)->port == fs->port &&
+ 			 (*e)->info.ip.V6[0] == fs->ip.V6[0] && (*e)->info.ip.V6[1] == fs->ip.V6[1]) 
+ 			return *e;
+ 		e = &((*e)->next);
+@@ -412,7 +410,6 @@ uint32_t ObservationDomain = ntohl(ipfix_header->ObservationDomain);
+ 	(*e)->info.header.size  = sizeof(exporter_info_record_t);
+ 	(*e)->info.id 			= ObservationDomain;
+ 	(*e)->info.ip			= fs->ip;
+-	(*e)->port				= fs->port;
+ 	(*e)->info.sa_family	= fs->sa_family;
+ 	(*e)->info.version 		= 10;
+ 	(*e)->info.sysid	 	= 0;

diff --git a/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild b/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild
index 975d26b9c44..4b780ec598c 100644
--- a/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild
+++ b/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild
@@ -36,6 +36,7 @@ RDEPEND="
 PATCHES=(
 	"${FILESDIR}"/${PN}-1.6.19-compiler.patch
 	"${FILESDIR}"/${PN}-1.6.19-libft.patch
+	"${FILESDIR}"/${PN}-1.6.21-remove-strict-rfc-7011-handling.patch
 )
 DOCS=( AUTHORS ChangeLog README.md )
 
@@ -53,11 +54,11 @@ src_configure() {
 	# --without-ftconf is not handled well #322201
 	econf \
 		$(use ftconv && echo "--enable-ftconv --with-ftpath=/usr") \
+		$(use nfpcapd && echo --enable-nfpcapd) \
 		$(use nfprofile && echo --enable-nfprofile) \
 		$(use nftrack && echo --enable-nftrack) \
 		$(use_enable debug devel) \
 		$(use_enable jnat) \
-		$(use_enable nfpcapd) \
 		$(use_enable nsel) \
 		$(use_enable readpcap) \
 		$(use_enable sflow) \


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2021-03-15 21:09 Sam James
  0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2021-03-15 21:09 UTC (permalink / raw
  To: gentoo-commits

commit:     6dace4048ed813d3811cdb8d325fd4519c117753
Author:     Vjaceslavs Klimovs <vklimovs <AT> gmail <DOT> com>
AuthorDate: Fri Aug 14 04:32:18 2020 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Mar 15 21:03:37 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6dace404

net-analyzer/nfdump: add use flags and init scripts for nfcapd

Closes: https://bugs.gentoo.org/712590

Signed-off-by: Vjaceslavs Klimovs <vklimovs <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-analyzer/nfdump/files/nfcapd.confd      | 11 ++++
 net-analyzer/nfdump/files/nfcapd.initd      | 60 ++++++++++++++++++++++
 net-analyzer/nfdump/metadata.xml            |  8 ++-
 net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild | 78 +++++++++++++++++++++++++++++
 4 files changed, 156 insertions(+), 1 deletion(-)

diff --git a/net-analyzer/nfdump/files/nfcapd.confd b/net-analyzer/nfdump/files/nfcapd.confd
new file mode 100644
index 00000000000..28ea35fd074
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfcapd.confd
@@ -0,0 +1,11 @@
+#shellcheck shell=sh
+#shellcheck disable=SC2034
+
+#port number to listen on
+#PORT="2055"
+
+#maximum size of collected files
+#MAX_SIZE="1G"
+
+#enable sending of all received packets to specified address
+#REPEAT_TO="192.168.1.1/60062"

diff --git a/net-analyzer/nfdump/files/nfcapd.initd b/net-analyzer/nfdump/files/nfcapd.initd
new file mode 100644
index 00000000000..98d388cb710
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfcapd.initd
@@ -0,0 +1,60 @@
+#!/sbin/openrc-run
+#shellcheck shell=sh
+
+IDENT="${RC_SVCNAME#*.}"
+PIDFILE="/run/nfcapd/${IDENT}.pid"
+USER="nfcapd"
+GROUP="nfcapd"
+
+ssd_start(){
+	if [ -n "${MAX_SIZE}" ]; then
+		set -- "$@" -e
+	fi
+	if [ -n "${PORT}" ]; then
+		set -- "$@" -p "${PORT}"
+	fi
+	if [ -n "${REPEAT_TO}" ]; then
+		set -- "$@" -R "${REPEAT_TO}"
+	fi
+	start-stop-daemon "$@"
+}
+
+checkconfig() {
+	if [ "${IDENT}" = "${RC_SVCNAME}" ]; then
+		eerror "You have to create an init script for each ident:"
+		eerror " cd /etc/init.d/; ln -s nfcapd nfcapd.ident"
+		return 1
+	fi
+}
+
+depend() {
+	need net
+}
+
+start() {
+	checkconfig || return 1
+
+	checkpath -d -m 0750 -o nfcapd:nfcapd /run/nfcapd
+	checkpath -d -m 0750 -o nfcapd:nfcapd /var/tmp/nfcapd/"${IDENT}"
+
+	if [ -n "${MAX_SIZE}" ]; then
+		nfexpire -u /var/tmp/nfcapd/"${IDENT}" -s "${MAX_SIZE}" \
+			> /dev/null 2>&1
+		chown -R ${USER}:${GROUP} /var/tmp/nfcapd/"${IDENT}"
+	fi
+
+	ebegin "Starting ${RC_SVCNAME}"
+	ssd_start --start --quiet --exec /usr/bin/nfcapd \
+		--pidfile "${PIDFILE}" -- -D -P "${PIDFILE}" -u ${USER} \
+		-g ${GROUP} -I "${IDENT}" -l /var/tmp/nfcapd/"${IDENT}"
+	eend $?
+}
+
+stop() {
+	checkconfig || return 1
+
+	ebegin "Stopping ${RC_SVCNAME}"
+	start-stop-daemon --stop --exec /usr/bin/nfcapd \
+		--pidfile "${PIDFILE}"
+	eend $?
+}

diff --git a/net-analyzer/nfdump/metadata.xml b/net-analyzer/nfdump/metadata.xml
index f785b897385..f9f3c305c35 100644
--- a/net-analyzer/nfdump/metadata.xml
+++ b/net-analyzer/nfdump/metadata.xml
@@ -6,12 +6,18 @@
     <name>Gentoo network monitoring and analysis project</name>
   </maintainer>
   <use>
-    <flag name="readpcap">Build nfcapd collector to read from pcap file instead ofnetwork data</flag>
     <flag name="ftconv">Build the flow-tools to nfdump converter</flag>
+    <flag name="jnat">Build nfudmp to support JunOS NAT event logging</flag>
+    <flag name="nfpcapd">Build nfpcapd collector to create netflow data from precollected pcap traffic</flag>
     <flag name="nfprofile">Build nfprofile used by NfSen</flag>
     <flag name="nftrack">Build nfprofile used by PortTracker</flag>
+    <flag name="nsel">Build nfudmp to support NSEL/NEL event data</flag>
+    <flag name="readpcap">Build nfcapd collector to read from pcap file instead ofnetwork data</flag>
     <flag name="sflow">Build sflow collector sfcpad</flag>
   </use>
+  <longdescription>nfdump is a toolset to collect and process netflow and sflow
+    data, sent from netflow/sflow compatible devices. The toolset supports
+    netflow v1, v5/v7,v9,IPFIX and SFLOW.</longdescription>
   <upstream>
     <remote-id type="sourceforge">nfdump</remote-id>
     <remote-id type="github">phaag/nfdump</remote-id>

diff --git a/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild b/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild
new file mode 100644
index 00000000000..975d26b9c44
--- /dev/null
+++ b/net-analyzer/nfdump/nfdump-1.6.21-r1.ebuild
@@ -0,0 +1,78 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools
+
+DESCRIPTION="A set of tools to collect and process netflow data"
+HOMEPAGE="https://github.com/phaag/nfdump"
+SRC_URI="https://github.com/phaag/nfdump/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/1.6.15"
+KEYWORDS="~amd64 ~x86"
+IUSE="debug doc jnat ftconv nfpcapd nfprofile nftrack nsel readpcap sflow
+	static-libs"
+REQUIRED_USE="?? ( jnat nsel )"
+
+COMMON_DEPEND="
+	app-arch/bzip2
+	sys-libs/zlib
+	ftconv? ( net-analyzer/flow-tools )
+	nfpcapd? ( net-libs/libpcap )
+	nfprofile? ( net-analyzer/rrdtool )
+	nftrack? ( net-analyzer/rrdtool )
+	readpcap? ( net-libs/libpcap )
+"
+DEPEND="
+	${COMMON_DEPEND}
+	sys-devel/flex
+	virtual/yacc
+	doc? ( app-doc/doxygen media-gfx/graphviz )
+"
+RDEPEND="
+	${COMMON_DEPEND}
+"
+PATCHES=(
+	"${FILESDIR}"/${PN}-1.6.19-compiler.patch
+	"${FILESDIR}"/${PN}-1.6.19-libft.patch
+)
+DOCS=( AUTHORS ChangeLog README.md )
+
+src_prepare() {
+	default
+
+	eautoreconf
+
+	if use doc; then
+		doxygen -u doc/Doxyfile.in || die
+	fi
+}
+
+src_configure() {
+	# --without-ftconf is not handled well #322201
+	econf \
+		$(use ftconv && echo "--enable-ftconv --with-ftpath=/usr") \
+		$(use nfprofile && echo --enable-nfprofile) \
+		$(use nftrack && echo --enable-nftrack) \
+		$(use_enable debug devel) \
+		$(use_enable jnat) \
+		$(use_enable nfpcapd) \
+		$(use_enable nsel) \
+		$(use_enable readpcap) \
+		$(use_enable sflow) \
+		$(use_enable static-libs static)
+}
+
+src_install() {
+	default
+
+	find "${ED}" -name '*.la' -delete || die
+
+	newinitd "${FILESDIR}"/nfcapd.initd nfcapd
+	newconfd "${FILESDIR}"/nfcapd.confd nfcapd
+
+	if use doc; then
+		dodoc -r doc/html
+	fi
+}


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2021-08-13  0:40 Sam James
  0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2021-08-13  0:40 UTC (permalink / raw
  To: gentoo-commits

commit:     01fb67c3b70674a3ff75d11f9c9dfd8f73ec6e08
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Aug 13 00:35:55 2021 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Aug 13 00:35:55 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=01fb67c3

net-analyzer/nfdump: drop 1.6.22-r1

Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-analyzer/nfdump/Manifest                       |   1 -
 .../nfdump-1.6.22-libtool-archives-slibtool.patch  | 111 ---------------------
 net-analyzer/nfdump/nfdump-1.6.22-r1.ebuild        |  82 ---------------
 3 files changed, 194 deletions(-)

diff --git a/net-analyzer/nfdump/Manifest b/net-analyzer/nfdump/Manifest
index a5942d524cc..32325041d89 100644
--- a/net-analyzer/nfdump/Manifest
+++ b/net-analyzer/nfdump/Manifest
@@ -1,2 +1 @@
-DIST nfdump-1.6.22.tar.gz 563266 BLAKE2B f985a8f8bcbb7ff3ab98d4f01449b121e92914bc47ec7fa07c1a7a068f6722447228b0166d0f2e966c0bab2c93e34133743e8dff7d8dc41a1c70ffac64fbbf6e SHA512 3508e54b4c4785a79118147779300eebd9485532e157b37ed6487255dacaa49959d425c8fc489caa98ff559a4859b9e456e97a6c8a06a1029eb904aa1f9efb61
 DIST nfdump-1.6.23.tar.gz 568879 BLAKE2B ca844f87e02fb3761d5b470cac11beada9873b0c7e3e9ca7ccc7899d57f0cfd96329698ac84467a55d683e83ce16c2b114a571845c7cb6069addcdd5d4a43903 SHA512 e3f79af69a170985fcbd1757fab86e90840d040cf7a6214c7f9851ed59695d3844a15269904c3ba989b6b6ed2ddf29fd19a493165d3037e49aa2bb69b831f168

diff --git a/net-analyzer/nfdump/files/nfdump-1.6.22-libtool-archives-slibtool.patch b/net-analyzer/nfdump/files/nfdump-1.6.22-libtool-archives-slibtool.patch
deleted file mode 100644
index 0a0048120ea..00000000000
--- a/net-analyzer/nfdump/files/nfdump-1.6.22-libtool-archives-slibtool.patch
+++ /dev/null
@@ -1,111 +0,0 @@
-https://bugs.gentoo.org/778704
-https://github.com/phaag/nfdump/pull/282
-
-From 44b6854a7e67bec438659452993a517b9ec3e753 Mon Sep 17 00:00:00 2001
-From: orbea <orbea@riseup.net>
-Date: Sat, 27 Mar 2021 07:23:12 -0700
-Subject: [PATCH] bin: Use the libtool archives to link.
-
-Signed-off-by: orbea <orbea@riseup.net>
----
- bin/Makefile.am | 40 ++++++++++++++--------------------------
- 1 file changed, 14 insertions(+), 26 deletions(-)
-
-diff --git a/bin/Makefile.am b/bin/Makefile.am
-index 0f8e787..456cda4 100755
---- a/bin/Makefile.am
-+++ b/bin/Makefile.am
-@@ -68,37 +68,31 @@ libnfdump_la_LDFLAGS = -release 1.6.22
- 
- nfdump_SOURCES = nfdump.c nfdump.h nfstat.c nfstat.h nfexport.c nfexport.h  \
- 	$(nflowcache) $(nfprof)
--nfdump_LDADD = -lnfdump
--nfdump_DEPENDENCIES = libnfdump.la
-+nfdump_LDADD = libnfdump.la
- 
- nfreplay_SOURCES = nfreplay.c $(nfprof) \
- 	$(nfnet) $(collector) $(nfv1) $(nfv9) $(nfv5v7) $(ipfix)
--nfreplay_LDADD = -lnfdump
--nfreplay_DEPENDENCIES = libnfdump.la
-+nfreplay_LDADD = libnfdump.la
- 
- nfprofile_SOURCES = nfprofile.c profile.c profile.h $(nfstatfile) 
--nfprofile_LDADD = -lnfdump -lrrd
--nfprofile_DEPENDENCIES = libnfdump.la
-+nfprofile_LDADD = libnfdump.la -lrrd
- 
- nftrack_SOURCES = ../extra/nftrack/nftrack.c \
- 	../extra/nftrack/nftrack_rrd.c ../extra/nftrack/nftrack_rrd.h \
- 	../extra/nftrack/nftrack_stat.c ../extra/nftrack/nftrack_stat.h 
- nftrack_CFLAGS = -I ../extra/nftrack
--nftrack_LDADD = -lnfdump -lrrd
--nftrack_DEPENDENCIES = libnfdump.la
-+nftrack_LDADD = libnfdump.la -lrrd
- 
- nfcapd_SOURCES = nfcapd.c \
- 	$(nfstatfile) $(launch) \
- 	$(nfnet) $(collector) $(nfv1) $(nfv5v7) $(nfv9) $(ipfix) $(bookkeeper) $(expire)
--nfcapd_LDADD = -lnfdump 
--nfcapd_DEPENDENCIES = libnfdump.la
-+nfcapd_LDADD = libnfdump.la
- 
- nfpcapd_SOURCES = nfpcapd.c \
- 	$(pcaproc) $(netflow_pcap) \
- 	$(nfstatfile) $(launch) \
- 	$(nfnet) $(collector) $(bookkeeper) $(expire) $(content)
--nfpcapd_LDADD = -lnfdump 
--nfpcapd_DEPENDENCIES = libnfdump.la
-+nfpcapd_LDADD = libnfdump.la
- 
- if READPCAP
- nfcapd_CFLAGS = -DPCAP
-@@ -116,8 +110,7 @@ endif
- sfcapd_SOURCES = sfcapd.c sflow_nfdump.c sflow_nfdump.h sflow.h sflow_v2v4.h sflow_process.c  sflow_process.h\
- 	$(nfstatfile) $(launch) \
- 	$(nfnet) $(collector) $(bookkeeper) $(expire)
--sfcapd_LDADD = -lnfdump 
--sfcapd_DEPENDENCIES = libnfdump.la
-+sfcapd_LDADD = libnfdump.la
- 
- if READPCAP
- sfcapd_CFLAGS = -DPCAP
-@@ -126,32 +119,27 @@ sfcapd_LDADD += -lpcap
- endif
- 
- nfreader_SOURCES = nfreader.c 
--nfreader_LDADD = -lnfdump 
--nfreader_DEPENDENCIES = libnfdump.la
-+nfreader_LDADD = libnfdump.la
- 
- nfanon_SOURCES = nfanon.c $(anon)
--nfanon_LDADD = -lnfdump 
--nfanon_DEPENDENCIES = libnfdump.la
-+nfanon_LDADD = libnfdump.la
- 
- nfgen_SOURCES = nfgen.c 
--nfgen_LDADD = -lnfdump 
--nfgen_DEPENDENCIES = libnfdump.la
-+nfgen_LDADD = libnfdump.la
- 
- nfexpire_SOURCES = nfexpire.c \
- 	$(bookkeeper) $(expire) $(nfstatfile)
--nfexpire_LDADD = -lnfdump @FTS_OBJ@
--nfexpire_DEPENDENCIES = libnfdump.la
-+nfexpire_LDADD = libnfdump.la @FTS_OBJ@
- 
- nftest_SOURCES = nftest.c 
--nftest_LDADD = -lnfdump 
--nftest_DEPENDENCIES = nfgen libnfdump.la
-+nftest_LDADD = libnfdump.la
-+nftest_DEPENDENCIES = nfgen
- 
- if FT2NFDUMP
- ft2nfdump_SOURCES = ft2nfdump.c 
- ft2nfdump_CFLAGS = @FT_INCLUDES@
--ft2nfdump_LDADD = -lnfdump -lft -lz
-+ft2nfdump_LDADD = libnfdump.la -lft -lz
- ft2nfdump_LDADD += @FT_LDFLAGS@
--ft2nfdump_DEPENDENCIES = libnfdump.la
- endif
- 
- check_DIST = inline.c collector_inline.c nffile_inline.c nfdump_inline.c heapsort_inline.c applybits_inline.c 

diff --git a/net-analyzer/nfdump/nfdump-1.6.22-r1.ebuild b/net-analyzer/nfdump/nfdump-1.6.22-r1.ebuild
deleted file mode 100644
index 4b6ed40bdb2..00000000000
--- a/net-analyzer/nfdump/nfdump-1.6.22-r1.ebuild
+++ /dev/null
@@ -1,82 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools
-
-DESCRIPTION="A set of tools to collect and process netflow data"
-HOMEPAGE="https://github.com/phaag/nfdump"
-SRC_URI="https://github.com/phaag/nfdump/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="BSD"
-SLOT="0/1.6.22"
-KEYWORDS="amd64 x86"
-IUSE="debug doc jnat ftconv nfpcapd nfprofile nftrack nsel readpcap sflow"
-
-REQUIRED_USE="?? ( jnat nsel )"
-
-RDEPEND="
-	app-arch/bzip2
-	sys-libs/zlib
-	ftconv? ( net-analyzer/flow-tools )
-	nfpcapd? ( net-libs/libpcap )
-	nfprofile? ( net-analyzer/rrdtool )
-	nftrack? ( net-analyzer/rrdtool )
-	readpcap? ( net-libs/libpcap )
-"
-DEPEND="${RDEPEND}"
-BDEPEND="
-	sys-devel/flex
-	virtual/yacc
-	doc? (
-		app-doc/doxygen
-		media-gfx/graphviz
-	)
-"
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-1.6.19-compiler.patch
-	"${FILESDIR}"/${PN}-1.6.19-libft.patch
-	"${FILESDIR}"/${P}-libtool-archives-slibtool.patch
-)
-
-DOCS=( AUTHORS ChangeLog README.md )
-
-src_prepare() {
-	default
-
-	eautoreconf
-
-	if use doc; then
-		doxygen -u doc/Doxyfile.in || die
-	fi
-}
-
-src_configure() {
-	# --without-ftconf is not handled well #322201
-	econf \
-		$(use ftconv && echo "--enable-ftconv --with-ftpath=/usr") \
-		$(use nfpcapd && echo --enable-nfpcapd) \
-		$(use nfprofile && echo --enable-nfprofile) \
-		$(use nftrack && echo --enable-nftrack) \
-		$(use_enable debug devel) \
-		$(use_enable jnat) \
-		$(use_enable nsel) \
-		$(use_enable readpcap) \
-		$(use_enable sflow) \
-		--disable-static
-}
-
-src_install() {
-	default
-
-	find "${ED}" -name '*.la' -delete || die
-
-	newinitd "${FILESDIR}"/nfcapd.initd nfcapd
-	newconfd "${FILESDIR}"/nfcapd.confd nfcapd
-
-	if use doc; then
-		dodoc -r doc/html
-	fi
-}


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2022-03-24 23:03 Sam James
  0 siblings, 0 replies; 7+ messages in thread
From: Sam James @ 2022-03-24 23:03 UTC (permalink / raw
  To: gentoo-commits

commit:     e78ff1747765da9b82919cad40e123bd83591879
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Mar 24 22:48:36 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Mar 24 23:01:35 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e78ff174

net-analyzer/nfdump: fix autoreconf

Closes: https://bugs.gentoo.org/832420
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-analyzer/nfdump/files/nfdump-1.6.23-m4-dir.patch | 19 +++++++++++++++++++
 net-analyzer/nfdump/nfdump-1.6.23.ebuild             |  3 ++-
 2 files changed, 21 insertions(+), 1 deletion(-)

diff --git a/net-analyzer/nfdump/files/nfdump-1.6.23-m4-dir.patch b/net-analyzer/nfdump/files/nfdump-1.6.23-m4-dir.patch
new file mode 100644
index 000000000000..ac25ee094653
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfdump-1.6.23-m4-dir.patch
@@ -0,0 +1,19 @@
+Variant sent upstream (configure.ac hunk irrelevant now): https://github.com/phaag/nfdump/pull/336
+https://bugs.gentoo.org/832420
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -1,3 +1,4 @@
++ACLOCAL_AMFLAGS = -I m4
+ 
+ SUBDIRS = . bin man doc
+ 
+--- a/configure.ac
++++ b/configure.ac
+@@ -7,6 +7,7 @@ AC_INIT(nfdump, 1.6.23, peter@people.ops-trust.net)
+ 
+ AC_CONFIG_HEADER([config.h])
+ AM_INIT_AUTOMAKE([subdir-objects])
++AC_CONFIG_MACRO_DIR([m4])
+ 
+ # Checks for programs.
+ AX_CHECK_C11

diff --git a/net-analyzer/nfdump/nfdump-1.6.23.ebuild b/net-analyzer/nfdump/nfdump-1.6.23.ebuild
index 9c9c2bd847b6..dca53c21054e 100644
--- a/net-analyzer/nfdump/nfdump-1.6.23.ebuild
+++ b/net-analyzer/nfdump/nfdump-1.6.23.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -38,6 +38,7 @@ BDEPEND="
 PATCHES=(
 	"${FILESDIR}"/${PN}-1.6.19-compiler.patch
 	"${FILESDIR}"/${PN}-1.6.19-libft.patch
+	"${FILESDIR}"/${PN}-1.6.23-m4-dir.patch
 )
 
 DOCS=( AUTHORS ChangeLog README.md )


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/
@ 2024-07-30 19:31 Arthur Zamarin
  0 siblings, 0 replies; 7+ messages in thread
From: Arthur Zamarin @ 2024-07-30 19:31 UTC (permalink / raw
  To: gentoo-commits

commit:     f1bad49b20c2eca95793c711f72a093a686adfdd
Author:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 30 19:23:16 2024 +0000
Commit:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
CommitDate: Tue Jul 30 19:30:56 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f1bad49b

net-analyzer/nfdump: add 1.7.4, added systemd service

While the bug for adding systemd services requested more files,
after more checking what they do, I see no reason for the
complicated way that debian decided to do it. So What I recommend to
do is:

1. systemctl edit nfdump@somename

   [Service]
   Environment=options="-l /var/cache/nfdump_somename -p 2052"
2. systemctl enable --now nfdump@somename

Closes: https://bugs.gentoo.org/904952
Closes: https://bugs.gentoo.org/925033
Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org>

 net-analyzer/nfdump/Manifest             |  1 +
 net-analyzer/nfdump/files/nfdump.service | 16 ++++++
 net-analyzer/nfdump/nfdump-1.7.4.ebuild  | 96 ++++++++++++++++++++++++++++++++
 3 files changed, 113 insertions(+)

diff --git a/net-analyzer/nfdump/Manifest b/net-analyzer/nfdump/Manifest
index 3a86012a4c87..c29eee945827 100644
--- a/net-analyzer/nfdump/Manifest
+++ b/net-analyzer/nfdump/Manifest
@@ -1 +1,2 @@
 DIST nfdump-1.7.2.tar.gz 697405 BLAKE2B cf52f2cca5d80070bc00c7a7a87cc4820f04904ddeeebd4fc93cf3a2433bcf5798191daa86f0bfc7ee1f2f92e5d8bb087114d2c17e32b641a224189aeb54f822 SHA512 858d0aaae24f2e38f3708db9fd5cd40e99a6a50d5da5738c8ce4bf898fb153ce439c504d5fe8fb3c296d0069511a6f229ebdfc117f849a482e5ffdf457f06003
+DIST nfdump-1.7.4.tar.gz 756319 BLAKE2B 441fb5d3fcb4b83bfc42861eac67bf96ac7c7d6a44afd47c4e16615b22261e1628a1bffc645071817eb9085857ca3a3b632fd265dc897cf9af8fce2999f86787 SHA512 be65aeee9b982b30633102b3ca0f84eab280ca4fda4544be458a2387d051e62517127a2625bbc4329a844550a613df67f5015cc5a90a8e4b6a8c65d045650ee2

diff --git a/net-analyzer/nfdump/files/nfdump.service b/net-analyzer/nfdump/files/nfdump.service
new file mode 100644
index 000000000000..03e8443077ae
--- /dev/null
+++ b/net-analyzer/nfdump/files/nfdump.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=netflow capture daemon, %I instance
+Documentation=man:nfcapd(1)
+After=network.target auditd.service
+PartOf=nfdump.service
+
+[Service]
+Type=forking
+Environment=options="-l /var/cache/nfdump -p 2055"
+ExecStart=/usr/bin/nfcapd -D -P %t/nfcapd.%I.pid $options
+PIDFile=%t/nfcapd.%I.pid
+KillMode=process
+Restart=no
+
+[Install]
+WantedBy=multi-user.target

diff --git a/net-analyzer/nfdump/nfdump-1.7.4.ebuild b/net-analyzer/nfdump/nfdump-1.7.4.ebuild
new file mode 100644
index 000000000000..5bb38c317ad6
--- /dev/null
+++ b/net-analyzer/nfdump/nfdump-1.7.4.ebuild
@@ -0,0 +1,96 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools flag-o-matic toolchain-funcs systemd
+
+DESCRIPTION="A set of tools to collect and process netflow data"
+HOMEPAGE="https://github.com/phaag/nfdump"
+SRC_URI="https://github.com/phaag/nfdump/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0/${PV}"
+KEYWORDS="~amd64 ~x86"
+IUSE="debug doc jnat ftconv nfpcapd nfprofile nftrack nsel readpcap sflow zstd"
+
+REQUIRED_USE="?? ( jnat nsel )"
+
+RDEPEND="
+	app-arch/bzip2
+	app-arch/lz4:=
+	sys-libs/zlib
+	elibc_musl? ( sys-libs/fts-standalone )
+	ftconv? ( net-analyzer/flow-tools )
+	nfpcapd? ( net-libs/libpcap )
+	nfprofile? ( net-analyzer/rrdtool )
+	nftrack? ( net-analyzer/rrdtool )
+	readpcap? ( net-libs/libpcap )
+	zstd? ( app-arch/zstd:= )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+	app-alternatives/lex
+	app-alternatives/yacc
+	doc? (
+		app-text/doxygen
+		media-gfx/graphviz
+	)
+"
+
+QA_CONFIG_IMPL_DECL_SKIP=(
+	# Not available on Linux, with fallback at src/libnffile/util.h, bug #904952
+	htonll
+)
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-1.6.19-libft.patch
+)
+
+DOCS=( AUTHORS ChangeLog README.md )
+
+src_prepare() {
+	default
+
+	eautoreconf
+
+	if use doc; then
+		doxygen -u doc/Doxyfile.in || die
+	fi
+}
+
+src_configure() {
+	tc-export CC
+
+	# bug #853763
+	use elibc_musl && append-libs "-lfts"
+
+	# --without-ftconf is not handled well, bug #322201
+	local myeconfargs=(
+		$(usex ftconv "--enable-ftconv --with-ftpath=/usr")
+		$(usex nfpcapd --enable-nfpcapd)
+		$(usex nfprofile --enable-nfprofile)
+		$(usex nftrack --enable-nftrack)
+		$(use_enable debug devel)
+		$(use_enable jnat)
+		$(use_enable nsel)
+		$(use_enable readpcap)
+		$(use_enable sflow)
+		$(use_with zstd zstdpath)
+	)
+	econf "${myeconfargs[@]}"
+}
+
+src_install() {
+	default
+
+	find "${ED}" -name '*.la' -type f -delete || die
+
+	newinitd "${FILESDIR}"/nfcapd.initd nfcapd
+	newconfd "${FILESDIR}"/nfcapd.confd nfcapd
+	systemd_newunit "${FILESDIR}/nfdump.service" nfdump@.service
+
+	if use doc; then
+		dodoc -r doc/html
+	fi
+}


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-07-30 19:31 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-12 15:36 [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nfdump/files/, net-analyzer/nfdump/ Jeroen Roovers
  -- strict thread matches above, loose matches on Subject: below --
2024-07-30 19:31 Arthur Zamarin
2022-03-24 23:03 Sam James
2021-08-13  0:40 Sam James
2021-03-15 21:09 Sam James
2021-03-15 21:09 Sam James
2017-12-11 20:37 Jeroen Roovers

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox