@@ -0,0 +1,33 @@
1+{ stdenv, fetchFromGitHub, ocaml, dune, findlib, ocaml-migrate-parsetree, ppx_tools_versioned }:
2+
3+let version = "1.4.0"; in
4+
5+stdenv.mkDerivation {
6+ name = "ocaml${ocaml.version}-bisect_ppx-${version}";
7+
8+ src = fetchFromGitHub {
9+ owner = "aantron";
10+ repo = "bisect_ppx";
11+ rev = version;
12+ sha256 = "1plhm4pvrhpapz5zaks194ji1fgzmp13y942g10pbn9m7kgkqg4h";
13+ };
14+
15+ buildInputs = [
16+ ocaml
17+ dune
18+ findlib
19+ ocaml-migrate-parsetree
20+ ppx_tools_versioned
21+ ];
22+
23+ buildPhase = "dune build -p bisect_ppx";
24+
25+ inherit (dune) installPhase;
26+
27+ meta = {
28+ homepage = https://github.com/aantron/bisect_ppx;
29+ platforms = ocaml.meta.platforms or [];
30+ description = "Code coverage for OCaml";
31+ license = stdenv.lib.licenses.mpl20;
32+ };
33+}