summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/imagelib/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/ocaml-modules/imagelib/default.nix')
-rw-r--r--pkgs/development/ocaml-modules/imagelib/default.nix26
1 files changed, 26 insertions, 0 deletions
diff --git a/pkgs/development/ocaml-modules/imagelib/default.nix b/pkgs/development/ocaml-modules/imagelib/default.nix
new file mode 100644
index 000000000000..77b18f0ce3a9
--- /dev/null
+++ b/pkgs/development/ocaml-modules/imagelib/default.nix
@@ -0,0 +1,26 @@
+{ stdenv, fetchFromGitHub, which, ocaml, findlib, ocamlbuild, decompress }:
+
+stdenv.mkDerivation rec {
+  version = "20171028";
+  name = "ocaml${ocaml.version}-imagelib-${version}";
+  src = fetchFromGitHub {
+    owner = "rlepigre";
+    repo = "ocaml-imagelib";
+    rev = "ocaml-imagelib_${version}";
+    sha256 = "1frkrgcrv4ybdmqcfxpfsywx0hm1arxgxp32n8kzky6qip1g0zxf";
+  };
+
+  buildInputs = [ which ocaml findlib ocamlbuild ];
+
+  propagatedBuildInputs = [ decompress ];
+
+  createFindlibDestdir = true;
+
+  meta = {
+    description = "Image formats such as PNG and PPM in OCaml";
+    license = stdenv.lib.licenses.lgpl3;
+    maintainers = [ stdenv.lib.maintainers.vbgl ];
+    inherit (src.meta) homepage;
+    inherit (ocaml.meta) platforms;
+  };
+}