nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at devShellTools-shell 79 lines 2.2 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchurl, 5 autoPatchelfHook, 6 alsa-lib, 7 libX11, 8 pcsclite, 9 testers, 10}: 11 12stdenv.mkDerivation ( 13 finalAttrs: 14 let 15 version = "4.18.0"; 16 buildNum = "3768"; 17 in 18 { 19 pname = "tlclient"; 20 version = "${version}-${buildNum}"; 21 22 src = fetchurl { 23 url = "https://www.cendio.com/downloads/clients/tl-${finalAttrs.version}-client-linux-dynamic-x86_64.tar.gz"; 24 hash = "sha256-fTezGhn0UESEQRPrHYVZNcplV48wb5X/xqplIfLRLAA="; 25 }; 26 27 nativeBuildInputs = [ 28 autoPatchelfHook 29 ]; 30 31 buildInputs = [ 32 alsa-lib 33 libX11 34 pcsclite 35 ]; 36 37 dontConfigure = true; 38 dontBuild = true; 39 40 installPhase = '' 41 runHook preInstall 42 43 mkdir -p "$out" 44 cp -R lib "$out/" 45 cp -R lib/tlclient/share "$out/" 46 47 install -Dm644 "lib/tlclient/EULA.txt" "$out/share/licenses/tlclient/EULA.txt" 48 install -m644 "lib/tlclient/open_source_licenses.txt" "$out/share/licenses/tlclient/open_source_licenses.txt" 49 substituteInPlace "$out/share/applications/thinlinc-client.desktop" \ 50 --replace-fail "/opt/thinlinc/bin/" "" 51 52 install -Dm644 "etc/tlclient.conf" "$out/etc/tlclient.conf" 53 install -Dm755 bin/tlclient* -t "$out/bin" 54 install -Dm644 "lib/tlclient/thinlinc_128.png" "$out/share/icons/hicolor/128x128/apps/thinlinc-client.png" 55 56 runHook postInstall 57 ''; 58 59 passthru.tests.version = testers.testVersion { 60 package = finalAttrs.finalPackage; 61 version = "${version} build ${buildNum}"; 62 }; 63 64 meta = { 65 description = "Linux remote desktop client built on open source technology"; 66 license = { 67 fullName = "Cendio End User License Agreement 3.2"; 68 url = "https://www.cendio.com/thinlinc/docs/legal/eula"; 69 free = false; 70 }; 71 homepage = "https://www.cendio.com/"; 72 changelog = "https://www.cendio.com/thinlinc/docs/relnotes/${version}/"; 73 maintainers = with lib.maintainers; [ felixalbrigtsen ]; 74 platforms = with lib.platforms; linux ++ darwin ++ windows; 75 broken = !(stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isx86_64); 76 mainProgram = "tlclient"; 77 }; 78 } 79)