mirror of
https://git.openafs.org/openafs.git
synced 2025-01-18 23:10:58 +00:00
0754537c11
Check for kindlegen in configure and do nothing in the MOBI build rule if the binary didn't exist. This is still a bit of a hack since the rule will run with every invocation of make. The target needs to be made conditional. But at least this way make all in the documentation directory doesn't fail. Change-Id: I57f158929b3907678b9848a60edb9765136f7dbb Reviewed-on: http://gerrit.openafs.org/5090 Reviewed-by: Derrick Brashear <shadow@dementix.org> Tested-by: Derrick Brashear <shadow@dementix.org>
60 lines
1.7 KiB
Makefile
60 lines
1.7 KiB
Makefile
# Makefile to build the AFS QuickStart guide for Unix.
|
|
#
|
|
# This makefile assumes that various utilities are available on the system.
|
|
# On Debian lenny, installing the packages:
|
|
#
|
|
# dblatex
|
|
# docbook-xsl
|
|
# libxml2-utils
|
|
# xsltproc
|
|
#
|
|
# gave me all the utilities needed.
|
|
#
|
|
# 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.
|
|
|
|
BOOK = auqbg000
|
|
|
|
all: $(BOOK).pdf index.html $(BOOK).epub $(BOOK).mobi
|
|
|
|
include @TOP_OBJDIR@/src/config/Makefile.config
|
|
VERSION=version
|
|
include @TOP_OBJDIR@/src/config/Makefile.version
|
|
|
|
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
|
|
|
|
index.html: $(SRCS)
|
|
$(XSLTPROC) --param navig.graphics 1 \
|
|
--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
|
|
|
|
$(BOOK).mobi: $(BOOK).epub
|
|
if test -n "$(KINDLEGEN)" && test -x "$(DBTOEPUB)" ; then \
|
|
kindlegen $(BOOK).epub -o $(BOOK).mobi; \
|
|
fi
|
|
|
|
check:
|
|
xmllint --noout --valid $(BOOK).xml
|
|
|
|
clean:
|
|
rm -f *.aux *.epub *.fo *.html *.log *.mobi *.out *.pdf
|