nixpkgs/pkgs/development/ocaml-modules/cohttp/default.nix

31 lines
1,016 B
Nix
Raw Normal View History

2016-11-12 09:55:42 +01:00
{ stdenv, buildOcaml, fetchurl, ocaml, cmdliner, re, uri, fieldslib_p4
, sexplib_p4, conduit , stringext, base64, magic-mime, ounit, alcotest
, asyncSupport ? stdenv.lib.versionAtLeast ocaml.version "4.02"
, lwt ? null, async_p4 ? null, async_ssl_p4 ? null
}:
buildOcaml rec {
name = "cohttp";
2016-01-12 16:14:07 +01:00
version = "0.19.3";
2016-11-12 09:55:42 +01:00
minimumSupportedOcamlVersion = "4.01";
src = fetchurl {
url = "https://github.com/mirage/ocaml-cohttp/archive/v${version}.tar.gz";
2016-01-12 16:14:07 +01:00
sha256 = "1nrzpd4h52c1hnzcgsz462676saj9zss708ng001h54dglk8i1iv";
};
2016-11-12 09:55:42 +01:00
buildInputs = [ alcotest cmdliner conduit magic-mime ounit lwt ]
++ stdenv.lib.optionals asyncSupport [ async_p4 async_ssl_p4 ];
propagatedBuildInputs = [ re stringext uri fieldslib_p4 sexplib_p4 base64 ];
buildFlags = "PREFIX=$(out)";
meta = with stdenv.lib; {
homepage = https://github.com/mirage/ocaml-cohttp;
description = "Very lightweight HTTP server using Lwt or Async";
license = licenses.mit;
maintainers = [ maintainers.ericbmerritt ];
};
}