diff mbox series

[meta-networking] netperf: fix build failure due to autotools.bbclass change

Message ID 20250227191950.295912-1-dmitry.baryshkov@linaro.org
State Accepted
Headers show
Series [meta-networking] netperf: fix build failure due to autotools.bbclass change | expand

Commit Message

Dmitry Baryshkov Feb. 27, 2025, 7:19 p.m. UTC
Recent change to autotools.bbclass broke netperf as it can not now find
proper macros. Remove old workaround and add a proper patch to utilize
ACLOCAL_AMFLAGS option.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
---
 ...0001-Makefile.am-add-ACLOCAL_AMFLAGS.patch | 41 +++++++++++++++++++
 .../recipes-support/netperf/netperf_git.bb    |  7 +---
 2 files changed, 42 insertions(+), 6 deletions(-)
 create mode 100644 meta-networking/recipes-support/netperf/files/0001-Makefile.am-add-ACLOCAL_AMFLAGS.patch
diff mbox series

Patch

diff --git a/meta-networking/recipes-support/netperf/files/0001-Makefile.am-add-ACLOCAL_AMFLAGS.patch b/meta-networking/recipes-support/netperf/files/0001-Makefile.am-add-ACLOCAL_AMFLAGS.patch
new file mode 100644
index 000000000000..6aba8a4f797f
--- /dev/null
+++ b/meta-networking/recipes-support/netperf/files/0001-Makefile.am-add-ACLOCAL_AMFLAGS.patch
@@ -0,0 +1,41 @@ 
+From 333e92a2d804420748447e043c6a04affc600e20 Mon Sep 17 00:00:00 2001
+From: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
+Date: Thu, 27 Feb 2025 21:09:04 +0200
+Subject: [PATCH] Makefile.am: add ACLOCAL_AMFLAGS
+
+Add ACLOCAL_AMFLAGS, a standard way to tell aclocal where to find
+necessary macros.
+
+Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
+Upstream-Status: Submitted [https://github.com/HewlettPackard/netperf/pull/84]
+---
+ Makefile.am | 1 +
+ autogen.sh  | 2 +-
+ 2 files changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 2cb9c24f2eec..dc266e34c997 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -19,6 +19,7 @@
+ # OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+ # USE OR OTHER DEALINGS IN THE SOFTWARE.
+ 
++ACLOCAL_AMFLAGS = -I src/missing/m4
+ AUTOMAKE_OPTIONS = dist-bzip2 dist-zip
+ SUBDIRS = src doc
+ EXTRA_DIST = README.* Release_Notes inet_ntop.c autogen.sh m4
+diff --git a/autogen.sh b/autogen.sh
+index bc8389c24171..1156f42edae6 100755
+--- a/autogen.sh
++++ b/autogen.sh
+@@ -1,5 +1,5 @@
+ #! /bin/sh
+ 
+-aclocal -I src/missing/m4 \
++aclocal \
+ && automake  --add-missing \
+ && autoconf && autoheader
+-- 
+2.39.5
+
diff --git a/meta-networking/recipes-support/netperf/netperf_git.bb b/meta-networking/recipes-support/netperf/netperf_git.bb
index 579a04b86fa0..fa73548d836d 100644
--- a/meta-networking/recipes-support/netperf/netperf_git.bb
+++ b/meta-networking/recipes-support/netperf/netperf_git.bb
@@ -15,6 +15,7 @@  SRC_URI = "git://github.com/HewlettPackard/netperf.git;branch=master;protocol=ht
            file://0001-netlib.c-Move-including-sched.h-out-og-function.patch \
            file://0001-nettest_omni-Remove-duplicate-variable-definitions.patch \
            file://netserver_permissions.patch \
+           file://0001-Makefile.am-add-ACLOCAL_AMFLAGS.patch \
            "
 
 SRCREV = "3bc455b23f901dae377ca0a558e1e32aa56b31c4"
@@ -35,12 +36,6 @@  PACKAGECONFIG[sctp] = "--enable-sctp,--disable-sctp,lksctp-tools,"
 PACKAGECONFIG[intervals] = "--enable-intervals,--disable-intervals,,"
 PACKAGECONFIG[histogram] = "--enable-histogram,--disable-histogram,,"
 
-# autotools.bbclass attends to include m4 files with path depth <= 2 by
-# "find ${S} -maxdepth 2 -name \*.m4", so move m4 files from m4/m4.
-do_configure:prepend() {
-    test -d ${S}/m4/m4 && mv -f ${S}/m4/m4 ${S}/m4-files
-}
-
 do_install() {
     sed -e 's#/usr/sbin/#${sbindir}/#g' -i ${UNPACKDIR}/init
     install -d ${D}${sbindir} ${D}${bindir} ${D}${sysconfdir}/init.d ${D}${systemd_system_unitdir}