ethtool: fix ptest execution failure
v2 cover ethtool: fix ptest execution failure
Change since v1:
Remove bash and gawk dependency.
The following changes since commit 894df445fa71a170397c6e0b4960a89ef20a4230:
guile: Update to 2.0.11 version (2014-05-21 19:50:21 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib chonglu/ethtool
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=chonglu/ethtool
Chong Lu (1):
ethtool: fix ptest execution failure
meta/recipes-extended/ethtool/ethtool/run-ptest | 2 +- meta/recipes-extended/ethtool/ethtool_3.14.bb | 16 +++++++++++----- 2 files changed, 12 insertions(+), 6 deletions(-)
Signature · 1 line
1.8.1.2
PATCH v2 1/1 ethtool: fix ptest execution failure
Modify ptest suite to make it enabled on new version.
--- meta/recipes-extended/ethtool/ethtool/run-ptest | 2 +- meta/recipes-extended/ethtool/ethtool_3.14.bb | 16 +++++++++++----- 2 files changed, 12 insertions(+), 6 deletions(-)
meta/recipes-extended/ethtool/ethtool/run-ptest +1 -1
@@ -1,2 +1,2 @@ #!/bin/sh -make -k runtest-TESTS +make -k check-TESTS
meta/recipes-extended/ethtool/ethtool_3.14.bb +11 -5
@@ -20,9 +20,15 @@ do_compile_ptest() { } do_install_ptest () { - cp ${B}/Makefile ${D}${PTEST_PATH} - install ${B}/test-cmdline ${D}${PTEST_PATH} - install ${B}/test-features ${D}${PTEST_PATH} - install ${B}/ethtool ${D}${PTEST_PATH}/ethtool - sed -i 's/^Makefile/_Makefile/' ${D}${PTEST_PATH}/Makefile + for i in Makefile test-cmdline test-features; do \ + install ${B}/$i ${D}${PTEST_PATH}; done + install ${S}/test-driver ${D}${PTEST_PATH} + sed -e 's/^Makefile/_Makefile/' \ + -e 's/^test_cmdline_OBJECTS/#test_cmdline_OBJECTS/' \ + -e 's/^test_features_OBJECTS/#test_features_OBJECTS/' \ + -e 's/^top_srcdir = \(.*\)/top_srcdir = ./' \ + -e '/^all:/,+1d' \ + -e 's/bash/sh/' \ + -e 's/gawk/awk/' \ + -i ${D}${PTEST_PATH}/Makefile }
Signature · 1 line
1.8.1.2
Quoted 15 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Chong Lu
Sent: Tuesday, May 27, 2014 04:44
To: [email protected]
Subject: [OE-core] [PATCH 1/1][V2] ethtool: fix ptest execution failureModify ptest suite to make it enabled on new version.
meta/recipes-extended/ethtool/ethtool/run-ptest line 2
Quoted 3 lines
meta/recipes-extended/ethtool/ethtool/run-ptest +1
-1@@ -1,2 +1,2 @@ #!/bin/sh -make -k runtest-TESTS +make -k check-TESTS
[Tudor Florea] I don't think this is the good approach.
The concept of ptest is to split "check" target testing into building part executed on host machine and then running part on the target. (as per https://wiki.yoctoproject.org/wiki/Ptest#Building_the_test_suite ) My impression is that with this patch we are shifting this approach.
I know that this patch http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta/recipes-devtools/automake/automake/buildtest.patch ) does not produce "buildtest-TESTS" and "runtest-TESTS" targets because automake use now parallel testing by default.
Having said that the real solution for issue like this is another (quite challenging) patch in automake along with the above one to deal with parallel testing hence leave the tested package recipe (e.g. ethtool) untouched.
The short term solution might be to avoid parallel testing for this package.
In yocto, with cross-testing environment we use are not taking (yet) any benefits of the parallel building environment.
I have sent a while back a patch for this package but for some reason it was not merged:
+++ b/meta/recipes-extended/ethtool/ethtool-3.12.1/use_serial_tests.patch @@ -0,0 +1,20 @@
+ptest needs buildtest-TESTS and runtest-TESTS targets.
+serial-tests is required to generate those targets.
+
+Signed-off-by: Tudor Florea <[email protected]>
+Upstream-Status: Inappropriate
+(default automake behavior incompatible with ptest)
+
+diff -ruN a/configure.ac b/configure.ac
+--- a/configure.ac 2013-12-03 10:37:40.773157142 +0100
++++ b/configure.ac 2013-12-03 10:37:21.521992831 +0100
+@@ -2,7 +2,7 @@
+ AC_INIT(ethtool, 3.12.1, [email protected])
+ AC_PREREQ(2.52)
+ AC_CONFIG_SRCDIR([ethtool.c])
+-AM_INIT_AUTOMAKE([gnu])
++AM_INIT_AUTOMAKE([gnu serial-tests])
+ AC_CONFIG_HEADERS([ethtool-config.h])
+
+ AM_MAINTAINER_MODE