Support building Windows help files, update README
authorJelmer Vernooij <jelmer@samba.org>
Mon, 14 Jun 2004 13:48:57 +0000 (13:48 +0000)
committerJelmer Vernooij <jelmer@samba.org>
Mon, 14 Jun 2004 13:48:57 +0000 (13:48 +0000)
branches/SAMBA_4/Makefile.in
branches/SAMBA_4/README

index 42137ae026fb4fd6b3ebb10223735f6237917bd5..42d94ea183e508a369c9bb1492b1f79cf3ec9a08 100644 (file)
@@ -13,6 +13,7 @@
 
 # Programs
 WGET = @WGET@
+XML_CATALOG_FILES = /etc/xml/catalog:$(shell pwd)/samba.catalog
 XSLTPROC = @XSLTPROC@
 XMLLINT = @XMLLINT@
 DVIPS = @DVIPS@
@@ -32,24 +33,25 @@ LATEX += --interaction nonstopmode
 endif
 
 # Paths
-TOPDIR = $(shell pwd)
-OUTPUTDIR = $(TOPDIR)/output
+OUTPUTDIR = output
 ARCHIVEDIR = $(OUTPUTDIR)/archive
 SRCDIR = @SAMBASOURCEDIR@
 MANDIR = $(OUTPUTDIR)/manpages
 EPSTOPDF = @EPSTOPDF@
-MANPAGEDIR = $(TOPDIR)/manpages
-HOWTODIR = $(TOPDIR)/howto
-GUIDEDOC = $(TOPDIR)/guide
-DEVDOCDIR = $(TOPDIR)/devel
+MANPAGEDIR = manpages
+HOWTODIR = howto
+GUIDEDOC = guide
+DEVDOCDIR = /devel
 MAKEINDEX = @MAKEINDEX@
 IMAGEPROJDIR = $(HOWTODIR)/imagefiles
 IMAGEGUIDEDIR = $(GUIDEDOC)/images
-EXAMPLESDIR = $(TOPDIR)/examples
-SMBDOTCONFDOC = $(TOPDIR)/smbdotconf
+EXAMPLESDIR = examples
+SMBDOTCONFDOC = smbdotconf
 PSDIR = $(OUTPUTDIR)
 PDFDIR = $(OUTPUTDIR)
 DVIDIR = $(OUTPUTDIR)
+FODIR = $(OUTPUTDIR)
+HTMLHELPDIR = $(OUTPUTDIR)/htmlhelp
 VALIDATEDIR = $(OUTPUTDIR)/validate
 TXTDIR = $(OUTPUTDIR)/textdocs
 HTMLDIR=$(OUTPUTDIR)/htmldocs
@@ -98,11 +100,13 @@ release: manpages htmlman html pdf guide
 
 pdf: $(PDFDIR) $(PDFDIR)/Samba-Developers-Guide.pdf # $(PDFDIR)/Samba-HOWTO-Collection.pdf
 
-dvi: $(DVIDIR)  $(DVIDIR)/Samba-Developers-Guide.dvi # $(DVIDIR)/Samba-HOWTO-Collection.dvi
+dvi: $(DVIDIR) $(DVIDIR)/Samba-Developers-Guide.dvi # $(DVIDIR)/Samba-HOWTO-Collection.dvi
 
 ps: $(PSDIR) $(PSDIR)/Samba-Developers-Guide.ps # $(PSDIR)/Samba-HOWTO-Collection.ps 
 
-txt: $(TXTDIR)  $(TXTDIR)/Samba-Developers-Guide.txt # $(TXTDIR)/Samba-HOWTO-Collection.txt
+txt: $(TXTDIR) $(TXTDIR)/Samba-Developers-Guide.txt # $(TXTDIR)/Samba-HOWTO-Collection.txt
+
+fo: $(FODIR) $(FODIR)/Samba-HOWTO-Collection.fo $(FODIR)/Samba-Developers-Guide.fo
 
 htmlman: $(HTMLDIR) $(MANPAGES_HTML) $(HTMLDIR)/samba.css
 
@@ -208,6 +212,20 @@ $(PSDIR)/%.ps: $(DVIDIR)/%.dvi
 xslt/figures/%.pdf: xslt/figures/%.eps
        $(EPSTOPDF) $<
 
+# Fo
+$(FODIR):
+       mkdir $(FODIR)
+
+$(FODIR)/%.fo: %.xml $(FODIR)
+       $(XSLTPROC) --output $@ http://docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl $<
+
+$(HTMLHELPDIR):
+       mkdir $(HTMLHELPDIR)
+
+$(HTMLHELPDIR)/%: %.xml $(HTMLHELPDIR) 
+       -mkdir $@
+       $(XSLTPROC) --stringparam base.dir "$@/" http://docbook.sourceforge.net/release/xsl/current/htmlhelp/htmlhelp.xsl $<
+
 # Single large HTML files
 
 $(HTMLDIR):
