about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/ocaml-modules/pgocaml/default.nix
blob: f4d1ef829bb461e5f11379548537cf9ffc4bce4f (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, fetchurl, buildOcaml, ocaml, calendar, csv, re }:

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

buildOcaml {
  name = "pgocaml";
  version = "2.3";
  src = fetchurl {
    url = https://github.com/darioteixeira/pgocaml/archive/v2.3.tar.gz;
    sha256 = "18lymxlvcf4nwxawkidq3pilsp5rhl0l8ifq6pjk3ssjlx9w53pg";
  };

  buildInputs = [ ];
  propagatedBuildInputs = [ calendar csv re ];

  configureFlags = [ "--enable-p4" ];

  createFindlibDestdir = true;

  meta = with stdenv.lib; {
    description = "An interface to PostgreSQL databases for OCaml applications";
    homepage = http://pgocaml.forge.ocamlcore.org/;
    license = licenses.lgpl2;
    maintainers = with maintainers; [ vbgl ];
  };
}