nixpkgs/pkgs/development/tools/ocaml/js_of_ocaml/compiler.nix
Ryan Mulligan 5cb865e100 ocamlPackages.js_of_ocaml: 3.0.0 -> 3.1.0
Semi-automatic update generated by https://github.com/ryantm/nix-update tools. These checks were done:

- built on NixOS
/tmp/tmp.I0xNTw0Lrg /home/ryantm/.cache/nixpkgs
/home/ryantm/.cache/nixpkgs
- Warning: no binary found that responded to help or version flags. (This warning appears even if the package isn't expected to have binaries.)
- found 3.1.0 with grep in /nix/store/rg3dh55klmmy5gffvv353nbgwjg0mh11-js_of_ocaml-3.1.0
- directory tree listing: https://gist.github.com/4afbe9caa678f6e8124185a1cc5d2a9c
2018-03-31 12:19:28 +02:00

36 lines
883 B
Nix

{ stdenv, fetchFromGitHub, ocaml, findlib, jbuilder
, cmdliner, cppo, yojson
}:
if !stdenv.lib.versionAtLeast ocaml.version "4.02"
then throw "js_of_ocaml-compiler is not available for OCaml ${ocaml.version}"
else
stdenv.mkDerivation rec {
name = "js_of_ocaml-compiler-${version}";
version = "3.1.0";
src = fetchFromGitHub {
owner = "ocsigen";
repo = "js_of_ocaml";
rev = version;
sha256 = "17a0kb39bcx2qq41cq7kjrxghm67l1yahrs47yakgb1avna0pqd9";
};
buildInputs = [ ocaml findlib jbuilder cmdliner cppo ];
propagatedBuildInputs = [ yojson ];
buildPhase = "jbuilder build -p js_of_ocaml-compiler";
inherit (jbuilder) installPhase;
meta = {
description = "Compiler from OCaml bytecode to Javascript";
license = stdenv.lib.licenses.gpl2;
maintainers = [ stdenv.lib.maintainers.vbgl ];
inherit (src.meta) homepage;
inherit (ocaml.meta) platforms;
};
}