Return-Path: owner-LDP-L@cornell.edu
Received: from listproc.mail.cornell.edu (LISTPROC.MAIL.CORNELL.EDU [132.236.56.14]) by keos.Helsinki.FI (8.6.9/H46) with SMTP id HAA07600 for <LARS.WIRZENIUS@CS.HELSINKI.FI>; Tue, 15 Nov 1994 07:26:01 +0200
Received: from host ([127.0.0.1]) by listproc.mail.cornell.edu with SMTP id <90457-5>; Tue, 15 Nov 1994 00:24:31 -0500
Received: from cornell.edu ([132.236.56.6]) by listproc.mail.cornell.edu with SMTP id <90913-1>; Mon, 14 Nov 1994 22:06:53 -0500
Received: from cornell.edu (PHQUERY) by cornell.edu with cornell-phquery id <373213-8>; Mon, 14 Nov 1994 22:04:48 -0500
Received: from rasty.anu.edu.au ([150.203.15.214]) by cornell.edu with SMTP id <373167-4>; Mon, 14 Nov 1994 22:01:43 -0500
Received: by rasty.anu.edu.au id AA12151
  (5.67b/IDA-1.4.4 for ldp-l@cornell.edu); Tue, 15 Nov 1994 13:58:22 +1100
Message-Id: <199411150258.AA12151@rasty.anu.edu.au>
Date: 	Mon, 14 Nov 1994 22:58:20 -0500
Reply-To: LDP-L@cornell.edu
Sender: owner-LDP-L@cornell.edu
From: Paul Gortmaker <paul@RASTY.ANU.EDU.AU>
To: Linux Documentation Project writers <LDP-L@cornell.edu>
Subject: Patch to linuxdoc-sgml package
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
X-To: ldp-l@cornell.edu
X-PH: V4.1@cornell.edu (Cornell Modified) 
X-Mailer: ELM [version 2.4 PL17]
X-Listprocessor-Version: 7.01 -- ListProcessor by CREN
Content-Length: 10951
Status: RO
X-Status: 


This patch fixes a number of minor bugs in the Howto formatting package.
These are bugs that I have come across while using the package to
format the Ethernet-Howto.

It also fixes up the built in documentation in a few places.

Fixes:

	1)	LaTeX has to run 3 times to get the offset caused
		by the number of "toc" pages. Fixed in "qtex".

	2)	Documented manner for making cross-references is
		cumbersome, and worse, it is broken. Show much
		simpler way.

	3)	Make binaries stripped to cut down on wasted space.

	4)	Tilde character in LaTeX mapping breaks when in
		an URL (as in http://myhost.edu/~joe.blow/index.html)
		ala csh expansion. Can't use a normal ~ either as
		that is a hard space in TeX. Fixed by using "\~{}"

	5)	The "&tilde" in the html mapping is printed literally
		as "&tilde" instead of "~". Fixed in html general.

	6)	Some (all?) versions of "getopt" don't seem to like
		things like "-Tlatex". Changed the docs to reflect
		that "-T latex" is a better choice.

Hopefully this won't break anything else. I will also upload this patch to
sunsite, as these mailing lists sometimes do *nasty* things to patches.

Regards,
Paul.
--

diff -cr linuxdoc-sgml-1.1-original/bin/qtex linuxdoc-sgml-1.1/bin/qtex
*** linuxdoc-sgml-1.1-original/bin/qtex	Wed Jun  8 05:13:25 1994
--- linuxdoc-sgml-1.1/bin/qtex	Mon Nov 14 00:12:33 1994
***************
*** 27,33 ****
  ######################################################################
  
  DVI="no"
! TWO_PASSES="yes"
  SAVE="no"
  BIBTEX="no"
  CHAPTER="no"
--- 27,33 ----
  ######################################################################
  
  DVI="no"
! MULTIPLE_PASSES="yes"
  SAVE="no"
  BIBTEX="no"
  CHAPTER="no"
