447 lines
7.7 KiB
HTML
447 lines
7.7 KiB
HTML
<HTML
|
|
><HEAD
|
|
><TITLE
|
|
>Introduction</TITLE
|
|
><META
|
|
NAME="GENERATOR"
|
|
CONTENT="Modular DocBook HTML Stylesheet Version 1.63
|
|
"><LINK
|
|
REL="HOME"
|
|
TITLE="DocBook Install mini-HOWTO"
|
|
HREF="index.html"><LINK
|
|
REL="PREVIOUS"
|
|
TITLE="DocBook Install mini-HOWTO"
|
|
HREF="index.html"><LINK
|
|
REL="NEXT"
|
|
TITLE="Download the Packages"
|
|
HREF="download.html"></HEAD
|
|
><BODY
|
|
CLASS="SECT1"
|
|
BGCOLOR="#FFFFFF"
|
|
TEXT="#000000"
|
|
LINK="#0000FF"
|
|
VLINK="#840084"
|
|
ALINK="#0000FF"
|
|
><DIV
|
|
CLASS="NAVHEADER"
|
|
><TABLE
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
CELLPADDING="0"
|
|
CELLSPACING="0"
|
|
><TR
|
|
><TH
|
|
COLSPAN="3"
|
|
ALIGN="center"
|
|
>DocBook Install mini-HOWTO</TH
|
|
></TR
|
|
><TR
|
|
><TD
|
|
WIDTH="10%"
|
|
ALIGN="left"
|
|
VALIGN="bottom"
|
|
><A
|
|
HREF="index.html"
|
|
>Prev</A
|
|
></TD
|
|
><TD
|
|
WIDTH="80%"
|
|
ALIGN="center"
|
|
VALIGN="bottom"
|
|
></TD
|
|
><TD
|
|
WIDTH="10%"
|
|
ALIGN="right"
|
|
VALIGN="bottom"
|
|
><A
|
|
HREF="download.html"
|
|
>Next</A
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
><HR
|
|
ALIGN="LEFT"
|
|
WIDTH="100%"></DIV
|
|
><DIV
|
|
CLASS="SECT1"
|
|
><H1
|
|
CLASS="SECT1"
|
|
><A
|
|
NAME="INTRO"
|
|
>1. Introduction</A
|
|
></H1
|
|
><DIV
|
|
CLASS="SECT2"
|
|
><H2
|
|
CLASS="SECT2"
|
|
><A
|
|
NAME="VERSIONS"
|
|
>1.1. Information About this Document</A
|
|
></H2
|
|
><P
|
|
> The lastest version of this mini-HOWTO can be found at:
|
|
</P
|
|
><P
|
|
> <A
|
|
HREF="http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/"
|
|
TARGET="_top"
|
|
>http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/</A
|
|
>
|
|
</P
|
|
><P
|
|
> See the "Legal" section in the appendix for copyright, licenses, and disclaimer information pertaining to this document.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="SECT2"
|
|
><H2
|
|
CLASS="SECT2"
|
|
><A
|
|
NAME="AEN28"
|
|
>1.2. What is DocBook</A
|
|
></H2
|
|
><P
|
|
> DocBook is a Standard Generalized Markup Language (SGML) Document
|
|
Type Definition (DTD) that defines a set of textual document markup
|
|
tags that work much like the familiar HTML language used on the web.
|
|
</P
|
|
><P
|
|
> DocBook is intended for the authoring of books and articles. As
|
|
such, it provides tags specifically designed to describe books
|
|
and articles. For instance, the <TT
|
|
CLASS="SGMLTAG"
|
|
><book></TT
|
|
>
|
|
and <TT
|
|
CLASS="SGMLTAG"
|
|
><article></TT
|
|
>
|
|
DocBook tags are used to create books and articles. Within these
|
|
documents, the <TT
|
|
CLASS="SGMLTAG"
|
|
><chapter></TT
|
|
>,
|
|
<TT
|
|
CLASS="SGMLTAG"
|
|
><sect1></TT
|
|
>, and <TT
|
|
CLASS="SGMLTAG"
|
|
><para></TT
|
|
>
|
|
tags are used. DocBook SGML files are stored in text files with a <TT
|
|
CLASS="FILENAME"
|
|
>sgml</TT
|
|
>
|
|
or <TT
|
|
CLASS="FILENAME"
|
|
>gml</TT
|
|
> suffix.
|
|
</P
|
|
><P
|
|
> When processed, a single DocBook SGML file can
|
|
output <TT
|
|
CLASS="FILENAME"
|
|
>html</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>pdf</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>ps</TT
|
|
>,
|
|
<TT
|
|
CLASS="FILENAME"
|
|
>txt</TT
|
|
> and other formats for both
|
|
online and printed publication. The processing is governed by
|
|
stylesheets that can automatically generate a table of contents,
|
|
page numbering, chapter & section numbering, and other
|
|
features.
|
|
</P
|
|
><P
|
|
> DocBook is also designed for authoring unix <B
|
|
CLASS="COMMAND"
|
|
>man</B
|
|
> pages by writing
|
|
<TT
|
|
CLASS="SGMLTAG"
|
|
><refentry></TT
|
|
> documents. If you don't know what a <B
|
|
CLASS="COMMAND"
|
|
>man</B
|
|
> page is,
|
|
try the command <B
|
|
CLASS="COMMAND"
|
|
>man man</B
|
|
> on your terminal.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="SECT2"
|
|
><H2
|
|
CLASS="SECT2"
|
|
><A
|
|
NAME="AEN49"
|
|
>1.3. Brief Overview</A
|
|
></H2
|
|
><P
|
|
> Here are brief descriptions of the packages we will work with in the next sections:
|
|
</P
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>OpenJade. </B
|
|
> OpenJade is an implementation of the ISO/IEC 10179:1996
|
|
international standard Document Style Semantics and Specification
|
|
Language (DSSSL). OpenJade executes the DSSSL language to process
|
|
SGML and XML input files. In particular, it uses the Modular
|
|
DocBook Stylesheets dsl code to process DocBook SGML/XML files
|
|
into other formats such as <TT
|
|
CLASS="FILENAME"
|
|
>html</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>tex</TT
|
|
>,
|
|
<TT
|
|
CLASS="FILENAME"
|
|
>rtf</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>txt</TT
|
|
> and others.
|
|
OpenJade is the essential engine for converting a DocBook file into
|
|
other formats. The TeX output format is used mostly as an
|
|
intermediate format to obtain <TT
|
|
CLASS="FILENAME"
|
|
>dvi</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>pdf</TT
|
|
>,
|
|
and <TT
|
|
CLASS="FILENAME"
|
|
>ps</TT
|
|
> via TeX macros and dvi converters.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>DocBook SGML DTD. </B
|
|
> The DocBook Document Type Definition (DTD) files are SGML files
|
|
that define the DocBook language. It defines the
|
|
valid tag set and rules of their use. OpenJade
|
|
requires access to the DTD files for every document
|
|
type that it parses.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>ISO8879 ENTITY SGML. </B
|
|
> Entities define how to represent special characters that
|
|
have either no keyboard key or have special meaning
|
|
in SGML. Examples familiar from HTML include
|
|
"&amp;"='&', "&gt;"='>', and "&lt;"='<'.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>DocBook DSSSL (Modular DocBook Stylesheets). </B
|
|
> The DSSSL files (dsl suffix) for a particular DTD, in this case DocBook,
|
|
specify how to convert DocBook into html, rtf, tex etc. A
|
|
dsl file is input to <B
|
|
CLASS="COMMAND"
|
|
>openjade</B
|
|
> along with
|
|
your DocBook sgml file and tells <B
|
|
CLASS="COMMAND"
|
|
>openjade</B
|
|
>
|
|
how to transform/style your document into another file
|
|
format. The dsl for online (<TT
|
|
CLASS="FILENAME"
|
|
>html</TT
|
|
>) formats is often different
|
|
than for print (<TT
|
|
CLASS="FILENAME"
|
|
>dvi</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>pdf</TT
|
|
>, <TT
|
|
CLASS="FILENAME"
|
|
>ps</TT
|
|
>) formats.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>SGMLtools-Lite. </B
|
|
> SGMLtools-Lite is a frontend wrapper for running <B
|
|
CLASS="COMMAND"
|
|
>openjade</B
|
|
> and the
|
|
<B
|
|
CLASS="COMMAND"
|
|
>TeX</B
|
|
> macros <B
|
|
CLASS="COMMAND"
|
|
>jadetex</B
|
|
> and <B
|
|
CLASS="COMMAND"
|
|
>pdfjadetex</B
|
|
>,
|
|
macros included with OpenJade.
|
|
Converting a DocBook file to <TT
|
|
CLASS="FILENAME"
|
|
>ps</TT
|
|
> or <TT
|
|
CLASS="FILENAME"
|
|
>pdf</TT
|
|
> is a two or three-step
|
|
process. OpenJade outputs a <TT
|
|
CLASS="FILENAME"
|
|
>tex</TT
|
|
> file which is the input of <B
|
|
CLASS="COMMAND"
|
|
>jadetex</B
|
|
> to
|
|
produce a <TT
|
|
CLASS="FILENAME"
|
|
>dvi</TT
|
|
> file, and <B
|
|
CLASS="COMMAND"
|
|
>pdfjadetex</B
|
|
> to produce a <TT
|
|
CLASS="FILENAME"
|
|
>pdf</TT
|
|
>.
|
|
A <TT
|
|
CLASS="FILENAME"
|
|
>ps</TT
|
|
> file is obtained
|
|
by passing the <TT
|
|
CLASS="FILENAME"
|
|
>dvi</TT
|
|
> file through <B
|
|
CLASS="COMMAND"
|
|
>dvips</B
|
|
>. The <B
|
|
CLASS="COMMAND"
|
|
>sgmltools</B
|
|
>
|
|
script provides a single command to perform these tasks.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>HTMLdoc. </B
|
|
> HTMLdoc is a free program for converting html files into a
|
|
<TT
|
|
CLASS="FILENAME"
|
|
>pdf</TT
|
|
> or <TT
|
|
CLASS="FILENAME"
|
|
>ps</TT
|
|
> file.
|
|
</P
|
|
></DIV
|
|
><DIV
|
|
CLASS="FORMALPARA"
|
|
><P
|
|
><B
|
|
>SGMLSpm and docbook2X. </B
|
|
> Together, these two are used to generate <B
|
|
CLASS="COMMAND"
|
|
>man</B
|
|
> pages. SGMLSpm is a perl5 module
|
|
library for processing parsed output from <TT
|
|
CLASS="FILENAME"
|
|
>onsgmls</TT
|
|
>, a program
|
|
included with OpenJade. SGMLSpm includes an application called <TT
|
|
CLASS="FILENAME"
|
|
>sgmlspl</TT
|
|
>
|
|
to use the SGMLSpm library. <TT
|
|
CLASS="FILENAME"
|
|
>Sgmlspl</TT
|
|
> requires "spec files",
|
|
which are available from various other sources on the Internet, for each
|
|
type of document transformation to be performed. DocBook2X is a package that
|
|
provides the spec files for transforming DocBook files into <B
|
|
CLASS="COMMAND"
|
|
>man</B
|
|
> pages.
|
|
</P
|
|
></DIV
|
|
></DIV
|
|
></DIV
|
|
><DIV
|
|
CLASS="NAVFOOTER"
|
|
><HR
|
|
ALIGN="LEFT"
|
|
WIDTH="100%"><TABLE
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
CELLPADDING="0"
|
|
CELLSPACING="0"
|
|
><TR
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="left"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="index.html"
|
|
>Prev</A
|
|
></TD
|
|
><TD
|
|
WIDTH="34%"
|
|
ALIGN="center"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="index.html"
|
|
>Home</A
|
|
></TD
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="right"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="download.html"
|
|
>Next</A
|
|
></TD
|
|
></TR
|
|
><TR
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="left"
|
|
VALIGN="top"
|
|
>DocBook Install mini-HOWTO</TD
|
|
><TD
|
|
WIDTH="34%"
|
|
ALIGN="center"
|
|
VALIGN="top"
|
|
> </TD
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="right"
|
|
VALIGN="top"
|
|
>Download the Packages</TD
|
|
></TR
|
|
></TABLE
|
|
></DIV
|
|
></BODY
|
|
></HTML
|
|
> |