blob: e5e346e5e96dc03bac232c9d712c1f19ca1d6880 [file] [log] [blame]
Andrew Geissler9aee5002022-03-30 16:27:02 +00001require gstreamer1.0-plugins-common.inc
2
3DESCRIPTION = "'Base' GStreamer plugins and helper libraries"
4HOMEPAGE = "https://gstreamer.freedesktop.org/"
5BUGTRACKER = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues"
6LICENSE = "LGPL-2.1-or-later"
7LIC_FILES_CHKSUM = "file://COPYING;md5=69333daa044cb77e486cc36129f7a770"
8
9SRC_URI = "https://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-${PV}.tar.xz \
10 file://0001-ENGR00312515-get-caps-from-src-pad-when-query-caps.patch \
11 file://0003-viv-fb-Make-sure-config.h-is-included.patch \
12 file://0002-ssaparse-enhance-SSA-text-lines-parsing.patch \
Patrick Williams92b42cb2022-09-03 06:53:57 -050013 file://0001-include-required-system-headers-for-isspace-and-ssca.patch \
Andrew Geissler9aee5002022-03-30 16:27:02 +000014 "
Andrew Geissler615f2f12022-07-15 14:00:58 -050015SRC_URI[sha256sum] = "7e30b3dd81a70380ff7554f998471d6996ff76bbe6fc5447096f851e24473c9f"
Andrew Geissler9aee5002022-03-30 16:27:02 +000016
17S = "${WORKDIR}/gst-plugins-base-${PV}"
18
19DEPENDS += "iso-codes util-linux zlib"
20
21inherit gobject-introspection
22
23# opengl packageconfig factored out to make it easy for distros
24# and BSP layers to choose OpenGL APIs/platforms/window systems
25PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gles2 egl', '', d)}"
26
27PACKAGECONFIG ??= " \
28 ${GSTREAMER_ORC} \
29 ${PACKAGECONFIG_GL} \
30 ${@bb.utils.filter('DISTRO_FEATURES', 'alsa x11', d)} \
31 jpeg ogg pango png theora vorbis \
32 ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland egl', '', d)} \
33"
34
35OPENGL_APIS = 'opengl gles2'
36OPENGL_PLATFORMS = 'egl'
37
38X11DEPENDS = "virtual/libx11 libsm libxrender libxv"
39X11ENABLEOPTS = "-Dx11=enabled -Dxvideo=enabled -Dxshm=enabled"
40X11DISABLEOPTS = "-Dx11=disabled -Dxvideo=disabled -Dxshm=disabled"
41
42PACKAGECONFIG[alsa] = "-Dalsa=enabled,-Dalsa=disabled,alsa-lib"
43PACKAGECONFIG[cdparanoia] = "-Dcdparanoia=enabled,-Dcdparanoia=disabled,cdparanoia"
44PACKAGECONFIG[graphene] = "-Dgl-graphene=enabled,-Dgl-graphene=disabled,graphene"
45PACKAGECONFIG[jpeg] = "-Dgl-jpeg=enabled,-Dgl-jpeg=disabled,jpeg"
46PACKAGECONFIG[ogg] = "-Dogg=enabled,-Dogg=disabled,libogg"
47PACKAGECONFIG[opus] = "-Dopus=enabled,-Dopus=disabled,libopus"
48PACKAGECONFIG[pango] = "-Dpango=enabled,-Dpango=disabled,pango"
49PACKAGECONFIG[png] = "-Dgl-png=enabled,-Dgl-png=disabled,libpng"
Patrick Williams03907ee2022-05-01 06:28:52 -050050# This enables Qt5 QML examples in -base. The Qt5 GStreamer
51# qmlglsink and qmlglsrc plugins still exist in -good.
Andrew Geissler9aee5002022-03-30 16:27:02 +000052PACKAGECONFIG[qt5] = "-Dqt5=enabled,-Dqt5=disabled,qtbase qtdeclarative qtbase-native"
53PACKAGECONFIG[theora] = "-Dtheora=enabled,-Dtheora=disabled,libtheora"
54PACKAGECONFIG[tremor] = "-Dtremor=enabled,-Dtremor=disabled,tremor"
55PACKAGECONFIG[visual] = "-Dlibvisual=enabled,-Dlibvisual=disabled,libvisual"
56PACKAGECONFIG[vorbis] = "-Dvorbis=enabled,-Dvorbis=disabled,libvorbis"
57PACKAGECONFIG[x11] = "${X11ENABLEOPTS},${X11DISABLEOPTS},${X11DEPENDS}"
58
59# OpenGL API packageconfigs
60PACKAGECONFIG[opengl] = ",,virtual/libgl libglu"
61PACKAGECONFIG[gles2] = ",,virtual/libgles2"
62
63# OpenGL platform packageconfigs
64PACKAGECONFIG[egl] = ",,virtual/egl"
65
66# OpenGL window systems (except for X11)
67PACKAGECONFIG[gbm] = ",,virtual/libgbm libgudev libdrm"
68PACKAGECONFIG[wayland] = ",,wayland-native wayland wayland-protocols libdrm"
69PACKAGECONFIG[dispmanx] = ",,virtual/libomxil"
70PACKAGECONFIG[viv-fb] = ",,virtual/libgles2 virtual/libg2d"
71
72OPENGL_WINSYS = "${@bb.utils.filter('PACKAGECONFIG', 'x11 gbm wayland dispmanx egl viv-fb', d)}"
73
74EXTRA_OEMESON += " \
75 -Ddoc=disabled \
76 ${@get_opengl_cmdline_list('gl_api', d.getVar('OPENGL_APIS'), d)} \
77 ${@get_opengl_cmdline_list('gl_platform', d.getVar('OPENGL_PLATFORMS'), d)} \
78 ${@get_opengl_cmdline_list('gl_winsys', d.getVar('OPENGL_WINSYS'), d)} \
79"
80
81FILES:${PN}-dev += "${libdir}/gstreamer-1.0/include/gst/gl/gstglconfig.h"
82FILES:${MLPREFIX}libgsttag-1.0 += "${datadir}/gst-plugins-base/1.0/license-translations.dict"
83
84def get_opengl_cmdline_list(switch_name, options, d):
85 selected_options = []
86 if bb.utils.contains('DISTRO_FEATURES', 'opengl', True, False, d):
87 for option in options.split():
88 if bb.utils.contains('PACKAGECONFIG', option, True, False, d):
89 selected_options += [option]
90 if selected_options:
91 return '-D' + switch_name + '=' + ','.join(selected_options)
92 else:
93 return ''
94
95CVE_PRODUCT += "gst-plugins-base"