buildDunePackage: new support function; use it to refactor some OCaml derivations
This commit is contained in:
@@ -1,26 +1,22 @@
|
||||
{ stdenv, fetchFromGitHub, ocaml, findlib, dune, cppo
|
||||
, bos, cmdliner, tyxml
|
||||
}:
|
||||
{ stdenv, fetchFromGitHub, buildDunePackage, cppo, bos, cmdliner, tyxml }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "ocaml${ocaml.version}-odoc-${version}";
|
||||
buildDunePackage rec {
|
||||
pname = "odoc";
|
||||
version = "1.3.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ocaml";
|
||||
repo = "odoc";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
sha256 = "0hjan5aj5zk8j8qyagv9r4hqm469mh207cv2m6kxwgnw0c3cz7sy";
|
||||
};
|
||||
|
||||
buildInputs = [ ocaml findlib dune cppo bos cmdliner tyxml ];
|
||||
|
||||
inherit (dune) installPhase;
|
||||
buildInputs = [ cppo bos cmdliner tyxml ];
|
||||
|
||||
meta = {
|
||||
description = "A documentation generator for OCaml";
|
||||
license = stdenv.lib.licenses.isc;
|
||||
maintainers = [ stdenv.lib.maintainers.vbgl ];
|
||||
inherit (ocaml.meta) platforms;
|
||||
inherit (src.meta) homepage;
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user