nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg }:
2let
3 pname = "xmlm";
4 webpage = "http://erratique.ch/software/${pname}";
5in
6
7if !stdenv.lib.versionAtLeast ocaml.version "4.02"
8then throw "xmlm is not available for OCaml ${ocaml.version}"
9else
10
11stdenv.mkDerivation rec {
12 name = "ocaml${ocaml.version}-${pname}-${version}";
13 version = "1.3.0";
14
15 src = fetchurl {
16 url = "${webpage}/releases/${pname}-${version}.tbz";
17 sha256 = "1rrdxg5kh9zaqmgapy9bhdqyxbbvxxib3bdfg1vhw4rrkp1z0x8n";
18 };
19
20 buildInputs = [ ocaml findlib ocamlbuild topkg ];
21
22 inherit (topkg) buildPhase installPhase;
23
24 meta = with stdenv.lib; {
25 description = "An OCaml streaming codec to decode and encode the XML data format";
26 homepage = "${webpage}";
27 platforms = ocaml.meta.platforms or [];
28 maintainers = [ maintainers.vbgl ];
29 license = licenses.bsd3;
30 };
31}