From f9930accfd196d212ceba895762ee9673faf4066 Mon Sep 17 00:00:00 2001 From: "Chas Williams (CONTRACTOR)" Date: Thu, 2 Jun 2011 19:00:47 -0400 Subject: [PATCH] doc: let configure find the XML tools if possible configure should attempt to find the XML tools we need to process the documentation. if it can't, it should provide a safe default. still allow the user to override via command line. Reviewed-on: http://gerrit.openafs.org/4766 Tested-by: BuildBot Reviewed-by: Simon Wilkinson Reviewed-by: Derrick Brashear (cherry picked from commit cc2bc3e17ff5f7a10c515e309f8fec47a6fa14b6) Change-Id: I4773affa193b5210da6416dd8b4321bd3f471429 Reviewed-on: http://gerrit.openafs.org/4794 Tested-by: BuildBot Reviewed-by: Derrick Brashear --- acinclude.m4 | 10 ++++++++-- doc/xml/AdminGuide/Makefile.in | 3 ++- doc/xml/QuickStartUnix/Makefile.in | 3 ++- doc/xml/UserGuide/Makefile.in | 3 ++- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 1dd4bfe61d..98a4e0dadb 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -231,12 +231,11 @@ AC_ARG_ENABLE([linux-syscall-probing], , [enable_linux_syscall_probing="maybe"]) - AC_ARG_WITH([xslt-processor], AS_HELP_STRING([--with-xslt-processor=ARG], [which XSLT processor to use (possible choices are: libxslt, saxon, xalan-j, xsltproc)]), XSLTPROC="$withval", - XSLTPROC="libxslt") + AC_CHECK_PROGS([XSLTPROC], [libxslt saxon xalan-j xsltproc], [echo])) AC_ARG_WITH([html-xsl], AS_HELP_STRING([--with-html-xsl], @@ -244,6 +243,12 @@ AC_ARG_WITH([html-xsl], HTML_XSL="$withval", HTML_XSL=no) +AC_ARG_WITH([docbook2pdf], + AS_HELP_STRING([--with-docbook2pdf=ARG], + [which Docbook to PDF utility to use (possible choices are: docbook2pdf, dblatex)]), + DOCBOOK2PDF="$withval", + AC_CHECK_PROGS([DOCBOOK2PDF], [docbook2pdf dblatex], [echo])) + enable_login="no" dnl weird ass systems @@ -1428,6 +1433,7 @@ AC_SUBST(DARWIN_INFOFILE) AC_SUBST(IRIX_BUILD_IP35) AC_SUBST(HTML_XSL) AC_SUBST(XSLTPROC) +AC_SUBST(DOCBOOK2PDF) OPENAFS_OSCONF OPENAFS_FUSE diff --git a/doc/xml/AdminGuide/Makefile.in b/doc/xml/AdminGuide/Makefile.in index 76835254e5..d442707fc6 100644 --- a/doc/xml/AdminGuide/Makefile.in +++ b/doc/xml/AdminGuide/Makefile.in @@ -27,13 +27,14 @@ SRCS = $(BOOK) auagd005.xml auagd006.xml auagd007.xml auagd008.xml \ auagd024.xml auagd025.xml HTML_XSL = @HTML_XSL@ XSLTPROC = @XSLTPROC@ +DOCBOOK2PDF = @DOCBOOK2PDF@ html: $(SRCS) $(VERSFILE).xml $(XSLTPROC) --param navig.graphics 1 \ --stringparam navig.graphics.path ../ $(HTML_XSL) $(BOOK) pdf: $(SRCS) $(VERSFILE).xml - dblatex $(BOOK) + $(DOCBOOK2PDF) $(BOOK) check: xmllint --noout --valid $(BOOK) diff --git a/doc/xml/QuickStartUnix/Makefile.in b/doc/xml/QuickStartUnix/Makefile.in index 2c2afb7536..7d82c76f83 100644 --- a/doc/xml/QuickStartUnix/Makefile.in +++ b/doc/xml/QuickStartUnix/Makefile.in @@ -24,13 +24,14 @@ SRCS = $(BOOK) auqbg003.xml auqbg004.xml auqbg005.xml auqbg006.xml \ auqbg007.xml auqbg008.xml appendix.xml appendix_dafs.xml HTML_XSL = @HTML_XSL@ XSLTPROC = @XSLTPROC@ +DOCBOOK2PDF = @DOCBOOK2PDF@ html: $(SRCS) $(VERSFILE).xml $(XSLTPROC) --param navig.graphics 1 \ --stringparam navig.graphics.path ../ $(HTML_XSL) $(BOOK) pdf: $(SRCS) $(VERSFILE).xml - dblatex $(BOOK) + $(DOCBOOK2PDF) $(BOOK) check: xmllint --noout --valid $(BOOK) diff --git a/doc/xml/UserGuide/Makefile.in b/doc/xml/UserGuide/Makefile.in index fe4fb91c69..40608a7c4f 100644 --- a/doc/xml/UserGuide/Makefile.in +++ b/doc/xml/UserGuide/Makefile.in @@ -25,13 +25,14 @@ SRCS = $(BOOK) auusg003.xml auusg004.xml auusg005.xml auusg006.xml \ auusg012.xml HTML_XSL = @HTML_XSL@ XSLTPROC = @XSLTPROC@ +DOCBOOK2PDF = @DOCBOOK2PDF@ html: $(SRCS) $(VERSFILE).xml $(XSLTPROC) --param navig.graphics 1 \ --stringparam navig.graphics.path ../ $(HTML_XSL) $(BOOK) pdf: $(SRCS) $(VERSFILE).xml - dblatex $(BOOK) + $(DOCBOOK2PDF) $(BOOK) check: xmllint --noout --valid $(BOOK)