[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH BOOK] Making multi page html-book

From: B. W. Fitzpatrick <fitz_at_red-bean.com>
Date: 2003-02-10 07:20:44 CET

Jani Averbach <jaa@cc.jyu.fi> writes:
> Hello!
> With this patch it is possible to do multi page html version of book.
> There is however one caveat, xlstproc produces enormous amount of pages
> when it has been driven by chunk.xls and name for those dir is almoust
> unpredictable. So there is need for temp-dir. This patch create that temp
> dir during making of book, other solution would be create it permanently
> to svn-tree.
> The multi page and single page version can live happily and peacefully
> in the same install(target) directory. Entry point for multi page
> version is index.html.

This looks good, except for a couple of things that I tweaked, and the
updated patch is included below.

1. I've changed the output dir for the chunk html to follow convention
2. make clean now zaps the whole dir


1. Images aren't working in the chunk copy--they're referenced and
   all, but there isn't even a link to the image (not even a broken
   one). Can you fix this?

2. Are you up for adding this target to the top-level Makefile.in?

Thanks--this is very nice to have!


Brian W. Fitzpatrick    <fitz_at_red-bean.com>   http://www.red-bean.com/fitz/
Index: Makefile
--- Makefile	(revision 4741)
+++ Makefile	(working copy)
@@ -6,6 +6,7 @@
 SHELL = /bin/sh
 BOOK_DIR = ${BOOK_TOP}/book
@@ -27,6 +28,7 @@
 XSL_DIR = ${BOOK_TOP}/tools/xsl
 XSL_FO = ${BOOK_TOP}/tools/fo-stylesheet.xsl
 XSL_HTML = $(XSL_DIR)/html/docbook.xsl
+XSL_HTML_CHUNK = $(XSL_DIR)/html/chunk.xsl
 RUN_FOP = ${BOOK_TOP}/tools/bin/run-fop.sh
@@ -34,15 +36,15 @@
 install: install-book install-misc-docs
-all-html: book-html misc-docs-html
+all-html: book-html book-html-chunk misc-docs-html
 all-pdf: book-pdf misc-docs-pdf
 all-ps: book-ps misc-docs-ps
-all-book: book-html book-pdf book-ps
+all-book: book-html book-html-chunk book-pdf book-ps
-install-book: install-book-html install-book-pdf install-book-ps
+install-book: install-book-html install-book-html-chunk install-book-pdf install-book-ps
 all-misc-docs: misc-docs-html misc-docs-pdf book-ps
@@ -57,6 +59,11 @@
+## This trailing slash is essential that xsltproc will output pages to the dir
+book-html-chunk: $(BOOK_ALL_SOURCE)
+	mkdir -p $(BOOK_HTML_CHUNK_DIR)
 book-pdf: $(BOOK_PDF_TARGET)
 book-ps: $(BOOK_PS_TARGET)
@@ -77,6 +84,12 @@
 	$(INSTALL) $(BOOK_DIR)/images/*.png $(BOOK_INSTALL_DIR)/images
+## index.html is created last
+install-book-html-chunk: $(BOOK_HTML_CHUNK_DIR)/index.html
+	$(INSTALL) -d $(BOOK_INSTALL_DIR)/images
+	$(INSTALL) $(BOOK_DIR)/images/*.png $(BOOK_INSTALL_DIR)/images
 install-book-pdf: $(BOOK_PDF_TARGET) $(BOOK_INSTALL_DIR)
@@ -84,7 +97,7 @@
 misc-docs-html: $(MDOCS_HTML_TARGET)
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Feb 10 07:20:32 2003

This is an archived mail posted to the Subversion Dev mailing list.