nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ stdenv, fetchFromGitHub, ocaml, findlib, ocamlbuild, topkg
2}:
3
4if !stdenv.lib.versionAtLeast ocaml.version "4.03"
5then throw "decompress is not available for OCaml ${ocaml.version}"
6else
7
8stdenv.mkDerivation rec {
9 version = "0.6";
10 name = "ocaml${ocaml.version}-decompress-${version}";
11
12 src = fetchFromGitHub {
13 owner = "mirage";
14 repo = "decompress";
15 rev = "v${version}";
16 sha256 = "0hfs5zrvimzvjwdg57vrxx9bb7irvlm07dk2yv3s5qhj30zimd08";
17 };
18
19 buildInputs = [ ocaml findlib ocamlbuild topkg ];
20
21 inherit (topkg) buildPhase installPhase;
22
23 meta = {
24 description = "Pure OCaml implementation of Zlib";
25 license = stdenv.lib.licenses.mit;
26 maintainers = [ stdenv.lib.maintainers.vbgl ];
27 inherit (src.meta) homepage;
28 inherit (ocaml.meta) platforms;
29 };
30}