[library-web] Pass current channels in all the xsltproc calls



commit 16fb58f8ddd41d74f56426d893413641d5f5c8ad
Author: Frédéric Péters <fpeters 0d be>
Date:   Fri Dec 3 23:31:31 2010 +0100

    Pass current channels in all the xsltproc calls

 src/modtypes/gnomedocbook.py |    6 ++++++
 src/modtypes/gtkdoc.py       |   12 ++++++++++++
 src/modtypes/htmlfiles.py    |    6 ++++++
 src/modtypes/mallard.py      |    6 ++++++
 4 files changed, 30 insertions(+), 0 deletions(-)
---
diff --git a/src/modtypes/gnomedocbook.py b/src/modtypes/gnomedocbook.py
index 224a135..2cbb487 100644
--- a/src/modtypes/gnomedocbook.py
+++ b/src/modtypes/gnomedocbook.py
@@ -222,6 +222,12 @@ class GnomeDocbookModule(DocModule):
 
                 if self.nightly:
                     cmd[5:5] = ['--param', 'libgo.nightly', 'true()']
+
+                if app.config.symbols_dbm_filepath:
+                    cmd.insert(-2, '--param')
+                    cmd.insert(-2, 'libgo.dbm_support')
+                    cmd.insert(-2, 'true()')
+
                 onepage_cmd = cmd[:]
 
                 # 1st, generate a single page with all documentation, and
diff --git a/src/modtypes/gtkdoc.py b/src/modtypes/gtkdoc.py
index 561502a..ded7e19 100644
--- a/src/modtypes/gtkdoc.py
+++ b/src/modtypes/gtkdoc.py
@@ -88,6 +88,12 @@ class GtkDocModule(DocModule):
                     '--stringparam', 'libgo.channel', self.channel,
                     self.gtkdoc_xsl_file,
                     os.path.join(ext_dirname, self.dirname, main_sgml_file)]
+
+            if app.config.symbols_dbm_filepath:
+                cmd.insert(-2, '--param')
+                cmd.insert(-2, 'libgo.dbm_support')
+                cmd.insert(-2, 'true()')
+
             logging.debug('executing %s' % ' '.join(cmd))
             xsltproc = subprocess.Popen(cmd, stdin = subprocess.PIPE, stderr = subprocess.PIPE)
             stdout, stderr = xsltproc.communicate()
@@ -133,6 +139,12 @@ class GtkDocModule(DocModule):
                                     self.html2html_xsl_file,
                                     os.path.join(ext_dirname,
                                             self.dirname, temporary.name)]
+
+                            if app.config.symbols_dbm_filepath:
+                                cmd.insert(-2, '--param')
+                                cmd.insert(-2, 'libgo.dbm_support')
+                                cmd.insert(-2, 'true()')
+
                             rc = subprocess.call(cmd)
                     else:
                         # simply copy files shipped in tarball
diff --git a/src/modtypes/htmlfiles.py b/src/modtypes/htmlfiles.py
index c522f56..1700874 100644
--- a/src/modtypes/htmlfiles.py
+++ b/src/modtypes/htmlfiles.py
@@ -109,6 +109,12 @@ class HtmlFilesModule(DocModule):
                             cmd.insert(-2, '--stringparam')
                             cmd.insert(-2, 'libgo.%s' % k)
                             cmd.insert(-2, self.extra_xslt_attribs[k])
+
+                    if app.config.symbols_dbm_filepath:
+                        cmd.insert(-2, '--param')
+                        cmd.insert(-2, 'libgo.dbm_support')
+                        cmd.insert(-2, 'true()')
+
                     rc = subprocess.call(cmd)
             else:
                 # simply copy HTML files shipped in tarball
diff --git a/src/modtypes/mallard.py b/src/modtypes/mallard.py
index 6909f3a..1a72aa2 100644
--- a/src/modtypes/mallard.py
+++ b/src/modtypes/mallard.py
@@ -252,6 +252,12 @@ class MallardModule(DocModule):
 
                 if self.nightly:
                     cmd[5:5] = ['--param', 'libgo.nightly', 'true()']
+
+                if app.config.symbols_dbm_filepath:
+                    cmd.insert(-2, '--param')
+                    cmd.insert(-2, 'libgo.dbm_support')
+                    cmd.insert(-2, 'true()')
+
                 onepage_cmd = cmd[:]
 
                 logging.debug('executing %s' % ' '.join(cmd))



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]