mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Fix ndpi-netfilter2 compilation on ARM
This commit is contained in:
parent
643dd1e00d
commit
41314d1a5b
3 changed files with 26 additions and 15 deletions
|
@ -39,8 +39,9 @@ define Package/iptables-mod-ndpi/description
|
||||||
nDPI is a ntop-maintained superset of the popular OpenDPI library
|
nDPI is a ntop-maintained superset of the popular OpenDPI library
|
||||||
endef
|
endef
|
||||||
|
|
||||||
#CONFIGURE_CMD = ./autogen.sh
|
CONFIGURE_CMD=./autogen.sh
|
||||||
#CONFIGURE_ARGS += --with-pic
|
CONFIGURE_ARGS += --with-pic
|
||||||
|
|
||||||
MAKE_PATH:=ndpi-netfilter
|
MAKE_PATH:=ndpi-netfilter
|
||||||
|
|
||||||
MAKE_FLAGS += \
|
MAKE_FLAGS += \
|
||||||
|
@ -48,20 +49,9 @@ MAKE_FLAGS += \
|
||||||
MODULES_DIR="$(TARGET_MODULES_DIR)" \
|
MODULES_DIR="$(TARGET_MODULES_DIR)" \
|
||||||
ARCH="$(LINUX_KARCH)" \
|
ARCH="$(LINUX_KARCH)" \
|
||||||
CROSS_COMPILE="$(TARGET_CROSS)" \
|
CROSS_COMPILE="$(TARGET_CROSS)" \
|
||||||
|
CC="$(TARGET_CC)" \
|
||||||
NDPI_PATH=$(PKG_BUILD_DIR)/ndpi-netfilter
|
NDPI_PATH=$(PKG_BUILD_DIR)/ndpi-netfilter
|
||||||
|
|
||||||
define Build/Configure
|
|
||||||
cd $(PKG_BUILD_DIR) && \
|
|
||||||
CC="" ./autogen.sh \
|
|
||||||
--host="$(GNU_TARGET_NAME)"
|
|
||||||
# --with-pic \
|
|
||||||
# CFLAGS="$(TARGET_CFLAGS)" \
|
|
||||||
# HOST_CFLAGS="$(BUILD_CFLAGS)" \
|
|
||||||
# BUILD_CPPFLAGS="$(TARGET_CPPLAGS)" \
|
|
||||||
# BUILD_CFLAGS="$(TARGET_CFLAGS)" \
|
|
||||||
# BUILD_LDFLAGS="$(TARGET_LDFLAGS)"
|
|
||||||
endef
|
|
||||||
|
|
||||||
define Build/Compile
|
define Build/Compile
|
||||||
(cd $(PKG_BUILD_DIR)/src/lib &&\
|
(cd $(PKG_BUILD_DIR)/src/lib &&\
|
||||||
gcc -g -O2 -fPIC -DPIC -DNDPI_LIB_COMPILATION -I../../src/include/ -I../../src/lib/third_party/include/ ndpi_network_list_compile.c -o ndpi_network_list_compile &&\
|
gcc -g -O2 -fPIC -DPIC -DNDPI_LIB_COMPILATION -I../../src/include/ -I../../src/lib/third_party/include/ ndpi_network_list_compile.c -o ndpi_network_list_compile &&\
|
||||||
|
|
10
ndpi-netfilter2/patches/outline-atomics.patch
Normal file
10
ndpi-netfilter2/patches/outline-atomics.patch
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
--- a/ndpi-netfilter/src/Makefile 2022-08-03 21:27:52.321058402 +0200
|
||||||
|
+++ b/ndpi-netfilter/src/Makefile 2022-08-03 21:28:27.572452447 +0200
|
||||||
|
@@ -5,6 +5,7 @@
|
||||||
|
ccflags-y += -I${src}/${NDPI_SRC}/include -I${src}/${NDPI_SRC}/lib -I${src}/../libre -I${src}/${NDPI_SRC}/lib/third_party/include
|
||||||
|
ccflags-y += -DHAVE_CONFIG_H -DNDPI_LIB_COMPILATION -DOPENDPI_NETFILTER_MODULE -DNDPI_DETECTION_SUPPORT_IPV6 -g
|
||||||
|
ccflags-y += -Wno-declaration-after-statement
|
||||||
|
+ccflags-y += -mno-outline-atomics
|
||||||
|
#ccflags-y += -Wshadow-local
|
||||||
|
# Needed for pahole
|
||||||
|
#ccflags-y += -femit-struct-debug-detailed=any
|
11
ndpi-netfilter2/patches/skbuff-check_fix.patch
Normal file
11
ndpi-netfilter2/patches/skbuff-check_fix.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- a/ndpi-netfilter/src/Makefile 2022-08-03 19:15:39.849630013 +0200
|
||||||
|
+++ b/ndpi-netfilter/src/Makefile 2022-08-03 19:15:57.481336123 +0200
|
||||||
|
@@ -13,7 +13,7 @@
|
||||||
|
KERNEL_DIR := /lib/modules/$(shell uname -r)/build
|
||||||
|
endif
|
||||||
|
|
||||||
|
-ifeq ($(shell grep -qc userid $(KERNEL_DIR)/source/include/linux/skbuff.h),1)
|
||||||
|
+ifeq ($(shell grep -qc userid $(KERNEL_DIR)/include/linux/skbuff.h),1)
|
||||||
|
ccflags-y += -DUSE_HACK_USERID=1
|
||||||
|
endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue