From 5ab18b18ed158e2daf924b2a40fc91224804abd2 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Thu, 17 Nov 2022 08:46:24 +0100 Subject: [PATCH] =?UTF-8?q?ocamlPackages.reactivedata:=200.2.2=20=E2=86=92?= =?UTF-8?q?=200.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ocaml-modules/reactivedata/default.nix | 22 ++++++------------- .../tools/ocaml/js_of_ocaml/tyxml.nix | 3 ++- 2 files changed, 9 insertions(+), 16 deletions(-) diff --git a/pkgs/development/ocaml-modules/reactivedata/default.nix b/pkgs/development/ocaml-modules/reactivedata/default.nix index 9be32d28bab9..3aafd9807a01 100644 --- a/pkgs/development/ocaml-modules/reactivedata/default.nix +++ b/pkgs/development/ocaml-modules/reactivedata/default.nix @@ -1,34 +1,26 @@ -{ 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 ]; }; } diff --git a/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix b/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix index e371c9f10bf0..30d5af3d4b08 100644 --- a/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix +++ b/pkgs/development/tools/ocaml/js_of_ocaml/tyxml.nix @@ -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 ];