mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-24 23:47:14 -08:00
net-firewall/nftables: Bump to version 0.8.1
Package-Manager: Portage-2.3.19, Repoman-2.3.6
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
DIST nftables-0.6.tar.gz 252523 BLAKE2B 0359ca5265b244c433efd0b3c5d6aaf1a68c40b70b9199602e8f17b4e509a24e48554aefafc89d51c9e1e821c471690af9c99f1178f227d3cd9395897837de9e SHA512 17f3b94687865e077dc082cf61b29ab2854fd1ffe18212a8d424f2876aef8db9780dd4d06dca8e6d093498151d47bab73e40e1f54062a83a23a3cbe75f27e921
|
||||
DIST nftables-0.7.tar.gz 292652 BLAKE2B 036afb1d27ea7d078f976c76a87a4b1ccef519197594910f7f3cb9d37b09103da41c15f611e24392cc9648f216606a29bd312a9026ecf053fc3b71959d1da7e1 SHA512 6032720abf3af8a6dc0b4f507c6ae970447f504d59db4a34b2e0eea3c59962bc69d9ebfaa4e26a117747eb9d0224716a9709b96551b5479d914d7498f26ed43a
|
||||
DIST nftables-0.8.1.tar.gz 329098 BLAKE2B d6e5803e146ed5883761d620ef1549e883a2947b495a9b1ff2a40c70794ab5125596e0802fb60bff6d1a21e666c94338b92a22ef3c4c1b66e0b4521cd3dfb78d SHA512 5cae3a411f24adc17786b45d4ed8256eb44fd90f044f7f5d7ddebb1875d0317197e13128d9b22115cd7fcdfa21dba3c539de325ecedce707f8766c93e03efc75
|
||||
DIST nftables-0.8.tar.gz 327629 BLAKE2B a484c22ac010f68fc7458c12cabd0c35e474a0bf81fa4edbefba12d75b424898d38adb11a7fbb4542efbbb2d14be823701b3d9ced7b9fd669338366733fa169b SHA512 90ffebc338c121334ca42822793b6fdeff48390e755c690308919de47064b53f9af735a2c2914e5255f1bddec90484599337d4cdd67f7a01a3956deefcef9fcb
|
||||
|
||||
@@ -0,0 +1,84 @@
|
||||
# Copyright 1999-2018 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
inherit autotools linux-info systemd
|
||||
|
||||
DESCRIPTION="Linux kernel (3.13+) firewall, NAT and packet mangling tools"
|
||||
HOMEPAGE="https://netfilter.org/projects/nftables/"
|
||||
SRC_URI="https://git.netfilter.org/nftables/snapshot/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm ~ia64 ~x86"
|
||||
IUSE="debug doc +gmp +readline"
|
||||
|
||||
RDEPEND=">=net-libs/libmnl-1.0.3:0=
|
||||
gmp? ( dev-libs/gmp:0= )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
>=net-libs/libnftnl-1.0.8:0="
|
||||
|
||||
DEPEND="${RDEPEND}
|
||||
>=app-text/docbook2X-0.8.8-r4
|
||||
doc? ( >=app-text/dblatex-0.3.7 )
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
virtual/pkgconfig"
|
||||
|
||||
S="${WORKDIR}/v${PV}"
|
||||
|
||||
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
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local myeconfargs=(
|
||||
--sbindir="${EPREFIX}"/sbin
|
||||
$(use_enable doc pdf-doc)
|
||||
$(use_enable debug)
|
||||
$(use_with readline cli)
|
||||
$(use_with !gmp mini_gmp)
|
||||
)
|
||||
econf "${myeconfargs[@]}"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
|
||||
dodir /usr/libexec/${PN}
|
||||
exeinto /usr/libexec/${PN}
|
||||
doexe "${FILESDIR}"/libexec/${PN}.sh
|
||||
|
||||
newconfd "${FILESDIR}"/${PN}.confd ${PN}
|
||||
newinitd "${FILESDIR}"/${PN}.init ${PN}
|
||||
keepdir /var/lib/nftables
|
||||
|
||||
systemd_dounit "${FILESDIR}"/systemd/${PN}-restore.service
|
||||
systemd_enable_service basic.target ${PN}-restore.service
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
local save_file
|
||||
save_file="${EROOT%/}/var/lib/nftables/rules-save"
|
||||
|
||||
# In order for the nftables-restore systemd service to start
|
||||
# the save_file must exist.
|
||||
if [[ ! -f ${save_file} ]]; then
|
||||
touch ${save_file}
|
||||
fi
|
||||
|
||||
elog "If you are creating firewall rules before the next system restart "
|
||||
elog "the nftables-restore service must be manually started in order to "
|
||||
elog "save those rules on shutdown."
|
||||
}
|
||||
Reference in New Issue
Block a user