Fix xpath selector. Clean up whitespace.

svn path=/trunk/; revision=54955
This commit is contained in:
Gerald Combs 2014-01-25 01:09:28 +00:00
parent 4c5bb90167
commit 927914a2cf
4 changed files with 6 additions and 5 deletions

View File

@ -225,6 +225,7 @@ set(WSUG_SOURCE
SET( WSDG_GENERATED_FILES )
# Convert an AsciiDoc document to a Docbook chapter
# .asciidoc -> whole book (.dbk) -> chapter (.xml)
MACRO( ASCIIDOC2CHAPTER _asciidocsource _conffile )
GET_FILENAME_COMPONENT( _source_base_name ${_asciidocsource} NAME_WE )
set( A2X_HTML_OPTS --stylesheet=ws.css )
@ -246,7 +247,7 @@ MACRO( ASCIIDOC2CHAPTER _asciidocsource _conffile )
${_output_xml}
${_output_dbk}
COMMAND ${XMLLINT_EXECUTABLE}
--xpath chapter
--xpath //chapter
${_output_dbk}
> ${_output_xml}
DEPENDS

View File

@ -56,6 +56,7 @@ else
endif
# Convert an AsciiDoc document to a Docbook chapter
# .asciidoc -> whole book (.dbk) -> chapter (.xml)
.asciidoc.xml:
$(A2X) --verbose \
--asciidoc-opts="--conf-file=asciidoc.conf" \
@ -63,7 +64,7 @@ endif
--format=docbook --doctype=book \
$<
mv $*.xml $*.dbk
xmllint --xpath chapter $*.dbk > $@
xmllint --xpath //chapter $*.dbk > $@
if HAVE_XSLTPROC
ALL_TARGETS=git_version_check wsug wsdg release_notes

View File

@ -33,6 +33,7 @@ A2X_TEXT_OPTS=$(A2X_TEXT_OPTS) --lynx
.SUFFIXES: .fo .pdf
# Convert an AsciiDoc document to a Docbook chapter
# .asciidoc -> whole book (.dbk) -> chapter (.xml)
.asciidoc.xml:
$(SH) <<
PATH=/usr/bin
@ -43,6 +44,7 @@ A2X_TEXT_OPTS=$(A2X_TEXT_OPTS) --lynx
$<
<<
mv $*.xml $*.dbk
# We want the top-level <chapter/>, not the whole book.
xmllint --xpath //chapter $*.dbk > $@
.SUFFIXES: .asciidoc .xml

View File

@ -1,10 +1,7 @@
++++++++++++++++++++++++++++++++++++++
<!-- WSDG Chapter Sources -->
++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++
<!-- $Id$ -->