Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / ocaml-modules / yuujinchou / default.nix
blob48c1fb471fadb22a9065e7a320069d2c3d4991e7
1 { lib, ocaml, fetchFromGitHub, buildDunePackage
2 , algaeff, bwd
3 , qcheck-alcotest
4 }:
6 let params = if lib.versionAtLeast ocaml.version "5.0" then {
7     version = "5.1.0";
8     hash = "sha256-J3qkytgJkk2gT83KJ47nNM4cXqVHbx4iTPK+fLwR7Wk=";
9     propagatedBuildInputs = [ algaeff bwd ];
10   } else {
11     version = "2.0.0";
12     hash = "sha256:1nhz44cyipy922anzml856532m73nn0g7iwkg79yzhq6yb87109w";
13   }
14 ; in
16 buildDunePackage rec {
17   pname = "yuujinchou";
18   inherit (params) version;
20   minimalOCamlVersion = "4.12";
22   src = fetchFromGitHub {
23     owner = "RedPRL";
24     repo = pname;
25     rev = version;
26     inherit (params) hash;
27   };
29   propagatedBuildInputs = params.propagatedBuildInputs or [];
32   doCheck = true;
33   checkInputs = [ qcheck-alcotest ];
35   meta = {
36     description = "Name pattern combinators";
37     homepage = "https://github.com/RedPRL/yuujinchou";
38     license = lib.licenses.asl20;
39     maintainers = [ lib.maintainers.vbgl ];
40   };