summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/lens/default.nix
blob: c26b3dbe73747cec2e3950ba108136934f5276eb (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
{ lib, ocaml, fetchzip, ppx_deriving, ppxfind, buildDunePackage }:

if lib.versionAtLeast ocaml.version "4.10"
then throw "lens is not available for OCaml ${ocaml.version}"
else

buildDunePackage rec {
  pname = "lens";
  version = "1.2.3";

  src = fetchzip {
    url = "https://github.com/pdonadeo/ocaml-lens/archive/v${version}.tar.gz";
    sha256 = "09k2vhzysx91syjhgv6w1shc9mgzi0l4bhwpx1g5pi4r4ghjp07y";
  };

  minimumOCamlVersion = "4.04.1";
  buildInputs = [ ppx_deriving ppxfind ];

  meta = with lib; {
    homepage = "https://github.com/pdonadeo/ocaml-lens";
    description = "Functional lenses";
    license = licenses.bsd3;
    maintainers = with maintainers; [
      kazcw
    ];
  };
}