{ lib, stdenv, buildDotnetModule, fetchFromGitHub, dotnetCorePackages, openssl, mono, nixosTests, }: buildDotnetModule rec { pname = "jackett"; version = "0.22.998"; src = fetchFromGitHub { owner = pname; repo = pname; rev = "v${version}"; hash = "sha512-EBFu+ga5shxACG7jt5js8yLf7wR9fK84nan9ZBx8B4rp73A0JL5A4gg8s3NxC/NIUHf3kUBPiApyAdz8ECuhZQ=="; }; projectFile = "src/Jackett.Server/Jackett.Server.csproj"; nugetDeps = ./deps.nix; dotnet-runtime = dotnetCorePackages.aspnetcore_8_0; dotnet-sdk = dotnetCorePackages.sdk_8_0; dotnetInstallFlags = [ "-p:TargetFramework=net8.0" ]; runtimeDeps = [ openssl ]; doCheck = !(stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64); # mono is not available on aarch64-darwin nativeCheckInputs = [ mono ]; testProjectFile = "src/Jackett.Test/Jackett.Test.csproj"; postFixup = '' # For compatibility ln -s $out/bin/jackett $out/bin/Jackett || : ln -s $out/bin/Jackett $out/bin/jackett || : ''; passthru.updateScript = ./updater.sh; passthru.tests = { inherit (nixosTests) jackett; }; meta = with lib; { description = "API Support for your favorite torrent trackers"; mainProgram = "jackett"; homepage = "https://github.com/Jackett/Jackett/"; changelog = "https://github.com/Jackett/Jackett/releases/tag/v${version}"; license = licenses.gpl2Only; maintainers = with maintainers; [ edwtjo nyanloutre purcell ]; }; }