{ lib, stdenv, fetchurl, unzip, }: let version = "1.6.3"; srcs = { x86_64-linux = fetchurl { url = "https://github.com/jstarks/npiperelay/releases/download/v0.1.0/npiperelay_windows_amd64.zip"; sha256 = "sha256-a572H/0XwDUHqaPVTYFdzrPa5mmsZ/w79CJdHnZM5fY="; }; # aarch64-linux = fetchurl { # url = # "https://deconz.dresden-elektronik.de/debian/stable/deconz_${version}-debian-buster-stable_arm64.deb"; # sha256 = "sha256-zuy4e9bzcRqDeXP6mfzZLCDK/3we25LH6xktnO6HXps="; # }; }; in stdenv.mkDerivation rec { pname = "npiperelay"; inherit version; src = srcs.${stdenv.hostPlatform.system}; nativeBuildInputs = [unzip]; #buildInputs = [ qtserialport qtwebsockets ]; unpackPhase = '' mkdir npiperelay-$version cd npiperelay-$version unzip $src ''; #unpackPhase = "dpkg-deb -x $src ."; installPhase = '' mkdir -p $out/bin cp npiperelay.exe $out/bin/npiperelay.exe chmod +x $out/bin/npiperelay.exe ''; meta = with lib; { description = "Helper to interface with Windows ssh-agent.exe service from Windows Subsystem for Linux (WSL)"; # 2019-08-19: The homepage links to old software that doesn't even work -- # it fails to detect ConBee2. homepage = "https://github.com/rupor-github/wsl-ssh-agent"; license = licenses.free; platforms = ["x86_64-linux"]; maintainers = with maintainers; [sstent]; }; }