Re: [OE-core] [PATCH] lttng-tools: fix ptest

2016-09-27 Thread Nathan Lynch
On 09/27/2016 06:41 AM, Burton, Ross wrote:
> 
> 
> -RDEPENDS_${PN}-ptest += "make perl bash"
> +RDEPENDS_${PN}-ptest += "make perl bash gawk ${PN} babeltrace procps"
> +# babelstats.pl  wants getopt-long
> +RDEPENDS_${PN}-ptest += "perl-module-getopt-long"
> +# getopt itself needs overload
> +RDEPENDS_${PN}-ptest += "perl-module-overload"
> +# overload, in turn, needs overload_ing_
> +RDEPENDS_${PN}-ptest += "perl-module-overloading"
> 
> 
> Why are those perl dependencies here and not in the perl modules themselves?

No good reason. I'll move them to the perl metadata and respin.


-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] lttng-tools: fix ptest

2016-09-27 Thread Burton, Ross
On 22 September 2016 at 22:53, Nathan Lynch  wrote:

> -RDEPENDS_${PN}-ptest += "make perl bash"
> +RDEPENDS_${PN}-ptest += "make perl bash gawk ${PN} babeltrace procps"
> +# babelstats.pl wants getopt-long
> +RDEPENDS_${PN}-ptest += "perl-module-getopt-long"
> +# getopt itself needs overload
> +RDEPENDS_${PN}-ptest += "perl-module-overload"
> +# overload, in turn, needs overload_ing_
> +RDEPENDS_${PN}-ptest += "perl-module-overloading"
>

Why are those perl dependencies here and not in the perl modules themselves?

Ross
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] lttng-tools: fix ptest

2016-09-22 Thread Nathan Lynch
Since the upgrade to 2.8, lttng-tools' test harness silently succeeds
but doesn't actually run the tests.  This is because upstream made
some changes in their test harness:

https://github.com/lttng/lttng-tools/commit/83666813cad3142ceccb929ca9b44d0e9cf53bc8

Updates to address this include:
- drop now-irrelevant patch
- change the ptest-run make target
- remove indiscriminate search/replace commands from do_install_ptest
- copy entire build directory into PTEST_PATH and then remove unneeded files
- use lttng binaries installed on the system for the tests
- add lttng-tools-ptest runtime dependencies
  - lttng-tools itself
  - babeltrace, used by the test harness to process traces
  - perl modules required by babelstats.pl test script
  - procps (for pgrep, pidof)
  - gawk
- remove unnecessary chmod and munging of utils.sh script library
- remove checkpatch from ptest installation tree
- avoid path-munging of libtool artifacts altogether
- use more efficient find+sed patterns to munge Makefiles
- reduce test harness output to conform to ptest rules

On qemux86-64 and qemuarm I get relatively stable results, with
PASS/FAIL varying by +-1 on successive runs.

TOTAL: 2345
PASS:  1735
SKIP:  311
XFAIL: 0
FAIL:  292
XPASS: 0
ERROR: 7

There are some ERRORs worth looking into further but this should be a
useful basis for future work.

Signed-off-by: Nathan Lynch 
---
 meta/recipes-kernel/lttng/lttng-tools/run-ptest|  7 +-
 .../lttng/lttng-tools/runtest-2.4.0.patch  | 27 
 meta/recipes-kernel/lttng/lttng-tools_git.bb   | 80 --
 3 files changed, 63 insertions(+), 51 deletions(-)
 delete mode 100644 meta/recipes-kernel/lttng/lttng-tools/runtest-2.4.0.patch

diff --git a/meta/recipes-kernel/lttng/lttng-tools/run-ptest 
b/meta/recipes-kernel/lttng/lttng-tools/run-ptest
index e758815c77d4..6230063442d6 100755
--- a/meta/recipes-kernel/lttng/lttng-tools/run-ptest
+++ b/meta/recipes-kernel/lttng/lttng-tools/run-ptest
@@ -1,4 +1,5 @@
 #!/bin/sh
-
-make -C tests installcheck
-
+# Without --ignore-exit, the tap harness causes any FAILs within a
+# test plan to raise ERRORs; this is just noise.
+makeargs="LOG_DRIVER_FLAGS=--ignore-exit"
+make -t all >/dev/null 2>&1 && exec make -s $makeargs check 2>/dev/null
diff --git a/meta/recipes-kernel/lttng/lttng-tools/runtest-2.4.0.patch 
b/meta/recipes-kernel/lttng/lttng-tools/runtest-2.4.0.patch
deleted file mode 100644
index 958bce48e0b0..
--- a/meta/recipes-kernel/lttng/lttng-tools/runtest-2.4.0.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-diff --git a/Makefile.am b/Makefile.am
-index 584f59b..c2bcabd 100644
 a/Makefile.am
