Commit 5ab18b18 authored by Vincent Laporte's avatar Vincent Laporte Committed by Vincent Laporte
Browse files

ocamlPackages.reactivedata: 0.2.2 → 0.3

parent c7db6a8a
Loading
Loading
Loading
Loading
+7 −15
Original line number Diff line number Diff line
{ lib, stdenv, fetchFromGitHub, ocaml, findlib, ocamlbuild, react, opaline }:
{ lib, fetchFromGitHub, buildDunePackage, react }:

if lib.versionOlder ocaml.version "4.04"
then throw "reactiveData is not available for OCaml ${ocaml.version}"
else

stdenv.mkDerivation rec {
  pname = "ocaml${ocaml.version}-reactiveData";
  version = "0.2.2";
buildDunePackage rec {
  pname = "reactiveData";
  version = "0.3";
  duneVersion = "3";
  minimalOCamlVersion = "4.08";

  src = fetchFromGitHub {
    owner = "ocsigen";
    repo = "reactiveData";
    rev = version;
    sha256 = "sha256-YLkacIbjxZQ/ThgSxjTqviBYih6eW2GX5H7iybQDv1A=";
    sha256 = "sha256-imUphE1vMe3bYqHhgTuGT+B7uLn75acX6fAwBLh1tz4=";
  };

  nativeBuildInputs = [ ocaml findlib ocamlbuild opaline ];
  propagatedBuildInputs = [ react ];

  strictDeps = true;

  buildPhase = "ocaml pkg/build.ml native=true native-dynlink=true";

  installPhase = "opaline -prefix $out -libdir $OCAMLFIND_DESTDIR";

  meta = with lib; {
    description = "An OCaml module for functional reactive programming (FRP) based on React";
    homepage = "https://github.com/ocsigen/reactiveData";
    license = licenses.lgpl21;
    platforms = ocaml.meta.platforms or [ ];
    maintainers = with maintainers; [ vbgl ];
  };
}
+2 −1
Original line number Diff line number Diff line
@@ -6,7 +6,8 @@
buildDunePackage {
  pname = "js_of_ocaml-tyxml";

  inherit (js_of_ocaml-compiler) version src useDune2;
  inherit (js_of_ocaml-compiler) version src;
  duneVersion = "3";

  buildInputs = [ js_of_ocaml-ppx ];