[net-firewall/iptables] sync with tree
This commit is contained in:
parent
26d32e5453
commit
b3bce0c2be
@ -1,13 +1,12 @@
|
|||||||
# Copyright 1999-2016 Gentoo Foundation
|
# Copyright 1999-2018 Gentoo Foundation
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
# $Id$
|
|
||||||
|
|
||||||
EAPI="5"
|
EAPI=6
|
||||||
|
|
||||||
# Force users doing their own patches to install their own tools
|
# Force users doing their own patches to install their own tools
|
||||||
AUTOTOOLS_AUTO_DEPEND=no
|
AUTOTOOLS_AUTO_DEPEND=no
|
||||||
|
|
||||||
inherit eutils multilib systemd toolchain-funcs autotools flag-o-matic git-r3
|
inherit ltprune multilib systemd toolchain-funcs autotools flag-o-matic git-r3
|
||||||
|
|
||||||
DESCRIPTION="Linux kernel (2.4+) firewall, NAT and packet mangling tools"
|
DESCRIPTION="Linux kernel (2.4+) firewall, NAT and packet mangling tools"
|
||||||
HOMEPAGE="http://www.netfilter.org/projects/iptables/"
|
HOMEPAGE="http://www.netfilter.org/projects/iptables/"
|
||||||
@ -20,16 +19,17 @@ SLOT="0/12"
|
|||||||
KEYWORDS=""
|
KEYWORDS=""
|
||||||
IUSE="conntrack ipv6 netlink nftables pcap static-libs"
|
IUSE="conntrack ipv6 netlink nftables pcap static-libs"
|
||||||
|
|
||||||
RDEPEND="
|
COMMON_DEPEND="
|
||||||
conntrack? ( net-libs/libnetfilter_conntrack )
|
conntrack? ( >=net-libs/libnetfilter_conntrack-1.0.6 )
|
||||||
netlink? ( net-libs/libnfnetlink )
|
netlink? ( net-libs/libnfnetlink )
|
||||||
nftables? (
|
nftables? (
|
||||||
>=net-libs/libmnl-1.0
|
>=net-libs/libmnl-1.0:0=
|
||||||
>=net-libs/libnftnl-1.0.5
|
>=net-libs/libnftnl-1.0.5:0=
|
||||||
)
|
)
|
||||||
pcap? ( net-libs/libpcap )
|
pcap? ( net-libs/libpcap )
|
||||||
"
|
"
|
||||||
DEPEND="${RDEPEND}
|
|
||||||
|
DEPEND="${COMMON_DEPEND}
|
||||||
virtual/os-headers
|
virtual/os-headers
|
||||||
virtual/pkgconfig
|
virtual/pkgconfig
|
||||||
nftables? (
|
nftables? (
|
||||||
@ -37,6 +37,9 @@ DEPEND="${RDEPEND}
|
|||||||
virtual/yacc
|
virtual/yacc
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
|
RDEPEND="${COMMON_DEPEND}
|
||||||
|
nftables? ( net-misc/ethertypes )
|
||||||
|
"
|
||||||
|
|
||||||
src_prepare() {
|
src_prepare() {
|
||||||
# use the saner headers from the kernel
|
# use the saner headers from the kernel
|
||||||
@ -57,19 +60,23 @@ src_configure() {
|
|||||||
-e "/nfconntrack=[01]/s:=[01]:=$(usex conntrack 1 0):" \
|
-e "/nfconntrack=[01]/s:=[01]:=$(usex conntrack 1 0):" \
|
||||||
configure || die
|
configure || die
|
||||||
|
|
||||||
econf \
|
local myeconfargs=(
|
||||||
--sbindir="${EPREFIX}/sbin" \
|
--sbindir="${EPREFIX}/sbin"
|
||||||
--libexecdir="${EPREFIX}/$(get_libdir)" \
|
--libexecdir="${EPREFIX}/$(get_libdir)"
|
||||||
--enable-devel \
|
--enable-devel
|
||||||
--enable-shared \
|
--enable-shared
|
||||||
$(use_enable nftables) \
|
$(use_enable nftables)
|
||||||
$(use_enable pcap bpf-compiler) \
|
$(use_enable pcap bpf-compiler)
|
||||||
$(use_enable pcap nfsynproxy) \
|
$(use_enable pcap nfsynproxy)
|
||||||
$(use_enable static-libs static) \
|
$(use_enable static-libs static)
|
||||||
$(use_enable ipv6)
|
$(use_enable ipv6)
|
||||||
|
)
|
||||||
|
econf "${myeconfargs[@]}"
|
||||||
}
|
}
|
||||||
|
|
||||||
src_compile() {
|
src_compile() {
|
||||||
|
# Deal with parallel build errors.
|
||||||
|
use nftables && emake -C iptables xtables-config-parser.h
|
||||||
emake V=1
|
emake V=1
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -98,6 +105,11 @@ src_install() {
|
|||||||
newconfd "${FILESDIR}"/ip6tables-1.4.13.confd ip6tables
|
newconfd "${FILESDIR}"/ip6tables-1.4.13.confd ip6tables
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if use nftables; then
|
||||||
|
# Bug 647458
|
||||||
|
rm "${ED%/}"/etc/ethertypes || die
|
||||||
|
fi
|
||||||
|
|
||||||
systemd_dounit "${FILESDIR}"/systemd/iptables-{re,}store.service
|
systemd_dounit "${FILESDIR}"/systemd/iptables-{re,}store.service
|
||||||
if use ipv6 ; then
|
if use ipv6 ; then
|
||||||
systemd_dounit "${FILESDIR}"/systemd/ip6tables-{re,}store.service
|
systemd_dounit "${FILESDIR}"/systemd/ip6tables-{re,}store.service
|
||||||
|
Loading…
Reference in New Issue
Block a user