[PATCH libXfont] doc: use fop backend to gen .pdf and .ps documents
Gaetan Nadon
memsize at videotron.ca
Sun Jan 24 12:16:29 PST 2010
As for app-xfs, invoke xmlto with the fop backend.
Also resurrect the postscript version using fop.
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 d47a551..5830cde 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -62,6 +62,9 @@ EXTRA_DIST += doc/fontlib.xml doc/fontlib.xsl doc/fontlib.css
if MAKE_DEVEL_DOCS
if HAVE_XMLTO
noinst_DATA = doc/fontlib.txt doc/fontlib.html $(srcdir)/doc/fontlib.css
+if HAVE_XMLFOP
+noinst_DATA += doc/fontlib.pdf doc/fontlib.ps
+endif
CLEANFILES = doc/fontlib.txt doc/fontlib.html doc/fontlib.pdf doc/fontlib.ps
doc/fontlib.txt: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
@@ -71,9 +74,9 @@ doc/fontlib.html: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
$(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc xhtml-nochunks $(srcdir)/doc/fontlib.xml
doc/fontlib.pdf: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
- $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc pdf $(srcdir)/doc/fontlib.xml
+ $(AM_V_GEN)$(XMLTO) --with-fop -m $(srcdir)/doc/fontlib.xsl -o doc pdf $(srcdir)/doc/fontlib.xml
doc/fontlib.ps: $(srcdir)/doc/fontlib.xml $(srcdir)/doc/fontlib.xsl
- $(AM_V_GEN)$(XMLTO) -m $(srcdir)/doc/fontlib.xsl -o doc ps $(srcdir)/doc/fontlib.xml
+ $(AM_V_GEN)$(XMLTO) --with-fop -m $(srcdir)/doc/fontlib.xsl -o doc ps $(srcdir)/doc/fontlib.xml
endif HAVE_XMLTO
endif MAKE_DEVEL_DOCS
diff --git a/configure.ac b/configure.ac
index 6e39c1d..eb00a72 100644
--- a/configure.ac
+++ b/configure.ac
@@ -58,6 +58,15 @@ AC_ARG_ENABLE(devel-docs,
[DEVEL_DOCS=$enableval], [DEVEL_DOCS=yes])
AM_CONDITIONAL([MAKE_DEVEL_DOCS], [test "x$DEVEL_DOCS" = "xyes"])
+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])
+
# Look for headers
AC_CHECK_HEADERS([endian.h poll.h sys/poll.h])
AC_CHECK_FUNCS([poll])
--
1.6.0.4
Initial post for review
More information about the xorg-devel
mailing list