summaryrefslogtreecommitdiffstats
path: root/Documentation/Makefile
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2013-12-20 13:48:46 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-12-20 16:39:56 -0800
commit17dfee415a72c498e1ead9584b3440c25d8a30e0 (patch)
treebd01d266bc78d3cdf632bbf36a3b01eaea2719e1 /Documentation/Makefile
parent5c3ed901b572bf0bb56eddc5d95c7cb0f132d83a (diff)
downloadsubsurface-17dfee415a72c498e1ead9584b3440c25d8a30e0.tar.gz
Include the user-manual.html file in the git tree
This way when building Subsurface asciidoc is not necessary at all - except if you want to work on the user manual and want to see the result of your work. Previously the build wouldn't fail without asciidoc, but there would be no working user manual when pressing F1 from within the application. This solves the problem by shipping the HTML file with the sources. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'Documentation/Makefile')
-rw-r--r--Documentation/Makefile14
1 files changed, 12 insertions, 2 deletions
diff --git a/Documentation/Makefile b/Documentation/Makefile
index 761f43bf6..c3ae22e02 100644
--- a/Documentation/Makefile
+++ b/Documentation/Makefile
@@ -1,3 +1,12 @@
+#
+# in order for "normal" developers not to have to install asciidoc (which
+# brings in a couple hundred MB of dependencies) we now include both the
+# user-manual.txt and a copy of the generated .html file in git
+#
+# in order to avoid unnecessary thrash with minor version differences, when
+# submitting patches to the user manual, only submit the changes to the .txt
+# file - the maintainer will recreate the .html.git file
+
DOCNAME = user-manual
DOCSOURCE = $(DOCNAME).txt
HTMLDOC = $(DOCNAME).html
@@ -18,8 +27,9 @@ $(OUT)$(DOCNAME).pdf: $(DOCSOURCE)
$(A2X) -f pdf $<
$(OUT)$(HTMLDOC): $(DOCSOURCE)
- @echo "if asciidoc isn't found no HTML documentation is produced but Subsurface is still functional"
- $(ASCIIDOC) -a toc -a toclevels=3 -a themedir=$(PWD) -a theme=$(THEME) -a stylesdir=$(PWD) $< || true
+ @echo "if asciidoc isn't found the html file included in the sources is copied"
+ $(ASCIIDOC) -a toc -a toclevels=3 -a themedir=$(PWD) -a theme=$(THEME) -a stylesdir=$(PWD) \
+ -o $(HTMLDOC) $< || cp $(HTMLDOC).git $(HTMLDOC)
# Alternatively::
$(OUT)$(DOCNAME).xhtml: $(DOCSOURCE)