diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2014-06-06 10:54:51 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-06-06 10:54:51 -0700 |
commit | 20bbff27730a8ad59c0a1fcd36c476609933babd (patch) | |
tree | 9c72951e3b2703de5ebc3f3f611077f22fbdb908 /Documentation/Makefile | |
parent | 2f1d7c0bdc1a9ae3aa8901facedbb5b48bd3c87b (diff) | |
download | subsurface-20bbff27730a8ad59c0a1fcd36c476609933babd.tar.gz |
User manual: update Makefile for multi language support
New translations need to be explicitly added to the Makefile
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'Documentation/Makefile')
-rw-r--r-- | Documentation/Makefile | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/Documentation/Makefile b/Documentation/Makefile index 204aeb8e8..5ef7c384e 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -7,29 +7,32 @@ # 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 +DOCNAMES = user-manual user-manual_es + +HTMLDOCS = $(patsubst %,$(OUT)%.html,$(DOCNAMES)) +TEXTDOCS = $(patsubst %,$(OUT)%.text,$(DOCNAMES)) +PDFDOCS = $(patsubst %,$(OUT)%.pdf,$(DOCNAMES)) + ASCIIDOC = asciidoc A2X = a2x BROWSER = firefox THEME = compact_subsurface PWD = $(realpath .) -all: doc $(addprefix $(DOCNAME).,pdf text) +all: $(HTMLEDOCS) $(TEXTDOCS) $(PDFDOCS) -doc: $(OUT)$(HTMLDOC) +doc: $(HTMLDOCS) -$(OUT)$(DOCNAME).text: $(DOCSOURCE) +$(OUT)%.text: %.txt $(A2X) -f text $< -$(OUT)$(DOCNAME).pdf: $(DOCSOURCE) - $(A2X) -f pdf $< +$(OUT)%.pdf: %.txt + $(A2X) --dblatex-opts "-P latex.output.revhistory=0" -f pdf $< -$(OUT)$(HTMLDOC): $(DOCSOURCE) +$(OUT)%.html: %.txt @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 $(OUT)$(HTMLDOC) $< || cp $(HTMLDOC).git $(OUT)$(HTMLDOC) + -o $@ $< || cp $@.git $@ # Alternatively:: $(OUT)$(DOCNAME).xhtml: $(DOCSOURCE) @@ -39,4 +42,4 @@ show: $(HTMLDOC) $(BROWSER) $< clean: - rm -f *~ docbook-xsl.css $(HTMLDOC) $(addprefix $(DOCNAME).,pdf text) + rm -f *~ docbook-xsl.css $(HTMLDOCS) $(TEXTDOCS) $(PDFDOCS) |