2015-11-30 18:07:36 +01:00
|
|
|
{ stdenv, fetchzip, ocaml, findlib, cppo, easy-format, biniou }:
|
2014-07-05 08:50:47 +02:00
|
|
|
let
|
|
|
|
pname = "yojson";
|
2015-11-30 18:07:36 +01:00
|
|
|
version = "1.2.3";
|
2014-07-05 08:50:47 +02:00
|
|
|
in
|
2014-08-19 18:39:45 +02:00
|
|
|
stdenv.mkDerivation {
|
2014-07-05 08:50:47 +02:00
|
|
|
|
2014-08-19 18:39:45 +02:00
|
|
|
name = "ocaml-${pname}-${version}";
|
2014-07-05 08:50:47 +02:00
|
|
|
|
2015-11-30 18:07:36 +01:00
|
|
|
src = fetchzip {
|
|
|
|
url = "https://github.com/mjambon/${pname}/archive/v${version}.tar.gz";
|
|
|
|
sha256 = "10dvkndgwanvw4agbjln7kgb1n9s6lii7jw82kwxczl5rd1sgmvl";
|
2014-07-05 08:50:47 +02:00
|
|
|
};
|
|
|
|
|
2014-08-19 18:39:45 +02:00
|
|
|
buildInputs = [ ocaml findlib ];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ cppo easy-format biniou ];
|
2014-07-05 08:50:47 +02:00
|
|
|
|
|
|
|
createFindlibDestdir = true;
|
|
|
|
|
|
|
|
makeFlags = "PREFIX=$(out)";
|
|
|
|
|
|
|
|
preBuild = ''
|
|
|
|
mkdir $out/bin
|
|
|
|
'';
|
|
|
|
|
2014-09-21 12:02:55 +02:00
|
|
|
meta = with stdenv.lib; {
|
2014-07-05 08:50:47 +02:00
|
|
|
description = "An optimized parsing and printing library for the JSON format";
|
2015-11-30 18:07:36 +01:00
|
|
|
homepage = "http://mjambon.com/${pname}.html";
|
2014-09-21 12:02:55 +02:00
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = [ maintainers.vbgl ];
|
2015-12-24 18:49:07 +01:00
|
|
|
platforms = ocaml.meta.platforms or [];
|
2014-07-05 08:50:47 +02:00
|
|
|
};
|
|
|
|
}
|