grilo-plugins: add grl-chromaprint

This commit is contained in:
Jan Tojnar 2019-09-29 13:48:21 +02:00
parent a631d57c79
commit 0038189df8
No known key found for this signature in database
GPG Key ID: 7FAB2A15F7A607A4
2 changed files with 31 additions and 0 deletions

View File

@ -0,0 +1,13 @@
diff --git a/src/chromaprint/grl-chromaprint.c b/src/chromaprint/grl-chromaprint.c
index 5a3598b..8979291 100644
--- a/src/chromaprint/grl-chromaprint.c
+++ b/src/chromaprint/grl-chromaprint.c
@@ -111,6 +111,8 @@
gst_init (NULL, NULL);
+ @load_plugins@
+
source = grl_chromaprint_source_new ();
grl_registry_register_source (registry,
plugin,

View File

@ -1,5 +1,6 @@
{ stdenv
, fetchurl
, substituteAll
, meson
, ninja
, pkgconfig
@ -16,6 +17,7 @@
, libgdata
, libmediaart
, grilo
, gst_all_1
, gnome-online-accounts
, gmime
, gom
@ -36,6 +38,21 @@ stdenv.mkDerivation rec {
sha256 = "0jldaixc4kzycn5v8ixkjld1n0z3dp0l1p3vchgdwpvdvc7kcfw0";
};
patches = [
# grl-chromaprint requires the following GStreamer elements:
# * fakesink (gstreamer)
# * playbin (gst-plugins-base)
# * chromaprint (gst-plugins-bad)
(substituteAll {
src = ./chromaprint-gst-plugins.patch;
load_plugins = stdenv.lib.concatMapStrings (plugin: ''gst_registry_scan_path(gst_registry_get(), "${plugin}/lib/gstreamer-1.0");'') (with gst_all_1; [
gstreamer
gst-plugins-base
gst-plugins-bad
]);
})
];
nativeBuildInputs = [
meson
ninja
@ -64,6 +81,7 @@ stdenv.mkDerivation rec {
libmediaart
tracker
dleyna-server
gst_all_1.gstreamer
];
passthru = {