summary refs log tree commit diff
path: root/pkgs/development/coq-modules
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
parentc9fc7a2a9cba048f84311efe11fd8cc849bc859b (diff)
downloadnixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.tar
nixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.tar.gz
nixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.tar.bz2
nixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.tar.lz
nixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.tar.xz
nixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.tar.zst
nixpkgs-cf210c082df58474913f1b371b96c0ba6a4df980.zip
coqPackages.hierarchy-builder: init at 0.9.0
Diffstat (limited to 'pkgs/development/coq-modules')
-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 00000000000..ee9c6cb75cf
--- /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;
+  };
+}