[PATCH app-xfs 2/2] doc: use fop backend to convert xml to pdf
Gaetan Nadon
memsize at videotron.ca
Fri Jan 22 06:34:43 PST 2010
The default is passiveTex which does not work.
Add XMLFOP and HAVE_XMLFOP to skip pdf if fop is missing.
Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
---
Makefile.am | 7 +++++--
configure.ac | 9 +++++++++
2 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index fe4639c..41abd05 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -175,7 +175,10 @@ EXTRA_DIST += doc/xfs-design.xml doc/xfs-design.css doc/xfs-design.xsl
if MAKE_DEVEL_DOCS
if HAVE_XMLTO
-noinst_DATA = doc/xfs-design/index.html doc/xfs-design.pdf doc/xfs-design.txt
+noinst_DATA = doc/xfs-design/index.html doc/xfs-design.txt
+if HAVE_XMLFOP
+noinst_DATA += doc/xfs-design.pdf
+endif HAVE_XMLFOP
CLEANFILES += $(noinst_DATA)
doc/xfs-design/index.html: $(srcdir)/doc/xfs-design.xml $(srcdir)/doc/xfs-design.xsl doc/xfs-design/xfs-design.css
@@ -190,7 +193,7 @@ clean-local:
-rm -rf doc/xfs-design
doc/xfs-design.pdf: $(srcdir)/doc/xfs-design.xml $(srcdir)/doc/xfs-design.xsl
- $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/xfs-design.xsl -o doc pdf $(srcdir)/doc/xfs-design.xml
+ $(AM_V_GEN)$(XMLTO) --with-fop -m $(srcdir)/doc/xfs-design.xsl -o doc pdf $(srcdir)/doc/xfs-design.xml
doc/xfs-design.txt: $(srcdir)/doc/xfs-design.xml $(srcdir)/doc/xfs-design.xsl
$(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/xfs-design.xsl -o doc txt $(srcdir)/doc/xfs-design.xml
diff --git a/configure.ac b/configure.ac
index b429ed5..85bcac6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -95,6 +95,15 @@ AC_ARG_WITH(default-font-path, AS_HELP_STRING([--with-default-font-path=PATH], [
[ FONTPATH="${DEFAULT_FONT_PATH}" ])
AC_SUBST([FONTPATH])
+AC_PATH_PROG([XMLFOP], [fop])
+if test "x$XMLFOP" = "x"; then
+ AC_MSG_WARN([fop not found - pdf documentation targets will be skipped])
+ have_xmlfop=no
+else
+ have_xmlfop=yes
+fi
+AM_CONDITIONAL([HAVE_XMLFOP], [test "$have_xmlfop" = yes])
+
# Option to enable support for building developer internals docs
AC_ARG_ENABLE(devel-docs,
AS_HELP_STRING([--enable-devel-docs],
--
1.6.0.4
Revised series with pdf enabled
More information about the xorg-devel
mailing list