auth: fix cellservdb update check
[openafs.git] / doc / xml / QuickStartUnix / Makefile.in
index 30cb05c..c494977 100644 (file)
 # HTML_XSL is specific to Debian and will need to be modified on other
 # systems until we have a better mechanism for finding the correct path.
 
-all: pdf html
+BOOK = auqbg000
+
+all: $(BOOK).pdf index.html $(BOOK).epub $(BOOK).mobi
 
 include @TOP_OBJDIR@/src/config/Makefile.config
-VERSFILE=version
+VERSION=version
 include @TOP_OBJDIR@/src/config/Makefile.version
 
-BOOK     = auqbg000.xml
-SRCS     = $(BOOK) auqbg003.xml auqbg004.xml auqbg005.xml auqbg006.xml \
-          auqbg007.xml auqbg008.xml appendix.xml
+SRCS     = $(BOOK).xml auqbg003.xml auqbg004.xml auqbg005.xml auqbg006.xml \
+          auqbg007.xml auqbg008.xml appendix.xml appendix_dafs.xml \
+          $(VERSION).xml
 HTML_XSL = @HTML_XSL@
+DOCBOOK_STYLESHEETS = @DOCBOOK_STYLESHEETS@
 XSLTPROC = @XSLTPROC@
+DOCBOOK2PDF = @DOCBOOK2PDF@
+DBTOEPUB = $(DOCBOOK_STYLESHEETS)/epub/bin/dbtoepub
+KINDLEGEN = @KINDLEGEN@
 
-html: $(SRCS) $(VERSFILE).xml
+index.html: $(SRCS)
        $(XSLTPROC) --param navig.graphics 1 \
-           --stringparam navig.graphics.path ../ $(HTML_XSL) $(BOOK)
+           --stringparam navig.graphics.path ../ $(DOCBOOK_STYLESHEETS)/$(HTML_XSL) $(BOOK).xml
+
+$(BOOK).pdf: $(SRCS)
+       if test "x$(DOCBOOK2PDF)" = "xfop"; then \
+               $(XSLTPROC) $(DOCBOOK_STYLESHEETS)/fo/docbook.xsl $(BOOK).xml > $(BOOK).fo; \
+               $(DOCBOOK2PDF) $(BOOK).fo $(BOOK).pdf; \
+       else \
+               $(DOCBOOK2PDF) $(BOOK).xml; \
+       fi
+
+$(BOOK).epub: $(SRCS)
+       if test -x "$(DBTOEPUB)" ; then \
+               $(DBTOEPUB) -s $(TOP_SRCDIR)/../doc/xml/mobi-fixup.xsl $(BOOK).xml; \
+       fi
 
-pdf: $(SRCS)
-       dblatex $(BOOK)
+$(BOOK).mobi: $(BOOK).epub
+       if test -n "$(KINDLEGEN)" && test -x "$(DBTOEPUB)" ; then \
+               $(KINDLEGEN) $(BOOK).epub -o $(BOOK).mobi; \
+       fi
 
 check:
-       xmllint --noout --valid $(BOOK)
+       xmllint --noout --valid $(BOOK).xml
 
 clean:
-       rm -f *.html *.pdf
+       rm -f *.aux *.epub *.fo *.html *.log *.mobi *.out *.pdf