diff options
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/ndi/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/ndi/default.nix | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/nixpkgs/pkgs/development/libraries/ndi/default.nix b/nixpkgs/pkgs/development/libraries/ndi/default.nix index 7ea64aa3f134..1c15455b6add 100644 --- a/nixpkgs/pkgs/development/libraries/ndi/default.nix +++ b/nixpkgs/pkgs/development/libraries/ndi/default.nix @@ -1,15 +1,19 @@ -{ lib, stdenv, requireFile, avahi }: +{ lib, stdenv, requireFile, avahi, obs-studio-plugins }: +let + versionJSON = lib.importJSON ./version.json; +in stdenv.mkDerivation rec { pname = "ndi"; - fullVersion = "4.6.2"; - version = builtins.head (builtins.splitVersion fullVersion); + version = versionJSON.version; + majorVersion = builtins.head (builtins.splitVersion version); + installerName = "Install_NDI_SDK_v${majorVersion}_Linux"; src = requireFile rec { - name = "InstallNDISDK_v${version}_Linux.tar.gz"; - sha256 = "181ypfj1bl0kljzrfr6037i14ykg2y4plkzdhym6m3z7kcrnm1fl"; + name = "${installerName}.tar.gz"; + sha256 = versionJSON.hash; message = '' - In order to use NDI SDK version ${fullVersion}, you need to comply with + In order to use NDI SDK version ${version}, you need to comply with NewTek's license and download the appropriate Linux tarball from: ${meta.homepage} @@ -25,7 +29,7 @@ stdenv.mkDerivation rec { unpackPhase = '' unpackFile ${src} - echo y | ./InstallNDISDK_v4_Linux.sh + echo y | ./${installerName}.sh sourceRoot="NDI SDK for Linux"; ''; @@ -51,6 +55,11 @@ stdenv.mkDerivation rec { # Stripping breaks ndi-record. dontStrip = true; + passthru.tests = { + inherit (obs-studio-plugins) obs-ndi; + }; + passthru.updateScript = ./update.py; + meta = with lib; { homepage = "https://ndi.tv/sdk/"; description = "NDI Software Developer Kit"; |