summaryrefslogtreecommitdiffstats
path: root/pkgs/development/ocaml-modules/duff/default.nix
blob: adf4c7f02b3ab12371fd04347afc3854864d241f (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
{
  lib,
  fetchurl,
  buildDunePackage,
  fmt,
  alcotest,
  hxd,
  crowbar,
  bigstringaf,
}:

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

  minimalOCamlVersion = "4.08";
  duneVersion = "3";

  src = fetchurl {
    url = "https://github.com/mirage/duff/releases/download/v${finalAttrs.version}/duff-${finalAttrs.version}.tbz";
    sha256 = "sha256-+UU89Ko7aFDv6MxvE/BT6+XyER+vF3zqv7sD5dmtbt4=";
  };

  propagatedBuildInputs = [ fmt ];

  doCheck = true;
  checkInputs = [
    alcotest
    crowbar
    hxd
    bigstringaf
  ];

  meta = {
    description = "Pure OCaml implementation of libXdiff (Rabin’s fingerprint)";
    homepage = "https://github.com/mirage/duff";
    license = lib.licenses.mit;
    maintainers = [ lib.maintainers.vbgl ];
  };
})