@@ -0,0 +1,44 @@
1+{ stdenv, fetchurl, makeDesktopItem, openssl_1_1, xorg, curl, fontconfig, krb5, zlib, dotnet-sdk }:
2+
3+stdenv.mkDerivation rec {
4+ pname = "wasabiwallet";
5+ version = "1.1.5";
6+
7+ src = fetchurl {
8+ url = "https://github.com/zkSNACKs/WalletWasabi/releases/download/v${version}/WasabiLinux-${version}.tar.gz";
9+ sha256 = "1iq7qkpq073yq1bz8pam4cbm2myznhpjr3g9afblvmxwgbdjxak0";
10+ };
11+
12+ dontBuild = true;
13+ dontPatchELF = true;
14+
15+ desktopItem = makeDesktopItem {
16+ name = "wasabi";
17+ exec = "wasabiwallet";
18+ desktopName = "Wasabi";
19+ genericName = "Bitcoin wallet";
20+ comment = meta.description;
21+ categories = "Application;Network;Utility;";
22+ };
23+
24+ installPhase = ''
25+ mkdir -p $out/opt/${pname} $out/bin $out/share/applications
26+ cp -Rv . $out/opt/${pname}
27+ cd $out/opt/${pname}
28+ for i in $(find . -type f -name '*.so') wassabee
29+ do
30+ patchelf --set-rpath ${stdenv.lib.makeLibraryPath [ openssl_1_1 stdenv.cc.cc.lib xorg.libX11 curl fontconfig.lib krb5 zlib dotnet-sdk ]} $i
31+ done
32+ patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" wassabee
33+ ln -s $out/opt/${pname}/wassabee $out/bin/${pname}
34+ cp -v $desktopItem/share/applications/* $out/share/applications
35+ '';
36+
37+ meta = with stdenv.lib; {
38+ description = "Privacy focused Bitcoin wallet";
39+ homepage = "https://wasabiwallet.io/";
40+ license = licenses.mit;
41+ platforms = [ "x86_64-linux" ];
42+ maintainers = with maintainers; [ mmahut ];
43+ };
44+}