@@ -244,25 +262,18 @@ $(PLUCKERDIR)/%.pdb: $(HTMLDIR)/%.html
 
 # Manpages
 $(SMBDOTCONFDOC)/parameters.all.xml: $(SMBDOTCONFDOC)/generate-file-list.sh
-       @cd $(SMBDOTCONFDOC) && \
-       /bin/sh generate-file-list.sh >parameters.all.xml && \
-       cd $(OUTPUTDIR)
+       @cd $(SMBDOTCONFDOC) && /bin/sh generate-file-list.sh >parameters.all.xml
 
 $(SMBDOTCONFDOC)/parameters.global.xml: $(SMBDOTCONFDOC)/parameters.all.xml $(SMBDOTCONFDOC)/generate-context.xsl
-       @cd $(SMBDOTCONFDOC) && \
-       $(XSLTPROC) --xinclude \
-       --param smb.context "'G'" \
+       $(XSLTPROC) --xinclude --param smb.context "'G'" \
        --output parameters.global.xml \
-       generate-context.xsl parameters.all.xml && \
-       cd $(OUTPUTDIR)
+       $(SMBDOTCONFDOC)/generate-context.xsl $(SMBDOTCONFDOC)/parameters.all.xml
 
 $(SMBDOTCONFDOC)/parameters.service.xml: $(SMBDOTCONFDOC)/parameters.all.xml $(SMBDOTCONFDOC)/generate-context.xsl
-       @cd $(SMBDOTCONFDOC) && \
        $(XSLTPROC) --xinclude \
        --param smb.context "'S'" \
        --output parameters.service.xml \
-       generate-context.xsl parameters.all.xml && \
-       cd $(OUTPUTDIR)
+       $(SMBDOTCONFDOC)/generate-context.xsl $(SMBDOTCONFDOC)/parameters.all.xml
 
 smb.conf.5.xml: $(SMBDOTCONFDOC)/smb.conf.5.xml $(SMBDOTCONFDOC)/parameters.all.xml \
                $(SMBDOTCONFDOC)/parameters.global.xml $(SMBDOTCONFDOC)/parameters.service.xml 
index 54a6d6ef8f440873a9bdcc0ae948f2de92ad4554..3aa1090388fd612067dd9195b4ecc01b90098667 100644 (file)
@@ -44,7 +44,7 @@ at http://www.docbook.org/
 
 The Output
 ----------
-The current Samba CVS tree contains the XML/DocBook source files.
+The current Samba Subversion tree contains the XML/DocBook source files.
 
 A regularly generated version can be found at http://samba.org/samba/docs/.
 
@@ -63,13 +63,14 @@ For generating PDF (thru LaTeX):
    dated 20030622 -- it works best. Versions previous to 20030425 are known
    to have problems, as well as current (as of 20031210) snapshots.
  * pdflatex
+ * thumbpdf
 
 For generating PostScript (thru LaTeX):
  * latex
  * dvips 
 
 For generating ASCII:
- * xmlto 
+ * html2text
 
 This directory now contains a ./configure script and Makefile to 
 support the automated building of man pages (including HTML versions), and 
@@ -78,3 +79,21 @@ Samba Developers Guide (HTML,DVI,TeX,PDF,PS,Text versions).
 
 The configure script detects which of the required utilities are installed 
 and builds as much docs as it can using these tools.
+
+Help! Building the docs generates a lot of HTTP traffic...
+-------------
+To be able to build the docs without an internet connection (or faster with 
+a slow internet connection), you need to set up "catalogs".
+
+A catalog contains a list of mappings to locally cached documents. E.g. :
+http://db2latex.sf.net/xsl/ -> /usr/share/sgml/docbook/db2latex/xsl/
+
+Add the following two lines to /etc/xml/catalog for db2latex:
+<rewriteURI uriStartString="http://db2latex.sourceforge.net/xsl/" rewritePrefix="/export/user/me/source/docbook/db2latex/xsl/"/>
+<rewriteURI uriStartString="http://docbook.sourceforge.net/release/xsl/current/" rewritePrefix="/export/user/me/source/docbook/docbook-xsl/"/>
+
+(of course, adapt /export/user/me/source/ to whatever path db2latex is 
+ installed in...)
+
+catalog entries for the other DTD's and XSL scripts should be present on your 
+system already.