commit:     b6b2a0c93ecc164d8b3089ee932aeae5a9e38b0b
Author:     Nicholas Vinson <nvinson234 <AT> gmail <DOT> com>
AuthorDate: Tue Dec 20 15:53:21 2016 +0000
Commit:     Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Sat Jan  7 21:46:02 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b6b2a0c9

net-firewall/nftables: add xml USE flag

libnftnl-1.0.7 no longer supports outputing the firewall state as XML.
If a user wants that output, the user must use libnftnl-1.0.6.
Therefore, I added the xml USE flag so I could restrict libnftnl to
1.0.6 when xml is enabled and allow newer versions to be used when it is
not.

Unforunately, nftables unconditionally compiles support for xml output,
so when xml use is attempted with a version of libnftnl that does not
support it, the result is just an empty file.

Package-Manager: Portage-2.3.3, Repoman-2.3.1

 net-firewall/nftables/nftables-0.6-r4.ebuild | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/net-firewall/nftables/nftables-0.6-r4.ebuild 
b/net-firewall/nftables/nftables-0.6-r4.ebuild
index 7874baf..5750a3a 100644
--- a/net-firewall/nftables/nftables-0.6-r4.ebuild
+++ b/net-firewall/nftables/nftables-0.6-r4.ebuild
@@ -13,12 +13,13 @@ 
SRC_URI="http://git.netfilter.org/nftables/snapshot/v${PV}.tar.gz -> ${P}.tar.gz
 LICENSE="GPL-2"
 SLOT="0"
 KEYWORDS="~amd64 ~arm ~x86"
-IUSE="debug doc gmp +readline"
+IUSE="debug doc gmp +readline xml"
 
 RDEPEND=">=net-libs/libmnl-1.0.3
-       >=net-libs/libnftnl-1.0.6
        gmp? ( dev-libs/gmp:0= )
-       readline? ( sys-libs/readline:0= )"
+       readline? ( sys-libs/readline:0= )
+       >=net-libs/libnftnl-1.0.6[xml(-)?]
+       "
 DEPEND="${RDEPEND}
        >=app-text/docbook2X-0.8.8-r4
        doc? ( >=app-text/dblatex-0.3.7 )
@@ -73,7 +74,7 @@ src_install() {
 
 pkg_postinst() {
        local save_file
-       save_file="${EROOT}var/lib/nftables/rules-save"
+       save_file="${EROOT%/}/var/lib/nftables/rules-save"
 
        elog "In order for the nftables-restore systemd service to start, "
        elog "the file, ${save_file}, must exist.  To create this "

Reply via email to