allow dsssl stylesheets to be specified at scons command line

This commit is contained in:
Radim Kolar 2014-09-09 07:49:51 +02:00
parent 863bff21a0
commit 626c1dac57
3 changed files with 7 additions and 2 deletions

View File

@ -12,6 +12,7 @@ Version NEXT
Do not use sgmlformat, call jade directly Do not use sgmlformat, call jade directly
correctly zero entire sockaddr_in structure during name resolving, correctly zero entire sockaddr_in structure during name resolving,
error found by clang. error found by clang.
allow docbook dsssl stylesheets to be specified at scons command line
Version 2.8.1b26 - 1 Oct 2009 Version 2.8.1b26 - 1 Oct 2009
fver now reports if server can process extra data in input packets. fver now reports if server can process extra data in input packets.

View File

@ -55,6 +55,7 @@ SCons command line options:
sysconfdir=directory where to look for fspd and client configuration sysconfdir=directory where to look for fspd and client configuration
files. Default prefix/etc files. Default prefix/etc
without-clients=yes dont build and install client commands without-clients=yes dont build and install client commands
dsssl=directory Look for DocBook DSSSL Stylesheets there
Client utilities: Client utilities:
All inter-command states are kept in these three shell environment All inter-command states are kept in these three shell environment

View File

@ -1,12 +1,13 @@
# #
# SCons Locate DSSSL docbook stylesheets # SCons Locate DSSSL docbook stylesheets
# #
# Version 1.1 # Version 1.2
# 08-Sep-2014 # 09-Sep-2014
# #
import os import os
import stat import stat
from SCons.Script import ARGUMENTS
def findDocbookStylesheets(check): def findDocbookStylesheets(check):
"""Return path to Docbook stylesheets or None.""" """Return path to Docbook stylesheets or None."""
@ -14,6 +15,8 @@ def findDocbookStylesheets(check):
"/usr/local/share/sgml/docbook/dsssl/modular", "/usr/local/share/sgml/docbook/dsssl/modular",
"/usr/share/sgml/stylesheets/dsssl/docbook" "/usr/share/sgml/stylesheets/dsssl/docbook"
] ]
customdsssl = ARGUMENTS.get('dsssl', None)
if customdsssl: directories.insert(0, customdsssl)
files = [ "html/docbook.dsl", "catalog", "common/dbcommon.dsl" ] files = [ "html/docbook.dsl", "catalog", "common/dbcommon.dsl" ]
check.Message("Locating Docbook DSSSL Stylesheets... ") check.Message("Locating Docbook DSSSL Stylesheets... ")
for d in directories: for d in directories: