ocamlPackages.ppx_optcomp: init at 113.33.0[01]+4.03

This commit is contained in:
Vincent Laporte 2017-02-23 18:34:17 +00:00
parent 63796fd38f
commit d6bc0c9236
2 changed files with 39 additions and 1 deletions

@ -0,0 +1,34 @@
{ stdenv, fetchzip, ocaml, findlib, ocamlbuild, opam, topkg, oasis
, ppx_core, ppx_tools
}:
let
param = {
"4.03" = {
version = "113.33.00+4.03";
sha256 = "1fkz6n40l4ck8bcr548d2yp08zc9fjv42zldlh0cj3ammhiz3gap";
};
"4.04" = {
version = "113.33.01+4.03";
sha256 = "1caw5dfgh5rw8mcgar0hdn485j1rqlnkbfb8wd0wdl5zhkg8jk3d";
};
}."${ocaml.meta.branch}";
in
stdenv.mkDerivation {
name = "ocaml${ocaml.version}-ppx_optcomp-${param.version}";
src = fetchzip {
url = "http://github.com/janestreet/ppx_optcomp/archive/${param.version}.tar.gz";
inherit (param) sha256;
};
buildInputs = [ ocaml findlib ocamlbuild opam oasis ppx_tools ];
propagatedBuildInputs = [ ppx_core ];
inherit (topkg) installPhase;
meta = {
license = stdenv.lib.licenses.asl20;
inherit (ocaml.meta) platforms;
};
}

@ -559,7 +559,11 @@ let
then callPackage ../development/ocaml-modules/janestreet/ppx_core-113_33_01.nix {}
else callPackage ../development/ocaml-modules/janestreet/ppx-core.nix {};
ppx_optcomp = callPackage ../development/ocaml-modules/janestreet/ppx-optcomp.nix {};
ppx_optcomp =
if lib.versionOlder "4.03" ocaml.version
then callPackage ../development/ocaml-modules/janestreet/ppx_optcomp-113_33_01.nix {
oasis = ocaml_oasis; }
else callPackage ../development/ocaml-modules/janestreet/ppx-optcomp.nix {};
ppx_driver = callPackage ../development/ocaml-modules/janestreet/ppx-driver.nix {};