diff --git a/0001-build-add-missing-AM_CPPFLAGS-to-examples.patch b/0001-build-add-missing-AM_CPPFLAGS-to-examples.patch new file mode 100644 index 0000000..5319ec2 --- /dev/null +++ b/0001-build-add-missing-AM_CPPFLAGS-to-examples.patch @@ -0,0 +1,28 @@ +From 6b46cd26f9503ae50e9741747092a72d2fc35ec3 Mon Sep 17 00:00:00 2001 +From: Jan Engelhardt +Date: Tue, 22 Feb 2022 05:44:57 +0100 +Subject: [PATCH] build: add missing AM_CPPFLAGS to examples/ + +examples$ make V=1 +depbase=`echo nft-buffer.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\ +gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -MT nft-buffer.o -MD -MP -MF $depbase.Tpo -c -o nft-buffer.o nft-buffer.c &&\ +mv -f $depbase.Tpo $depbase.Po +nft-buffer.c:3:10: fatal error: nftables/libnftables.h: No such file or directory + +Signed-off-by: Jan Engelhardt +--- + examples/Makefile.am | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/examples/Makefile.am b/examples/Makefile.am +index c972170d..d7234ce4 100644 +--- a/examples/Makefile.am ++++ b/examples/Makefile.am +@@ -1,3 +1,4 @@ ++AM_CPPFLAGS = -I$(top_srcdir)/include + noinst_PROGRAMS = nft-buffer \ + nft-json-file + +-- +2.35.1 + diff --git a/nftables.changes b/nftables.changes index 4ab83f9..dee7af9 100644 --- a/nftables.changes +++ b/nftables.changes @@ -7,6 +7,7 @@ Tue Feb 22 04:39:01 UTC 2022 - Jan Engelhardt * Support for tcp fastopen, md5sig and mptcp options. * MP-TCP subtype matching support. * JSON support for flowtables. +- Add 0001-build-add-missing-AM_CPPFLAGS-to-examples.patch ------------------------------------------------------------------- Thu Nov 18 22:15:03 UTC 2021 - Jan Engelhardt diff --git a/nftables.spec b/nftables.spec index ae1b1fd..1478b43 100644 --- a/nftables.spec +++ b/nftables.spec @@ -28,14 +28,16 @@ URL: https://netfilter.org/projects/nftables/ Source: http://ftp.netfilter.org/pub/%name/%name-%version.tar.bz2 Source2: http://ftp.netfilter.org/pub/%name/%name-%version.tar.bz2.sig Source3: %name.keyring +Patch1: 0001-build-add-missing-AM_CPPFLAGS-to-examples.patch BuildRequires: asciidoc BuildRequires: bison BuildRequires: flex BuildRequires: gmp-devel +BuildRequires: libtool BuildRequires: pkg-config >= 0.21 BuildRequires: python3-base -BuildRequires: readline-devel BuildRequires: pkgconfig(jansson) +BuildRequires: pkgconfig(libedit) BuildRequires: pkgconfig(libmnl) >= 1.0.4 BuildRequires: pkgconfig(libnftnl) >= 1.2.1 BuildRequires: pkgconfig(xtables) >= 1.6.1 @@ -81,6 +83,7 @@ A Python module for nftables. %autosetup -p1 %build +autoreconf -fi mkdir bin ln -s "%_bindir/docbook-to-man" bin/docbook2x-man export PATH="$PATH:$PWD/bin"