diff options
author | Konstantin Shalygin | 2020-06-18 15:47:57 +0700 |
---|---|---|
committer | Konstantin Shalygin | 2020-06-18 15:47:57 +0700 |
commit | 186a5e606e28710ce17fde2ce78e574b3164906b (patch) | |
tree | 79426ee55499fcb12cc78cba256080d060e67867 | |
parent | 0502e96aac52e653c9cee64964a7eb52901d2d35 (diff) | |
download | aur-186a5e606e28710ce17fde2ce78e574b3164906b.tar.gz |
Added Linux 5.7 comapt patch
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 9 | ||||
-rw-r--r-- | ipt-netflow-2.5_compat.patch | 29 |
3 files changed, 38 insertions, 4 deletions
@@ -1,7 +1,7 @@ pkgbase = ipt_netflow pkgdesc = Netflow as netfilter extension. pkgver = 2.5 - pkgrel = 1 + pkgrel = 2 url = https://github.com/aabc/ipt-netflow arch = any license = GPL @@ -12,7 +12,9 @@ pkgbase = ipt_netflow depends = linux depends = iptables source = https://github.com/aabc/ipt-netflow/archive/v2.5.tar.gz + source = ipt-netflow-2.5_compat.patch sha256sums = d765220c60da6fb569f743ca7f3c4c4873527033a263aef31388a1e770b78490 + sha256sums = 1863da2f404b23a1de7592e6f90375cdf18cf2d9001a2923810f631e16d02882 pkgname = ipt_netflow @@ -4,15 +4,17 @@ _netflow='ipt-netflow' pkgname='ipt_netflow' pkgver='2.5' -pkgrel='1' +pkgrel='2' pkgdesc='Netflow as netfilter extension.' arch=('any') url="https://github.com/aabc/${_netflow}" license=('GPL') depends=('linux' 'iptables') makedepends=('gcc' 'gzip' 'gawk' 'sed') -source=("${url}/archive/v${pkgver}.tar.gz") -sha256sums=('d765220c60da6fb569f743ca7f3c4c4873527033a263aef31388a1e770b78490') +source=("${url}/archive/v${pkgver}.tar.gz" + "${_netflow}-${pkgver}_compat.patch") +sha256sums=('d765220c60da6fb569f743ca7f3c4c4873527033a263aef31388a1e770b78490' + '1863da2f404b23a1de7592e6f90375cdf18cf2d9001a2923810f631e16d02882') # define '-lts' for linux-lts package _linux_custom="" _kdir="`pacman -Ql linux${_linux_custom} | awk '/(\/modules\/)([0-9.-])+-(.*)'${_linux_custom}'\/$/ {print $2}' | head -n1`" @@ -20,6 +22,7 @@ _kver="`pacman -Ql linux${_linux_custom} | gawk 'match($0, /(\/usr\/lib\/modules prepare() { cd "${srcdir}/${_netflow}-${pkgver}" + patch -p1 -i "${srcdir}/${_netflow}-${pkgver}_compat.patch" ./configure \ --disable-snmp-agent \ diff --git a/ipt-netflow-2.5_compat.patch b/ipt-netflow-2.5_compat.patch new file mode 100644 index 000000000000..a54cc7c97d09 --- /dev/null +++ b/ipt-netflow-2.5_compat.patch @@ -0,0 +1,29 @@ +diff -Naupr ipt-netflow-2.5/configure ipt-netflow/configure +--- ipt-netflow-2.5/configure 2020-04-24 14:05:11.000000000 +0700 ++++ ipt-netflow/configure 2020-06-18 15:45:20.866195767 +0700 +@@ -641,6 +641,8 @@ iptables_modules #IPTLIB + snmp_check + dkms_check + ++rm -f compat_def.h ++ + REPLACE="\ + s!@CARGS@!$CARGS!;\ + s!@KVERSION@!$KVERSION!;\ +diff -Naupr ipt-netflow-2.5/ipt_NETFLOW.c ipt-netflow/ipt_NETFLOW.c +--- ipt-netflow-2.5/ipt_NETFLOW.c 2020-04-24 14:05:11.000000000 +0700 ++++ ipt-netflow/ipt_NETFLOW.c 2020-06-18 15:45:20.866195767 +0700 +@@ -3515,11 +3515,13 @@ static inline __u8 hook2dir(const __u8 h + } + #endif + ++#if LINUX_VERSION_CODE < KERNEL_VERSION(5,7,0) + static inline void put_unaligned_be24(u32 val, unsigned char *p) + { + *p++ = val >> 16; + put_unaligned_be16(val, p); + } ++#endif + + static struct { + s64 ms; /* this much abs milliseconds */ |