summaryrefslogtreecommitdiffstats
path: root/pkgs/development/coq-modules/hierarchy-builder
diff options
context:
space:
mode:
authorCyril Cohen <cohen@crans.org>2020-03-10 15:21:07 +0100
committerVincent Laporte <vbgl@users.noreply.github.com>2020-03-11 17:15:52 +0100
commitcf210c082df58474913f1b371b96c0ba6a4df980 (patch)
treec032991f45e638524a4f8f4193685332bc32b5f1 /pkgs/development/coq-modules/hierarchy-builder
parentc9fc7a2a9cba048f84311efe11fd8cc849bc859b (diff)
coqPackages.hierarchy-builder: init at 0.9.0
Diffstat (limited to 'pkgs/development/coq-modules/hierarchy-builder')
-rw-r--r--pkgs/development/coq-modules/hierarchy-builder/default.nix43
1 files changed, 43 insertions, 0 deletions
diff --git a/pkgs/development/coq-modules/hierarchy-builder/default.nix b/pkgs/development/coq-modules/hierarchy-builder/default.nix
new file mode 100644
index 000000000000..ee9c6cb75cff
--- /dev/null
+++ b/pkgs/development/coq-modules/hierarchy-builder/default.nix
@@ -0,0 +1,43 @@
+{ stdenv, fetchFromGitHub, which, coq, coq-elpi }:
+
+let
+ versions = {
+ "0.9.0" = {
+ rev = "v0.9.0";
+ sha256 = "1yss9f732r7bjaswgn46vd1rr3688ir0vz37wxkmy598xhrnd2ak";
+ };
+ };
+ version = x: versions.${x} // {version = x;};
+ params = {
+ "8.10" = version "0.9.0";
+ "8.11" = version "0.9.0";
+ };
+ param = params.${coq.coq-version};
+in
+
+stdenv.mkDerivation rec {
+ name = "coq${coq.coq-version}-hierarchy-builder-${param.version}";
+
+ src = fetchFromGitHub {
+ owner = "math-comp";
+ repo = "hierarchy-builder";
+ inherit (param) rev sha256;
+ };
+
+ propagatedBuildInputs = [ coq-elpi ];
+ buildInputs = [ coq coq.ocaml coq.ocamlPackages.elpi ];
+
+ installPhase = ''make -f Makefile.coq VFILES=structures.v COQLIB=$out/lib/coq/${coq.coq-version}/ install'';
+
+ meta = {
+ description = "Coq plugin embedding ELPI.";
+ maintainers = [ stdenv.lib.maintainers.cohencyril ];
+ license = stdenv.lib.licenses.lgpl21;
+ inherit (coq.meta) platforms;
+ inherit (src.meta) homepage;
+ };
+
+ passthru = {
+ compatibleCoqVersions = stdenv.lib.flip builtins.hasAttr params;
+ };
+}