diff options
author | Alexander Bokovoy <ab@samba.org> | 2012-09-17 13:07:26 +0300 |
---|---|---|
committer | Alexander Bokovoy <ab@samba.org> | 2012-09-17 14:18:31 +0200 |
commit | 73ed1533105ac3f90813e5a0e7888a095eff4b75 (patch) | |
tree | 74ec0f4b2878b3d6a9ebf37c6d08be4a601c2100 /buildtools/wafsamba | |
parent | 57990cbcbbdf83d7b9997ac1fd33528c63c96226 (diff) | |
download | samba-73ed1533105ac3f90813e5a0e7888a095eff4b75.tar.gz samba-73ed1533105ac3f90813e5a0e7888a095eff4b75.tar.bz2 samba-73ed1533105ac3f90813e5a0e7888a095eff4b75.zip |
docs-xml: convert smb.conf.5 build to waf
smb.conf(5) is different from other manpages because before it is
built, it gets merged together from a number of smaller files, one
per parameter. So we first create a parameters.all.xml file that
references all these files and then include it into master smb.conf.5.xml
One small issue is how to handle generated files in WAF build
from xi:include perspective as the files are generated in bin/default/docs-xml
rather than in docs-xml. We solve this by further expanding use of XML catalogs
and rewriting virtual path http://www.samba.org/samba/smbdotconf/ to proper
location.
Both docs-xml autoconf and waf builds work correctly now.
Autobuild-User(master): Alexander Bokovoy <ab@samba.org>
Autobuild-Date(master): Mon Sep 17 14:18:31 CEST 2012 on sn-devel-104
Diffstat (limited to 'buildtools/wafsamba')
-rw-r--r-- | buildtools/wafsamba/wafsamba.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py index 1f71bd39f3..50bd4fa6e2 100644 --- a/buildtools/wafsamba/wafsamba.py +++ b/buildtools/wafsamba/wafsamba.py @@ -789,14 +789,16 @@ def SAMBAMANPAGES(bld, manpages): '''build and install manual pages''' bld.env.SAMBA_EXPAND_XSL = bld.srcnode.abspath() + '/docs-xml/xslt/expand-sambadoc.xsl' bld.env.SAMBA_MAN_XSL = bld.srcnode.abspath() + '/docs-xml/xslt/man.xsl' - os.environ["XML_CATALOG_FILES"] = 'file:///etc/xml/catalog file://' + bld.srcnode.abspath() + '/bin/default/docs-xml/build/catalog.xml' + bld.env.SAMBA_CATALOGS = 'file:///etc/xml/catalog file://' + bld.srcnode.abspath() + '/bin/default/docs-xml/build/catalog.xml' for m in manpages.split(): source = m + '.xml' bld.SAMBA_GENERATOR(m, source=source, target=m, group='final', - rule='${XSLTPROC} --xinclude --stringparam noreference 0 -o ${TGT}.xml --nonet ${SAMBA_EXPAND_XSL} ${SRC} && ${XSLTPROC} --nonet -o ${TGT} ${SAMBA_MAN_XSL} ${TGT}.xml' + rule='''export XML_CATALOG_FILES="${SAMBA_CATALOGS}" + ${XSLTPROC} --xinclude --stringparam noreference 0 -o ${TGT}.xml --nonet ${SAMBA_EXPAND_XSL} ${SRC} + ${XSLTPROC} --nonet -o ${TGT} ${SAMBA_MAN_XSL} ${TGT}.xml''' ) bld.INSTALL_FILES('${MANDIR}/man%s' % m[-1], m, flat=True) Build.BuildContext.SAMBAMANPAGES = SAMBAMANPAGES |