blob: 4fef3c0619f3f443cc64ef67eb22f014f4d1c5b2 (
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
|
{ lib, buildDunePackage, fetchFromGitHub, ppxlib, ounit
, ppx_deriving, yojson
}:
let param =
if lib.versionAtLeast ppxlib.version "0.26" then {
version = "3.7.0";
sha256 = "sha256-niKxn1fX0mL1MhlZvbN1wgRed9AHh+z9s6l++k1VX9k=";
} else {
version = "3.6.1";
sha256 = "1icz5h6p3pfj7my5gi7wxpflrb8c902dqa17f9w424njilnpyrbk";
}
; in
buildDunePackage rec {
pname = "ppx_deriving_yojson";
inherit (param) version;
minimalOCamlVersion = "4.07";
src = fetchFromGitHub {
owner = "ocaml-ppx";
repo = "ppx_deriving_yojson";
rev = "v${version}";
inherit (param) sha256;
};
propagatedBuildInputs = [ ppxlib ppx_deriving yojson ];
doCheck = true;
checkInputs = [ ounit ];
meta = {
description = "A Yojson codec generator for OCaml >= 4.04";
inherit (src.meta) homepage;
license = lib.licenses.mit;
maintainers = [ lib.maintainers.vbgl ];
};
}
|