aboutsummaryrefslogtreecommitdiff
path: root/doc/stdlib/dune
diff options
context:
space:
mode:
Diffstat (limited to 'doc/stdlib/dune')
-rw-r--r--doc/stdlib/dune20
1 files changed, 14 insertions, 6 deletions
diff --git a/doc/stdlib/dune b/doc/stdlib/dune
index 7fe2493fbf..0b6ca5f178 100644
--- a/doc/stdlib/dune
+++ b/doc/stdlib/dune
@@ -5,7 +5,7 @@
(deps
make-library-index index-list.html.template hidden-files
(source_tree %{project_root}/theories)
- (source_tree %{project_root}/plugins))
+ (source_tree %{project_root}/user-contrib))
(action
(chdir %{project_root}
; On windows run will fail
@@ -13,10 +13,12 @@
(rule
(targets html)
+ (alias stdlib-html)
+ (package coq-doc)
(deps
; This will be replaced soon by `theories/**/*.v` soon, thanks to rgrinberg
(source_tree %{project_root}/theories)
- (source_tree %{project_root}/plugins)
+ (source_tree %{project_root}/user-contrib)
(:header %{project_root}/doc/common/styles/html/coqremote/header.html)
(:footer %{project_root}/doc/common/styles/html/coqremote/footer.html)
; For .glob files, should be gone when Coq Dune is smarter.
@@ -24,13 +26,19 @@
(action
(progn
(run mkdir -p html)
- (bash "%{bin:coqdoc} -q -d html --with-header %{header} --with-footer %{footer} --multi-index --html -g -R %{project_root}/theories Coq -R %{project_root}/plugins Coq $(find %{project_root}/theories %{project_root}/plugins -name *.v)")
+ (bash "%{bin:coqdoc} -q -d html --with-header %{header} --with-footer %{footer} --multi-index --html -g -R %{project_root}/theories Coq -Q %{project_root}/user-contrib/Ltac2 Ltac2 $(find %{project_root}/theories %{project_root}/user-contrib -name *.v)")
(run mv html/index.html html/genindex.html)
(with-stdout-to
_index.html
(progn (cat %{header}) (cat index-list.html) (cat %{footer})))
(run cp _index.html html/index.html))))
-(alias
- (name stdlib-html)
- (deps html))
+; Installable directories are not yet fully supported by Dune. See
+; ocaml/dune#1868. Yet, this makes coq-doc.install a valid target to
+; generate the whole Coq documentation. And the result under
+; _build/install/default/doc/coq-doc looks just right!
+
+(install
+ (files (html as html/stdlib))
+ (section doc)
+ (package coq-doc))