summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYuqing Zhu <carol.zhu@nxp.com>2018-06-06 11:44:18 +0800
committerOtavio Salvador <otavio@ossystems.com.br>2018-06-06 11:24:42 -0300
commit611ef6c6480168bebe7999b25c8b80d92b001831 (patch)
tree0b25c9cda22f8a4981a344519f032dab07f69c36
parentaa7f4c93d8e489aa0b582dfb163b24a7970a0bed (diff)
downloadmeta-freescale-611ef6c6480168bebe7999b25c8b80d92b001831.tar.gz
gstreamer1.0: Use i.MX fork of GST for customizations
Create the new gstreamer recipe with i.mx specific version. Merge inc/bb. Switch to use i.MX fork of GST. All patches are put into the fork. Signed-off-by: Yuqing Zhu <carol.zhu@nxp.com> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> (cherry picked from commit 67065b32b2434eb8c5eb7a9911176a3b3b410c30)
-rw-r--r--recipes-multimedia/gstreamer/files/0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch35
-rw-r--r--recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch42
-rw-r--r--recipes-multimedia/gstreamer/files/gtk-doc-tweaks.patch47
-rw-r--r--recipes-multimedia/gstreamer/gstreamer1.0_1.12.imx.bb74
4 files changed, 198 insertions, 0 deletions
diff --git a/recipes-multimedia/gstreamer/files/0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch b/recipes-multimedia/gstreamer/files/0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch
new file mode 100644
index 00000000..67a872cd
--- /dev/null
+++ b/recipes-multimedia/gstreamer/files/0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch
@@ -0,0 +1,35 @@
1From a1d7c582392c8bc87fa9411af77b20e011944357 Mon Sep 17 00:00:00 2001
2From: Alexander Kanavin <alex.kanavin@gmail.com>
3Date: Thu, 25 Jan 2018 17:55:02 +0200
4Subject: [PATCH] gst/gstpluginloader.c: when env var is set do not fall
5 through to system plugin scanner
6
7If we set a custom GST_PLUGIN_SCANNER env var, then we probably want to use that and only that.
8
9Falling through to the one installed on the system is problamatic in cross-compilation
10environemnts, regardless of whether one pointed to by the env var succeeded or failed.
11
12Upstream-Status: Pending
13Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
14---
15 gst/gstpluginloader.c | 4 +---
16 1 file changed, 1 insertion(+), 3 deletions(-)
17
18diff --git a/gst/gstpluginloader.c b/gst/gstpluginloader.c
19index 430829d..3a75731 100644
20--- a/gst/gstpluginloader.c
21+++ b/gst/gstpluginloader.c
22@@ -471,9 +471,7 @@ gst_plugin_loader_spawn (GstPluginLoader * loader)
23 helper_bin = g_strdup (env);
24 res = gst_plugin_loader_try_helper (loader, helper_bin);
25 g_free (helper_bin);
26- }
27-
28- if (!res) {
29+ } else {
30 GST_LOG ("Trying installed plugin scanner");
31
32 #ifdef G_OS_WIN32
33--
342.15.1
35
diff --git a/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch b/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
new file mode 100644
index 00000000..2cab87f9
--- /dev/null
+++ b/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
@@ -0,0 +1,42 @@
1From 90916f96262fa7b27a0a99788c69f9fd6df11000 Mon Sep 17 00:00:00 2001
2From: Alexander Kanavin <alex.kanavin@gmail.com>
3Date: Tue, 24 Nov 2015 16:46:27 +0200
4Subject: [PATCH] introspection.m4: prefix pkgconfig paths with
5 PKG_CONFIG_SYSROOT_DIR
6
7We can't use our tweaked introspection.m4 from gobject-introspection tarball
8because gstreamer also defines INTROSPECTION_INIT in its introspection.m4, which
9is later supplied to g-ir-scanner.
10
11Upstream-Status: Pending [review on oe-core list]
12Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
13---
14 common/m4/introspection.m4 | 12 ++++++------
15 1 file changed, 6 insertions(+), 6 deletions(-)
16
17diff --git a/common/m4/introspection.m4 b/common/m4/introspection.m4
18index 162be57..217a6ae 100644
19--- a/common/m4/introspection.m4
20+++ b/common/m4/introspection.m4
21@@ -54,14 +54,14 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
22 INTROSPECTION_GIRDIR=
23 INTROSPECTION_TYPELIBDIR=
24 if test "x$found_introspection" = "xyes"; then
25- INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
26- INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
27- INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
28+ INTROSPECTION_SCANNER=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
29+ INTROSPECTION_COMPILER=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
30+ INTROSPECTION_GENERATE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
31 INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
32 INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
33 INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
34 INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
35- INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
36+ INTROSPECTION_MAKEFILE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
37 INTROSPECTION_INIT="extern void gst_init(gint*,gchar**); gst_init(NULL,NULL);"
38 fi
39 AC_SUBST(INTROSPECTION_SCANNER)
40--
412.6.2
42
diff --git a/recipes-multimedia/gstreamer/files/gtk-doc-tweaks.patch b/recipes-multimedia/gstreamer/files/gtk-doc-tweaks.patch
new file mode 100644
index 00000000..d86c78d7
--- /dev/null
+++ b/recipes-multimedia/gstreamer/files/gtk-doc-tweaks.patch
@@ -0,0 +1,47 @@
1From 7018ca1c4bf26c8317e7fcd2e7e4e648195f42ca Mon Sep 17 00:00:00 2001
2From: Ross Burton <ross.burton@intel.com>
3Date: Wed, 20 Dec 2017 13:03:03 +0000
4Subject: [PATCH] gstreamer: use a patch instead of sed to fix gtk-doc
5
6Patch the gtk-doc makefiles so that the qemu wrapper is used to run transient
7binaries instead of libtool wrapper or running them directly.
8
9Also substitute a bogus plugin scanner, as trying to run the real one is causing
10issues during build on x86_64.
11
12Upstream-Status: Inappropriate
13Signed-off-by: Ross Burton <ross.burton@intel.com>
14
15---
16 common/gtk-doc.mak | 5 +++--
17 1 file changed, 3 insertions(+), 2 deletions(-)
18
19diff --git a/common/gtk-doc.mak b/common/gtk-doc.mak
20index 3f83491..e5cb0d1 100644
21--- a/common/gtk-doc.mak
22+++ b/common/gtk-doc.mak
23@@ -6,11 +6,11 @@
24 if GTK_DOC_USE_LIBTOOL
25 GTKDOC_CC = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(INCLUDES) $(GTKDOC_DEPS_CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
26 GTKDOC_LD = $(LIBTOOL) --tag=CC --mode=link $(CC) $(GTKDOC_DEPS_LIBS) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS)
27-GTKDOC_RUN = $(LIBTOOL) --mode=execute
28+GTKDOC_RUN = $(top_builddir)/gtkdoc-qemuwrapper
29 else
30 GTKDOC_CC = $(CC) $(INCLUDES) $(GTKDOC_DEPS_CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
31 GTKDOC_LD = $(CC) $(GTKDOC_DEPS_LIBS) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS)
32-GTKDOC_RUN =
33+GTKDOC_RUN = $(top_builddir)/gtkdoc-qemuwrapper
34 endif
35
36 # We set GPATH here; this gives us semantics for GNU make
37@@ -101,6 +101,7 @@ scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
38 GST_PLUGIN_PATH_1_0= \
39 GST_REGISTRY_1_0=doc-registry.xml \
40 $(GTKDOC_EXTRA_ENVIRONMENT) \
41+ GST_PLUGIN_SCANNER_1_0="$(top_builddir)/libs/gst/helpers/gst-plugin-scanner-dummy" \
42 CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" \
43 CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" \
44 LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
45--
462.15.1
47
diff --git a/recipes-multimedia/gstreamer/gstreamer1.0_1.12.imx.bb b/recipes-multimedia/gstreamer/gstreamer1.0_1.12.imx.bb
new file mode 100644
index 00000000..24537952
--- /dev/null
+++ b/recipes-multimedia/gstreamer/gstreamer1.0_1.12.imx.bb
@@ -0,0 +1,74 @@
1SUMMARY = "GStreamer 1.0 multimedia framework"
2DESCRIPTION = "GStreamer is a multimedia framework for encoding and decoding video and sound. \
3It supports a wide range of formats including mp3, ogg, avi, mpeg and quicktime."
4HOMEPAGE = "http://gstreamer.freedesktop.org/"
5BUGTRACKER = "https://bugzilla.gnome.org/enter_bug.cgi?product=Gstreamer"
6SECTION = "multimedia"
7LICENSE = "LGPLv2+"
8
9DEPENDS = "glib-2.0 glib-2.0-native libcap libxml2 bison-native flex-native elfutils"
10
11inherit autotools pkgconfig gettext upstream-version-is-even gobject-introspection gtk-doc
12
13# This way common/m4/introspection.m4 will come first
14# (it has a custom INTROSPECTION_INIT macro, and so must be used instead of our common introspection.m4 file)
15acpaths = "-I ${S}/common/m4 -I ${S}/m4"
16
17LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d \
18 file://gst/gst.h;beginline=1;endline=21;md5=e059138481205ee2c6fc1c079c016d0d"
19
20# Use i.MX fork of GST for customizations
21GST1.0_SRC ?= "gitsm://source.codeaurora.org/external/imx/gstreamer.git;protocol=https"
22SRCBRANCH = "imx-1.12.x"
23
24SRC_URI = " \
25 ${GST1.0_SRC};branch=${SRCBRANCH} \
26 file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
27 file://gtk-doc-tweaks.patch \
28 file://0001-gst-gstpluginloader.c-when-env-var-is-set-do-not-fal.patch \
29"
30SRCREV = "cca1ebf223bd423ed5fc21031014ee1f3ce497a1"
31
32EXTRA_AUTORECONF = ""
33
34PACKAGECONFIG ??= ""
35
36PACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
37PACKAGECONFIG[tests] = "--enable-tests,--disable-tests"
38PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind,"
39PACKAGECONFIG[gst-tracer-hooks] = "--enable-gst-tracer-hooks,--disable-gst-tracer-hooks,"
40
41EXTRA_OECONF = " \
42 --disable-dependency-tracking \
43 --disable-examples \
44"
45
46CACHED_CONFIGUREVARS += "ac_cv_header_valgrind_valgrind_h=no"
47
48# musl libc generates warnings if <sys/poll.h> is included directly
49CACHED_CONFIGUREVARS += "ac_cv_header_sys_poll_h=no"
50
51PACKAGES += "${PN}-bash-completion"
52
53FILES_${PN} += "${libdir}/gstreamer-1.0/*.so"
54FILES_${PN}-dev += "${libdir}/gstreamer-1.0/*.la ${libdir}/gstreamer-1.0/*.a ${libdir}/gstreamer-1.0/include"
55FILES_${PN}-bash-completion += "${datadir}/bash-completion/completions/ ${datadir}/bash-completion/helpers/gst*"
56
57RRECOMMENDS_${PN}_qemux86 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
58RRECOMMENDS_${PN}_qemux86-64 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
59
60delete_pkg_m4_file() {
61 # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
62 rm "${S}/common/m4/pkg.m4" || true
63 rm -f "${S}/common/m4/gtk-doc.m4"
64}
65
66do_configure[prefuncs] += "delete_pkg_m4_file"
67
68do_compile_prepend() {
69 export GIR_EXTRA_LIBS_PATH="${B}/gst/.libs:${B}/libs/gst/base/.libs"
70}
71
72S = "${WORKDIR}/git"
73
74COMPATIBLE_MACHINE = "(mx6|mx7|mx8)"