gst-plugins-base-1.18.0.ebuild (5208B)
1 # Copyright 1999-2020 Gentoo Authors 2 # Distributed under the terms of the GNU General Public License v2 3 4 EAPI=6 5 GST_ORG_MODULE="gst-plugins-base" 6 7 inherit flag-o-matic gstreamer-meson 8 9 DESCRIPTION="Basepack of plugins for gstreamer" 10 HOMEPAGE="https://gstreamer.freedesktop.org/" 11 12 LICENSE="GPL-2+ LGPL-2+" 13 #KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris" 14 15 # For OpenGL we have three separate concepts, with a list of possibilities in each: 16 # * opengl APIs - opengl and/or gles2; USE=opengl and USE=gles2 enable these accordingly; if neither is enabled, OpenGL helper library and elements are not built at all and all the other options aren't relevant 17 # * opengl platforms - glx and/or egl; also cgl, wgl, eagl for non-linux; USE="X opengl" enables glx platform; USE="egl" enables egl platform. Rest is up for relevant prefix teams. 18 # * opengl windowing system - x11, wayland, win32, cocoa, android, viv_fb, gbm and/or dispmanx; USE=X enables x11 (but for WSI it's automagic - FIXME), USE=wayland enables wayland, USE=gbm enables gbm (automagic upstream - FIXME); rest is up for relevant prefix/arch teams/contributors to test and provide patches 19 # With the following limitations: 20 # * If opengl and/or gles2 is enabled, a platform has to be enabled - x11 or egl in our case, but x11 (glx) is acceptable only with opengl 21 # * If opengl and/or gles2 is enabled, a windowing system has to be enabled - x11, wayland or gbm in our case 22 # * glx platform requires opengl API 23 # * wayland, gbm and most other non-glx WSIs require egl platform 24 # Additionally there is optional dmabuf support with egl for additional dmabuf based upload/download/eglimage options; 25 # and optional graphene usage for gltransformation and glvideoflip elements and more GLSL Uniforms support in glshader; 26 # and libpng/jpeg are required for gloverlay element; 27 28 # Keep default IUSE options for relevant ones mirrored with gst-plugins-gtk and gst-plugins-bad 29 IUSE="alsa +egl gbm gles2 +introspection ivorbis +ogg +opengl +orc +pango theora +vorbis wayland +X" 30 GL_REQUIRED_USE=" 31 || ( gbm wayland X ) 32 wayland? ( egl ) 33 gbm? ( egl ) 34 " 35 REQUIRED_USE=" 36 ivorbis? ( ogg ) 37 theora? ( ogg ) 38 vorbis? ( ogg ) 39 opengl? ( || ( egl X ) ${GL_REQUIRED_USE} ) 40 gles2? ( egl ${GL_REQUIRED_USE} ) 41 " 42 43 # Dependencies needed by opengl library and plugin (enabled via USE gles2 and/or opengl) 44 # dmabuf automagic from libdrm headers (drm_fourcc.h) and EGL, so ensure it with USE=egl (platform independent header used only, thus no MULTILIB_USEDEP); provides dmabuf based upload/download/eglimage options 45 GL_DEPS=" 46 >=media-libs/mesa-9.0[egl?,gbm?,gles2?,wayland?,${MULTILIB_USEDEP}] 47 egl? ( 48 x11-libs/libdrm 49 ) 50 gbm? ( 51 >=dev-libs/libgudev-147[${MULTILIB_USEDEP}] 52 >=x11-libs/libdrm-2.4.55[${MULTILIB_USEDEP}] 53 ) 54 wayland? ( 55 dev-libs/wayland[${MULTILIB_USEDEP}] 56 ) 57 58 media-libs/libpng:0[${MULTILIB_USEDEP}] 59 virtual/jpeg:0[${MULTILIB_USEDEP}] 60 " # graphene for optional gltransformation and glvideoflip elements and more GLSL Uniforms support in glshader; libpng/jpeg for gloverlay element 61 # >=media-libs/graphene-1.4.0[${MULTILIB_USEDEP}] 62 63 RDEPEND=" 64 app-text/iso-codes 65 >=dev-libs/glib-2.40.0:2[${MULTILIB_USEDEP}] 66 >=media-libs/gstreamer-${PV}:1.0[introspection?,${MULTILIB_USEDEP}] 67 >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] 68 alsa? ( >=media-libs/alsa-lib-1.0.27.2[${MULTILIB_USEDEP}] ) 69 introspection? ( >=dev-libs/gobject-introspection-1.31.1:= ) 70 ivorbis? ( >=media-libs/tremor-0_pre20130223[${MULTILIB_USEDEP}] ) 71 ogg? ( >=media-libs/libogg-1.3.0[${MULTILIB_USEDEP}] ) 72 orc? ( >=dev-lang/orc-0.4.24[${MULTILIB_USEDEP}] ) 73 pango? ( >=x11-libs/pango-1.36.3[${MULTILIB_USEDEP}] ) 74 theora? ( >=media-libs/libtheora-1.1.1[encode,${MULTILIB_USEDEP}] ) 75 vorbis? ( >=media-libs/libvorbis-1.3.3-r1[${MULTILIB_USEDEP}] ) 76 X? ( 77 >=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}] 78 >=x11-libs/libXext-1.3.2[${MULTILIB_USEDEP}] 79 >=x11-libs/libXv-1.0.10[${MULTILIB_USEDEP}] 80 ) 81 82 gles2? ( ${GL_DEPS} ) 83 opengl? ( ${GL_DEPS} ) 84 85 !<media-libs/gst-plugins-bad-1.15.0:1.0 86 " 87 DEPEND="${RDEPEND} 88 dev-util/glib-utils 89 >=dev-util/gtk-doc-am-1.12 90 X? ( x11-base/xorg-proto ) 91 " 92 93 multilib_src_configure() { 94 filter-flags -mno-sse -mno-sse2 -mno-sse4.1 #610340 95 96 local emesonargs=( 97 -Diso-codes=enabled 98 $(meson_feature alsa) 99 $(meson_feature ogg) 100 $(meson_feature orc) 101 $(meson_feature pango) 102 $(meson_feature theora) 103 $(meson_feature vorbis) 104 $(meson_feature X x) 105 $(meson_feature X xshm) 106 $(meson_feature X xvideo) 107 ) 108 109 if use opengl || use gles2; then 110 emesonargs+=( 111 -Dgl=enabled 112 -Dgl_api=opengl,$(use gles2 && echo gles2) 113 -Dgl_platform=$(use X && echo glx,)$(use egl && echo egl) 114 -Dgl_winsys=$(use X && echo x11,)$(use wayland && echo wayland,)$(use egl && echo egl,)$(use gbm && echo gbm) 115 ) 116 else 117 emesonargs+=( 118 -Dgl=disabled 119 -Dgl_api= 120 -Dgl_platform= 121 -Dgl_winsys= 122 ) 123 fi 124 125 gstreamer_multilib_src_configure 126 } 127 128 multilib_src_install_all() { 129 DOCS="AUTHORS NEWS README RELEASE" 130 einstalldocs 131 find "${ED}" -name '*.la' -delete || die 132 } 133 134 multilib_src_test() { 135 unset GSETTINGS_BACKEND 136 eninja check 137 }