xrdp: add update script

Signed-off-by: lucasew <lucas59356@gmail.com>

lucasew 7773daec 7257e998

+30 -19
+28 -17
pkgs/applications/networking/remote/xrdp/default.nix
··· 19 19 , lame 20 20 , pixman 21 21 , libjpeg_turbo 22 + , _experimental-update-script-combinators 23 + , gitUpdater 22 24 }: 23 25 24 26 let 25 - version = "0.9.25.1"; 26 - patchedXrdpSrc = applyPatches { 27 - patches = [ ./dynamic_config.patch ]; 28 - name = "xrdp-patched-${version}"; 29 - src = fetchFromGitHub { 30 - owner = "neutrinolabs"; 31 - repo = "xrdp"; 32 - rev = "v${version}"; 33 - fetchSubmodules = true; 34 - hash = "sha256-oAs0oWkCyj3ObdJuHLfT25ZzkTrxNAXDiFU64OOP4Ow="; 35 - }; 36 - }; 37 - 38 27 xorgxrdp = stdenv.mkDerivation rec { 39 28 pname = "xorgxrdp"; 40 29 version = "0.9.20"; ··· 62 51 63 52 preConfigure = "./bootstrap"; 64 53 65 - configureFlags = [ "XRDP_CFLAGS=-I${patchedXrdpSrc}/common" ]; 54 + configureFlags = [ "XRDP_CFLAGS=-I${xrdp.src}/common" ]; 66 55 67 56 enableParallelBuilding = true; 57 + 58 + passthru.updateScript = gitUpdater { rev-prefix = "v"; }; 68 59 }; 69 60 70 - xrdp = stdenv.mkDerivation { 71 - inherit version; 61 + xrdp = stdenv.mkDerivation rec { 72 62 pname = "xrdp"; 63 + version = "0.9.25.1"; 73 64 74 - src = patchedXrdpSrc; 65 + src = applyPatches { 66 + inherit version; 67 + patches = [ ./dynamic_config.patch ]; 68 + name = "xrdp-patched-${version}"; 69 + src = fetchFromGitHub { 70 + owner = "neutrinolabs"; 71 + repo = "xrdp"; 72 + rev = "v${version}"; 73 + fetchSubmodules = true; 74 + hash = "sha256-oAs0oWkCyj3ObdJuHLfT25ZzkTrxNAXDiFU64OOP4Ow="; 75 + }; 76 + }; 75 77 76 78 nativeBuildInputs = [ pkg-config autoconf automake which libtool nasm perl ]; 77 79 ··· 149 151 ''; 150 152 151 153 enableParallelBuilding = true; 154 + 155 + passthru = { 156 + inherit xorgxrdp; 157 + updateScript = _experimental-update-script-combinators.sequence (map (item: item.command) [ 158 + (gitUpdater { rev-prefix = "v"; attrPath = "xrdp.src"; ignoredVersions = [ "beta" ]; }) 159 + { command = ["rm" "update-git-commits.txt"]; } 160 + (gitUpdater { rev-prefix = "v"; attrPath = "xrdp.xorgxrdp"; }) 161 + ]); 162 + }; 152 163 153 164 meta = with lib; { 154 165 description = "An open source RDP server";
+2 -2
pkgs/applications/networking/remote/xrdp/pulseaudio-module-xrdp/default.nix
··· 1 1 { stdenv 2 2 , fetchFromGitHub 3 3 , lib 4 - , nix-update-script 5 4 , pulseaudio 6 5 , autoreconfHook 7 6 , pkg-config 8 7 , nixosTests 8 + , gitUpdater 9 9 }: 10 10 11 11 stdenv.mkDerivation rec { ··· 47 47 ]; 48 48 49 49 passthru = { 50 - updateScript = nix-update-script { }; 50 + updateScript = gitUpdater { rev-prefix = "v"; }; 51 51 tests = { 52 52 inherit (nixosTests) xrdp-with-audio-pulseaudio; 53 53 };