ocamlPackages.reactivedata: 0.2 -> 0.2.1

This commit is contained in:
Vincent Laporte 2016-12-10 09:58:33 +00:00
parent 5d309cc834
commit 6b546f2543

View File

@ -1,28 +1,20 @@
{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, ocaml_react, camlp4, opam }: { stdenv, fetchurl, ocaml, findlib, ocamlbuild, ocaml_react, opam }:
let assert stdenv.lib.versionAtLeast ocaml.version "3.11";
ocamlVersion = stdenv.lib.getVersion ocaml;
in
assert stdenv.lib.versionAtLeast ocamlVersion "3.11";
stdenv.mkDerivation { stdenv.mkDerivation {
name = "ocaml-reactiveData-0.2"; name = "ocaml${ocaml.version}-reactiveData-0.2.1";
src = fetchurl { src = fetchurl {
url = https://github.com/ocsigen/reactiveData/archive/0.2.tar.gz; url = https://github.com/ocsigen/reactiveData/archive/0.2.1.tar.gz;
sha256 = "0rskcxnyjn8sxqnncdm6rh9wm99nha5m5sc83fywgzs64xfl43fq"; sha256 = "0wcs0z50nia1cpk8mh6i5qbc6sff9cc8x7s7q1q89d7m73bnv4vf";
}; };
buildInputs = [ ocaml findlib ocamlbuild opam camlp4 ]; buildInputs = [ ocaml findlib ocamlbuild opam ];
propagatedBuildInputs = [ocaml_react]; propagatedBuildInputs = [ocaml_react];
buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true"; buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true";
installPhase = '' installPhase = "opam-installer -i --prefix=$out --libdir=$OCAMLFIND_DESTDIR";
opam-installer --script --prefix=$out reactiveData.install > install.sh
sed -i s!lib/reactiveData!lib/ocaml/${ocamlVersion}/site-lib/reactiveData! install.sh
sh install.sh
'';
meta = with stdenv.lib; { meta = with stdenv.lib; {
description = "An OCaml module for functional reactive programming (FRP) based on React"; description = "An OCaml module for functional reactive programming (FRP) based on React";