ocamlPackages.reason: 2.0.0 -> 3.0.0
This commit is contained in:
parent
a86e48acae
commit
1b2a0e0f45
@ -1,41 +1,20 @@
|
|||||||
{ stdenv, makeWrapper, buildOcaml, fetchFromGitHub,
|
{ stdenv, makeWrapper, buildOcaml, fetchFromGitHub,
|
||||||
ocaml, opam, topkg, menhir, merlin_extend, ppx_tools_versioned, utop }:
|
ocaml, opam, topkg, menhir, merlin_extend, ppx_tools_versioned, utop }:
|
||||||
|
|
||||||
let
|
buildOcaml rec {
|
||||||
version = "2.0.0";
|
name = "reason";
|
||||||
|
version = "3.0.0";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "facebook";
|
owner = "facebook";
|
||||||
repo = "reason";
|
repo = "reason";
|
||||||
rev = version;
|
rev = version;
|
||||||
sha256 = "0l3lwfvppplah707rq5nqjav2354lq6d7xfflfigkzhn74hlx6iy";
|
sha256 = "0vj3y9vlm9gqvj9grmb9n487avbrj4q5611m7wv1bsdpndvv96jr";
|
||||||
};
|
|
||||||
meta = with stdenv.lib; {
|
|
||||||
homepage = https://facebook.github.io/reason/;
|
|
||||||
description = "Facebook's friendly syntax to OCaml";
|
|
||||||
license = licenses.bsd3;
|
|
||||||
maintainers = [ maintainers.volth ];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
reason-parser = buildOcaml {
|
propagatedBuildInputs = [ menhir merlin_extend ppx_tools_versioned ];
|
||||||
name = "reason-parser";
|
|
||||||
inherit version src meta;
|
|
||||||
sourceRoot = "reason-${version}-src/reason-parser";
|
|
||||||
|
|
||||||
minimumSupportedOcamlVersion = "4.02";
|
buildInputs = [ makeWrapper opam topkg utop menhir opam topkg ];
|
||||||
|
|
||||||
propagatedBuildInputs = [ menhir merlin_extend ppx_tools_versioned ];
|
|
||||||
buildInputs = [ opam topkg ];
|
|
||||||
|
|
||||||
createFindlibDestdir = true;
|
|
||||||
|
|
||||||
inherit (topkg) installPhase;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
buildOcaml {
|
|
||||||
name = "reason";
|
|
||||||
inherit version src meta;
|
|
||||||
|
|
||||||
buildInputs = [ makeWrapper opam topkg reason-parser utop ];
|
|
||||||
|
|
||||||
buildFlags = [ "build" ]; # do not "make tests" before reason lib is installed
|
buildFlags = [ "build" ]; # do not "make tests" before reason lib is installed
|
||||||
|
|
||||||
@ -48,10 +27,15 @@ buildOcaml {
|
|||||||
installPhase = ''
|
installPhase = ''
|
||||||
${topkg.installPhase}
|
${topkg.installPhase}
|
||||||
|
|
||||||
wrapProgram $out/bin/reup \
|
|
||||||
--prefix PATH : "${opam}/bin"
|
|
||||||
wrapProgram $out/bin/rtop \
|
wrapProgram $out/bin/rtop \
|
||||||
--prefix PATH : "${utop}/bin" \
|
--prefix PATH : "${utop}/bin" \
|
||||||
--set OCAMLPATH $out/lib/ocaml/${ocaml.version}/site-lib:$OCAMLPATH
|
--set OCAMLPATH $out/lib/ocaml/${ocaml.version}/site-lib:$OCAMLPATH
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
meta = with stdenv.lib; {
|
||||||
|
homepage = https://facebook.github.io/reason/;
|
||||||
|
description = "Facebook's friendly syntax to OCaml";
|
||||||
|
license = licenses.bsd3;
|
||||||
|
maintainers = [ maintainers.volth ];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user