***************
*** 137,143 ****
          case $i in
  	      -c)       CHAPTER="yes"; shift;;
  	      -d)	DVI="yes"; shift;;
! 	      -x)  	TWO_PASSES="yes"; shift;;
  	      -b)  	BIBTEX="yes"; shift;;
  	      -s)    	SAVE="yes"; shift;;
  	      -v)	VERBOSE="yes"; shift;;
--- 137,143 ----
          case $i in
  	      -c)       CHAPTER="yes"; shift;;
  	      -d)	DVI="yes"; shift;;
! 	      -x)  	MULTIPLE_PASSES="yes"; shift;;
  	      -b)  	BIBTEX="yes"; shift;;
  	      -s)    	SAVE="yes"; shift;;
  	      -v)	VERBOSE="yes"; shift;;
***************
*** 171,177 ****
  
  if [ $BIBTEX = "yes" ]
  then
! 	TWO_PASSES="yes"
  	announce "BiBTeXing $FILE ... "
  	bibtex $FILE > /dev/null
  	
--- 171,177 ----
  
  if [ $BIBTEX = "yes" ]
  then
! 	MULTIPLE_PASSES="yes"
  	announce "BiBTeXing $FILE ... "
  	bibtex $FILE > /dev/null
  	
***************
*** 179,187 ****
  	LaTeX $FILE  
  fi
  
! if [ $TWO_PASSES = "yes" ]
  then
  	announce "LaTeXing again ... "
          LaTeX $FILE
  fi
  
--- 179,189 ----
  	LaTeX $FILE  
  fi
  
! if [ $MULTIPLE_PASSES = "yes" ]
  then
  	announce "LaTeXing again ... "
+         LaTeX $FILE
+ 	announce "And again ... "
          LaTeX $FILE
  fi
  
diff -cr linuxdoc-sgml-1.1-original/doc/guide.sgml linuxdoc-sgml-1.1/doc/guide.sgml
*** linuxdoc-sgml-1.1-original/doc/guide.sgml	Wed Jun  8 05:23:35 1994
--- linuxdoc-sgml-1.1/doc/guide.sgml	Mon Nov 14 00:15:55 1994
***************
*** 280,296 ****
  it to LaTeX, and produce PostScript output (via <tt/dvips/) with
  the command:
  <tscreen><verb>
! $ format -Tlatex foo | qtex > foo.ps
  </verb></tscreen>
  Or, you can produce a DVI file using the <tt>-d</tt> switch with 
  <tt>qtex</tt>, as so:
  <tscreen><verb>
! $ format -Tlatex foo | qtex -d > foo.dvi
  </verb></tscreen>
  
  If you want to produce plain ASCII, through <tt/groff/, use the command:
  <tscreen><verb>
