about summary refs log tree commit diff
path: root/pkgs/development/coq-modules/mathcomp
diff options
context:
space:
mode:
authorVincent Laporte <Vincent.Laporte@gmail.com>2015-05-28 14:11:58 +0200
committerVincent Laporte <Vincent.Laporte@gmail.com>2015-06-19 18:11:33 +0200
commit0f6b981fbabf22cc816fe09846e6452e22ea6ae2 (patch)
tree94fc59565bfc8a1a6d40a018a9019e165962791e /pkgs/development/coq-modules/mathcomp
parente6b29c024be556362552b6879534e4d372bd8dfd (diff)
downloadnixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.tar
nixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.tar.gz
nixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.tar.bz2
nixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.tar.lz
nixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.tar.xz
nixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.tar.zst
nixlib-0f6b981fbabf22cc816fe09846e6452e22ea6ae2.zip
coq-mathcomp: also build and install the documentation
Diffstat (limited to 'pkgs/development/coq-modules/mathcomp')
-rw-r--r--pkgs/development/coq-modules/mathcomp/default.nix11
1 files changed, 10 insertions, 1 deletions
diff --git a/pkgs/development/coq-modules/mathcomp/default.nix b/pkgs/development/coq-modules/mathcomp/default.nix
index 02d06edd538b..9ebfba98d836 100644
--- a/pkgs/development/coq-modules/mathcomp/default.nix
+++ b/pkgs/development/coq-modules/mathcomp/default.nix
@@ -1,4 +1,6 @@
-{stdenv, fetchurl, coq, ssreflect}:
+{ stdenv, fetchurl, coq, ssreflect
+, graphviz, ocaml, withDoc ? true
+}:
 
 stdenv.mkDerivation {
 
@@ -9,12 +11,19 @@ stdenv.mkDerivation {
     sha256 = "1297svwi18blrlyd8vsqilar2h5nfixlvlifdkbx47aljq4m5bam";
   };
 
+  nativeBuildInputs = stdenv.lib.optionals withDoc [ graphviz ocaml ];
   propagatedBuildInputs = [ coq ssreflect ];
 
   enableParallelBuilding = true;
 
+  buildFlags = stdenv.lib.optionalString withDoc "doc";
+
   installFlags = "COQLIB=$(out)/lib/coq/${coq.coq-version}/";
 
+  postInstall = stdenv.lib.optionalString withDoc ''
+    make -f Makefile.coq install-doc DOCDIR=$out/share/coq/${coq.coq-version}/
+  '';
+
   meta = with stdenv.lib; {
     homepage = http://ssr.msr-inria.inria.fr/;
     license = licenses.cecill-b;