3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/tools/ocaml/cppo/default.nix

39 lines
901 B
Nix
Raw Normal View History

{ stdenv, fetchFromGitHub, ocaml, findlib, ocamlbuild }:
2014-06-25 09:25:14 +01:00
let
pname = "cppo";
2017-04-28 17:10:41 +01:00
version = "1.5.0";
2014-06-25 09:25:14 +01:00
webpage = "http://mjambon.com/${pname}.html";
in
2017-04-28 17:10:41 +01:00
assert stdenv.lib.versionAtLeast ocaml.version "3.12";
2014-06-25 09:25:14 +01:00
stdenv.mkDerivation rec {
name = "${pname}-${version}";
2016-05-22 16:22:25 +01:00
src = fetchFromGitHub {
owner = "mjambon";
repo = pname;
rev = "v${version}";
2017-04-28 17:10:41 +01:00
sha256 = "1xqldjz9risndnabvadw41fdbi5sa2hl4fnqls7j9xfbby1izbg8";
2014-06-25 09:25:14 +01:00
};
buildInputs = [ ocaml findlib ocamlbuild ];
2014-06-25 09:25:14 +01:00
createFindlibDestdir = true;
makeFlags = "PREFIX=$(out)";
preBuild = ''
mkdir $out/bin
'';
meta = with stdenv.lib; {
2014-06-25 09:25:14 +01:00
description = "The C preprocessor for OCaml";
longDescription = ''
Cppo is an equivalent of the C preprocessor targeted at the OCaml language and its variants.
'';
homepage = "${webpage}";
maintainers = [ maintainers.vbgl ];
license = licenses.bsd3;
2014-06-25 09:25:14 +01:00
};
}