From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-libs/nDPI/
Date: Mon, 3 Jan 2022 11:23:03 +0000 (UTC) [thread overview]
Message-ID: <1641208880.fa4c91dd460e1604ec58cc6b3531e8170812da3f.sam@gentoo> (raw)
commit: fa4c91dd460e1604ec58cc6b3531e8170812da3f
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Jan 3 10:50:06 2022 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Jan 3 11:21:20 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fa4c91dd
net-libs/nDPI: add 4.0
Includes a patch which adds an API to allow ntopong to work too.
(Working on ar/other build system patches upstream.)
Bug: https://bugs.gentoo.org/799782
Bug: https://bugs.gentoo.org/625730
Closes: https://bugs.gentoo.org/830403
Thanks-to: Larry Sexton <sexton.larry048 <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>
net-libs/nDPI/Manifest | 2 ++
net-libs/nDPI/nDPI-4.0.ebuild | 59 ++++++++++++++++++++++++++++++++++++
net-libs/nDPI/nDPI-9999.ebuild | 68 ++++++++++++++++++++----------------------
3 files changed, 93 insertions(+), 36 deletions(-)
diff --git a/net-libs/nDPI/Manifest b/net-libs/nDPI/Manifest
index 505e78a99b99..eae6568123c4 100644
--- a/net-libs/nDPI/Manifest
+++ b/net-libs/nDPI/Manifest
@@ -1 +1,3 @@
DIST nDPI-3.4.tar.gz 37976087 BLAKE2B 49e25586671a91278d90775c3dbc881ce4ca9ae4afd3108b1caff3b0d38251808bcd52ead253f451474195994fbf94658f70241acedb23c35a475df3b15c4a20 SHA512 ed5a22b6ddc14ad707a18a0bd96746c1df489969faaa42016fa9aad8d414fc4ee303b96cac15c3ba86f484a80a0aaa2dd1be5f92be672912e0e0d30da4bdad4c
+DIST nDPI-4.0-patches.tar.bz2 8744 BLAKE2B 48bfb2cf240823b64ab15a3f8a21acece878102ebb4cc807648b264ef091107a05d66fc672cccd1bc721ad3ea0edde786a1f133dfc84c91422604a9929e327ed SHA512 99a780c18c048ceec29c42828c420fe3f9624906eaef70f92af6abdbf7bc29133e048d7f8de85d8b73aa6667066e7ab5843fa293221d5ec8bbe87803dde83db6
+DIST nDPI-4.0.tar.gz 120053617 BLAKE2B ea0f333bd62622c1ab792137f9bbf2e35cb3790aae191c5caeaea36c7ce376bfa84633e99e321c16bcfbe5812d6674b825bdc4197297cee76064ed88f344a577 SHA512 2526041bc02a210e65bad31323a66167d79a37d14697cf4459054cc54715e53f9673b0000cefa6b452bbe3b3e6c25f0bafcf59d24323d210e2ce6782d9153f81
diff --git a/net-libs/nDPI/nDPI-4.0.ebuild b/net-libs/nDPI/nDPI-4.0.ebuild
new file mode 100644
index 000000000000..8516413b47eb
--- /dev/null
+++ b/net-libs/nDPI/nDPI-4.0.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools
+
+DESCRIPTION="Open Source Deep Packet Inspection Software Toolkit"
+HOMEPAGE="https://www.ntop.org/"
+if [[ ${PV} == 9999 ]] ; then
+ EGIT_REPO_URI="https://github.com/ntop/${PN}"
+ inherit git-r3
+else
+ SRC_URI="https://github.com/ntop/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${P}-patches.tar.bz2"
+
+ KEYWORDS="~amd64 ~x86"
+fi
+
+LICENSE="LGPL-3+"
+SLOT="0/$(ver_cut 1)"
+
+DEPEND="dev-libs/json-c:=
+ dev-libs/libgcrypt:=
+ dev-libs/libgpg-error
+ net-libs/libpcap"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${WORKDIR}"/${P}-patches/
+)
+
+# Also sent a patch upstream https://github.com/ntop/nDPI/pull/1392 for
+# AR/CC etc but doesn't apply cleanly (at all) to 4.0.
+
+src_prepare() {
+ default
+
+ sed -i \
+ -e "s%^libdir\s*=\s*\${prefix}/lib\s*$%libdir = \${prefix}/$(get_libdir)%" \
+ src/lib/Makefile.in || die
+
+ eautoreconf
+}
+
+src_test() {
+ pushd tests || die
+
+ ./do.sh || die "Failed tests"
+ ./do-unit.sh || die "Failed unit tests"
+
+ popd || die
+}
+
+src_install() {
+ default
+
+ rm "${ED}/usr/$(get_libdir)"/lib${PN,,}.a || die
+}
diff --git a/net-libs/nDPI/nDPI-9999.ebuild b/net-libs/nDPI/nDPI-9999.ebuild
index bd4ac3459b84..ea288e57ec66 100644
--- a/net-libs/nDPI/nDPI-9999.ebuild
+++ b/net-libs/nDPI/nDPI-9999.ebuild
@@ -1,58 +1,54 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
-inherit autotools git-r3
+inherit autotools
DESCRIPTION="Open Source Deep Packet Inspection Software Toolkit"
HOMEPAGE="https://www.ntop.org/"
-EGIT_REPO_URI="https://github.com/ntop/${PN}"
+if [[ ${PV} == 9999 ]] ; then
+ EGIT_REPO_URI="https://github.com/ntop/${PN}"
+ inherit git-r3
+else
+ SRC_URI="https://github.com/ntop/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
-LICENSE="GPL-3"
-SLOT="0"
-KEYWORDS=""
-IUSE="static-libs"
+ KEYWORDS="~amd64 ~x86"
+fi
-DEPEND="
- dev-libs/json-c:=
- net-libs/libpcap
-"
-RDEPEND="
- ${DEPEND}
-"
+LICENSE="LGPL-3+"
+SLOT="0/$(ver_cut 1)"
+
+DEPEND="dev-libs/json-c:=
+ dev-libs/libgcrypt:=
+ dev-libs/libgpg-error
+ net-libs/libpcap"
+RDEPEND="${DEPEND}"
+
+# Also sent a patch upstream https://github.com/ntop/nDPI/pull/1392 for
+# AR/CC etc but doesn't apply cleanly (at all) to 4.0.
src_prepare() {
- eval $(grep '^NDPI_MAJOR=' autogen.sh)
- eval $(grep '^NDPI_MINOR=' autogen.sh)
- eval $(grep '^NDPI_PATCH=' autogen.sh)
- NDPI_VERSION_SHORT="${NDPI_MAJOR}.${NDPI_MINOR}.${NDPI_PATCH}"
-
- sed \
- -e "s/@NDPI_MAJOR@/${NDPI_MAJOR}/g" \
- -e "s/@NDPI_MINOR@/${NDPI_MINOR}/g" \
- -e "s/@NDPI_PATCH@/${NDPI_PATCH}/g" \
- -e "s/@NDPI_VERSION_SHORT@/${NDPI_VERSION_SHORT}/g" \
- < "${S}/configure.seed" \
- > "${S}/configure.ac" || die
+ default
sed -i \
-e "s%^libdir\s*=\s*\${prefix}/lib\s*$%libdir = \${prefix}/$(get_libdir)%" \
src/lib/Makefile.in || die
- default
eautoreconf
+}
- # Taken from autogen.sh (bug #704074):
- sed -i \
- -e "s/#define PACKAGE/#define NDPI_PACKAGE/g" \
- -e "s/#define VERSION/#define NDPI_VERSION/g" \
- configure || die
+src_test() {
+ pushd tests || die
+
+ ./do.sh || die "Failed tests"
+ ./do-unit.sh || die "Failed unit tests"
+
+ popd || die
}
src_install() {
default
- if ! use static-libs; then
- rm "${D}"/usr/$(get_libdir)/lib${PN,,}.a || die
- fi
+
+ rm "${ED}/usr/$(get_libdir)"/lib${PN,,}.a || die
}
next reply other threads:[~2022-01-03 11:23 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-03 11:23 Sam James [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-06-09 16:13 [gentoo-commits] repo/gentoo:master commit in: net-libs/nDPI/ Sam James
2024-06-09 15:55 Sam James
2024-06-09 15:55 Sam James
2023-02-03 16:53 Sam James
2022-08-18 0:31 Sam James
2022-07-09 4:01 Sam James
2022-02-08 6:31 Sam James
2022-01-04 6:46 Sam James
2020-05-16 11:49 Jeroen Roovers
2020-01-28 11:53 Jeroen Roovers
2019-12-28 10:14 Jeroen Roovers
2019-12-28 1:03 Jeroen Roovers
2019-12-28 1:03 Jeroen Roovers
2019-04-08 21:36 Patrice Clement
2018-01-22 21:03 Slawek Lis
2017-12-19 21:45 Thomas Deutschmann
2017-10-22 17:15 Jeroen Roovers
2017-06-19 11:59 Slawek Lis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1641208880.fa4c91dd460e1604ec58cc6b3531e8170812da3f.sam@gentoo \
--to=sam@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox