Syncing with 3.0. This should be it for doc sources. Not all builds tested
[privoxy.git] / doc / source / GNUmakefile.in
index b7dd456..cdff651 100644 (file)
@@ -1,6 +1,6 @@
 # Note:  Makefile is built automatically from Makefile.in
 #
-# $Id: GNUmakefile.in,v 1.1 2002/06/05 00:28:28 hal9 Exp $
+# $Id: GNUmakefile.in,v 1.3 2002/06/07 00:27:04 hal9 Exp $
 #
 # Location: doc/source/Makefile.in 
 # Purpose: Build documentation
@@ -82,7 +82,7 @@ DOC_FILES = AUTHORS LICENSE README ChangeLog \
 .PHONY: all dok webserver dok-webserver clean dok-clean clobber ensure-wdump \
 ensure-jadebin ensure-dkprefix user dok-user devel dok-devel faq dok-faq \
 readme dok-readme authors dok-authors index dok-index webserver dok-webserver \
-man dok-man man2html manuals dok-release dok-pdf dok-pdf2 announce config-file
+man dok-man man2html manuals dok-release dok-pdf dok-shtml announce config-file
 #############################################################################
 #
 # Documentation
@@ -222,14 +222,18 @@ dok-man-test: ensure-dkprefix ensure-jadebin dok-release
        $(MAKE) man2html
        $(MAKE) clean
 
-# For those with man2html ala RH7's.
+# For those with man2html ala RH7s.
 man2html: ensure-dkprefix ensure-jadebin ensure-wdump
+       mkdir -p doc/webserver/man-page
 ifneq ($(MAN2HTML),false)
-       $(MAN2HTML) $(ROOT)/privoxy.1 |grep -v "^Content-type" > tmp.html
+       $(MAN2HTML) privoxy.1 |grep -v "^Content-type" > tmp.html
        $(PERL) -pi.bak -e 's/<A .*Contents<\/A>//; s/<A .*man2html<\/A>/man2html/' tmp.html
        $(PERL) -pi.bak -e 's/(<\/HEAD>)/<LINK REL=\"STYLESHEET\" TYPE=\"text\/css\" HREF=\"..\/p_doc.css\"><\/HEAD>/' tmp.html
+# Twice because my version of man2html is pulling in commas and periods in URLs.
+       $(PERL) -pi.bak -e 's/(<A.*),(">)/$$1$$2/g' tmp.html
+       $(PERL) -pi.bak -e 's,\.">,">,g' tmp.html
 # Get rid of spurious \a from conversion. (How to do this with perl?)
-       $(SED) -e 's/\a//g' tmp.html > ../webserver/man-page/privoxy-man-page.html
+       $(SED) -e 's/\a//g' tmp.html > doc/webserver/man-page/privoxy-man-page.html && $(RM) tmp.*
 else
        $(MAKE) groff2html
 endif
@@ -257,12 +261,16 @@ dok-pdf: dok-release
        cd ../pdf && db2pdf --pdf -s ldp.dsl faq.sgml && mv faq.pdf privoxy-faq.pdf > /dev/null 2>&1
        $(RM) ../pdf/*.sgml ../pdf/*.dsl ../pdf/*.out ../pdf/*.tex ../pdf/*.log ../pdf/*.aux
 
-# the layout and style with db2pdf sucks, here is an alternative
-dok-pdf2: dok-release 
-       mkdir -p $(DOC_TMP) # this directory not in cvs
-       $(DB) -V nochunks user-manual.sgml > $(DOC_TMP)/privoxy-user-manual.html
-       $(DB) -V nochunks developer-manual.sgml > $(DOC_TMP)/privoxy-developer-manual.html
-       $(DB) -V nochunks faq.sgml > $(DOC_TMP)/privoxy-faq.html
+# Generate single page html. Used only for creating pdf docs (ATM).
+# Currently using: See http://www.easysw.com/htmldoc/pdf-o-matic.php.
+# If using this generator, remember U-M has a couple of graphics in 
+# a parallel directory.
+#
+dok-shtml: dok-release 
+       mkdir -p doc/source/temp # this directory not in cvs
+       cd doc/source && $(DB) -iuser-man -V nochunks user-manual.sgml > temp/privoxy-user-manual.html
+       cd doc/source && $(DB) -V nochunks developer-manual.sgml > temp/privoxy-developer-manual.html
+       cd doc/source && $(DB) -V nochunks faq.sgml > temp/privoxy-faq.html
 # one could use html2ps and ps2pdf. well, that does not work. htmlps produces incorrect output.
 
 # Create release announcement in text and html, with short and long versions.
@@ -342,6 +350,13 @@ coffee:
 #############################################################################
 
 # $Log: GNUmakefile.in,v $
+# Revision 1.3  2002/06/07 00:27:04  hal9
+# Fixing man2html quirk that pulls in punctuation, and breaks URLs.
+#
+# Revision 1.2  2002/06/05 04:17:19  hal9
+# Add dok-man-test target as temp workaround for docbook2man ignoring -i command
+# line option.
+#
 # Revision 1.1  2002/06/05 00:28:28  hal9
 # Moving all doc building to doc/source. Rewrite all targets (not well tested).
 # Docs are now built without touching sgml source.