From 1281f51b6972ec61101bf54e05daf338c8209ca9 Mon Sep 17 00:00:00 2001 From: William Casarin Date: Wed, 24 Jun 2015 23:47:44 -0700 Subject: [PATCH] obs-studio: audio support --- pkgs/applications/video/obs-studio/default.nix | 10 ++++++++-- pkgs/top-level/all-packages.nix | 4 +++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/video/obs-studio/default.nix b/pkgs/applications/video/obs-studio/default.nix index 894a51c58cce..953f0c3a8b23 100644 --- a/pkgs/applications/video/obs-studio/default.nix +++ b/pkgs/applications/video/obs-studio/default.nix @@ -7,9 +7,14 @@ , qt5 , libv4l , x264 + +, pulseaudioSupport ? false +, libpulseaudio }: -stdenv.mkDerivation rec { +let + optional = stdenv.lib.optional; +in stdenv.mkDerivation rec { name = "obs-studio-${version}"; version = "0.10.0"; @@ -26,7 +31,8 @@ stdenv.mkDerivation rec { qt5.base qt5.x11extras x264 - ]; + ] + ++ optional pulseaudioSupport libpulseaudio; # obs attempts to dlopen libobs-opengl, it fails unless we make sure # DL_OPENGL is an explicit path. Not sure if there's a better way diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e7d5caa44718..b29a88eea6b6 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12089,7 +12089,9 @@ let inherit (gnome) libglade; }; - obs-studio = callPackage ../applications/video/obs-studio { }; + obs-studio = callPackage ../applications/video/obs-studio { + pulseaudioSupport = config.pulseaudio or false; + }; ocrad = callPackage ../applications/graphics/ocrad { };