! $ format -Tnroff foo | qroff > foo.txt
  </verb></tscreen>
  Note that I have tailored the <tt/groff/ conversion for plain ASCII output.
  (That is, I've removed page headers, page numbers, changed the margins,
--- 280,296 ----
  it to LaTeX, and produce PostScript output (via <tt/dvips/) with
  the command:
  <tscreen><verb>
! $ format -T latex foo | qtex > foo.ps
  </verb></tscreen>
  Or, you can produce a DVI file using the <tt>-d</tt> switch with 
  <tt>qtex</tt>, as so:
  <tscreen><verb>
! $ format -T latex foo | qtex -d > foo.dvi
  </verb></tscreen>
  
  If you want to produce plain ASCII, through <tt/groff/, use the command:
  <tscreen><verb>
! $ format -T nroff foo | qroff > foo.txt
  </verb></tscreen>
  Note that I have tailored the <tt/groff/ conversion for plain ASCII output.
  (That is, I've removed page headers, page numbers, changed the margins,
***************
*** 301,308 ****
  If you want to produce HTML, the procedure is a bit more complicated,
  because of cross-references. Here's an example:
  <tscreen><verb>
! $ format -Thtml foo.sgml | prehtml | fixref > tmp.html
! $ format -Thtml foo.sgml | prehtml >> tmp.html
  $ cat tmp.html | html2html foo > foo.html
  $ rm tmp.html
  </verb></tscreen>
--- 301,308 ----
  If you want to produce HTML, the procedure is a bit more complicated,
  because of cross-references. Here's an example:
  <tscreen><verb>
! $ format -T html foo.sgml | prehtml | fixref > tmp.html
! $ format -T html foo.sgml | prehtml >> tmp.html
  $ cat tmp.html | html2html foo > foo.html
  $ rm tmp.html
  </verb></tscreen>
***************
*** 318,324 ****
  If you just want to capture your errors from the SGML conversion,
  use something like
  <tscreen><verb>
! $ format -Tnroff foo > /dev/null
  </verb></tscreen>
  
  <sect1>Development note
--- 318,324 ----
  If you just want to capture your errors from the SGML conversion,
  use something like
  <tscreen><verb>
! $ format -T nroff foo > /dev/null
  </verb></tscreen>
  
  <sect1>Development note
***************
*** 576,589 ****
  embodies the entire document). 
  
  </sect2>
! <sect1><heading><label id="cross-ref">Cross-references</>
  
  <p>Now we're going to move onto other features of the system. 
  Cross-references are easy. For example, if you want to make a
  cross-reference to a certain section, you need to label that section
  as so:
  <tscreen><verb>
! <sect1><heading><label id="sec-intro">Introduction&etago;>
  </verb></tscreen>
  You can then refer to that section somewhere in the text using the
  expression:
--- 576,589 ----
  embodies the entire document). 
  
  </sect2>
! <sect1>Cross-references<label id="cross-ref">
  
  <p>Now we're going to move onto other features of the system. 
  Cross-references are easy. For example, if you want to make a
  cross-reference to a certain section, you need to label that section
  as so:
  <tscreen><verb>
! <sect1>Introduction<label id="sec-intro">
  </verb></tscreen>
  You can then refer to that section somewhere in the text using the
  expression:
diff -cr linuxdoc-sgml-1.1-original/doc/guide.txt linuxdoc-sgml-1.1/doc/guide.txt
*** linuxdoc-sgml-1.1-original/doc/guide.txt	Wed Jun  8 05:24:45 1994
--- linuxdoc-sgml-1.1/doc/guide.txt	Mon Nov 14 00:16:37 1994
***************
*** 289,295 ****
    LaTeX, and produce PostScript output (via dvips) with the command:
  
  
!        $ format -Tlatex foo | qtex > foo.ps
  
  
  
--- 289,295 ----
    LaTeX, and produce PostScript output (via dvips) with the command:
  
  
!        $ format -T latex foo | qtex > foo.ps
  
  
  
***************
*** 297,303 ****
    Or, you can produce a DVI file using the -d switch with qtex, as so:
  
  
!        $ format -Tlatex foo | qtex -d > foo.dvi
  
  
  
--- 297,303 ----
    Or, you can produce a DVI file using the -d switch with qtex, as so:
  
  
!        $ format -T latex foo | qtex -d > foo.dvi
  
  
  
***************
*** 305,311 ****
    If you want to produce plain ASCII, through groff, use the command:
  
  
!        $ format -Tnroff foo | qroff > foo.txt
  
  
  
--- 305,311 ----
    If you want to produce plain ASCII, through groff, use the command:
  
  
!        $ format -T nroff foo | qroff > foo.txt
  
  
  
***************
*** 320,327 ****
    because of cross-references. Here's an example:
  
  
!        $ format -Thtml foo.sgml | prehtml | fixref > tmp.html
!        $ format -Thtml foo.sgml | prehtml >> tmp.html
         $ cat tmp.html | html2html foo > foo.html
         $ rm tmp.html
  
--- 320,327 ----
    because of cross-references. Here's an example:
  
  
!        $ format -T html foo.sgml | prehtml | fixref > tmp.html
!        $ format -T html foo.sgml | prehtml >> tmp.html
         $ cat tmp.html | html2html foo > foo.html
         $ rm tmp.html
  
***************
*** 340,346 ****
    something like
  
  
!        $ format -Tnroff foo > /dev/null
  
  
  
--- 340,346 ----
    something like
  
  
!        $ format -T nroff foo > /dev/null
  
  
  
***************
*** 669,675 ****
    reference to a certain section, you need to label that section as so:
  
  
!        <sect1><heading><label id="sec-intro">Introduction</>
  
  
  
--- 669,675 ----
    reference to a certain section, you need to label that section as so:
  
  
!        <sect1>Introduction<label id="sec-intro">
  
  
  
diff -cr linuxdoc-sgml-1.1-original/html-fix/Makefile linuxdoc-sgml-1.1/html-fix/Makefile
*** linuxdoc-sgml-1.1-original/html-fix/Makefile	Wed Jun  8 05:13:33 1994
--- linuxdoc-sgml-1.1/html-fix/Makefile	Sat Jul 30 18:09:52 1994
***************
*** 5,14 ****
  all: fixref html2html
  
  fixref: fixref.c
! 	gcc -o fixref fixref.c  -ll
  
  html2html: html2html.c
! 	gcc -o html2html html2html.c -ll
  
  install:
  	cp html2html fixref ../bin
--- 5,14 ----
  all: fixref html2html
  
  fixref: fixref.c
! 	gcc -s  -o fixref fixref.c -lfl
  
  html2html: html2html.c
! 	gcc -s  -o html2html html2html.c  -lfl
  
  install:
  	cp html2html fixref ../bin
diff -cr linuxdoc-sgml-1.1-original/rep/html/general linuxdoc-sgml-1.1/rep/html/general
*** linuxdoc-sgml-1.1-original/rep/html/general	Wed Jun  8 05:13:45 1994
--- linuxdoc-sgml-1.1/rep/html/general	Sun Nov 13 14:03:00 1994
***************
*** 71,77 ****
  <!entity lcub sdata "{" >
  <!entity verbar sdata "|" >
  <!entity rcub sdata "}" >
! <!entity tilde sdata "&tilde;" >
  <!entity bsol sdata "\" >
  <!entity dollar sdata "$" >
  <!entity nbsp sdata "~" >
--- 71,77 ----
  <!entity lcub sdata "{" >
  <!entity verbar sdata "|" >
  <!entity rcub sdata "}" >
! <!entity tilde sdata "~" >
  <!entity bsol sdata "\" >
  <!entity dollar sdata "$" >
  <!entity nbsp sdata "~" >
diff -cr linuxdoc-sgml-1.1-original/rep/latex/general linuxdoc-sgml-1.1/rep/latex/general
*** linuxdoc-sgml-1.1-original/rep/latex/general	Wed Jun  8 05:13:43 1994
--- linuxdoc-sgml-1.1/rep/latex/general	Sun Nov 13 14:23:49 1994
***************
*** 71,77 ****
  <!entity lcub sdata "\{" >
  <!entity verbar sdata "{\verbar}" >
  <!entity rcub sdata "\}" >
! <!entity tilde sdata "\verb+~+" >
  <!entity bsol sdata "\verb+\+" >
  <!entity dollar sdata "\$" >
  <!entity nbsp sdata "~" >
--- 71,77 ----
  <!entity lcub sdata "\{" >
  <!entity verbar sdata "{\verbar}" >
  <!entity rcub sdata "\}" >
! <!entity tilde sdata "\~{}" >
  <!entity bsol sdata "\verb+\+" >
  <!entity dollar sdata "\$" >
  <!entity nbsp sdata "~" >

