Unverified Commit 2150ba29 authored by Franz Pletz's avatar Franz Pletz
Browse files

obs-studio-plugins.obs-ndi: remove

Not maintained anymore and incompatible with obs-studio 32. Was replaced
by distroav.
parent 90f3af7b
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -60,8 +60,6 @@

  obs-mute-filter = callPackage ./obs-mute-filter.nix { };

  obs-ndi = qt6Packages.callPackage ./obs-ndi { };

  obs-noise = callPackage ./obs-noise.nix { };

  obs-pipewire-audio-capture = callPackage ./obs-pipewire-audio-capture.nix { };
+0 −62
Original line number Diff line number Diff line
{
  lib,
  stdenv,
  fetchFromGitHub,
  obs-studio,
  cmake,
  qtbase,
  ndi,
  curl,
}:

stdenv.mkDerivation rec {
  pname = "obs-ndi";
  version = "4.14.1";

  nativeBuildInputs = [
    cmake
    qtbase
  ];
  buildInputs = [
    obs-studio
    qtbase
    ndi
    curl
  ];

  src = fetchFromGitHub {
    owner = "Palakis";
    repo = "obs-ndi";
    rev = version;
    sha256 = "sha256-ex/fZmZpFM6GTKNBQClzSf6Ns0Yts5+0PAmf5mIQCwc=";
  };

  patches = [
    ./hardcode-ndi-path.patch
  ];

  postPatch = ''
    # Add path (variable added in hardcode-ndi-path.patch
    sed -i -e s,@NDI@,${ndi},g src/plugin-main.cpp

    # Replace bundled NDI SDK with the upstream version
    # (This fixes soname issues)
    rm -rf lib/ndi
    ln -s ${ndi}/include lib/ndi
  '';

  cmakeFlags = [ "-DENABLE_QT=ON" ];

  env.NIX_CFLAGS_COMPILE = "-Wno-deprecated-declarations";

  dontWrapQtApps = true;

  meta = with lib; {
    description = "Network A/V plugin for OBS Studio";
    homepage = "https://github.com/Palakis/obs-ndi";
    license = licenses.gpl2;
    maintainers = with maintainers; [ jshcmpbll ];
    platforms = platforms.linux;
    hydraPlatforms = ndi.meta.hydraPlatforms;
  };
}
+0 −16
Original line number Diff line number Diff line
diff --git a/src/plugin-main.cpp b/src/plugin-main.cpp
index 0d94add..617af73 100644
--- a/src/plugin-main.cpp
+++ b/src/plugin-main.cpp
@@ -244,10 +244,7 @@ const NDIlib_v4 *load_ndilib()
 	if (!path.isEmpty()) {
 		locations << path;
 	}
-#if defined(__linux__) || defined(__APPLE__)
-	locations << "/usr/lib";
-	locations << "/usr/local/lib";
-#endif
+	locations << "@NDI@/lib";
	for (auto location : locations) {
 		path = QDir::cleanPath(
 			QDir(location).absoluteFilePath(NDILIB_LIBRARY_NAME));