From a70da63d61c12c1119f49b4cfa30e9deb797614c Mon Sep 17 00:00:00 2001 From: stuebinm Date: Wed, 22 Dec 2021 14:24:44 +0100 Subject: [PATCH] use the voc's fork of obs notes: - doesn't use niv to manage its sources, since apparently niv doesn't support git submodules - haven't tested that this actually builds (it does build without the blackmagic stuff, which I don't have locally and didn't have the patience to fetch) --- pkgs/default.nix | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/pkgs/default.nix b/pkgs/default.nix index f8f9192..7c554c0 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -26,7 +26,28 @@ let blackmagicDesktopVideo = callPackage ./blackmagic-desktop-video { }; - obs-studio = unstable.obs-studio.overrideAttrs (_: rec { + obs-studio = unstable.obs-studio.overrideAttrs (old: rec { + src = pkgs.fetchgit { + url = "https://github.com/lukas2511/obs-studio"; + rev = "93ae2b1c11ad81787d69f30c6c251f02dc72c2f4"; + sha256 = "0zla25bjlqx78rb3fgc2yj8bgb4w4lfq6ans47mpb9nvm5ngx5rn"; + fetchSubmodules = true; + }; + + buildInputs = old.buildInputs ++ [ pkgs.libdrm ]; + + # disable browser-source patches which don't fit on this version of obs + patches = []; + cmakeFlags = [ + "-DCMAKE_CXX_FLAGS=-DDL_OPENGL=\\\"$(out)/lib/libobs-opengl.so\\\"" + "-DOBS_VERSION_OVERRIDE=27.0.1" + "-Wno-dev" # kill dev warnings that are useless for packaging + # is there a better way to change just one flag? (this is where I miss guix tbh) + # anyways turns browser sources off + "-DBUILD_BROWSER=OFF" + "-DCEF_ROOT_DIR=../../cef" + ]; + wrapLibraries = with (pkgs // newpkgs); [ xorg.libX11.out libvlc