Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / applications / version-management / sparkleshare / default.nix
blobda6bb386535c4cc8e1748399ee9abc029ece9985
2   appindicator-sharp,
3   bash,
4   coreutils,
5   fetchFromGitHub,
6   git,
7   git-lfs,
8   glib,
9   gtk-sharp-3_0,
10   lib,
11   makeWrapper,
12   meson,
13   mono,
14   ninja,
15   notify-sharp,
16   openssh,
17   openssl,
18   pkg-config,
19   stdenv,
20   symlinkJoin,
21   webkit2-sharp,
22   xdg-utils,
25 stdenv.mkDerivation rec {
26   pname = "sparkleshare";
27   version = "3.38";
29   src = fetchFromGitHub {
30     owner = "hbons";
31     repo = "SparkleShare";
32     rev = version;
33     sha256 = "1a9csflmj96iyr1l0mdm3ziv1bljfcjnzm9xb2y4qqk7ha2p6fbq";
34   };
36   nativeBuildInputs = [
37     makeWrapper
38     meson
39     mono
40     ninja
41     pkg-config
42   ];
44   buildInputs = [
45     appindicator-sharp
46     gtk-sharp-3_0
47     notify-sharp
48     webkit2-sharp
49   ];
51   patchPhase = ''
52     # Nix will manage the icon cache.
53     echo '#!/bin/sh' >scripts/post-install.sh
54   '';
56   postInstall = ''
57     wrapProgram $out/bin/sparkleshare \
58         --set PATH ${symlinkJoin {
59           name = "mono-path";
60           paths = [
61             bash
62             coreutils
63             git
64             git-lfs
65             glib
66             mono
67             openssh
68             openssl
69             xdg-utils
70           ];
71         }}/bin \
72         --set MONO_GAC_PREFIX ${lib.concatStringsSep ":" [
73           appindicator-sharp
74           gtk-sharp-3_0
75           webkit2-sharp
76         ]} \
77         --set LD_LIBRARY_PATH ${lib.makeLibraryPath [
78           appindicator-sharp
79           gtk-sharp-3_0.gtk3
80           webkit2-sharp
81           webkit2-sharp.webkitgtk
82         ]}
83   '';
85   meta = {
86     description = "Share and collaborate by syncing with any Git repository instantly. Linux, macOS, and Windows";
87     homepage = "https://sparkleshare.org";
88     license = lib.licenses.gpl3;
89     maintainers = with lib.maintainers; [ kevincox ];
90   };