nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix

rtorrent: cleanup

+20 -20
+20 -20
pkgs/by-name/rt/rtorrent/package.nix
··· 1 1 { 2 - lib, 3 - stdenv, 4 2 autoreconfHook, 5 3 cppunit, 6 4 curl, 7 5 fetchFromGitHub, 8 6 installShellFiles, 7 + lib, 9 8 libtool, 10 9 libtorrent-rakshasa, 10 + lua5_4_compat, 11 11 ncurses, 12 + nixosTests, 13 + nix-update-script, 12 14 openssl, 13 15 pkg-config, 14 - zlib, 15 - nixosTests, 16 - gitUpdater, 16 + stdenv, 17 + versionCheckHook, 17 18 withLua ? false, 18 - lua5_4_compat, 19 + zlib, 19 20 }: 20 21 21 22 stdenv.mkDerivation (finalAttrs: { ··· 26 25 src = fetchFromGitHub { 27 26 owner = "rakshasa"; 28 27 repo = "rtorrent"; 29 - rev = "v${finalAttrs.version}"; 28 + tag = "v${finalAttrs.version}"; 30 29 hash = "sha256-+lpivm3MXbuJ4XYhK5OaASpqpDKcCdW7JCFjQYBYCSA="; 31 30 }; 32 31 ··· 34 33 "out" 35 34 "man" 36 35 ]; 37 - 38 - passthru = { 39 - inherit libtorrent-rakshasa; 40 - }; 41 36 42 37 nativeBuildInputs = [ 43 38 autoreconfHook ··· 58 61 ] 59 62 ++ lib.optionals withLua [ "--with-lua" ]; 60 63 61 - passthru = { 62 - updateScript = gitUpdater { rev-prefix = "v"; }; 63 - tests = { 64 - inherit (nixosTests) rtorrent; 65 - }; 66 - }; 67 - 68 64 enableParallelBuilding = true; 69 65 70 66 postInstall = '' ··· 65 75 install -Dm644 doc/rtorrent.rc-example -t $out/share/doc/rtorrent/rtorrent.rc 66 76 ''; 67 77 78 + doInstallCheck = true; 79 + nativeInstallCheckInputs = [ versionCheckHook ]; 80 + versionCheckProgramArg = "-h"; 81 + 82 + passthru = { 83 + inherit libtorrent-rakshasa; 84 + tests = { inherit (nixosTests) rtorrent; }; 85 + updateScript = nix-update-script { }; 86 + }; 87 + 68 88 meta = { 69 - homepage = "https://rakshasa.github.io/rtorrent/"; 70 89 description = "Ncurses client for libtorrent, ideal for use with screen, tmux, or dtach"; 90 + homepage = "https://rakshasa.github.io/rtorrent/"; 71 91 license = lib.licenses.gpl2Plus; 92 + mainProgram = "rtorrent"; 72 93 maintainers = with lib.maintainers; [ 73 94 ebzzry 74 95 codyopel 75 96 thiagokokada 76 97 ]; 77 98 platforms = lib.platforms.unix; 78 - mainProgram = "rtorrent"; 79 99 }; 80 100 })