gnu: gst-plugins-good: Update package definition.

* gnu/packages/gstreamer.scm (gst-plugins-good): Update package definition.
[arguments]<#:glib-or-gtk?>: New argument.
<#:phases>['disable-tests-for-armhf]: Remove phase.
['disable-failing-tests]: Remove phase.
['patch-docbook-xml]: New phase.
['pre-check]: New phase.
[native-inputs]: Add docbook-xml, gettext-minimal, gobject-introspection,
gsettings-desktop-schemas, perl, libxml2 and xorg-server-for-tests.
[inputs]: Add bzip2, glib, glib-networking, glu, libgudev, libx11,
libxdamage, libxfixes, libxext, libxshmfence, mesa and v4l-utils.
Remove gst-plugins-base.
[propagated-inputs]: Add gstreamer and gst-plugins-base.
[synopsis]: Modify.
[description]: Modify.

Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
This commit is contained in:
Raghav Gururajan 2020-06-24 23:58:52 -04:00 committed by Danny Milosavljevic
parent d26bf52948
commit 798441b67d
No known key found for this signature in database
GPG key ID: E71A35542C30BAA5

View file

@ -547,77 +547,96 @@ (define-public gst-plugins-good
(source (source
(origin (origin
(method url-fetch) (method url-fetch)
(uri (string-append (uri
(string-append
"https://gstreamer.freedesktop.org/src/" name "/" "https://gstreamer.freedesktop.org/src/" name "/"
name "-" version ".tar.xz")) name "-" version ".tar.xz"))
(sha256 (sha256
(base32 (base32 "068k3cbv1yf3gbllfdzqsg263kzwh21y8dpwr0wvgh15vapkpfs0"))))
"068k3cbv1yf3gbllfdzqsg263kzwh21y8dpwr0wvgh15vapkpfs0"))))
(build-system meson-build-system) (build-system meson-build-system)
(arguments
`(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas
#:phases
(modify-phases %standard-phases
(add-after 'unpack 'patch-docbook-xml
(lambda* (#:key inputs #:allow-other-keys)
(with-directory-excursion "docs"
(substitute* "plugins/gst-plugins-good-plugins-docs.sgml"
(("http://www.oasis-open.org/docbook/xml/4.1.2/")
(string-append (assoc-ref inputs "docbook-xml")
"/xml/dtd/docbook/"))))
#t))
(add-before
'check 'pre-check
(lambda _
;; Tests require a running X server.
(system "Xvfb :1 +extension GLX &")
(setenv "DISPLAY" ":1")
;; Tests write to $HOME.
(setenv "HOME" (getcwd))
;; Tests look for $XDG_RUNTIME_DIR.
(setenv "XDG_RUNTIME_DIR" (getcwd))
;; For missing '/etc/machine-id'.
(setenv "DBUS_FATAL_WARNINGS" "0")
#t)))))
(native-inputs
`(("docbook-xml" ,docbook-xml-4.1.2)
("gettext" ,gettext-minimal)
("glib:bin" ,glib "bin")
("gobject-introspection" ,gobject-introspection)
("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
("perl" ,perl)
("pkg-config" ,pkg-config)
("python-wrapper" ,python-wrapper)
("xmllint" ,libxml2)
("xorg-server" ,xorg-server-for-tests)))
(inputs (inputs
`(("aalib" ,aalib) `(("aalib" ,aalib)
("bzip2" ,bzip2)
("cairo" ,cairo) ("cairo" ,cairo)
("flac" ,flac) ("flac" ,flac)
("gdk-pixbuf" ,gdk-pixbuf) ("gdk-pixbuf" ,gdk-pixbuf+svg)
("gst-plugins-base" ,gst-plugins-base) ("glib" ,glib)
("glib-networking" ,glib-networking)
("glu" ,glu)
("gtk+" ,gtk+) ("gtk+" ,gtk+)
("jack" ,jack-1) ("jack" ,jack-2)
("lame" ,lame) ("lame" ,lame)
("libavc1394" ,libavc1394) ("libavc1394" ,libavc1394)
("libcaca" ,libcaca) ("libcaca" ,libcaca)
("libdv" ,libdv) ("libdv" ,libdv)
("libgudev" ,libgudev)
("libiec61883" ,libiec61883) ("libiec61883" ,libiec61883)
("libjpeg" ,libjpeg-turbo) ("libjpeg" ,libjpeg-turbo)
("libpng" ,libpng) ("libpng" ,libpng)
("libshout" ,libshout) ("libshout" ,libshout)
("libsoup" ,libsoup) ("libsoup" ,libsoup)
("libvpx" ,libvpx) ("libvpx" ,libvpx)
("libx11" ,libx11)
("libxdamage" ,libxdamage)
("libxfixes" ,libxfixes)
("libxext" ,libxext)
("libxshm" ,libxshmfence)
("mesa" ,mesa)
("mpg123" ,mpg123) ("mpg123" ,mpg123)
("orc" ,orc) ("orc" ,orc)
("pulseaudio" ,pulseaudio) ("pulseaudio" ,pulseaudio)
("speex" ,speex) ("speex" ,speex)
("taglib" ,taglib) ("taglib" ,taglib)
("twolame" ,twolame) ("twolame" ,twolame)
("wavpack" ,wavpack))) ("v4l-utils" ,v4l-utils)
(native-inputs ("wavpack" ,wavpack)
`(("glib:bin" ,glib "bin") ("zlib" ,zlib)))
("pkg-config" ,pkg-config) (propagated-inputs
("python-wrapper" ,python-wrapper))) `(("gstreamer" ,gstreamer)
(arguments ("gst-plugins-base" ,gst-plugins-base)))
`(#:phases (synopsis "GStreamer plugins and helper libraries")
(modify-phases %standard-phases (description "GStreamer-Plugins-Good is a collection of plug-ins you'd want
,@%common-gstreamer-phases to have right next to you on the battlefield. Shooting sharp and making no
,@(if (string-prefix? "arm" (or (%current-target-system) mistakes, these plug-ins have it all: good looks, good code, and good
(%current-system))) licensing. Documented and dressed up in tests. If you're looking for a role
;; FIXME: These tests started failing on armhf after switching to Meson. model to base your own plug-in on, here it is.")
;; https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/issues/689
`((add-after 'unpack 'disable-tests-for-armhf
(lambda _
(substitute* "tests/check/elements/rtpbin_buffer_list.c"
(("tcase_add_test \\(tc_chain, test_bufferlist\\);")
""))
(substitute* "tests/check/elements/rtpulpfec.c"
(("tcase_add_loop_test.*rtpulpfecdec_recovered_from_many.*")
"")
(("tcase_add.*rtpulpfecdec_recovered_using_recovered_packet.*")
""))
#t)))
'())
(add-after
'unpack 'disable-failing-tests
(lambda _
;; Disable tests that fail non-deterministically.
;; This test fails on aarch64 on 1.12.x.
(substitute* "tests/check/elements/alpha.c"
(("tcase_add_test \\(tc_chain, test_chromakeying\\);" all)
(string-append "/* " all " */")))
#t)))))
(home-page "https://gstreamer.freedesktop.org/") (home-page "https://gstreamer.freedesktop.org/")
(synopsis
"Plugins for the GStreamer multimedia library")
(description "GStreamer Good Plug-ins is a set of plug-ins for the
GStreamer multimedia library. This set contains those plug-ins which the
developers consider to have good quality code and correct functionality.")
(license license:lgpl2.0+))) (license license:lgpl2.0+)))
(define-public gst-plugins-bad (define-public gst-plugins-bad