summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/decompress
diff options
context:
space:
mode:
authorVincent Laporte <Vincent.Laporte@gmail.com>2017-07-01 12:57:36 +0000
committerVincent Laporte <Vincent.Laporte@gmail.com>2017-07-01 12:57:36 +0000
commit6eb2d7d44b4cd68af3afd3549dc68c740927de69 (patch)
tree4ab3bd8339570d7aa5e3c3c57445d1b5a7c98338 /pkgs/development/ocaml-modules/decompress
parent982af09d2c87d186539f1fd500996277c6b85472 (diff)
downloadnixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.tar
nixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.tar.gz
nixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.tar.bz2
nixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.tar.lz
nixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.tar.xz
nixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.tar.zst
nixpkgs-6eb2d7d44b4cd68af3afd3549dc68c740927de69.zip
ocamlPackages.decompress: init at 0.6
decompress is a pure OCaml implementation of Zlib.

Homepage: https://github.com/mirage/decompress
Diffstat (limited to 'pkgs/development/ocaml-modules/decompress')
-rw-r--r--pkgs/development/ocaml-modules/decompress/default.nix30
1 files changed, 30 insertions, 0 deletions
diff --git a/pkgs/development/ocaml-modules/decompress/default.nix b/pkgs/development/ocaml-modules/decompress/default.nix
new file mode 100644
index 00000000000..389a136aae6
--- /dev/null
+++ b/pkgs/development/ocaml-modules/decompress/default.nix
@@ -0,0 +1,30 @@
+{ stdenv, fetchFromGitHub, ocaml, findlib, ocamlbuild, topkg, opam
+}:
+
+if !stdenv.lib.versionAtLeast ocaml.version "4.03"
+then throw "decompress is not available for OCaml ${ocaml.version}"
+else
+
+stdenv.mkDerivation rec {
+	version = "0.6";
+	name = "ocaml${ocaml.version}-decompress-${version}";
+
+	src = fetchFromGitHub {
+		owner = "mirage";
+		repo = "decompress";
+		rev = "v${version}";
+		sha256 = "0hfs5zrvimzvjwdg57vrxx9bb7irvlm07dk2yv3s5qhj30zimd08";
+	};
+
+	buildInputs = [ ocaml findlib ocamlbuild topkg opam ];
+
+	inherit (topkg) buildPhase installPhase;
+
+	meta = {
+		description = "Pure OCaml implementation of Zlib";
+		license = stdenv.lib.licenses.mit;
+		maintainers = [ stdenv.lib.maintainers.vbgl ];
+		inherit (src.meta) homepage;
+		inherit (ocaml.meta) platforms;
+	};
+}