about summary refs log tree commit diff
path: root/pkgs/by-name/gd/gdlv/package.nix
blob: 3c7900c80a999716f5a0c2dff36ade8600a59116 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{
  lib,
  stdenv,
  buildGoModule,
  fetchFromGitHub,
  AppKit,
  CoreGraphics,
  Foundation,
  Metal,
}:
buildGoModule rec {
  pname = "gdlv";
  version = "1.12.0";

  src = fetchFromGitHub {
    owner = "aarzilli";
    repo = "gdlv";
    rev = "v${version}";
    hash = "sha256-6NU7bhURdXM4EjVnsXVf9XFOUgHyVEI0kr15q9OnUTQ=";
  };

  vendorHash = null;
  subPackages = ".";

  preBuild =
    lib.optionalString
      (stdenv.hostPlatform.isDarwin && lib.versionOlder stdenv.hostPlatform.darwinMinVersion "11.0")
      ''
        export MACOSX_DEPLOYMENT_TARGET=10.15
      '';

  buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
    AppKit
    CoreGraphics
    Foundation
    Metal
  ];

  meta = with lib; {
    description = "GUI frontend for Delve";
    mainProgram = "gdlv";
    homepage = "https://github.com/aarzilli/gdlv";
    maintainers = with maintainers; [ mmlb ];
    license = licenses.gpl3;
  };
}