summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/lun
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2023-11-21 16:12:21 +0100
committerAlyssa Ross <hi@alyssa.is>2023-11-21 16:12:48 +0100
commit048a4cd441a59cbf89defb18bb45c9f0b4429b35 (patch)
treef8f5850ff05521ab82d65745894714a8796cbfb6 /pkgs/development/ocaml-modules/lun
parent030c5028b07afcedce7c5956015c629486cc79d9 (diff)
parent4c2d05dd6435d449a3651a6dd314d9411b5f8146 (diff)
downloadnixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.tar
nixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.tar.gz
nixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.tar.bz2
nixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.tar.lz
nixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.tar.xz
nixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.tar.zst
nixpkgs-048a4cd441a59cbf89defb18bb45c9f0b4429b35.zip
Rebase onto e4ad989506ec7d71f7302cc3067abd82730a4beb HEAD rootfs
Signed-off-by: Alyssa Ross <hi@alyssa.is>
Diffstat (limited to 'pkgs/development/ocaml-modules/lun')
-rw-r--r--pkgs/development/ocaml-modules/lun/default.nix20
-rw-r--r--pkgs/development/ocaml-modules/lun/ppx.nix17
2 files changed, 37 insertions, 0 deletions
diff --git a/pkgs/development/ocaml-modules/lun/default.nix b/pkgs/development/ocaml-modules/lun/default.nix
new file mode 100644
index 00000000000..aab83d4c3cd
--- /dev/null
+++ b/pkgs/development/ocaml-modules/lun/default.nix
@@ -0,0 +1,20 @@
+{ lib, buildDunePackage, fetchurl }:
+
+buildDunePackage rec {
+  pname = "lun";
+  version = "0.0.1";
+
+  minimalOCamlVersion = "4.12.0";
+
+  src = fetchurl {
+    url = "https://github.com/robur-coop/lun/releases/download/v${version}/lun-${version}.tbz";
+    hash = "sha256-zKi63/g7Rw/c+xhAEW+Oim8suGzeL0TtKM8my/aSp5M=";
+  };
+
+  meta = {
+    description = "Optics in OCaml";
+    homepage = "https://git.robur.coop/robur/lun";
+    license = lib.licenses.isc;
+    maintainers = with lib.maintainers; [ marsam ];
+  };
+}
diff --git a/pkgs/development/ocaml-modules/lun/ppx.nix b/pkgs/development/ocaml-modules/lun/ppx.nix
new file mode 100644
index 00000000000..fc138f1a6f8
--- /dev/null
+++ b/pkgs/development/ocaml-modules/lun/ppx.nix
@@ -0,0 +1,17 @@
+{ lib, buildDunePackage, fetchurl, fmt, lun, ppxlib }:
+
+buildDunePackage {
+  pname = "ppx_lun";
+  inherit (lun) version src;
+
+  propagatedBuildInputs = [ lun ppxlib ];
+
+  checkInputs = [ fmt ];
+
+  doCheck = true;
+
+  meta = lun.meta // {
+    description = "Optics with lun package and PPX";
+    license = lib.licenses.mit;
+  };
+}