about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorUlrik Strid <ulrik.strid@outlook.com>2023-10-04 10:30:35 +0200
committerGitHub <noreply@github.com>2023-10-04 10:30:35 +0200
commit8d301f41a14f734dfe8de047ada0f0a68b4f80e3 (patch)
tree3f5b271513c6baabc9577f771f6d58bce6dd5a77 /pkgs
parentd0828766543c4415bb51ea630da9a76663b04071 (diff)
parentbc1d216bb2c25e049435901f900c333a6f27498a (diff)
Merge pull request #256411 from wegank/zelus-init
ocamlPackages.zelus{,-gtk}: init at 2.2
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/development/ocaml-modules/zelus-gtk/default.nix24
-rw-r--r--pkgs/development/ocaml-modules/zelus/default.nix42
-rw-r--r--pkgs/top-level/ocaml-packages.nix4
3 files changed, 70 insertions, 0 deletions
diff --git a/pkgs/development/ocaml-modules/zelus-gtk/default.nix b/pkgs/development/ocaml-modules/zelus-gtk/default.nix
new file mode 100644
index 0000000000000..c0e0e586066af
--- /dev/null
+++ b/pkgs/development/ocaml-modules/zelus-gtk/default.nix
@@ -0,0 +1,24 @@
+{ buildDunePackage
+, zelus
+, lablgtk
+}:
+
+buildDunePackage {
+  pname = "zelus-gtk";
+  inherit (zelus) version src postPatch;
+
+  minimalOCamlVersion = "4.08.1";
+
+  nativeBuildInputs = [
+    zelus
+  ];
+
+  buildInputs = [
+    lablgtk
+  ];
+
+  meta = {
+    description = "Zelus GTK library";
+    inherit (zelus.meta) homepage license maintainers;
+  };
+}
diff --git a/pkgs/development/ocaml-modules/zelus/default.nix b/pkgs/development/ocaml-modules/zelus/default.nix
new file mode 100644
index 0000000000000..d326e234c0d02
--- /dev/null
+++ b/pkgs/development/ocaml-modules/zelus/default.nix
@@ -0,0 +1,42 @@
+{ lib
+, stdenv
+, buildDunePackage
+, fetchFromGitHub
+, menhir
+, menhirLib
+}:
+
+buildDunePackage rec {
+  pname = "zelus";
+  version = "2.2";
+
+  minimalOCamlVersion = "4.08.1";
+
+  src = fetchFromGitHub {
+    owner = "INRIA";
+    repo = "zelus";
+    rev = version;
+    hash = "sha256-NcGX343LProADtzJwlq1kmihLaya1giY6xv9ScvdgTA=";
+  };
+
+  # ./configure: cannot execute: required file not found
+  postPatch = lib.optionalString stdenv.isLinux ''
+    patchShebangs configure
+  '';
+
+  nativeBuildInputs = [
+    menhir
+  ];
+
+  buildInputs = [
+    menhirLib
+  ];
+
+  meta = with lib; {
+    description = "A synchronous language with ODEs";
+    homepage = "https://zelus.di.ens.fr";
+    license = licenses.inria-zelus;
+    mainProgram = "zeluc";
+    maintainers = with maintainers; [ wegank ];
+  };
+}
diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix
index f7ce96f135fa7..ae48af74bc0b0 100644
--- a/pkgs/top-level/ocaml-packages.nix
+++ b/pkgs/top-level/ocaml-packages.nix
@@ -1886,6 +1886,10 @@ let
 
     zed = callPackage ../development/ocaml-modules/zed { };
 
+    zelus = callPackage ../development/ocaml-modules/zelus { };
+
+    zelus-gtk = callPackage ../development/ocaml-modules/zelus-gtk { };
+
     zmq = callPackage ../development/ocaml-modules/zmq { };
 
     zmq-lwt = callPackage ../development/ocaml-modules/zmq/lwt.nix { };