aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Chinner <dchinner@redhat.com>2014-02-04 17:20:37 +1100
committerDave Chinner <david@fromorbit.com>2014-02-04 17:20:37 +1100
commit6274cfacddc4598c2bee871bab8c2d1b65038c0f (patch)
tree0920b05562aff19636baef5ae67eeeb44ea7834a
parent614d79afd00b9bb67c890423eb2bd4359b36d5f6 (diff)
downloadxfs-documentation-6274cfacddc4598c2bee871bab8c2d1b65038c0f.tar.gz
doc: use a2x to build targets
Use the a2x toolchain wrapper to convert the asciidoc via docbook formats. This allows for asciidoc book format output, automatci generation of table of contents and a whole raft of documentation target formats. Signed-off-by: Dave Chinner <dchinner@redhat.com> Signed-off-by: Dave Chinner <david@fromorbit.com>
-rw-r--r--.gitignore2
-rw-r--r--design/Makefile16
2 files changed, 12 insertions, 6 deletions
diff --git a/.gitignore b/.gitignore
index 2d19fc7..a2e10b4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,3 @@
*.html
+*.pdf
+*.css
diff --git a/design/Makefile b/design/Makefile
index 7fafba2..eab25ba 100644
--- a/design/Makefile
+++ b/design/Makefile
@@ -4,17 +4,21 @@
DOCFILES=$(wildcard *.asciidoc)
HTML_TARGETS=$(addsuffix .html, $(basename $(DOCFILES)))
+PDF_TARGETS=$(addsuffix .pdf, $(basename $(DOCFILES)))
-# just use asciidoc defaults right now to get us up and running.
-# We'll want to move to a2x to generate the output in future so we can add
-# things like table of contents and format directly into pdf, etc.
%.html: %.asciidoc
@echo "[html] $*"
- $(Q)asciidoc $<
+ $(Q)a2x -f xhtml $<
-all: html
+%.pdf: %.asciidoc
+ @echo "[pdf] $*"
+ $(Q)a2x -f pdf $<
+
+all: html pdf
html: $(HTML_TARGETS)
+pdf: $(PDF_TARGETS)
+
clean:
- @rm -f *.html
+ @rm -f *.html *.css