[svnbook commit] r2396 - in trunk/src: nb/stylesheets tools
cmpilato
noreply at red-bean.com
Tue Aug 22 20:30:24 CDT 2006
Author: cmpilato
Date: Tue Aug 22 20:30:23 2006
New Revision: 2396
Added:
trunk/src/nb/stylesheets/
trunk/src/nb/stylesheets/chunk-stylesheet.xsl (contents, props changed)
trunk/src/nb/stylesheets/fo-stylesheet.xsl (contents, props changed)
trunk/src/nb/stylesheets/html-stylesheet.xsl (contents, props changed)
Modified:
trunk/src/tools/Makefile.base-rules
trunk/src/tools/Makefile.base-vars
Log:
Enable local customization layers for all languages. If a specific
language needs to customize the stylesheets, a local "stylesheets/"
directory can be created, containing {html,chunk,fo}-stylesheet.xsl
files.
Thanks to maxb for valuable feedback on the patch.
* src/tools/Makefile.base-rules
(XSL_DIR): New variable.
* src/tools/Makefile.base-vars
(html, html-chunk, fo): Execute $(XSLTPROC) with stylesheets in
$(XSL_DIR) instead of $(TOOLS_DIR).
* src/nb/stylesheets
New directory.
* src/nb/stylesheets/chunk-stylesheet.xsl,
* src/nb/stylesheets/fo-stylesheet.xsl,
* src/nb/stylesheets/html-stylesheet.xsl,
New files, enables custom style sheets for the Norwegian book. No
layout changes, only imports the master stylesheets from
../../src/tools/.
Modified: trunk/src/tools/Makefile.base-rules
==============================================================================
--- trunk/src/tools/Makefile.base-rules (original)
+++ trunk/src/tools/Makefile.base-rules Tue Aug 22 20:30:23 2006
@@ -24,7 +24,7 @@
$(HTML_TARGET): $(ALL_SOURCE) $(VERSION_SOURCE) $(STYLESHEET) $(IMAGES)
$(ENSURE_XSL)
$(XSLTPROC) $(HTML_XSLTPROC_OPTS) --output $(HTML_TARGET) \
- $(TOOLS_DIR)/html-stylesheet.xsl $(XML_SOURCE)
+ $(XSL_DIR)/html-stylesheet.xsl $(XML_SOURCE)
# The trailing slash on the xsltproc --output option is essential to
# output pages into the directory
@@ -35,7 +35,7 @@
$(ENSURE_XSL)
$(XSLTPROC) $(HTML_XSLTPROC_OPTS) \
--output $(HTML_CHUNK_DIR)/ \
- $(TOOLS_DIR)/chunk-stylesheet.xsl $(XML_SOURCE)
+ $(XSL_DIR)/chunk-stylesheet.xsl $(XML_SOURCE)
cp $(STYLESHEET) $(HTML_CHUNK_DIR)
$(IFIMAGES) cp $(IMAGES) $(HTML_CHUNK_DIR)/images $(ENDIF)
@@ -58,7 +58,7 @@
$(FO_TARGET): $(ALL_SOURCE) $(VERSION_SOURCE) $(IMAGES)
$(ENSURE_XSL)
$(XSLTPROC) $(FO_XSLTPROC_OPTS) --output $(FO_TARGET) \
- $(TOOLS_DIR)/fo-stylesheet.xsl $(XML_SOURCE)
+ $(XSL_DIR)/fo-stylesheet.xsl $(XML_SOURCE)
pdf: $(PDF_TARGET)
$(PDF_TARGET): $(FO_TARGET) $(IMAGES)
Modified: trunk/src/tools/Makefile.base-vars
==============================================================================
--- trunk/src/tools/Makefile.base-vars (original)
+++ trunk/src/tools/Makefile.base-vars Tue Aug 22 20:30:23 2006
@@ -36,6 +36,7 @@
DIR = .
IMAGES =
TOOLS_DIR = ../tools
+XSL_DIR = `[ -d stylesheets ] && echo stylesheets || echo $(TOOLS_DIR)`
OUTNAME = $(NAME)
HTML_CHUNK_DIR = $(DIR)/html-chunk
More information about the svnbook-dev
mailing list