From 1c7d6584a7811b7785ae5c1e378f14b5ba0971cf Mon Sep 17 00:00:00 2001 From: takeshi_hoshina Date: Mon, 2 Nov 2020 11:07:33 +0900 Subject: basesystem-jj recipes --- .../recipes-support/ntop/ntop/embed-libs.patch | 20 ++++++++++++++++++++ .../fix-missing-return-from-non-void-function.patch | 19 +++++++++++++++++++ .../recipes-support/ntop/ntop_5.0.1.bb | 8 +++++--- 3 files changed, 44 insertions(+), 3 deletions(-) create mode 100644 external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/embed-libs.patch create mode 100644 external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/fix-missing-return-from-non-void-function.patch (limited to 'external/meta-openembedded/meta-networking/recipes-support/ntop') diff --git a/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/embed-libs.patch b/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/embed-libs.patch new file mode 100644 index 00000000..2d1ab737 --- /dev/null +++ b/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/embed-libs.patch @@ -0,0 +1,20 @@ +Use --embed option so that it can return libpython as well + +% ../recipe-sysroot-native/usr/bin/python3-native/python3-config --libs --embed +-lpython3.8 -lcrypt -lpthread -ldl -lutil -lm -lm +[kraj@apollo /mnt/b/yoe/build/tmp/work/cortexa7t2hf-neon-vfpv4-yoe-linux-gnueabi/ntop/5.0.1-r0/ntop-5.0.1] +% ../recipe-sysroot-native/usr/bin/python3-native/python3-config --libs +-lcrypt -lpthread -ldl -lutil -lm -lm + +Signed-off-by: Khem Raj +--- a/configure.in ++++ b/configure.in +@@ -1463,7 +1463,7 @@ dnl> + fi + + if test "x$PYTHON_CONFIG" != "x"; then +- PYTHON_LIBS="`$PYTHON_CONFIG --libs`" ++ PYTHON_LIBS="`$PYTHON_CONFIG --libs --embed`" + if test "x$PYTHON_LIBS" = "x"; then + AC_MSG_RESULT(Python[-devel] support is present but misconfigured) + else diff --git a/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/fix-missing-return-from-non-void-function.patch b/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/fix-missing-return-from-non-void-function.patch new file mode 100644 index 00000000..e627e59a --- /dev/null +++ b/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop/fix-missing-return-from-non-void-function.patch @@ -0,0 +1,19 @@ +Fix following error: + +netflowPlugin.c: In function 'netflowUtilsLoop': +netflowPlugin.c:2144:1: error: no return statement in function returning non-void [-Werror=return-type] + 2144 | } + | ^ + +Return NULL like netflowMainLoop does. + +--- ntop-5.0.1.orig/plugins/netflowPlugin.c 2012-03-09 17:44:17.000000000 +0000 ++++ ntop-5.0.1/plugins/netflowPlugin.c 2019-08-09 10:25:40.878799852 +0000 +@@ -2141,6 +2141,7 @@ + waitCondvar(&myGlobals.device[deviceId].netflowGlobals->ifStatsQueueCondvar); + } + } ++ return(NULL); + } + #endif + diff --git a/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb b/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb index 2a7a7f2c..d835e399 100644 --- a/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb +++ b/external/meta-openembedded/meta-networking/recipes-support/ntop/ntop_5.0.1.bb @@ -18,15 +18,17 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/ntop/ntop-${PV}.tar.gz \ file://use-static-inline.patch \ file://0001-nDPI-Include-sys-types.h.patch \ file://0001-plugins-Makefile.am-fix-for-automake-1.16.1.patch \ + file://fix-missing-return-from-non-void-function.patch \ + file://embed-libs.patch \ " SRC_URI[md5sum] = "01710b6925a8a5ffe1a41b8b512ebd69" SRC_URI[sha256sum] = "7e8e84cb14d2173beaca4d4cb991a14d84a4bef84ec37b2276bc363f45c52ef8" UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/ntop/files/ntop/Stable" -inherit autotools-brokensep useradd pythonnative pkgconfig systemd +inherit autotools-brokensep useradd python3native pkgconfig systemd -DEPENDS = "geoip rrdtool python zlib libpcap gdbm" +DEPENDS = "geoip rrdtool python3 zlib libpcap gdbm" PACKAGECONFIG ??= "openssl snmp plugins" PACKAGECONFIG[openssl] = "--with-ssl, --without-ssl, openssl, openssl" @@ -34,7 +36,7 @@ PACKAGECONFIG[snmp] = "--enable-snmp=yes NETSNMP=${STAGING_BINDIR_CROSS}/net-snm --disable-snmp,net-snmp," PACKAGECONFIG[plugins] = "--enable-plugins=yes, --disable-plugins, ," -EXTRA_OECONF += "ac_cv_file_aclocal_m4=yes ac_cv_file_depcomp=no" +EXTRA_OECONF += "ac_cv_file_aclocal_m4=yes ac_cv_file_depcomp=no PYTHON_CONFIG=python3-config" do_configure() { cp ${STAGING_DATADIR_NATIVE}/aclocal/libtool.m4 libtool.m4.in -- cgit 1.2.3-korg