2021-02-05 17:12:51 +00:00
|
|
|
{ stdenv, lib, pkg-config, ocaml, findlib, fetchurl, curl, ncurses, lwt }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
if lib.versionOlder ocaml.version "4.02"
|
2020-04-24 23:36:52 +00:00
|
|
|
then throw "ocurl is not available for OCaml ${ocaml.version}"
|
|
|
|
else
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2021-12-06 16:07:01 +00:00
|
|
|
pname = "ocurl";
|
|
|
|
version = "0.9.1";
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
src = fetchurl {
|
2021-12-06 16:07:01 +00:00
|
|
|
url = "http://ygrek.org.ua/p/release/ocurl/ocurl-${version}.tar.gz";
|
2020-05-29 06:06:01 +00:00
|
|
|
sha256 = "0n621cxb9012pj280c7821qqsdhypj8qy9qgrah79dkh6a8h2py6";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
nativeBuildInputs = [ pkg-config ocaml findlib ];
|
|
|
|
buildInputs = [ ncurses ];
|
2021-01-17 00:15:33 +00:00
|
|
|
propagatedBuildInputs = [ curl lwt ];
|
2022-03-05 16:20:37 +00:00
|
|
|
|
|
|
|
strictDeps = true;
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
createFindlibDestdir = true;
|
|
|
|
meta = {
|
|
|
|
description = "OCaml bindings to libcurl";
|
2021-01-15 22:18:51 +00:00
|
|
|
license = lib.licenses.mit;
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "http://ygrek.org.ua/p/ocurl/";
|
2021-01-15 22:18:51 +00:00
|
|
|
maintainers = with lib.maintainers; [ bennofs ];
|
2021-12-06 16:07:01 +00:00
|
|
|
platforms = ocaml.meta.platforms or [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|