about summary refs log tree commit diff
path: root/pkgs/development/libraries/gstreamer/bad/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/libraries/gstreamer/bad/default.nix')
-rw-r--r--pkgs/development/libraries/gstreamer/bad/default.nix11
1 files changed, 7 insertions, 4 deletions
diff --git a/pkgs/development/libraries/gstreamer/bad/default.nix b/pkgs/development/libraries/gstreamer/bad/default.nix
index ccfbd892a97d..3aebf03b8ce0 100644
--- a/pkgs/development/libraries/gstreamer/bad/default.nix
+++ b/pkgs/development/libraries/gstreamer/bad/default.nix
@@ -14,6 +14,8 @@
 , enableZbar ? false
 , faacSupport ? false
 , faac
+, opencvSupport ? false
+, opencv4
 , faad2
 , ldacbt
 , libass
@@ -54,7 +56,6 @@
 , libusb1
 , neon
 , openal
-, opencv4
 , openexr_3
 , openh264
 , libopenmpt
@@ -108,13 +109,13 @@
 
 stdenv.mkDerivation rec {
   pname = "gst-plugins-bad";
-  version = "1.22.3";
+  version = "1.22.4";
 
   outputs = [ "out" "dev" ];
 
   src = fetchurl {
     url = "https://gstreamer.freedesktop.org/src/${pname}/${pname}-${version}.tar.xz";
-    hash = "sha256-4XmP7i2GEn8GN0gcYH+YMpO/D9garXClx7RyBa82Idg=";
+    hash = "sha256-6q9TIkVl6qvVBco5xtV2lxm0V5XPUyzhzrYOGy6+maw=";
   };
 
   patches = [
@@ -171,7 +172,6 @@ stdenv.mkDerivation rec {
     libusb1
     neon
     openal
-    opencv4
     openexr_3
     openh264
     rtmpdump
@@ -192,6 +192,8 @@ stdenv.mkDerivation rec {
     libfreeaptx
     zxing-cpp
     usrsctp
+  ] ++ lib.optionals opencvSupport [
+    opencv4
   ] ++ lib.optionals enableZbar [
     zbar
   ] ++ lib.optionals faacSupport [
@@ -292,6 +294,7 @@ stdenv.mkDerivation rec {
     "-Dgs=disabled" # depends on `google-cloud-cpp`
     "-Donnx=disabled" # depends on `libonnxruntime` not packaged in nixpkgs as of writing
     "-Dopenaptx=enabled" # since gstreamer-1.20.1 `libfreeaptx` is supported for circumventing the dubious license conflict with `libopenaptx`
+    "-Dopencv=${if opencvSupport then "enabled" else "disabled"}" # Reduces rebuild size when `config.cudaSupport = true`
     "-Dmicrodns=${if microdnsSupport then "enabled" else "disabled"}"
     "-Dbluez=${if bluezSupport then "enabled" else "disabled"}"
     (lib.mesonEnable "doc" enableDocumentation)