-+++ b/Makefile.am
-@@ -12,3 +12,9 @@ dist_doc_DATA = LICENSE \
- dist_noinst_DATA = CodingStyle
- 
- EXTRA_DIST = extras/lttng-bash_completion gpl-2.0.txt lgpl-2.1.txt
-+
-+install-ptest:
-+  cp -r $(srcdir)/tests $(DESTDIR)
-+  for m in $$(find $(DESTDIR)/tests -name Makefile); do \
-+  sed -i -e 's|^Makefile:|_Makefile:|' $$m; \
-+done
-diff --git a/tests/run.sh b/tests/run.sh
-index c6c50fd..6455359 100755
 a/tests/run.sh
-+++ b/tests/run.sh
-@@ -19,4 +19,7 @@
- 
- [ -z "$1" ] && echo "Error: No testlist. Please specify a testlist to run." 
&& exit 1
- 
--prove --merge --exec '' - < $1
-+prove --merge -v --exec '' - < $1 | sed \
-+  -e 's|^ok \(.*\)|PASS: \1|' \
-+  -e 's|^not ok \(.*\)|FAIL: \1|' \
-+  | egrep -h 'PASS|FAIL'
diff --git a/meta/recipes-kernel/lttng/lttng-tools_git.bb 
b/meta/recipes-kernel/lttng/lttng-tools_git.bb
index 66269d895713..c715d95457d8 100644
--- a/meta/recipes-kernel/lttng/lttng-tools_git.bb
+++ b/meta/recipes-kernel/lttng/lttng-tools_git.bb
@@ -11,7 +11,13 @@ LIC_FILES_CHKSUM = 
"file://LICENSE;md5=01d7fc4496aacf37d90df90b90b0cac1 \
 
 DEPENDS = "liburcu popt libxml2"
 RDEPENDS_${PN} = "libgcc"
-RDEPENDS_${PN}-ptest += "make perl bash"
+RDEPENDS_${PN}-ptest += "make perl bash gawk ${PN} babeltrace procps"
+# babelstats.pl wants getopt-long
+RDEPENDS_${PN}-ptest += "perl-module-getopt-long"
+# getopt itself needs overload
+RDEPENDS_${PN}-ptest += "perl-module-overload"
+# overload, in turn, needs overload_ing_
+RDEPENDS_${PN}-ptest += "perl-module-overloading"
 
 SRCREV = "d11e0dba0df9024b8613c51e167a379b91e8b20b"
 PV = "2.8.1+git${SRCPV}"
@@ -28,7 +34,6 @@ PACKAGECONFIG[manpages] = "--enable-man-pages, 
--disable-man-pages, asciidoc-nat
 PACKAGECONFIG_remove_libc-musl = "lttng-ust"
 
 SRC_URI = "git://git.lttng.org/lttng-tools.git;branch=stable-2.8 \
-   file://runtest-2.4.0.patch \
file://run-ptest"
 
 S = "${WORKDIR}/git"
@@ -55,27 +60,60 @@ do_configure_prepend () {
 }
 
 do_install_ptest () {
-   chmod +x ${D}${PTEST_PATH}/tests/utils/utils.sh
-   for i in `find ${D}${PTEST_PATH} -perm /u+x -type f`; do
-   sed -e "s:\$TESTDIR.*/src/bin/lttng/\$LTTNG_BIN:\$LTTNG_BIN:g" \
- -e 
"s:\$TESTDIR/../src/bin/lttng-sessiond/\$SESSIOND_BIN:\$SESSIOND_BIN:g" \
-

[OE-core] [PATCH] lttng-tools: Fix ptest installed la files

2016-02-04 Thread Richard Purdie
The ptest .la files are just getting copied into new directories, we need
to relocate them and update the paths within.

Signed-off-by: Richard Purdie 

diff --git a/meta/recipes-kernel/lttng/lttng-tools_git.bb 
b/meta/recipes-kernel/lttng/lttng-tools_git.bb
index e68e7f3..2631203 100644
--- a/meta/recipes-kernel/lttng/lttng-tools_git.bb
+++ b/meta/recipes-kernel/lttng/lttng-tools_git.bb
@@ -69,6 +69,11 @@ do_install_ptest () {
  -i $i
done
 
+   # Update libdir references in copied .la files
+   for i in `find ${D}${PTEST_PATH} -type f -name *.la`; do
+   sed -i -e 's#${S}/tests/#${STAGING_DIR}${PTEST_PATH}#g' $i
+   done
+
sed -e "s:src/bin:bin:g" -e "s:lt-::g" \
-i ${D}${PTEST_PATH}/tests/utils/utils.sh
sed -e "s:ini_config:\.libs\/ini_config:" \


-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core