diff options
Diffstat (limited to 'meta-networking/recipes-support/ntopng')
10 files changed, 181 insertions, 142 deletions
diff --git a/meta-networking/recipes-support/ntopng/files/0001-Makefile.in-don-t-use-the-internal-lua.patch b/meta-networking/recipes-support/ntopng/files/0001-Makefile.in-don-t-use-the-internal-lua.patch index 46724558c4..bb5bcfbd63 100644 --- a/meta-networking/recipes-support/ntopng/files/0001-Makefile.in-don-t-use-the-internal-lua.patch +++ b/meta-networking/recipes-support/ntopng/files/0001-Makefile.in-don-t-use-the-internal-lua.patch @@ -1,4 +1,4 @@ -From 65c15247d268566b79e4595b8e734b7e40679d75 Mon Sep 17 00:00:00 2001 +From 52953ab99c727a19e88243dda2702d6814f7974d Mon Sep 17 00:00:00 2001 From: Mingli Yu <mingli.yu@windriver.com> Date: Wed, 4 Nov 2020 08:55:10 +0000 Subject: [PATCH] Makefile.in: don't use the internal lua @@ -15,18 +15,18 @@ Signed-off-by: Mingli Yu <mingli.yu@windriver.com> 1 file changed, 2 deletions(-) diff --git a/Makefile.in b/Makefile.in -index 143535746..fc06a5341 100755 +index d737e74..a611b16 100755 --- a/Makefile.in +++ b/Makefile.in -@@ -40,7 +40,6 @@ endif - - LUA_HOME=${PWD}/third-party/lua-5.3.5 +@@ -36,7 +36,6 @@ MONGOOSE_INC=-I$(MONGOOSE_HOME) + LUA_PLATFORM=generic + LUA_HOME=${PWD}/third-party/lua-5.4.3 LUA_INC=-I$(LUA_HOME)/src -LUA_LIB=$(LUA_HOME)/src/liblua.a - ###### - LIBRRDTOOL_HOME=${PWD}/third-party/rrdtool-1.4.8 -@@ -118,7 +117,6 @@ RPM_PKG = $(TARGET)-$(NTOPNG_VERSION)-@REVISION@.$(PLATFORM).rpm + ifeq ($(OS),Linux) + LUA_PLATFORM=linux +@@ -102,7 +101,6 @@ RPM_PKG = $(TARGET)-$(NTOPNG_VERSION)-@REVISION@.$(PLATFORM).rpm RPM_DATA_PKG = $(TARGET)-data-$(NTOPNG_VERSION)-@REVISION@.noarch.rpm ###### @@ -35,5 +35,5 @@ index 143535746..fc06a5341 100755 ifneq ($(HAS_ZEROMQ), 0) LIB_TARGETS += $(ZEROMQ_LIB) -- -2.26.2 +2.25.1 diff --git a/meta-networking/recipes-support/ntopng/files/0001-autogen.sh-not-generate-configure.patch b/meta-networking/recipes-support/ntopng/files/0001-autogen.sh-not-generate-configure.patch index ffc6ec1efc..d5c7f5f1cc 100644 --- a/meta-networking/recipes-support/ntopng/files/0001-autogen.sh-not-generate-configure.patch +++ b/meta-networking/recipes-support/ntopng/files/0001-autogen.sh-not-generate-configure.patch @@ -8,26 +8,28 @@ Only use autogen.sh to generate configure.ac. Upstream-Status: Inappropriate [embedded specific] Signed-off-by: Mingli Yu <mingli.yu@windriver.com> + +refresh patch to 4.0 +Signed-off-by: Changqing Li <changqing.li@windriver.com> --- - autogen.sh | 8 -------- - 1 file changed, 8 deletions(-) + autogen.sh | 7 ------- + 1 file changed, 7 deletions(-) diff --git a/autogen.sh b/autogen.sh -index df734ce9..d7bbf8cb 100755 +index 0aa7507..36e0423 100755 --- a/autogen.sh +++ b/autogen.sh -@@ -52,11 +52,3 @@ cat configure.seed | sed \ - -e "s/@NDPI_VERSION_SHORT@/$NDPI_VERSION_SHORT/g" \ - -e "s/@FUZZY@/$FUZZY/g" \ - > configure.ac +@@ -33,10 +33,3 @@ if test -z $PKG_CONFIG; then + echo "pkg-config is missing: please install it (apt-get install pkg-config) and try again" + exit + fi - -autoreconf -ivf --cat configure | sed "s/#define PACKAGE/#define NDPI_PACKAGE/g" | sed "s/#define VERSION/#define NDPI_VERSION/g" > configure.tmp --cat configure.tmp > configure - +-echo "./configure $@" -chmod +x configure -./configure $@ - -- -2.17.1 +2.25.1 diff --git a/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-Allow-dynamic-linking-against-ndpi-3.patch b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-Allow-dynamic-linking-against-ndpi-3.patch new file mode 100644 index 0000000000..c645110f22 --- /dev/null +++ b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-Allow-dynamic-linking-against-ndpi-3.patch @@ -0,0 +1,39 @@ +From a913b85f720f41bf7e5819c0dc4acc252467a8a4 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Tue, 15 Feb 2022 14:25:07 -0800 +Subject: [PATCH] configure.ac.in: Allow dynamic linking against ndpi 3.0 + +Linking statically is problematic since NDPI_LIBS is '-lndpi -lm' +and when we use -Bstatic it also brings in -lm to use libm.a and on some +architectures ( x86 ) which this does not work and results in missing symbols + +Fixes +ipe-sysroot/usr/lib/libm.a(e_logf.o): in function `logf_ifunc_selector': +/usr/src/debug/glibc/2.35-r0/git/math/../sysdeps/i386/i686/multiarch/ifunc-sse2.h:30: undefined reference to `_dl_x86_cpu_features' + +Upstream-Status: Submitted [https://github.com/ntop/ntopng/pull/6318] +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + configure.ac.in | 6 ++---- + 1 file changed, 2 insertions(+), 4 deletions(-) + +diff --git a/configure.ac.in b/configure.ac.in +index 7f4c0f893..c3299fda2 100644 +--- a/configure.ac.in ++++ b/configure.ac.in +@@ -193,10 +193,8 @@ if test -d /usr/local/include/ndpi ; then : + fi + + PKG_CHECK_MODULES([NDPI], [libndpi >= 2.0], [ +- NDPI_INC=`echo $NDPI_CFLAGS | sed -e "s/[ ]*$//"` +- # Use static libndpi library as building against the dynamic library fails +- NDPI_LIB="-Wl,-Bstatic $NDPI_LIBS -Wl,-Bdynamic" +- #NDPI_LIB="$NDPI_LIBS" ++ NDPI_INC="$NDPI_CFLAGS" ++ NDPI_LIB="$NDPI_LIBS" + NDPI_LIB_DEP= + ], [ + AC_MSG_CHECKING(for nDPI source) +-- +2.35.1 + diff --git a/meta-networking/recipes-support/ntopng/files/0001-configure.seed-fix-configure-error.patch b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-fix-configure-error.patch index dffab24ca2..d4908e3227 100644 --- a/meta-networking/recipes-support/ntopng/files/0001-configure.seed-fix-configure-error.patch +++ b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-fix-configure-error.patch @@ -1,7 +1,7 @@ From 29797dd037009d38e4976249ed21b2076240751e Mon Sep 17 00:00:00 2001 From: Mingli Yu <mingli.yu@windriver.com> Date: Wed, 4 Nov 2020 04:36:46 +0000 -Subject: [PATCH] configure.seed: fix configure error +Subject: [PATCH] configure.ac.in: fix configure error fix the below error: configure: error: cannot run test program while cross compiling @@ -10,13 +10,13 @@ Upstream-Status: Inappropriate [embedded specific] Signed-off-by: Mingli Yu <mingli.yu@windriver.com> --- - configure.seed | 13 +------------ + configure.ac.in | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) -diff --git a/configure.seed b/configure.seed +diff --git a/configure.ac.in b/configure.ac.in index a321f9bbf..03f9a31b0 100644 ---- a/configure.seed -+++ b/configure.seed +--- a/configure.ac.in ++++ b/configure.ac.in @@ -642,18 +642,7 @@ if test x$radcli = xtrue; then fi fi diff --git a/meta-networking/recipes-support/ntopng/files/0001-configure.seed-fix-host-contamination.patch b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-fix-host-contamination.patch index a5ac59fb32..5e1440b3d6 100644 --- a/meta-networking/recipes-support/ntopng/files/0001-configure.seed-fix-host-contamination.patch +++ b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-fix-host-contamination.patch @@ -1,7 +1,7 @@ -From 81e3512718f80965c26ccb1f9d694c91b121fea0 Mon Sep 17 00:00:00 2001 +From d9458227ddb4bbb8c63c607202a6854886d66090 Mon Sep 17 00:00:00 2001 From: Mingli Yu <mingli.yu@windriver.com> Date: Wed, 4 Nov 2020 06:28:28 +0000 -Subject: [PATCH] configure.seed: fix host contamination +Subject: [PATCH] configure.ac.in: fix host contamination Fix below error: This autoconf log indicates errors, it looked at host include and/or @@ -11,14 +11,14 @@ Upstream-Status: Inappropriate [OE specific] Signed-off-by: Mingli Yu <mingli.yu@windriver.com> --- - configure.seed | 47 +++++------------------------------------------ - 1 file changed, 5 insertions(+), 42 deletions(-) + configure.ac.in | 43 +++---------------------------------------- + 1 file changed, 3 insertions(+), 40 deletions(-) -diff --git a/configure.seed b/configure.seed -index 03f9a31b0..58aebb5b8 100644 ---- a/configure.seed -+++ b/configure.seed -@@ -79,31 +79,6 @@ fi +diff --git a/configure.ac.in b/configure.ac.in +index 1d6380c..beffc6c 100644 +--- a/configure.ac.in ++++ b/configure.ac.in +@@ -167,31 +167,6 @@ fi # REVISION=`git log --pretty=oneline | wc -l` @@ -28,7 +28,7 @@ index 03f9a31b0..58aebb5b8 100644 -fi - -if test -d "/usr/local/lib"; then -- LDFLAGS="${LDFLAGS} -L/usr/local/lib" +- LIBS="${LIBS} -L/usr/local/lib" -fi - -if test -d /opt/local/include; then : @@ -37,7 +37,7 @@ index 03f9a31b0..58aebb5b8 100644 -fi - -if test -d /opt/local/lib; then : -- LDFLAGS="${LDFLAGS} -L/opt/local/lib" +- LIBS="${LIBS} -L/opt/local/lib" -fi - -if [ test -f /usr/bin/lsb_release ]; then @@ -50,7 +50,7 @@ index 03f9a31b0..58aebb5b8 100644 SHORT_MACHINE=`uname -m | cut -b1-3` GIT_RELEASE="@GIT_RELEASE@" -@@ -214,23 +189,11 @@ dnl> fi +@@ -300,23 +275,11 @@ fi pkg-config --exists libssl if test "$?" -ne 1; then AC_DEFINE_UNQUOTED(NO_SSL_DL, 1, [has openssl]) @@ -62,7 +62,7 @@ index 03f9a31b0..58aebb5b8 100644 - if test -d "/usr/local/opt/openssl/lib"; then - AC_DEFINE_UNQUOTED(NO_SSL_DL, 1, [has openssl]) - SSL_INC="-I/usr/local/opt/openssl/include" -- SSL_LIB="-L/usr/local/opt/openssl/lib -lssl" +- SSL_LIB="-L/usr/local/opt/openssl/lib -lssl -lcrypto" - dnl Workaround for FreeBSD - elif test -f "/usr/lib/libssl.so"; then - AC_DEFINE_UNQUOTED(NO_SSL_DL, 1, [has openssl]) @@ -76,7 +76,7 @@ index 03f9a31b0..58aebb5b8 100644 + exit -1 fi - AC_CHECK_LIB([gcrypt], [gcry_cipher_checktag], [LDFLAGS="${LDFLAGS} -lgcrypt"]) + AC_CHECK_LIB([gcrypt], [gcry_cipher_checktag], [LIBS="${LIBS} -lgcrypt"]) -- -2.26.2 +2.25.1 diff --git a/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-not-check-clang-on-host.patch b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-not-check-clang-on-host.patch new file mode 100644 index 0000000000..ffb106723c --- /dev/null +++ b/meta-networking/recipes-support/ntopng/files/0001-configure.ac.in-not-check-clang-on-host.patch @@ -0,0 +1,44 @@ +From 5867be19e53a3cc09730b83282c83bdd26147cc3 Mon Sep 17 00:00:00 2001 +From: Mingli Yu <mingli.yu@windriver.com> +Date: Mon, 9 Nov 2020 04:05:25 +0000 +Subject: [PATCH] configure.ac.in: not check clang on host + +Don't check clang on host to avoid host contamination. + +Upstream-Status: Inappropriate [OE specific] + +Signed-off-by: Mingli Yu <mingli.yu@windriver.com> +--- + configure.ac.in | 16 ---------------- + 1 file changed, 16 deletions(-) + +diff --git a/configure.ac.in b/configure.ac.in +index 55bd49678..94bc0bc48 100644 +--- a/configure.ac.in ++++ b/configure.ac.in +@@ -90,22 +90,6 @@ if test $SYSTEM = "FreeBSD" || test $SYSTEM = "Darwin"; then + CFLAGS="-fno-color-diagnostics $CFLAGS" + fi + fi +-else +- if test $SYSTEM = "Linux"; then +- if [ test -f /usr/bin/clang++ ]; then +- CC=clang +- CXX=clang++ +- AC_MSG_RESULT(Using clang++ compiler) +- fi +- +- if [ test -f /etc/redhat-release ]; then +- OS=`cat /etc/redhat-release` +- else +- if [ test -f /usr/bin/lsb_release ]; then +- OS=`/usr/bin/lsb_release -d|cut -d ':' -f 2` +- fi +- fi +- fi + fi + + dnl> Remove spaces +-- +2.17.1 + diff --git a/meta-networking/recipes-support/ntopng/files/0001-configure.seed-not-check-clang-on-host.patch b/meta-networking/recipes-support/ntopng/files/0001-configure.seed-not-check-clang-on-host.patch deleted file mode 100644 index 95d1f99481..0000000000 --- a/meta-networking/recipes-support/ntopng/files/0001-configure.seed-not-check-clang-on-host.patch +++ /dev/null @@ -1,47 +0,0 @@ -From eead0c589b71d4256bf9f16492164786b0ee07e4 Mon Sep 17 00:00:00 2001 -From: Mingli Yu <mingli.yu@windriver.com> -Date: Mon, 9 Nov 2020 04:05:25 +0000 -Subject: [PATCH] configure.seed: not check clang on host - -Don't check clang on host to avoid host contamination. - -Upstream-Status: Inappropriate [OE specific] - -Signed-off-by: Mingli Yu <mingli.yu@windriver.com> ---- - configure.seed | 19 ------------------- - 1 file changed, 19 deletions(-) - -diff --git a/configure.seed b/configure.seed -index d0335b599..cb97adca2 100644 ---- a/configure.seed -+++ b/configure.seed -@@ -509,25 +509,6 @@ if test $SYSTEM = "Darwin"; then - CFLAGS="-fno-color-diagnostics $CFLAGS" - fi - fi --else -- if test $SYSTEM = "Linux"; then -- if [ test -f /usr/bin/clang++ ]; then -- CC=clang -- CXX=clang++ -- AC_MSG_RESULT(Using clang++ compiler) -- fi -- -- if [ test -f /etc/redhat-release ]; then -- if [ test -f /usr/bin/lsb_release ]; then -- dnl> CentOS 7 -- CENTOS_N2N_DEP=", n2n" -- fi -- else -- if [ test -f /usr/bin/lsb_release ]; then -- OS=`/usr/bin/lsb_release -d|cut -d ':' -f 2` -- fi -- fi -- fi - fi - - dnl> Remove spaces --- -2.26.2 - diff --git a/meta-networking/recipes-support/ntopng/ndpi_3.4.bb b/meta-networking/recipes-support/ntopng/ndpi_4.2.bb index 22e4d8e9ae..13c3398c2b 100644 --- a/meta-networking/recipes-support/ntopng/ndpi_3.4.bb +++ b/meta-networking/recipes-support/ntopng/ndpi_4.2.bb @@ -3,15 +3,15 @@ DESCRIPTION = "nDPI is an open source LGPLv3 library for deep-packet \ inspection. Based on OpenDPI it includes ntop extensions" SECTION = "libdevel" -DEPENDS = "libpcap" -RDEPENDS_${PN} += " libpcap" -LICENSE = "GPLv3" +DEPENDS = "libpcap json-c" +RDEPENDS:${PN} += " libpcap" +LICENSE = "GPL-3.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=b52f2d57d10c4f7ee67a7eb9615d5d24" -SRCREV = "64929a75e0a7a60d864bd25a9fd97fdf9ac892a2" -SRC_URI = "git://github.com/ntop/nDPI.git;branch=3.4-stable \ +SRCREV = "8b5c6af71b562549f8416b31803daae223e09f46" +SRC_URI = "git://github.com/ntop/nDPI.git;branch=4.2-stable;protocol=https \ file://0001-autogen.sh-not-generate-configure.patch \ -" + " S = "${WORKDIR}/git" @@ -19,7 +19,7 @@ inherit autotools-brokensep pkgconfig CPPFLAGS += "${SELECTED_OPTIMIZATION}" -do_configure_prepend() { +do_configure:prepend() { ${S}/autogen.sh } diff --git a/meta-networking/recipes-support/ntopng/ntopng_4.2.bb b/meta-networking/recipes-support/ntopng/ntopng_4.2.bb deleted file mode 100644 index 5961866515..0000000000 --- a/meta-networking/recipes-support/ntopng/ntopng_4.2.bb +++ /dev/null @@ -1,49 +0,0 @@ -SUMMARY = "Web-based Traffic and Security Network Traffic Monitoring" -DESCRIPTION = "ntopng is a web-based network traffic monitoring application \ -released under GPLv3. It is the new incarnation of the original \ -ntop written in 1998, and now revamped in terms of performance, \ -usability, and features." - -SECTION = "console/network" - -DEPENDS = "curl libmaxminddb libpcap lua mariadb ndpi json-c rrdtool zeromq" -RDEPENDS_${PN} = "bash redis" -LICENSE = "GPLv3" -LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504" - -SRCREV = "5e649a2d1130b4a3ab0c5bb673d615172cc0bdbb" -SRC_URI = "git://github.com/ntop/ntopng.git;protocol=git;branch=4.2-stable \ - file://0001-configure.seed-fix-configure-error.patch \ - file://0001-configure.seed-fix-host-contamination.patch \ - file://0001-Makefile.in-don-t-use-the-internal-lua.patch \ - file://0001-autogen.sh-generate-configure.ac-only.patch \ - file://0001-configure.seed-not-check-clang-on-host.patch \ - file://ntopng.service \ -" - -S = "${WORKDIR}/git" - -# don't use the lua under thirdparty as it supports cross compiling badly -export LUA_LIB = "${STAGING_LIBDIR}/liblua.a" - -LDFLAGS_append_mipsarch = " -latomic" -LDFLAGS_append_powerpc = " -latomic" -LDFLAGS_append_riscv32 = " -latomic" -inherit autotools-brokensep gettext systemd - -do_install_append() { - install -d ${D}${systemd_unitdir}/system/ - install -m 0644 ${WORKDIR}/ntopng.service ${D}${systemd_unitdir}/system -} - -FILES_${PN} += "\ - ${systemd_unitdir}/system/ntopng.service" - -FILES_${PN}-doc += "\ - /usr/man/man8/ntopng.8" - -do_configure_prepend() { - ${S}/autogen.sh -} - -SYSTEMD_SERVICE_${PN} = "ntopng.service" diff --git a/meta-networking/recipes-support/ntopng/ntopng_5.2.1.bb b/meta-networking/recipes-support/ntopng/ntopng_5.2.1.bb new file mode 100644 index 0000000000..a9ace9b412 --- /dev/null +++ b/meta-networking/recipes-support/ntopng/ntopng_5.2.1.bb @@ -0,0 +1,50 @@ +SUMMARY = "Web-based Traffic and Security Network Traffic Monitoring" +DESCRIPTION = "ntopng is a web-based network traffic monitoring application \ +released under GPLv3. It is the new incarnation of the original \ +ntop written in 1998, and now revamped in terms of performance, \ +usability, and features." + +SECTION = "console/network" + +DEPENDS = "curl hiredis libmaxminddb libpcap lua mariadb ndpi json-c rrdtool zeromq" +RDEPENDS:${PN} = "bash redis" +LICENSE = "GPL-3.0-only" +LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504" + +SRCREV = "d3ce78948e8d81dc1e2c5298ce556f9f2247aac1" +SRC_URI = "git://github.com/ntop/ntopng.git;protocol=https;branch=5.2-stable \ + file://0001-configure.ac.in-fix-configure-error.patch \ + file://0001-configure.ac.in-fix-host-contamination.patch \ + file://0001-Makefile.in-don-t-use-the-internal-lua.patch \ + file://0001-autogen.sh-generate-configure.ac-only.patch \ + file://0001-configure.ac.in-not-check-clang-on-host.patch \ + file://0001-configure.ac.in-Allow-dynamic-linking-against-ndpi-3.patch \ + file://ntopng.service \ + " + +S = "${WORKDIR}/git" + +# don't use the lua under thirdparty as it supports cross compiling badly +export LUA_LIB = "${STAGING_LIBDIR}/liblua.a" + +LDFLAGS:append:mipsarch = " -latomic" +LDFLAGS:append:powerpc = " -latomic" +LDFLAGS:append:riscv32 = " -latomic" +inherit autotools-brokensep gettext pkgconfig systemd + +do_install:append() { + install -d ${D}${systemd_unitdir}/system/ + install -m 0644 ${UNPACKDIR}/ntopng.service ${D}${systemd_unitdir}/system +} + +FILES:${PN} += "\ + ${systemd_unitdir}/system/ntopng.service" + +FILES:${PN}-doc += "\ + /usr/man/man8/ntopng.8" + +do_configure:prepend() { + ${S}/autogen.sh +} + +SYSTEMD_SERVICE:${PN} = "ntopng.service" |