net-libs/rpcsvc-proto: arm stable wrt bug #725002
[gentoo.git] / net-libs / nDPI / nDPI-2.2.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5 inherit autotools eutils ltprune multilib versionator
6
7 DESCRIPTION="Open Source Deep Packet Inspection Software Toolkit"
8 HOMEPAGE="https://www.ntop.org/"
9 SRC_URI="https://github.com/ntop/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
10
11 LICENSE="GPL-3"
12 SLOT="0"
13 KEYWORDS="~amd64 ~x86"
14 IUSE="static-libs"
15
16 DEPEND="dev-libs/json-c:=
17         net-libs/libpcap"
18 RDEPEND="${DEPEND}"
19
20 src_prepare() {
21         sed -e "s/@NDPI_MAJOR@/$(get_version_component_range 1)/g;s/@NDPI_MINOR@/$(get_version_component_range 2)/g;s/@NDPI_PATCH@/$(get_version_component_range 3)/g;s/@NDPI_VERSION_SHORT@/${PV}/g" < "${S}/configure.seed" > "${S}/configure.ac" || die
22
23         mv "${S}/src/lib/third_party/include/libcache.h" "${S}/src/include"
24         epatch "${FILESDIR}/${P}-libcache-include.patch"
25
26         default
27         eautoreconf
28 }
29
30 src_install() {
31         default
32         if ! use static-libs; then
33                 rm "${D}"/usr/$(get_libdir)/lib${PN,,}.a || die
34         fi
35         prune_libtool_files
36 }