summaryrefslogtreecommitdiffstats
path: root/pkgs/development/ocaml-modules/scfg/default.nix
blob: 060c367cf0efd3382732c004326e5ce8e5946d82 (plain)
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
47
48
49
50
51
52
53
54
55
56
57
{
  lib,
  buildDunePackage,
  fetchzip,
  bos,
  cmdliner,
  fmt,
  fpath,
  menhir,
  menhirLib,
  prelude,
  sedlex,
  writableTmpDirAsHomeHook,
}:

buildDunePackage (finalAttrs: {
  pname = "scfg";
  version = "0.5";

  # upstream git repo is misconfigured and cannot be cloned
  src = fetchzip {
    url = "https://git.zapashcanon.fr/zapashcanon/scfg/archive/${finalAttrs.version}.tar.gz";
    hash = "sha256-XyNVmI0W0B1JqR+uuojpHe9L5KKLhyoH8vN8+9i7Xcg=";
  };

  nativeBuildInputs = [
    menhir
  ];

  buildInputs = [
    cmdliner
  ];

  propagatedBuildInputs = [
    bos
    fmt
    fpath
    menhirLib
    prelude
    sedlex
  ];

  checkInputs = [
    writableTmpDirAsHomeHook
  ];

  doCheck = true;

  meta = {
    description = "Library to work with the scfg configuration file";
    homepage = "https://ocaml.org/p/scfg/";
    downloadPage = "https://git.zapashcanon.fr/zapashcanon/scfg";
    changelog = "https://git.zapashcanon.fr/zapashcanon/scfg/src/tag/${finalAttrs.version}/CHANGES.md";
    license = lib.licenses.isc;
    maintainers = [ lib.maintainers.ethancedwards8 ];
  };
})