2 ######################################################################
3 ldp_print - print tool/script for DocBook SGML/XML documents
4 ######################################################################
6 Copyright (C) 2002-2000 - Greg Ferguson (gferg@metalab.unc.edu)
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 ######################################################################
24 This process/script is used in the production environment for the
25 LDP. It relies on the HTMLDOC software package (GPL'ed) which can be
26 obtained from the Easy Software Products (c) web site:
28 http://www.easysw.com/htmldoc/
30 This process creates a PDF variant from the single-file HTML
31 representation of a DocBook SGML (or XML) instance. The simple
32 wrapper script (ldp_print) assumes that the file was created using
33 {open}jade in a manner similar to:
35 jade -t sgml -i html -V nochunks -d $style $fname > $fname.html
37 Give the script the filename as an argument. It will then parse the
38 file into 'title.html' and 'body.html' and send each to htmldoc (as
39 the corresponding title page and body of the document).
45 o Assumes perl is in /usr/bin; adjust if necessary
47 o You may need to specify where the htmldoc executable resides.
48 The script assumes it's within your $PATH.
50 o If you want Postscript as an output variant, uncomment the
51 appropriate lines (see below).
53 o Relies on output from a DocBook instance created via DSSSL/{open}jade!
55 o Cleans up (removes) the intermediate files it creates (but not the
56 PDF or Postscript files, obviously!)
58 o Works silently; PDF (PostScript) will be created in the same directory
59 as was specified for the input (single-file HTML) file.
61 o Provided without warranty or support!
63 o I ran into a problem with htmldoc v1.8.8 which required a source
64 code change (I was getting a core dump from the htmldoc process).
65 Here is the change required:
69 < /* gjf = 11Oct2000 */
70 < if( temprow == NULL )
74 UPDATE (2001-10-10): It appears that later versions of htmldoc
75 have this problem corrected. The patch is not required.
78 Greg Ferguson / gferg (at) metalab.unc.edu