summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-libs')
-rw-r--r--net-libs/libnftnl/Manifest2
-rw-r--r--net-libs/libnftnl/libnftnl-1.2.4.ebuild73
2 files changed, 75 insertions, 0 deletions
diff --git a/net-libs/libnftnl/Manifest b/net-libs/libnftnl/Manifest
index bcb01613be38..66595de1af49 100644
--- a/net-libs/libnftnl/Manifest
+++ b/net-libs/libnftnl/Manifest
@@ -3,3 +3,5 @@ DIST libnftnl-1.2.2.tar.bz2 394955 BLAKE2B 69c3338e295dd158faad812ec05db8b8ab12c
DIST libnftnl-1.2.2.tar.bz2.sig 566 BLAKE2B ffdb35811e57f55ba30dfdd3e6656166b5f515348f99ee11c771b7460fd1b26b1e598146afdf76f4765e865ae76472d7071eabb30604cf78964e2fcbd6a39508 SHA512 dc4263e744a79f2b7e4ea619e740d66d6013e62aab655f040150552a6f069794ac59b8cc87a9f630dd42f087ef60523ecf08dc89cd1194637d988f85f67aaf43
DIST libnftnl-1.2.3.tar.bz2 395208 BLAKE2B 893688a861bbb10609642bed912090b227d5d823cc1b94098b60ac85d137254ff3001971580e5059029a33c64e7226cc8473b0b9c1c79be77cbfb0c477254a1e SHA512 e2d16cbc062eb8900f0472abb8fe6b22910cc5a8efbb47445fe6ce6e2713a0637f74b46b2bf2031ba9ecb2e5eed932e3bbb49b015c7b7207591249de23d5149d
DIST libnftnl-1.2.3.tar.bz2.sig 566 BLAKE2B 82b49ab1c7a9a588fea67b516d57afb455ceb5242bf774ff7ec92e240b5c2373fe7cc90dd60f302cb4e0615ec0036d995c1ddf25d9b26d6168eeaaa3c7027511 SHA512 73b8f75851dd30f5f54fe85d4c75d9ab18151c38e7c63961b52965e5e7478d240931a09a078fda1fe6b1a32a588e092c98e44b57fe1c9542874ac76bb04a29a1
+DIST libnftnl-1.2.4.tar.bz2 395444 BLAKE2B 43a89fd2f7d9fd77e59423b599fe209c821da660669c7fe3c569ac262b78cfe1942ab9fd597bf09a0c93b7d1ff465ca79bd925967be93333a11468845ef785fd SHA512 5375d1d15627aabf25129433630395f53009b22a255fcd113b302af7f2f0a234fd54c827b0ef1c8fd3a13e272a1696f780560672d4af6abad0e19805f9d56326
+DIST libnftnl-1.2.4.tar.bz2.sig 566 BLAKE2B f7598f5ed56cf101a61358206d1e4e3fe3fa12514d6d6a89a00f4ec853d4473aefbfbedf7ce062160bd6c7578e5a09bfb6a5bf1c2b98f5858a8d9f4f9ce5be38 SHA512 89bb5ea536632518aad62e798868284fe82ba75d2af09b6505d506910aafdbaaed48b84b82fcf4ffb241672e51b696f8e24983636184b9713795c90f281f8683
diff --git a/net-libs/libnftnl/libnftnl-1.2.4.ebuild b/net-libs/libnftnl/libnftnl-1.2.4.ebuild
new file mode 100644
index 000000000000..e2640d03be0d
--- /dev/null
+++ b/net-libs/libnftnl/libnftnl-1.2.4.ebuild
@@ -0,0 +1,73 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}"/usr/share/openpgp-keys/netfilter.org.asc
+inherit linux-info usr-ldscript verify-sig
+
+DESCRIPTION="Netlink API to the in-kernel nf_tables subsystem"
+HOMEPAGE="https://netfilter.org/projects/nftables/"
+
+if [[ ${PV} =~ ^[9]{4,}$ ]]; then
+ inherit autotools git-r3
+ EGIT_REPO_URI="https://git.netfilter.org/${PN}"
+else
+ SRC_URI="
+ https://netfilter.org/projects/${PN}/files/${P}.tar.bz2
+ verify-sig? ( https://netfilter.org/projects/${PN}/files/${P}.tar.bz2.sig )
+ "
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+
+ BDEPEND+="verify-sig? ( sec-keys/openpgp-keys-netfilter )"
+fi
+
+LICENSE="GPL-2"
+SLOT="0/11" # libnftnl.so version
+IUSE="examples static-libs test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ >=net-libs/libmnl-1.0.4:=
+"
+BDEPEND+="
+ virtual/pkgconfig
+"
+DEPEND="${RDEPEND}"
+
+pkg_setup() {
+ if kernel_is ge 3 13; then
+ CONFIG_CHECK="~NF_TABLES"
+ linux-info_pkg_setup
+ else
+ eerror "This package requires kernel version 3.13 or newer to work properly."
+ fi
+}
+
+src_prepare() {
+ default
+
+ [[ ${PV} =~ ^[9]{4,}$ ]] && eautoreconf
+}
+
+src_configure() {
+ local myeconfargs=(
+ $(use_enable static-libs static)
+ )
+
+ econf "${myeconfargs[@]}"
+}
+
+src_install() {
+ default
+
+ gen_usr_ldscript -a nftnl
+
+ find "${ED}" -type f -name '*.la' -delete || die
+
+ if use examples; then
+ find examples/ -name 'Makefile*' -delete || die "Could not rm examples"
+ dodoc -r examples
+ docompress -x /usr/share/doc/${PF}/examples
+ fi
+}