Windows: Track Mixed RO Volume Release State
[openafs.git] / doc / xml / UserGuide / Makefile.in
1 # Makefile to build the AFS Admin Guide for Unix.
2 #
3 # This makefile assumes that various utilities are available on the system.
4 # On Debian lenny, installing the packages:
5 #
6 #     dblatex
7 #     docbook-xsl
8 #     libxml2-utils
9 #     xsltproc
10 #
11 # gave me all the utilities needed.
12 #
13 # HTML_XSL is possibly specific to Debian and may need to be modified on other
14 # systems.
15
16 BOOK = auusg000
17
18 all: $(BOOK).pdf index.html $(BOOK).epub $(BOOK).mobi
19
20 include @TOP_OBJDIR@/src/config/Makefile.config
21 VERSION=version
22 include @TOP_OBJDIR@/src/config/Makefile.version
23
24 SRCS     = $(BOOK).xml auusg003.xml auusg004.xml auusg005.xml auusg006.xml \
25            auusg007.xml auusg008.xml auusg009.xml auusg010.xml auusg011.xml \
26            auusg012.xml $(VERSION).xml
27 HTML_XSL = @HTML_XSL@
28 DOCBOOK_STYLESHEETS = @DOCBOOK_STYLESHEETS@
29 XSLTPROC = @XSLTPROC@
30 DOCBOOK2PDF = @DOCBOOK2PDF@
31 DBTOEPUB = $(DOCBOOK_STYLESHEETS)/epub/bin/dbtoepub
32
33 index.html: $(SRCS)
34         $(XSLTPROC) --param navig.graphics 1 \
35             --stringparam navig.graphics.path ../ $(DOCBOOK_STYLESHEETS)/$(HTML_XSL) $(BOOK).xml
36
37 $(BOOK).pdf: $(SRCS)
38         if test "x$(DOCBOOK2PDF)" = "xfop"; then \
39                 $(XSLTPROC) $(DOCBOOK_STYLESHEETS)/fo/docbook.xsl $(BOOK).xml > $(BOOK).fo; \
40                 $(DOCBOOK2PDF) $(BOOK).fo $(BOOK).pdf; \
41         else \
42                 $(DOCBOOK2PDF) $(BOOK).xml; \
43         fi
44
45 $(BOOK).epub: $(SRCS)
46         if test -x "$(DBTOEPUB)" ; then \
47                 $(DBTOEPUB) -s $(TOP_SRCDIR)/../doc/xml/mobi-fixup.xsl $(BOOK).xml; \
48         fi
49
50 $(BOOK).mobi: $(BOOK).epub
51         if test -n "$(KINDLEGEN)" && test -x "$(DBTOEPUB)" ; then \
52                 kindlegen $(BOOK).epub -o $(BOOK).mobi; \
53         fi
54
55 check:
56         xmllint --noout --valid $(BOOK).xml
57
58 clean:
59         rm -f *.aux *.epub *.fo *.html *.log *.mobi *.out *.pdf