Gentoo Archives: gentoo-commits

From: Sergey Popov <pinkbyte@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-firewall/ipt_netflow/, net-firewall/ipt_netflow/files/
Date: Mon, 05 Jul 2021 14:14:31
Message-Id: 1625494504.646844f1f2373014a76b78442bb66f244aa23aa5.pinkbyte@gentoo
1 commit: 646844f1f2373014a76b78442bb66f244aa23aa5
2 Author: Sergey Popov <pinkbyte <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jul 5 14:12:59 2021 +0000
4 Commit: Sergey Popov <pinkbyte <AT> gentoo <DOT> org>
5 CommitDate: Mon Jul 5 14:15:04 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=646844f1
7
8 net-firewall/ipt_netflow-2.6: stable on amd64/x86
9
10 Drop old version
11
12 Bug: https://bugs.gentoo.org/791598
13 Package-Manager: Portage-3.0.18, Repoman-3.0.2
14 Signed-off-by: Sergey Popov <pinkbyte <AT> gentoo.org>
15
16 net-firewall/ipt_netflow/Manifest | 1 -
17 .../ipt_netflow/files/ipt_netflow-2.5-gentoo.patch | 61 -----------
18 .../files/ipt_netflow-2.5.1-vlan_dev_priv.patch | 32 ------
19 .../ipt_netflow/ipt_netflow-2.5.1-r1.ebuild | 111 ---------------------
20 net-firewall/ipt_netflow/ipt_netflow-2.6.ebuild | 2 +-
21 5 files changed, 1 insertion(+), 206 deletions(-)
22
23 diff --git a/net-firewall/ipt_netflow/Manifest b/net-firewall/ipt_netflow/Manifest
24 index a779559db91..8d7eda97792 100644
25 --- a/net-firewall/ipt_netflow/Manifest
26 +++ b/net-firewall/ipt_netflow/Manifest
27 @@ -1,2 +1 @@
28 -DIST ipt_netflow-2.5.1.tar.gz 94627 BLAKE2B 440daed1f0c02e4700c6d4a97da08abc7bf51c73cd824a67fd2b7b9394b47d493ca7acfea34467d93cdce6dded2c5b24b4a2600b9f717aa54561d1f88a123dbc SHA512 dd0bde358f788f2d62ace6a0b1529128f0a686f9b776deeae3502d45d06d13971e8ea249d2647d00b00e73625c515bc12a4b7bd8d34fafd5f3b32f290d48cdce
29 DIST ipt_netflow-2.6.tar.gz 95752 BLAKE2B 088c7030addd34d9d889cfa705aa060d0793e33be957deb3b703daea4229afc24f7268285ce336e425a024dc9d8139633a5206ff9d769c95cf71c156acbd4f25 SHA512 0ccea556e25dc6bc2d8c7648ed1b4ab366097baf5b06f167ccd19d2adb0a195ad652635181573785f9e9fa208d163f22b6527310eb939455d7ee3bc141cbeed5
30
31 diff --git a/net-firewall/ipt_netflow/files/ipt_netflow-2.5-gentoo.patch b/net-firewall/ipt_netflow/files/ipt_netflow-2.5-gentoo.patch
32 deleted file mode 100644
33 index 508be107795..00000000000
34 --- a/net-firewall/ipt_netflow/files/ipt_netflow-2.5-gentoo.patch
35 +++ /dev/null
36 @@ -1,61 +0,0 @@
37 ---- a/Makefile.in
38 -+++ b/Makefile.in
39 -@@ -11,7 +11,7 @@
40 - SNMPTGSO = /usr/lib/snmp/dlmod/snmp_NETFLOW.so
41 - SNMPCONF = /etc/snmp/snmpd.conf
42 - SNMPLINE = dlmod netflow $(SNMPTGSO)
43 --CC = gcc
44 -+CC ?= gcc
45 -
46 - # https://www.kernel.org/doc/Documentation/kbuild/modules.txt
47 - # https://www.kernel.org/doc/Documentation/kbuild/makefiles.txt
48 -@@ -22,31 +22,31 @@
49 -
50 - ipt_NETFLOW.ko: version.h ipt_NETFLOW.c ipt_NETFLOW.h compat_def.h compat.h Makefile
51 - @echo Compiling for kernel $(KVERSION)
52 -- make -C $(KDIR) M=$(CURDIR) modules CONFIG_DEBUG_INFO=y
53 -+ $(MAKE) -C $(KDIR) M=$(CURDIR) modules CONFIG_DEBUG_INFO=y
54 - @touch $@
55 - compat_def.h: gen_compat_def
56 - ./gen_compat_def > $@
57 - sparse: | version.h ipt_NETFLOW.c ipt_NETFLOW.h compat.h Makefile
58 - @rm -f ipt_NETFLOW.ko ipt_NETFLOW.o
59 - @echo Compiling for kernel $(KVERSION)
60 -- make -C $(KDIR) M=$(CURDIR) modules C=1
61 -+ $(MAKE) -C $(KDIR) M=$(CURDIR) modules C=1
62 - @touch ipt_NETFLOW.ko
63 - coverity:
64 - coverity-submit -v
65 -
66 - minstall: | ipt_NETFLOW.ko
67 - @echo " *"
68 -- make -C $(KDIR) M=$(CURDIR) modules_install INSTALL_MOD_PATH=$(DESTDIR)
69 -+ $(MAKE) -C $(KDIR) M=$(CURDIR) modules_install INSTALL_MOD_PATH=$(DESTDIR)
70 - $(DEPMOD)
71 - mclean:
72 -- make -C $(KDIR) M=$(CURDIR) clean
73 -+ $(MAKE) -C $(KDIR) M=$(CURDIR) clean
74 - lclean:
75 - -rm -f *.so *_sh.o
76 - clean: mclean lclean
77 - -rm -f *.so *.o modules.order version.h compat_def.h
78 -
79 - snmp_NETFLOW.so: snmp_NETFLOW.c
80 -- $(CC) -fPIC -shared -o $@ $< -lnetsnmp
81 -+ $(CC) $(CFLAGS) $(LDFLAGS) -fPIC -shared -o $@ $< -lnetsnmp
82 -
83 - sinstall: | snmp_NETFLOW.so IPT-NETFLOW-MIB.my
84 - @echo " *"
85 -@@ -66,10 +66,10 @@
86 - fi
87 -
88 - %_sh.o: libipt_NETFLOW.c
89 -- $(CC) $(CFLAGS) -O2 -Wall -Wunused $(IPTABLES_CFLAGS) -fPIC -o $@ -c libipt_NETFLOW.c
90 -+ $(CC) $(CFLAGS) -Wall -Wunused $(IPTABLES_CFLAGS) -fPIC -o $@ -c libipt_NETFLOW.c
91 -
92 - %.so: %_sh.o
93 -- $(CC) -shared -o $@ $<
94 -+ $(CC) $(LDFLAGS) -shared -o $@ $<
95 -
96 - version.h: ipt_NETFLOW.c ipt_NETFLOW.h compat.h Makefile
97 - @./version.sh --define > version.h
98
99 diff --git a/net-firewall/ipt_netflow/files/ipt_netflow-2.5.1-vlan_dev_priv.patch b/net-firewall/ipt_netflow/files/ipt_netflow-2.5.1-vlan_dev_priv.patch
100 deleted file mode 100644
101 index 49721e547fd..00000000000
102 --- a/net-firewall/ipt_netflow/files/ipt_netflow-2.5.1-vlan_dev_priv.patch
103 +++ /dev/null
104 @@ -1,32 +0,0 @@
105 -commit 1153f73f038205dc17303e6e6c455bbbb56191f7
106 -Author: ABC <abc@××××××××.com>
107 -Date: Wed Oct 14 15:35:57 2020 +0300
108 -
109 - gen_compat_def: Check for vlan_dev_priv instead of version if
110 -
111 -diff --git a/gen_compat_def b/gen_compat_def
112 -index c0f20f6..3965e94 100755
113 ---- a/gen_compat_def
114 -+++ b/gen_compat_def
115 -@@ -85,6 +85,8 @@ kbuild_test_struct proc_ops linux/proc_fs.h
116 - kbuild_test_struct proc_ops linux/proc_fs.h
117 - # No since v5.1, but present in CentOS-8's 4.18.0-227
118 - kbuild_test_symbol synchronize_sched linux/rcupdate.h
119 -+# Stumbled on 5.9
120 -+kbuild_test_struct vlan_dev_priv linux/if_vlan.h
121 -
122 - echo "// End of compat_def.h"
123 -
124 -diff --git a/ipt_NETFLOW.c b/ipt_NETFLOW.c
125 -index 01055df..6f95166 100644
126 ---- a/ipt_NETFLOW.c
127 -+++ b/ipt_NETFLOW.c
128 -@@ -4874,7 +4874,7 @@ static void parse_l2_header(const struct sk_buff *skb, struct ipt_netflow_tuple
129 - tuple->tag[tag_num++] = htons(vlan_tx_tag_get(skb));
130 - else if (skb->dev && is_vlan_dev(skb->dev)) {
131 - struct net_device *vlan_dev = skb->dev;
132 --# if LINUX_VERSION_CODE >= KERNEL_VERSION(3,2,0)
133 -+# ifdef HAVE_VLAN_DEV_PRIV
134 - struct vlan_dev_priv *vlan = vlan_dev_priv(vlan_dev);
135 -
136 - /* `if` condition is `#if`ed intentionally, and this is
137
138 diff --git a/net-firewall/ipt_netflow/ipt_netflow-2.5.1-r1.ebuild b/net-firewall/ipt_netflow/ipt_netflow-2.5.1-r1.ebuild
139 deleted file mode 100644
140 index bf18a5d0083..00000000000
141 --- a/net-firewall/ipt_netflow/ipt_netflow-2.5.1-r1.ebuild
142 +++ /dev/null
143 @@ -1,111 +0,0 @@
144 -# Copyright 1999-2021 Gentoo Authors
145 -# Distributed under the terms of the GNU General Public License v2
146 -
147 -EAPI=7
148 -
149 -inherit linux-info linux-mod toolchain-funcs
150 -
151 -DESCRIPTION="Netflow iptables module"
152 -HOMEPAGE="
153 - https://sourceforge.net/projects/ipt-netflow
154 - https://github.com/aabc/ipt-netflow
155 -"
156 -SRC_URI="https://github.com/aabc/ipt-netflow/archive/v${PV}.tar.gz -> ${P}.tar.gz"
157 -
158 -LICENSE="GPL-2"
159 -SLOT="0"
160 -KEYWORDS="amd64 x86"
161 -
162 -IUSE="debug natevents snmp"
163 -
164 -RDEPEND="
165 - net-firewall/iptables:0=
166 - snmp? ( net-analyzer/net-snmp )
167 -"
168 -DEPEND="${RDEPEND}"
169 -BDEPEND="
170 - virtual/linux-sources
171 - virtual/pkgconfig
172 -"
173 -
174 -PATCHES=(
175 - "${FILESDIR}/${PN}-2.0-configure.patch" # bug #455984
176 - "${FILESDIR}/${PN}-2.5-gentoo.patch"
177 - "${FILESDIR}/${P}-vlan_dev_priv.patch"
178 -)
179 -
180 -pkg_setup() {
181 - linux-info_pkg_setup
182 -
183 - local CONFIG_CHECK="BRIDGE_NETFILTER ~IP_NF_IPTABLES VLAN_8021Q"
184 - use debug && CONFIG_CHECK+=" ~DEBUG_FS"
185 - if use natevents; then
186 - CONFIG_CHECK+=" NF_CONNTRACK_EVENTS"
187 - if kernel_is lt 5 2; then
188 - CONFIG_CHECK+=" NF_NAT_NEEDED"
189 - else
190 - CONFIG_CHECK+=" NF_NAT"
191 - fi
192 - fi
193 -
194 - BUILD_TARGETS="all"
195 - MODULE_NAMES="ipt_NETFLOW(ipt_netflow:${S})"
196 - IPT_LIB="/usr/$(get_libdir)/xtables"
197 -
198 - linux-mod_pkg_setup
199 -}
200 -
201 -src_unpack() {
202 - default
203 -
204 - mv "${WORKDIR}"/${PN/_/-}-* "${WORKDIR}"/${P} || die
205 -}
206 -
207 -src_prepare() {
208 - default
209 -
210 - # Checking for directory is enough
211 - sed -i -e 's:-s /etc/snmp/snmpd.conf:-d /etc/snmp:' configure || die
212 -}
213 -
214 -do_conf() {
215 - tc-export CC
216 - echo ./configure $*
217 - ./configure $* ${EXTRA_ECONF} || die 'configure failed'
218 -}
219 -
220 -src_configure() {
221 - local IPT_VERSION="$($(tc-getPKG_CONFIG) --modversion xtables)"
222 - # this configure script is not based on autotools
223 - # ipt-src need to be defined, see bug #455984
224 - do_conf \
225 - --disable-dkms \
226 - --enable-aggregation \
227 - --enable-direction \
228 - --enable-macaddress \
229 - --enable-vlan \
230 - --ipt-lib="${IPT_LIB}" \
231 - --ipt-src="/usr/" \
232 - --ipt-ver="${IPT_VERSION}" \
233 - --kdir="${KV_DIR}" \
234 - --kver="${KV_FULL}" \
235 - $(use debug && echo '--enable-debugfs') \
236 - $(use natevents && echo '--enable-natevents') \
237 - $(use snmp && echo '--enable-snmp-rules' || echo '--disable-snmp-agent')
238 -}
239 -
240 -src_compile() {
241 - emake ARCH="$(tc-arch-kernel)" CC="$(tc-getCC)" LD="$(tc-getLD)" OBJDUMP="$(tc-getOBJDUMP)" all
242 -}
243 -
244 -src_install() {
245 - linux-mod_src_install
246 -
247 - use snmp && emake DESTDIR="${D}" SNMPTGSO="/usr/$(get_libdir)/snmp/dlmod/snmp_NETFLOW.so" sinstall
248 -
249 - exeinto "${IPT_LIB}"
250 - doexe libip{,6}t_NETFLOW.so
251 -
252 - doheader ipt_NETFLOW.h
253 - dodoc README*
254 -}
255
256 diff --git a/net-firewall/ipt_netflow/ipt_netflow-2.6.ebuild b/net-firewall/ipt_netflow/ipt_netflow-2.6.ebuild
257 index 97fce443ce9..29ed265510f 100644
258 --- a/net-firewall/ipt_netflow/ipt_netflow-2.6.ebuild
259 +++ b/net-firewall/ipt_netflow/ipt_netflow-2.6.ebuild
260 @@ -14,7 +14,7 @@ SRC_URI="https://github.com/aabc/ipt-netflow/archive/v${PV}.tar.gz -> ${P}.tar.g
261
262 LICENSE="GPL-2"
263 SLOT="0"
264 -KEYWORDS="~amd64 ~x86"
265 +KEYWORDS="amd64 x86"
266
267 IUSE="debug natevents snmp"