about summary refs log tree commit diff
path: root/pkgs/development/ocaml-modules/gapi-ocaml/default.nix
blob: 9c7be26503f5673bfd270f5e9a5f57ede0a9198e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{ stdenv, fetchFromGitHub, ocaml, findlib, jbuilder, ocurl, cryptokit, ocaml_extlib, yojson, ocamlnet, xmlm }:

if !stdenv.lib.versionAtLeast ocaml.version "4.02"
then throw "gapi-ocaml is not available for OCaml ${ocaml.version}"
else

stdenv.mkDerivation rec {
  name = "gapi-ocaml-${version}";
  version = "0.3.6";
  src = fetchFromGitHub {
    owner = "astrada";
    repo = "gapi-ocaml";
    rev = "v${version}";
    sha256 = "0qgsy51bhkpfgl5rdnjw4bqs5fbh2w4vwrfbl8y3lh1wrqmnwci4";
  };
  buildInputs = [ ocaml jbuilder findlib ];
  propagatedBuildInputs = [ ocurl cryptokit ocaml_extlib yojson ocamlnet xmlm ];

  inherit (jbuilder) installPhase;

  meta = {
    description = "OCaml client for google services";
    homepage = http://gapi-ocaml.forge.ocamlcore.org;
    license = stdenv.lib.licenses.mit;
    maintainers = with stdenv.lib.maintainers; [ bennofs ];
    platforms = ocaml.meta.platforms or [];
  };
}