summaryrefslogtreecommitdiffstats
path: root/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb
diff options
context:
space:
mode:
authorCarlos Rafael Giani <crg7475@mailbox.org>2020-01-12 14:59:45 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-01-16 22:21:31 +0000
commit20614408dc4e0593f2cce2e342d5b8a15f182c14 (patch)
tree633c74896ccece93dac45332417e9e140c0d239e /meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb
parent0db7ba34ca41b107042306d13a6f0162885c123b (diff)
downloadopenembedded-core-contrib-20614408dc4e0593f2cce2e342d5b8a15f182c14.tar.gz
gstreamer1.0-plugins-base: Transition to meson based builds
* OpenGL packageconfigs now work differently. There are separate ones for OpenGL API/platform/window system selection. The meson.build script expects the selected ones as comma separated lists. For example, like "-Dgl_api=opengl,gles2". The variables OPENGL_APIS / OPENGL_PLATFORMS / OPENGL_WINSYS are whitespace-separated lists (which is the OE norm) of the respective packageconfigs. .bbappend files can then extend these lists with additional possible configs. "Possible" means that the target can support those packageconfigs. This does not immediately add them to the PACKAGECONFIG variable - this still has to be done manually. The get_opengl_cmdline_list() goes through these lists, and for each entry, checks if it is contained in the PACKAGECONFIG variable. If so, they get added to the comma separated lists that are passed to meson. For example, a Raspberry Pi layer could add "dispmanx" to OPENGL_WINSYS. * The "ivorbis" packageconfig got renamed to "tremor", since that is the name of the OE recipe, and now also the name of the meson option. * 0001-meson-build-gir-even-when-cross-compiling-if-introsp.patch and 0002-meson-Add-variables-for-gir-files.patch are backported fixes for GIR support in the meson.build files. * make-gio_unix_2_0-dependency-configurable.patch removed because it is no longer useful to have. * link-with-libvchostif.patch removed because the flags it changed are no longer present in the meson.build scripts. If the related issue reappears, a similar patch can be applied again. * 0003-riff-add-missing-include-directories-when-calling-in.patch removed since the entire gst riff library has been excluded from GObject introspection due to naming convention issues. * Removed a number of autotool/M4 related patches and recipe lines. * gtk-doc support is handled here, not in gstreamer1.0-plugins-common.inc, since unlike with autotools, only some plugin set packages use gtk-doc. * zlib is no longer optional, and glib anyway depends on zlib, therefore it gets added to the DEPENDS list. * gettext handling now part of gstreamer1.0-plugins-common.inc. Signed-off-by: Carlos Rafael Giani <crg7475@mailbox.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb')
-rw-r--r--meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb95
1 files changed, 58 insertions, 37 deletions
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb
index cb99fba5ff..7ce9238c4a 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.16.1.bb
@@ -1,4 +1,4 @@
-require gstreamer1.0-plugins.inc
+require gstreamer1.0-plugins-common.inc
LICENSE = "GPLv2+ & LGPLv2+"
LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d \
@@ -7,67 +7,88 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d \
SRC_URI = " \
https://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-${PV}.tar.xz \
file://get-caps-from-src-pad-when-query-caps.patch \
+ file://0001-meson-build-gir-even-when-cross-compiling-if-introsp.patch \
+ file://0002-meson-Add-variables-for-gir-files.patch \
file://0003-ssaparse-enhance-SSA-text-lines-parsing.patch \
- file://make-gio_unix_2_0-dependency-configurable.patch \
- file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
- file://0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch \
- file://0003-riff-add-missing-include-directories-when-calling-in.patch \
- file://0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch \
file://0005-viv-fb-Make-sure-config.h-is-included.patch \
file://0009-glimagesink-Downrank-to-marginal.patch \
- file://0001-gstreamer-gl.pc.in-don-t-append-GL_CFLAGS-to-CFLAGS.patch \
- file://link-with-libvchostif.patch \
"
SRC_URI[md5sum] = "b5eb0651bab70bf1714f103bdd66ce47"
SRC_URI[sha256sum] = "5c3cc489933d0597087c9bc6ba251c93693d64554bcc563539a084fa2d5fcb2b"
S = "${WORKDIR}/gst-plugins-base-${PV}"
-DEPENDS += "iso-codes util-linux"
+DEPENDS += "iso-codes util-linux zlib"
-inherit gettext gobject-introspection
+inherit gobject-introspection gtk-doc
PACKAGES_DYNAMIC =+ "^libgst.*"
# opengl packageconfig factored out to make it easy for distros
-# and BSP layers to pick either (desktop) opengl, gles2, or no GL
+# and BSP layers to choose OpenGL APIs/platforms/window systems
PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gles2 egl', '', d)}"
PACKAGECONFIG ??= " \
${GSTREAMER_ORC} \
${PACKAGECONFIG_GL} \
${@bb.utils.filter('DISTRO_FEATURES', 'alsa x11', d)} \
- gio-unix-2.0 jpeg ogg pango png theora vorbis zlib \
+ jpeg ogg pango png theora vorbis \
${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland egl', '', d)} \
"
+OPENGL_APIS = 'opengl gles2'
+OPENGL_PLATFORMS = 'egl'
+OPENGL_WINSYS = 'x11 wayland gbm'
+
X11DEPENDS = "virtual/libx11 libsm libxrender libxv"
-X11ENABLEOPTS = "--enable-x --enable-xvideo --enable-xshm"
-X11DISABLEOPTS = "--disable-x --disable-xvideo --disable-xshm"
-
-PACKAGECONFIG[alsa] = "--enable-alsa,--disable-alsa,alsa-lib"
-PACKAGECONFIG[cdparanoia] = "--enable-cdparanoia,--disable-cdparanoia,cdparanoia"
-PACKAGECONFIG[egl] = "--enable-egl,--disable-egl,virtual/egl"
-PACKAGECONFIG[gbm] = "--enable-gbm,--disable-gbm,virtual/libgbm libgudev libdrm"
-PACKAGECONFIG[gio-unix-2.0] = "--enable-gio_unix_2_0,--disable-gio_unix_2_0,glib-2.0"
-PACKAGECONFIG[gles2] = "--enable-gles2,--disable-gles2,virtual/libgles2"
-PACKAGECONFIG[ivorbis] = "--enable-ivorbis,--disable-ivorbis,tremor"
-PACKAGECONFIG[jpeg] = "--enable-jpeg,--disable-jpeg,jpeg"
-PACKAGECONFIG[ogg] = "--enable-ogg,--disable-ogg,libogg"
-PACKAGECONFIG[opengl] = "--enable-opengl,--disable-opengl,virtual/libgl libglu"
-PACKAGECONFIG[opus] = "--enable-opus,--disable-opus,libopus"
-PACKAGECONFIG[pango] = "--enable-pango,--disable-pango,pango"
-PACKAGECONFIG[png] = "--enable-png,--disable-png,libpng"
-PACKAGECONFIG[theora] = "--enable-theora,--disable-theora,libtheora"
-PACKAGECONFIG[visual] = "--enable-libvisual,--disable-libvisual,libvisual"
-PACKAGECONFIG[vorbis] = "--enable-vorbis,--disable-vorbis,libvorbis"
+X11ENABLEOPTS = "-Dx11=enabled -Dxvideo=enabled -Dxshm=enabled"
+X11DISABLEOPTS = "-Dx11=disabled -Dxvideo=disabled -Dxshm=disabled"
+
+PACKAGECONFIG[alsa] = "-Dalsa=enabled,-Dalsa=disabled,alsa-lib"
+PACKAGECONFIG[cdparanoia] = "-Dcdparanoia=enabled,-Dcdparanoia=disabled,cdparanoia"
+PACKAGECONFIG[jpeg] = "-Dgl-jpeg=enabled,-Dgl-jpeg=disabled,jpeg"
+PACKAGECONFIG[ogg] = "-Dogg=enabled,-Dogg=disabled,libogg"
+PACKAGECONFIG[opus] = "-Dopus=enabled,-Dopus=disabled,libopus"
+PACKAGECONFIG[pango] = "-Dpango=enabled,-Dpango=disabled,pango"
+PACKAGECONFIG[png] = "-Dgl-png=enabled,-Dgl-png=disabled,libpng"
+PACKAGECONFIG[theora] = "-Dtheora=enabled,-Dtheora=disabled,libtheora"
+PACKAGECONFIG[tremor] = "-Dtremor=enabled,-Dtremor=disabled,tremor"
+PACKAGECONFIG[visual] = "-Dlibvisual=enabled,-Dlibvisual=disabled,libvisual"
+PACKAGECONFIG[vorbis] = "-Dvorbis=enabled,-Dvorbis=disabled,libvorbis"
PACKAGECONFIG[x11] = "${X11ENABLEOPTS},${X11DISABLEOPTS},${X11DEPENDS}"
-PACKAGECONFIG[wayland] = "--enable-wayland,--disable-wayland,wayland-native wayland wayland-protocols libdrm"
-PACKAGECONFIG[zlib] = "--enable-zlib,--disable-zlib,zlib"
-FILES_${PN}-dev += "${libdir}/gstreamer-${LIBV}/include/gst/gl/gstglconfig.h"
+# OpenGL API packageconfigs
+PACKAGECONFIG[opengl] = ",,virtual/libgl libglu"
+PACKAGECONFIG[gles2] = ",,virtual/libgles2"
+
+# OpenGL platform packageconfigs
+PACKAGECONFIG[egl] = ",,virtual/egl"
+
+# OpenGL window systems (except for X11)
+PACKAGECONFIG[gbm] = ",,virtual/libgbm libgudev libdrm"
+PACKAGECONFIG[wayland] = ",,wayland-native wayland wayland-protocols libdrm"
+
+EXTRA_OEMESON += " \
+ -Dgl-graphene=disabled \
+ ${@get_opengl_cmdline_list('gl_api', d.getVar('OPENGL_APIS'), d)} \
+ ${@get_opengl_cmdline_list('gl_platform', d.getVar('OPENGL_PLATFORMS'), d)} \
+ ${@get_opengl_cmdline_list('gl_winsys', d.getVar('OPENGL_WINSYS'), d)} \
+"
+
+GTKDOC_MESON_OPTION = "gtk_doc"
+GTKDOC_MESON_ENABLE_FLAG = "enabled"
+GTKDOC_MESON_DISABLE_FLAG = "disabled"
+
+FILES_${PN}-dev += "${libdir}/gstreamer-1.0/include/gst/gl/gstglconfig.h"
FILES_${MLPREFIX}libgsttag-1.0 += "${datadir}/gst-plugins-base/1.0/license-translations.dict"
-do_compile_prepend() {
- export GIR_EXTRA_LIBS_PATH="${B}/gst-libs/gst/tag/.libs:${B}/gst-libs/gst/video/.libs:${B}/gst-libs/gst/audio/.libs:${B}/gst-libs/gst/rtp/.libs:${B}/gst-libs/gst/allocators/.libs"
-}
+def get_opengl_cmdline_list(switch_name, options, d):
+ selected_options = []
+ if bb.utils.contains('DISTRO_FEATURES', 'opengl', True, False, d):
+ for option in options.split():
+ if bb.utils.contains('PACKAGECONFIG', option, True, False, d):
+ selected_options += [option]
+ if selected_options:
+ return '-D' + switch_name + '=' + ','.join(selected_options)
+ else:
+ return ''