diff options
author | Anuj Mittal <anuj.mittal@intel.com> | 2018-05-25 14:20:03 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-06-18 10:59:33 +0100 |
commit | d283b0eb909c78b020794ba78e7ec64c3fbee86f (patch) | |
tree | 99fe019cc2860bbf85d012cb6a3f93aa3f812910 /meta/recipes-multimedia/gstreamer/files | |
parent | 2e23543b48921182307065c1fa9e8b9d7fbb3cdc (diff) | |
download | openembedded-core-contrib-d283b0eb909c78b020794ba78e7ec64c3fbee86f.tar.gz |
gstreamer: enable ptest support
Make sure that the tests are packaged and can be executed
when ptest is enabled. Also, remove build host specific references
from Makefile.
Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-multimedia/gstreamer/files')
-rw-r--r-- | meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch | 69 | ||||
-rw-r--r-- | meta/recipes-multimedia/gstreamer/files/run-ptest | 3 |
2 files changed, 72 insertions, 0 deletions
diff --git a/meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch b/meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch new file mode 100644 index 0000000000..d02d869410 --- /dev/null +++ b/meta/recipes-multimedia/gstreamer/files/add-a-target-to-compile-tests.patch @@ -0,0 +1,69 @@ +From d61414bc17cf2df019510c2908048c4cabf5cf09 Mon Sep 17 00:00:00 2001 +From: Anuj Mittal <anuj.mittal@intel.com> +Date: Tue, 27 Feb 2018 09:27:01 +0800 +Subject: [PATCH] add targets for test installation + +Targets to make sure tests can be installed and then run on +the target. + +Upstream-Status: Inappropriate [specific to oe setup] + +Signed-off-by: Anuj Mittal <anuj.mittal@intel.com> + +--- + tests/check/Makefile.am | 27 ++++++++++++++++++++------- + 1 file changed, 20 insertions(+), 7 deletions(-) + +diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am +index 13b916d..a66786d 100644 +--- a/tests/check/Makefile.am ++++ b/tests/check/Makefile.am +@@ -8,11 +8,7 @@ REGISTRY_ENVIRONMENT = \ + GST_REGISTRY=$(CHECK_REGISTRY) + + AM_TESTS_ENVIRONMENT += \ +- GST_STATE_IGNORE_ELEMENTS="$(STATE_IGNORE_ELEMENTS)" \ +- $(REGISTRY_ENVIRONMENT) \ +- GST_PLUGIN_SCANNER_1_0=$(top_builddir)/libs/gst/helpers/gst-plugin-scanner \ +- GST_PLUGIN_SYSTEM_PATH_1_0= \ +- GST_PLUGIN_PATH_1_0=$(top_builddir)/plugins ++ GST_STATE_IGNORE_ELEMENTS="$(STATE_IGNORE_ELEMENTS)" + + plugindir = $(libdir)/gstreamer-@GST_API_VERSION@ + +@@ -178,6 +174,23 @@ noinst_PROGRAMS = + + TESTS = $(check_PROGRAMS) + ++install-ptest: $(TESTS) ++ @$(INSTALL) -d $(DESTDIR) ++ @for dir in `find -maxdepth 1 -type d`; do \ ++ if [ -x $$dir/.libs ]; then \ ++ $(INSTALL) -d $(DESTDIR)/$$dir; \ ++ $(INSTALL_PROGRAM) $$dir/.libs/* $(DESTDIR)/$$dir/; \ ++ fi \ ++ done ++ ++runtests: ++ @for b in $(TESTS); do \ ++ if [ -x $$b ]; then \ ++ $(AM_TESTS_ENVIRONMENT) $(SHELL) test-driver --test-name "$$b" \ ++ --log-file $$b.log --trs-file $$b.trs $$b; \ ++ fi \ ++ done ++ + noinst_HEADERS = \ + gst/capslist.h \ + gst/struct_arm.h \ +@@ -221,9 +234,9 @@ gst_gstprintf_LDADD = \ + $(LDADD) + + elements_fdsrc_CFLAGS=$(GST_OBJ_CFLAGS) $(AM_CFLAGS) \ +- -DTESTFILE=\"$(top_srcdir)/configure.ac\" ++ -DTESTFILE=\"Makefile\" + elements_filesrc_CFLAGS=$(GST_OBJ_CFLAGS) $(AM_CFLAGS) \ +- -DTESTFILE=\"$(top_srcdir)/configure.ac\" ++ -DTESTFILE=\"Makefile\" + + libs_controller_LDADD = \ + $(top_builddir)/libs/gst/controller/libgstcontroller-@GST_API_VERSION@.la \ diff --git a/meta/recipes-multimedia/gstreamer/files/run-ptest b/meta/recipes-multimedia/gstreamer/files/run-ptest new file mode 100644 index 0000000000..473d0b67a7 --- /dev/null +++ b/meta/recipes-multimedia/gstreamer/files/run-ptest @@ -0,0 +1,3 @@ +#!/bin/sh + +make -k runtests |