<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook V4.1//EN">

<article lang="en">

<articleinfo>
<title>DocBook Installatie mini-HOWTO</title>

<author>
<firstname>Robert</firstname>
<surname>Easter</surname>
<othername role="mi">B</othername>
<affiliation>
<address>
<email>reaster@reaster.com</email>
</address>
</affiliation>
</author>

<author>
<firstname>Vertaald door:Ellen</firstname>
<surname>Bokhorst</surname>
<affiliation>
<address>
<email>bokkie@nl.linux.org</email>
</address>
</affiliation>
</author>

<revhistory>
<revision>
<revnumber>v1.8</revnumber>
<date>04-02-2002</date>
<authorinitials>rbe</authorinitials>
</revision>
</revhistory>

<abstract>
<para>
De DocBook-Install-mini-HOWTO is een gedetailleerde praktische
handleiding voor nieuwelingen om snel DocBook ge&iuml;nstalleerd
te krijgen om SGML bestanden in HTML, PS en PDF bestanden
om te kunnen zetten op een
<ulink url="http://www.gnu.org/gnu/linux-and-gnu.html">GNU</ulink>/<ulink url="http://www.linux.org">Linux</ulink>
systeem - andere systemen kunnen vergelijkbaar zijn. Aangezien
er voor de setup van DocBook bestanden nodig zijn vanuit verscheidene apart
gedistribueerde packages, kan het voor beginners verwarrend zijn.
</para>
</abstract>

</articleinfo>


<sect1 id="intro">
<title>Introductie</title>

<sect2 id="versions">
<title>Informatie over dit document</title>

<para>
De laatste versie van deze mini-HOWTO is te vinden op:
</para>

<para>
<ulink url="http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/">http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/</ulink>
</para>

    <para>
    Zie de "Legal" sectie in de appendix voor het copyright, de licentie en
    disclaimer informatie betrekking hebbend op dit document.
    </para>
</sect2>


<sect2>
<title>Wat is DocBook</title>

<para>
DocBook is een Standard Generalized Markup Language (SGML) Document
Type Definition (DTD) waarin een set tekstuele document markup
tags wordt gedefinieerd die veel lijkt op de bekende HTML taal die op het
web wordt toegepast.
</para>
<para>
DocBook is bedoeld voor het bewerken van boeken en artikelen.
Als zodanig voorziet het in tags die specifiek zijn ontworpen
voor het schrijven van boeken en artikelen.
De <SGMLTag class="StartTag">book</SGMLTag> en
en <SGMLTag class="StartTag">article</SGMLTag>
DocBook tags bijvoorbeeld worden gebruikt om boeken en artikelen
aan te maken. Binnen deze documenten worden de
<SGMLTag class="StartTag">chapter</SGMLTag>,
<SGMLTag class="StartTag">sect1</SGMLTag>, en 
<SGMLTag class="StartTag">para</SGMLTag> tags gebruikt.
DocBook SGML bestanden worden opgeslagen in tekstbestanden met een
        <filename>sgml</filename> of <filename>gml</filename> toevoegsel.
</para>
<para>
Wanneer het wordt verwerkt, kan een enkel DocBook SGML bestand
als uitvoer <filename>html</filename>, <filename>pdf</filename>, 
<filename>ps</filename>, <filename>txt</filename> en andere formaten
voor zowel online als gedrukte publicatie opleveren.
De verwerking wordt bepaald door stylesheets die automatisch
inhoudsopgaves, paginanummeringen, hoofdstuk- &amp; en
sectienummeringen en andere features kunnen genereren.
</para>
<para>
DocBook is ook ontworpen voor het bewerken van unix 
<command>man</command> pages door het schrijven van
<SGMLTag class="StartTag">refentry</SGMLTag> documenten. 
Probeer de opdracht <command>man man</command> vanachter je terminal
als je niet weet wat een <command>man</command> page is.
</para>
</sect2>

<sect2>
<title>Beknopt overzicht</title>
<para>
Hier zijn beknopte beschrijvingen van de packages waarmee we in de
volgende secties zullen gaan werken:
</para>

<formalpara>
<title>OpenJade</title>
<para>
OpenJade is een implementatie van de ISO/IEC 10179:1996
internationale standaard Document Style Semantics and Specification
Language (DSSSL). OpenJade voert de DSSSL taal uit om SGML en XML
invoerbestanden te verwerken. In het bijzonder maakt het gebruik van
de Modulaire DocBook Stylesheets dsl code om DocBook SGML/XML bestanden
om te zetten naar andere formaten zoals <filename>html</filename>, 
<filename>tex</filename>, <filename>rtf</filename>, <filename>txt</filename> 
en anderen.
OpenJade is de essenti&euml;le engine voor het omzetten van een DocBook
bestand naar andere formaten. Het TeX uitvoerformaat wordt meestal
gebruikt als een tussenliggend formaat om
<filename>dvi</filename>, <filename>pdf</filename>, en <filename>ps</filename> 
via TeX macros en dvi converters te kunnen verkrijgen.
</para>
</formalpara>

<formalpara>
<title>DocBook SGML DTD</title>
<para>
De DocBook Document Type Definition (DTD) bestanden zijn SGML bestanden die
de DocBook taal defini&euml;ren. Het definieert de geldige set met tags
en regels voor gebruik. OpenJade vereist toegang tot de DTD bestanden
voor elk type document dat het verwerkt.
</para>
</formalpara>

<FormalPara>
<title>ISO8879 ENTITY SGML</title>
<para>
Entiteiten defini&euml;ren hoe speciale tekens worden voorgesteld die of 
niet op het toetsenbord voorkomen of een speciale betekenis hebben in SGML.
Voorbeelden bekend vanuit HTML zijn o.a.
"&amp;amp;"='&amp;', "&amp;gt;"='&gt;', en "&amp;lt;"='&lt;'.
</para>
</FormalPara>

<FormalPara>
<title>DocBook DSSSL (Modular DocBook Stylesheets)</title>
<para>
De DSSSL bestanden (met de extensie dsl) voor een bepaalde DTD, in dit geval
DocBook, specificeren hoe DocBook naar html, rtf, tex, enz te converteren.
Een dsl bestand is invoer voor <command>openjade</command> in combinatie
met je DocBook sgml bestand en het vertelt <command>openjade</command>
hoe je document in een ander bestandsformaat te transformeren/stijleren.
De dsl voor online (<filename>html</filename>) formaten is vaak anders dan
voor af te drukken (<filename>dvi</filename>, <filename>pdf</filename>, 
<filename>ps</filename>) formaten.
</para>
</FormalPara>

<FormalPara>
<title>SGMLtools-Lite</title>
<para>
SGMLtools-Lite is een frontend wrapper voor het uitvoeren van
<command>openjade</command> en de <command>TeX</command> macro's 
<command>jadetex</command> en <command>pdfjadetex</command>, macro's 
die in OpenJade zijn opgenomen. Het converteren van een DocBook bestand
naar <filename>ps</filename> of <filename>pdf</filename> is een proces bestaande
uit twee of drie stappen. OpenJade geeft als uitvoer een
<filename>tex</filename> bestand wat weer de invoer is voor 
<command>jadetex</command> om een <filename>dvi</filename> bestand te kunnen
produceren en <command>pdfjadetex</command> om een
<filename>pdf</filename> bestand te kunnen produceren. 
Een <filename>ps</filename> bestand wordt verkregen door het 
<filename>dvi</filename> bestand door te geven aan
<command>dvips</command>.  Het <command>sgmltools</command>
script voorziet in een enkele opdracht om deze taken uit te voeren.
</para>
</FormalPara>

<FormalPara>
<title>HTMLdoc</title>
<para>
HTMLdoc is een vrij programma voor het omzetten van html bestanden naar een
<filename>pdf</filename> of <filename>ps</filename> bestand.
</para>
</FormalPara>

<FormalPara>
<title>SGMLSpm en docbook2X</title>
<para>
Samen worden deze gebruikt om <command>man</command> pages te genereren.  
SGMLSpm is een perl5 module library voor het verder verwerken van verwerkte
uitvoer van <filename>onsgmls</filename>, een programma dat met OpenJade
wordt meegeleverd. In SGMLSpm is een applicatie genaamd
<filename>sgmlspl</filename> opgenomen voor gebruik van de SGMLSpm library.
Voor <filename>Sgmlspl</filename> zijn "spec files" nodig, die van diverse
bronnen op Internet beschikbaar zijn, voor elk type uit te voeren
documentomzetting. DocBook2X is een package dat voorziet in de spec files
voor het omzetten van de DocBook bestanden in <command>man</command> pages.
</para>
</FormalPara>

</sect2>
</sect1>




<sect1 id="download">
<title>Download de Packages</title>
<para>
In deze sectie zullen we de software op het Internet lokaliseren en downloaden.
</para>


<sect2>
<title>OpenJade</title>
<para>
OpenJade is een actief onderhouden open-source softwareproject gebaseerd
op het Jade Package van <ulink url="http://www.jclark.com/">James Clark</ulink>.
Download de laatste stabiele release vanaf:
</para>
<para>
<ulink url="http://openjade.sourceforge.net/">http://openjade.sourceforge.net/</ulink>
</para>
<para>
In OpenJade is ook het OpenSP package opgenomen en de TeX macro's,
<command>jadetex</command> en <command>pdfjadetex</command> voor het omzetten
van bestanden naar <filename>dvi</filename> en <filename>pdf</filename>.  
De volgende programma's worden door dit package geleverd:
</para>
<ItemizedList>
<ListItem><para>openjade</para></ListItem>
<ListItem><para>onsgmls</para></ListItem>
<ListItem><para>osgmlnorm</para></ListItem>
<ListItem><para>ospam</para></ListItem>
<ListItem><para>ospent</para></ListItem>
<ListItem><para>osx</para></ListItem>
</ItemizedList>

<para>
Voor gebruik van <command>jadetex</command> en 
<command>pdfjadetex</command> om <filename>dvi</filename>
<filename>ps</filename>, en <filename>pdf</filename> aan te kunnen maken, 
moet je een werkende TeX (<command>tex</command>) installatie hebben.  
Als je TeX niet hebt, kijk dan in je Linux distributie voor een binair
package dat kan worden opgehaald en ge&iuml;nstalleerd.
Anders kun je de <ProductName>teTeX</ProductName> distributie van TeX
downloaden vanaf:
</para>
<para>
<ulink url="http://www.tug.org/tetex/">http://www.tug.org/tetex/</ulink>
</para>
</sect2>

<sect2>
<title>DocBook SGML DTD</title>

<para>
De DocBook DTD voor SGML en XML wordt onderhouden door een technisch
commitee op <ulink url="http://www.oasis-open.org/">Oasis-Open.ORG</ulink>. 
Download de huidige versie (en eventuele oudere versies die je wellicht
nodig hebt) van DocBook SGML vanaf:
</para>

<para>
<ulink url="http://www.oasis-open.org/docbook/sgml/index.shtml">http://www.oasis-open.org/docbook/sgml/index.shtml</ulink>
</para>
</sect2>

<sect2>
<title>ISO8879 ENTITY SGML</title>
<para>
De entiteiten defini&euml;ren representaties voor speciale of niet
te typen symbolen of tekens, waaronder wiskundige symbolen, en de
entiteiten die je wellicht kent van HTML.
Deze bestanden moeten voor een juiste configuratie worden ge&iuml;nstalleerd.
</para>

<ItemizedList>
<ListItem>
<para>Bronnen op <ulink url="http://www.oasis-open.org/">OASIS</ulink>:
<ItemizedList>
<ListItem><para><ulink url="http://www.oasis-open.org/cover/topics.html#entities">http://www.oasis-open.org/cover/topics.html#entities</ulink></para></ListItem>
<ListItem><para><ulink url="http://www.oasis-open.org/cover/ISOEnts.zip">http://www.oasis-open.org/cover/ISOEnts.zip</ulink></para></ListItem>
<ListItem><para><ulink url="http://www.oasis-open.org/cover/isoENT-tar.gz">http://www.oasis-open.org/cover/isoENT-tar.gz</ulink></para></ListItem>
</ItemizedList>
</para>
</ListItem>
  </ItemizedList>

<para>
<filename>ISOEnts.zip</filename> kan simpelweg met <command>unzip</command>
worden uitgepakt in de directory waar de DocBook DTD is uitgepakt zonder
dat er iets anders nodig is, behalve het bestand 
<filename>isoENT-tar.gz</filename>. Ook de bestanden in 
<filename>isoENT-tar.gz</filename> kunnen 
worden uitgepakt in de directory met de DocBook DTD
bestanden (zie de volgende sectie over het installeren voor meer details).
Deze bestandsnamen eindigen op de extensie "<filename>.ent</filename>".  
Deze zullen moeten worden hernoemd naar een "<filename>.gml</filename>" 
toevoegsel. Je kunt dit handmatig doen, of je kunt het onderstaande
bestand gebruiken, gemaakt door de auteur, waarin de bestanden van zowel 
<filename>ISOEnts.zip</filename> als <filename>isoENT-tar.gz</filename>
zijn opgenomen:
</para>
<para>
<ulink url="http://reaster.com/iso8879-entities.tar.gz">http://reaster.com/iso8879-entities.tar.gz</ulink>
</para>

</sect2>

<sect2>
<title>DocBook DSSSL</title>
<para>
<ulink url="http://www.nwalsh.com/">Norman Walsh</ulink>'s Document Style Semantics and Specification
Language (DSSSL) bestanden voor de DocBook DTD (SGML/XML) worden onderhouden
in de <ulink url="http://docbook.sourceforge.net/">DocBook Open Repository
</ulink> op <ulink url="http://www.sourceforge.net/">SourceForge</ulink>.
Deze bestanden, ook bekend als de 
<ulink url="http://docbook.sourceforge.net/projects/dsssl/doc/">Modulaire 
DocBook Stylesheets</ulink>, vertellen <filename>openjade</filename> wat het
moet doen bij het converteren van je DocBook SGML bestand naar andere formaten.
Een dsl bestand specificeert ook zaken zoals de herindelingen van de tags
van de ene DTD naar die van een andere DTD en overige programmatische
conversies, geprogrammeerd in de
<ulink url="http://www.cs.berkeley.edu/~wilensky/CS294/dsssl/html/index.htm">DSSSL</ulink> taal. De DSSSL taal is samengesteld uit een groep verschillende
talen, maar overal doorheen de
<ulink url="http://www.cs.berkeley.edu/~wilensky/CS294/dsssl/html/h2-15.htm">Core Expression Language</ulink>
welke is gebaseerd op
<ulink url="http://www.schemers.org/Documents/Standards/R5RS/HTML/">Scheme
</ulink>.
</para>

<para>
Het DocBook DSSSL package en de bijbehorende documentatie kan worden
gedownload vanaf de site van het
<ulink url="http://docbook.sourceforge.net/projects/dsssl/">DocBook DSSSL Stylesheets Project</ulink>
</para>

<para>
Het <ulink url="http://www.linuxdoc.org/">Linux Documentatie Project</ulink> 
heeft een bestand met daarin aanpassingen op de stylesheet waarin
een aantal fraaie stijlfeatures zijn aangezet. Het kan worden gedownload vanaf:
</para>
<para>
<ulink url="http://www.linuxdoc.org/authors/tools/ldp.dsl">http://www.linuxdoc.org/authors/tools/ldp.dsl</ulink>
</para>
</sect2>

<sect2>
<title>SGMLtools-Lite</title>
<para>
SGMLtools-Lite is een frontend voor openjade, <filename>jadetex</filename>, 
<filename>pdfjadex</filename>, <filename>dvips</filename>, en andere
programma's. Het voorziet in een enkele opdracht voor het genereren van
alle mogelijke formaten met deze tools. De laatste release kan worden
gedownload vanaf:
</para>
<para><ulink url="http://sourceforge.net/projects/sgmltools-lite/">http://sourceforge.net/projects/sgmltools-lite/</ulink></para>
<para>
Dit package is optioneel, maar maakt het er soms wat gemakkelijker op.
</para>
</sect2>

<sect2>
<title>HTMLdoc</title>
<para>
HTMLdoc is een vrij verkrijgbaar programma voor het omzetten van 
websites in het Portable Document Formaat (<filename>pdf</filename>)
of <ProductName>PostScript</ProductName> (<filename>ps</filename>).  
Voor <filename>pdf</filename>, maakt het een structuur met bookmarks aan
die de navigatie vergemakkelijken.
Zowel <command>htmldoc</command> als <command>pdfjadetex</command> geeft
als uitvoer <filename>pdf</filename> bestanden, maar in een iets ander
formaat. Probeer beiden en kijk welke het beste resultaat oplevert voor
een bepaald docbook bestand. Zie wat links hieronder voor de site waar het
kan worden gedownload.
</para>

<para>
Je kunt de laatste versie van <ProductName>HTMLdoc</ProductName> downloaden
vanaf <ulink url="http://www.easysw.com/">Easy Software Products</ulink>'
<ulink url="ftp://ftp.easysw.com/pub/htmldoc/">ftp site</ulink>.
</para>

</sect2>

<sect2>
<title>DocBook2X</title>
<para>
Voor DocBook2X heb je perl5 en de SGMLS.pm perlmodule nodig, die beschikbaar
zijn bij het Comprehensive Perl Archive Network (CPAN). 
SGMLS.pm voorziet in library's en een programma genaamd
<filename>sgmlspl</filename> die DocBook bestanden omzet naar andere
formaten door gebruik te maken van spec files. De spec files zijn
perlbestanden die voorzien in de logica voor de omzetting naar een
bepaald formaat.
</para>
<para><ulink url="http://www.cpan.org/">http://www.cpan.org/</ulink></para>
<para><ulink url="http://docbook2x.sourceforge.net/">http://docbook2x.sourceforge.net/</ulink></para>
</sect2>

</sect1>


<sect1 id="install">
<title>Installeer de packages</title>
<sect2>
<title>Voor de installatie</title>
<para>
In de volgende secties worden suggesties gedaan voor hoe je de gedownloade
packages wellicht zou kunnen installeren om je DocBook SGML omgeving op
te zetten. Het kan zijn dat de voorbeelden verwijzen naar oude versies van
de packages, maar je zou ze in plaats daarvan zo aan moeten passen dat je 
de meest recente versies gebruikt.
</para>
<para>
Voor de meest bijgewerkte, authoratieve informatie moet je altijd de
documentatie lezen die met een package dat je gaat installeren wordt
meegeleverd. Vaak zul je een <filename>README</filename> en een
<filename>INSTALL</filename> bestand aantreffen als je het archief hebt
uitgepakt.
 </para>
 <para>
De gedetailleerde instructies hieronder werken wellicht niet exact zoals
weergegeven, aangezien packages voortdurend aan wijzigingen onderhevig zijn.
De instructies zouden je echter een algemeen idee kunnen geven van de
procedure om DocBook SGML werkend te krijgen.
 </para>
</sect2>

<sect2>
<title>Installeer OpenJade</title>

<sect3>
<title>openjade</title>
<para>
Hieronder staat wat je moet doen, maar denk eraan de bestanden te lezen die
met Openjade werden meegeleverd om erachter te komen of er iets speciaals
moet worden gedaan voor je platform:
</para>
<para>
<screen>
cd /usr/local
tar -xvzf ~/openjade-1.3.tar.gz
cd openjade-1.3
./configure --prefix=/usr/local/openjade-1.3
make
make install

# Eenmaal ge&iuml;nstalleerd, kunnen de objecten, enz worden
# verwijderd.
make clean
</screen>
</para>
<para>
De installatie plaatst library's in /usr/local/openjade-1.3/lib, dus
wellicht dat je ze graag toe wilt voegen aan /etc/ld.so.conf en ldconfig
uit wilt voeren.
Voeg /usr/local/openjade-1.3/bin toe aan je <envar>$PATH</envar>.
</para>
<para>
Wellicht dat je je afvraagt waarom ik de openjade source directory in
<filename>/usr/local</filename> dump. De auteur ervaarde het een en ander
bij de installatie van openjade. Bij nieuwere releases van OpenJade echter,
zou je een standaard (<filename>/usr/local/src</filename>) lokatie voor het
openjade source package kunnen proberen met een ander voorvoegsel als 
installatielokatie, en zien hoe dat gaat.
</para>
</sect3>

<sect3>
<title>jadetex &amp; pdfjadetex</title>
<para>
Zoals vermeld zijn <command>jadetex</command> en 
<command>pdfjadetex</command> TeX macro's die met OpenJade worden
verpakt. Ze zijn te vinden in /usr/local/openjade-3.1/dsssl. Een handige
handleiding om deze macro's te installeren werd voorbereid door
<author>
<firstname>Frank</firstname>
<othername role="mi">Atanassow</othername>
<surname>Christoph</surname>
<affiliation>
<orgname>Next Solution Co., Ltd.</orgname>
   </affiliation>
</author> en het is te vinden op:
</para>
<para><ulink url="ftp://ftp.dante.de/tex-archive/macros/jadetex/install.pdf">ftp://ftp.dante.de/tex-archive/macros/jadetex/install.pdf</ulink></para>
<para><ulink url="http://reaster.com/installjadetex.pdf">http://reaster.com/installjadetex.pdf</ulink></para>
<para>
Het volgende is gebaseerd op de instructies in install.pdf:
</para>
<sect4>
<title>Maak (zonodig) hugelatex aan</title>
<para>
De texmacros <command>jadetex</command> en <command>pdfjadetex</command> 
vereisen meer geheugen dan een reguliere uitvoering van <command>tex</command>.
De standaard geheugenlimietconfiguratie van <command>tex</command> is vaak
te beperkt. Het tex configuratiebestand <filename>texmf.cnf</filename> kan 
worden gewijzigd en de variabelen die het geheugengebruik van tex
beperken kan worden verhoogd. Maar in plaats van gewoon het bestand
<filename>texmf.cnf</filename> te wijzigen waardoor tex onder alle 
omstandigheden meer geheugen heeft, kan een aangepaste <command>tex</command> 
context worden gecre&euml;rd, genaamd <command>hugelatex</command>.
Als <command>hugelatex</command> reeds op je systeem is geconfigureerd,
dan kun je deze subsectie overslaan (<command>which hugelatex</command>).
</para>
<para>
Verifieer dat een werkende TeX is ge&iuml;nstalleerd en het zijn directory
kan vinden:
<screen>
bash$ which tex
/usr/share/texmf/bin/tex
bash$ kpsewhich -expand-var='$TEXMFMAIN'
/usr/share/texmf
bash$
</screen>
</para>
<para>
Het gebruik van <command>which</command> zou de lokatie van het programma
<command>tex</command> moeten lokaliseren. Als het niet wordt gevonden,
dan moet je teTeX wellicht nog installeren en daarna hiernaar toe terugkeren.
<command>kpsewhich</command> is een utility dat met teTeX wordt meegeleverd
en dat de main tex directory  weet te lokaliseren als alles goed gaat.
</para>
<para>
Nu de directory <filename>texmf</filename> bekend is, kan de installatie
beginnen:
</para>
<para>
<screen>
cd /usr/share/texmf
cd tex/latex
cp -r config config-temp
cd config-temp
tex -ini -progname=hugelatex latex.ini
mv latex.fmt hugelatex.fmt
mv hugelatex.fmt /usr/share/texmf/web2c
cd ..
rm -r config-temp
cd /usr/share/texmf/bin
ln -s tex hugelatex
cd /usr/share/texmf/web2c
</screen>
</para>
<para>
De <filename>web2c</filename> directory bevat het configuratiebestand
<filename>texmf.cnf</filename>. Maak een backup van dit bestand: 
<command>cp texmf.cnf texmf.cnf.orig</command>.
Wijzig het bestand met een editor naar keuze en voeg de volgende regels
aan het einde van het bestand toe:
</para>
<para>
<screen>
% hugelatex settings
extra_mem_top.hugelatex = 8000000
extra_mem_bot.hugelatex = 8000000
hash_extra.hugelatex = 15000
pool_size.hugelatex = 5000000
string_vacancies.hugelatex = 45000
max_strings.hugelatex = 55000
pool_free.hugelatex = 47500
nest_size.hugelatex = 500
param_size.hugelatex = 1500
save_size.hugelatex = 5000
stack_size.hugelatex = 15000

% jadetex
extra_mem_top.jadetex = 8000000
extra_mem_bot.jadetex = 8000000
hash_extra.jadetex = 20000
pool_size.jadetex = 5000000
string_vacancies.jadetex = 45000
max_strings.jadetex = 55000
pool_free.jadetex = 47500
nest_size.jadetex = 500
param_size.jadetex = 1500
save_size.jadetex = 5000
stack_size.jadetex = 15000

% pdfjadetex
extra_mem_top.pdfjadetex = 8000000
extra_mem_bot.pdfjadetex = 8000000
hash_extra.pdfjadetex = 20000
pool_size.pdfjadetex = 5000000
string_vacancies.pdfjadetex = 45000
max_strings.pdfjadetex = 55000
pool_free.pdfjadetex = 47500
nest_size.pdfjadetex = 500
param_size.pdfjadetex = 1500
save_size.pdfjadetex = 5000
stack_size.pdfjadetex = 15000
</screen>
Hier zijn we verder gegaan en hebben regels toegevoegd voor
<command>jadetex</command> en <command>pdfjadetex</command>, 
die we hieronder zullen instellen. Je kunt wat spelen met deze 
geheugeninstellingen zoals je dat wilt als je problemen ondervindt.
</para>
<para>
Na het instellen van <command>hugelatex</command>, zoals hierboven, 
werkt het wellicht niet totdat het programma
<command>texhash</command> is aangeroepen:
<screen>
root# texhash
texhash: Updating /usr/share/texmf/ls-R...
texhash: Updating /var/cache/fonts/ls-R...
texhash: Done.
root#
</screen>
</para>
</sect4>

<sect4>
<title>jadetex &amp; pdfjadetex</title>
<para>
Het instellen van <command>jadetex</command> en <command>pdfjadetex</command>
is vergelijkbaar met het instellen van <command>hugelatex</command>.
<screen>
cd /usr/local/openjade-1.3/dsssl
make -f Makefile.jadetex install
# make creates and installs the .fmt
# files to /usr/share/texmf/web2c

# Maak nu symlinks aan ...
cd /usr/share/texmf/bin
ln -s tex jadetex
ln -s pdftex pdfjadetex

# Start als laatste texhash op.
root# texhash
</screen>

Deze <filename>Makefile</filename> gebruikt <command>hugelatex</command>,
dus <command>hugelatex</command> moest reeds zijn ingesteld.
Wanneer tex als <command>hugelatex</command>, <command>jadetex</command>, of
<command>pdfjadetex</command> wordt uitgevoerd, 
krijgt het zijn programmanaam (context) van <VarName>argv[0]</VarName>
in de omgeving.  Dan scant het <filename>texmf.cnf</filename>, en gebruikt
het alle context specifieke instellingen die het aantreft. De formaat
(<filename>.fmt</filename>) bestanden in
<filename>/usr/share/texmf/web2c</filename> worden ook gebaseerd op de
context geladen.
</para>
<para>
De opdracht <command>jadetex</command> accepteert een tex bestand
gegenereerd door <command>openjade</command>, en geeft als uitvoer een
<filename>dvi</filename>. <command>pdfjadetex</command> accepteert een
<filename>tex</filename> bestand gegenereerd door
<command>openjade</command> en geeft als uitvoer een <filename>pdf</filename>
bestand.
Het programma <command>dvips</command> accepteert het 
<filename>dvi</filename> bestand en geeft als uitvoer een 
<ProductName>PostScript</ProductName> <filename>ps</filename> bestand welke
je naar je printer kunt sturen of met ghostscript <command>gs</command>
kunt bekijken.
</para>
</sect4>
</sect3>
</sect2>

<sect2>
<title>DocBook SGML DTD</title>
<sect3>
<title>Pak de DocBook SGML DTD uit</title>
<para>
De DocBook DTD bestaat gewoon uit een aantal <filename>sgml</filename> 
tekstbestanden, dus valt er niets te compileren.
Pak ze gewoon ergens uit.
<screen>
# DocBook DTD V4.1 in
# /usr/local/share/sgml/docbook/4.1

cd /usr/local/share
mkdir sgml; cd sgml
mkdir docbook; cd docbook
mkdir 4.1; cd 4.1
unzip -a ~/docbk41.zip
</screen>
Als je <filename>doctools-1.2</filename> uit de XFree86 distributie installeert,
zullen er een aantal oudere versies van de DocBook DTD, zoals
<filename>2.4.1/</filename> en <filename>3.0/</filename> in subdirectory's
van <filename>docbook</filename> worden ge&iuml;nstalleerd.
</para>
<para>
Er bestaan een aantal verschillen tussen de verschillende versies van de
DocBook DTD.
In de <filename>xxissues.txt</filename> bestanden worden die zaken 
gedocumenteerd. Tags die zijn toegevoegd, verwijderd en hernoemd
tussen de versies.
</para>
<para>
Als je de DocBook DTD V3.1 nodig hebt, dan kun je het vanaf dezelfde
plaats downloaden als waar V4.1 kan worden gedownload. V3.1 wordt veel
gebruikt, dus het is een goed idee het op te halen en het te installeren in
een <filename>3.1/</filename> subdirectory.
</para>
</sect3>

<sect3>
<title>Pak de ISO8879 Entiteiten uit</title>
<para>
Ga voor elk uitgepakte DocBook DTD naar die betreffende directory en
pak het bestand <filename>iso8879-entities.tar.gz</filename> uit:
<screen>
cd /usr/local/share/sgml/docbook/4.1
tar -xvzf ~/iso8879-entities.tar.gz
</screen>
In elke DocBook directory zou een <filename>docbook.cat</filename> of
<filename>catalog</filename> bestand of beiden voor moeten komen. Als
beiden aanwezig zijn, dan zijn ze naar alle waarschijnlijkheid identiek.
Als alleen <filename>docbook.cat</filename> aanwezig is, ga dan je gang
en maak een symlink:
<screen>
# Zonodig ...
cd /usr/local/share/sgml/docbook/4.1
ln -s docbook.cat catalog
</screen>
</para>
</sect3>
</sect2>

<sect2>
<title>DocBook DSSSL</title>
<para>
De installatie van de DocBook DSSSL, welke voor alle versies van DocBook is,
is slechts een kwestie van het ergens uitpakken.
<screen>
cd /usr/local/share/sgml
mkdir dsssl; cd dsssl
unzip -a ~/db160.zip

# Als je de ldp.dsl stylesheet aanpassing downloadde, kopieer het dan naar
cd docbook
cp ~/ldp.dsl html
cp ~/ldp.dsl print
# Kopieer het naar beide directory's.
</screen>
Dat is alles betreft het installeren van de DSSSL, behalve dan de setup
van de variabele <envar>$SGML_CATALOG_PATH</envar> welke later wordt
besproken. Vergeet niet de bestandsmodi en eigenaar/groep van deze
uitgepakte bestanden recht te zetten, vaak zijn ze onjuist.
</para>
</sect2>

<sect2>
<title>SGMLtools-Lite</title>
<para>
Als je dat wilt, kun je de SGMLtools-Lite installeren, maar het is optioneel.
De installatie ervan is de standaard:
<screen>
cd /usr/src
tar -xvzf ~/sgmltools-lite-3.0.2.tar.gz
cd sgmltools-lite-3.0.2
./configure
make install
</screen>
Hiermee wordt het <command>sgmltools</command> <command>python</command> 
script naar <filename>/usr/local/bin</filename> ge&iuml;nstalleerd.  
Het maakt gebruik van <command>python</command>, dus als je het niet
hebt, is dit package onbruikbaar.
</para>
<para>
Een aanpassing die moet worden uitgevoerd om het 
<command>sgmltools</command> script werkend te krijgen is het wijzigen
ervan en het instellen van het pad naar <command>openjade</command>:
<command>vi `which sgmltools`</command>.  Raadpleeg de docs
om er meer over te leren.
</para>
</sect2>

<sect2>
<title>htmldoc</title>

<sect3>
<title>binary</title>
<para>
Bijvoorkeur downloadde je een binaire distributie voor je platform van 
<command>htmldoc</command>. De installatie is eenvoudig: pak het gewoon
uit en voer de setup uit. Lees de docs in het package voor meer info.
</para>
</sect3>

<sect3>
<title>source</title>
<para>
Als je de broncode downloadde, zul je ook de 
<emphasis>Fast Light Tool Kit</emphasis> nodig hebben, anders zal het niet
linken:
</para>
<para>
<ulink url="http://www.fltk.org/">http://www.fltk.org/</ulink>
</para>

<para>
Installatie volgens de <command>autoconf</command> stijl.
Start gewoon het script <command>configure</command> en <command>make</command>,
<command>make install</command>. Als alles goed gaat, zal het worden
ge&iuml;nstalleerd in <filename>/usr/bin</filename>.
</para>
</sect3>

<sect3>
<title>ldp_print</title>
<para>
Het programma <command>htmldoc</command> heeft (of had) een paar
tekortkomingen bij het genereren van uitvoer van
 <filename>html</filename> bestanden vanuit <command>openjade</command>. 
Opsommingsitems werden bijvoorbeeld niet juist weergegeven en
geschaduwde gebieden waren niet altijd voorzien van schaduw.
</para>
<para>
Ter correctie van dit probleem is een <command>perl</command> script
 (<ulink url="http://www.linuxdoc.org/authors/tools/ldp_print.tar.gz">ldp_print</ulink>)
beschikbaar vanaf <ulink url="http://www.linuxdoc.org/">LinuxDoc.org</ulink>.
Het script <command>lpd_print</command> verwerkt een nochunks 
<filename>html</filename> bestand van <command>openjade</command> en past er
dan <command>htmldoc</command> op toe om een correct weergegeven  
<filename>pdf</filename> en <filename>ps</filename> te genereren.
 <tip><para>Haal het op!</para></tip>
</para>
<para>
        <screen>
tar -xvzf ldp_print.tar.gz
cd ldp_print

# Kopieer de lib naar een lokatie waar perl het kan vinden.
cp fix_print_html.lib /usr/lib/perl5/site_perl

cp ldp_print /usr/local/bin
</screen>
Bekijk het script voor het geval er regels instaan die je conform je
systeem moet wijzigen. Misschien dat op een dag de programmeerfouten van
<command>htmldoc</command> zijn opgelost en dat je dit script niet meer
nodig zult hebben.
</para>
</sect3>

</sect2>

<sect2>
<title>DocBook2X en SGMLS.pm (sgmlspl)</title>
<sect3>
<title>sgmlspl</title>
<para>
Voor de spec files van DocBook2X van enig nut zijn, moet de
<filename>SGMLS.pm</filename> module voor <command>perl</command> versie 5 
zijn ge&iuml;nstalleerd, in de veronderstelling dat perl 5 reeds is
ge&iuml;nstalleerd. De installatie van deze module is niet zo geautomatiseerd
als de meeste installaties van <command>perl</command> modules.
Het maakt gebruik van een <filename>Makefile</filename> dat moet worden
gewijzigd voordat <command>make</command> wordt uitgevoerd.
<screen>
cd /usr/src
tar -xvzf ~/SGMLSpm-1.03ii.tar.gz
cd SGMLSpm

# Wijzig Makfile
vi Makefile
# Stel in de user options van de Makefile
# alles correct in overeenkomstig je systeem.
# Voorbeeld:
#PERL = /usr/bin/perl
#BINDIR = /usr/local/bin
#PERL5DIR = /usr/lib/perl5/site_perl
#MODULEDIR = ${PERL5DIR}/SGMLS
#SPECDIR = ${PERL5DIR}
#HTMLDIR= /usr/local/apache/htdocs

make install
</screen>
sgmlspl wordt gekopieerd naar /usr/local/bin.
</para>
</sect3>

<sect3>
<title>docbook2X (docbook2man-spec.pl)</title>
<para>
DocBook2X bevat geen programma voor het compileren of de 
<command>installatie</command>, alhoewel er een paar scripts zijn die
je wellicht wilt bekijken. Je hoeft het dus alleen ergens uit te pakken.
<screen>
cd /usr/local/share/sgml
tar -xvzf ~/docbook2X-0.6.0.tar.gz
cd docbook2X
</screen>
In de directory met uitgepakte bestanden bevindt zich een
<filename>docbook2man-spec.pl</filename> bestand en een patch file 
dat een aantal dingen corrigeert.
Het toepassen van de patch is optioneel maar aan te bevelen.
<screen>
patch docbook2man-spec.pl docbook2man-spec.pl.patch
</screen>
Later, in <emphasis>Het gebruik van DocBook</emphasis>, zul je zien hoe
<command>sgmlspl</command> en <filename>docbook2man-spec.pl</filename> kunnen
worden toegepast om een <command>man</command> page vanuit een 
<SGMLTag class="StartTag">refentry</SGMLTag> DocBook document te genereren.
</para>
</sect3>

</sect2>


<sect2>
<title>$SGML_CATALOG_FILES</title>
<para>
De omgevingsvariabele <envar>$SGML_CATALOG_FILES</envar> wordt gebruikt door
<command>openjade</command> (en andere SGML software) om DTD's en
DSL (stylesheets) te lokaliseren.
SGML software kan niet functioneren zonder deze bestanden, welke zijn
uitgepakt in diverse directory's. Gegeven de setup tot dusverre wordt hier
aangegeven hoe <envar>$SGML_CATALOG_FILES</envar> kan worden ingesteld in
<filename>/etc/profile</filename>:
<screen>
##########################################################################################
# SGML DocBook - openjade sgmltools-lite
JADE_HOME=/usr/local/openjade-1.3
SGML_SHARE=/usr/local/share/sgml

PATH=$PATH:$JADE_HOME/bin

# DSSSL stylesheets
#       Norman Walsh's Modular DocBook Stylesheets
SGML_CATALOG_FILES=$SGML_SHARE/dsssl/docbook/catalog
#       OpenJade stylesheets
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$JADE_HOME/dsssl/catalog
#       sgmltools-lite's stylesheets
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$SGML_SHARE/stylesheets/sgmltools/sgmltools.cat

# DocBook DTD
#       Van OASIS-Open.org
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$SGML_SHARE/docbook/3.1/catalog
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$SGML_SHARE/docbook/4.1/catalog
#       Deze oude DTD's werden ge&iuml;nstalleerd via doctools-1.2 van 
#       XFree86.org
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$SGML_SHARE/docbook/2.4.1/catalog
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$SGML_SHARE/docbook/3.0/catalog

# sgmltools-lite catalog bestanden voor LinuxDoc
SGML_CATALOG_FILES=$SGML_CATALOG_FILES:$SGML_SHARE/dtd/sgmltools/catalog

export JADE_HOME SGML_SHARE PATH SGML_CATALOG_FILES
##########################################################################################
</screen>
Sla het bestand <filename>profile</filename> op, 
<command>logout</command> en log dan weer in om de wijzigingen te activeren.
</para>
<para>
Installatie compleet! In de volgende sectie, zullen we de installatie testen
en een aantal DocBook testbestanden <command>converteren</command>.
</para>
</sect2>

</sect1>

<sect1 id="using">
<title>Gebruiken van DocBook</title>
<para>
Nu alles is ge&iuml;nstalleerd, is de tijd aangebroken om het uit te gaan
testen en te bekijken hoe <command>openjade</command> en de andere tools 
kunnen worden toegepast.
</para>

<para>
<figure>
<title>Voorbeeld DocBook SGML bestand - <filename>test.sgml</filename></title>
<screen>
&lt;!DOCTYPE article PUBLIC &quot;-//OASIS//DTD DocBook V4.1//EN&quot;&gt;

&lt;article lang=&quot;en&quot;&gt;
&lt;articleinfo&gt;
&lt;title&gt;Dit is een test&lt;/title&gt;

&lt;author&gt;
&lt;firstname&gt;John&lt;/firstname&gt;
&lt;surname&gt;Doe&lt;/surname&gt;
&lt;othername role=&quot;mi&quot;&gt;L&lt;/othername&gt;
&lt;affiliation&gt;
&lt;address&gt;
&lt;email&gt;j.doe@jdoe dot com&lt;/email&gt;
&lt;/address&gt;
&lt;/affiliation&gt;
&lt;/author&gt;

&lt;revhistory&gt;
&lt;revision&gt;
&lt;revnumber&gt;v1.0&lt;/revnumber&gt;
&lt;date&gt;30-12-2000&lt;/date&gt;
&lt;authorinitials&gt;jld&lt;/authorinitials&gt;
&lt;/revision&gt;
&lt;/revhistory&gt;

&lt;abstract&gt;
&lt;para&gt;
Dit is een DocBook testdocument.
&lt;/para&gt;
&lt;/abstract&gt;

&lt;/articleinfo&gt;

&lt;sect1 id=&quot;test1&quot;&gt;
&lt;title&gt;Test 1&lt;/title&gt;
&lt;para&gt;
Test sectie 1.
&lt;/para&gt;
&lt;sect2&gt;
&lt;title&gt;Test 1.1&lt;/title&gt;
&lt;para&gt;
Test sectie 1.1
&lt;/para&gt;
&lt;/sect2&gt;

&lt;sect2&gt;
&lt;title&gt;Test 1.2&lt;/title&gt;
&lt;para&gt;
&lt;screen&gt;
-- Test sectie 1.2
openjade -t sgml -d $DSLFILE test.sgml
&lt;/screen&gt;
&lt;/para&gt;
&lt;/sect2&gt;

&lt;/sect1&gt;

&lt;sect1 id=&quot;test2&quot;&gt;
&lt;title&gt;Test 2&lt;/title&gt;
&lt;para&gt;
Test sectie 2.
&lt;/para&gt;

&lt;sect2&gt;
&lt;title&gt;Test 2.1&lt;/title&gt;
&lt;para&gt;
Test sectie 2.1
&lt;/para&gt;
&lt;/sect2&gt;

&lt;sect2&gt;
&lt;title&gt;Test 2.2&lt;/title&gt;
&lt;para&gt;
Test sectie 2.2
&lt;/para&gt;
&lt;/sect2&gt;

&lt;/sect1&gt;
&lt;/article&gt;
</screen>
</figure>
Zie voor een handleiding over DocBook en een referentie van DocBook elementen:
</para>

<FormalPara>
<title>DocBook: The Definitive Guide</title>
<para>
<ulink url="http://www.docbook.org/tdg/en/">http://www.docbook.org/tdg/en/</ulink>
</para>
</FormalPara>

<sect2>
<title>HTML genereren</title>
<sect3>
<title><filename>docbook.dsl</filename></title>
<para>
<figure>
<title>HTML-uitvoer genereren met behulp van 
<filename>docbook.dsl</filename></title>
<screen>
bash$ ls -l
total 4
-rw-r--r--   1 reaster  users        1077 Dec 31 16:25 test.sgml
bash$ echo $SGML_SHARE
/usr/local/share/sgml
bash$ openjade -t sgml -d $SGML_SHARE/dsssl/docbook/html/docbook.dsl test.sgml
[snip - DTDDECL catalog entries are not supported, repeats]
bash$ ls -l
total 12
-rw-r--r--   1 reaster  users        1885 Dec 31 17:34 t1.htm
-rw-r--r--   1 reaster  users        1077 Dec 31 16:25 test.sgml
-rw-r--r--   1 reaster  users        1544 Dec 31 17:34 x27.htm
bash$
</screen>
</figure>
De waarschuwingen over <VarName>DTDDECL</VarName> kunnen worden genegeerd.
Ze zijn wellicht wat ergerlijk, maar deze waarschuwingen zijn normaal wanneer
<command>openjade</command> wordt gebruikt. Andere waarschuwingen en foutmeldingen zouden moeten worden onderzocht en deze geven vaak syntaxfouten aan
die moeten worden gecorrigeerd.
</para>

<para>
Er worden twee <filename>htm</filename> bestanden gegenereerd, &eacute;&eacute;n
voor elke <SGMLTag class="StartTag">sect1</SGMLTag>. De bestandsnamen zijn
niet erg beschrijvend. Sectie &eacute;&eacute;n verschijnt op dezelfde pagina
als de informatie over het artikel. Dit is het resultaat van het gebruik van
de standaard stylesheet die wordt meegeleverd met de
<emphasis>Modulaire DocBook Stylesheets</emphasis>, <filename>docbook.dsl</filename>.
</para>

<para>
Stylesheets kunnen worden aangepast om deze standaards te verbeteren. Als je
het bestand <filename>ldp.dsl</filename> van het  
<ulink url="http://www.linuxdoc.org/">Linux Documentatie Project</ulink>
downloadde en het installeerde zoals
weergegeven in sectie 3.3, dan heb je reeds een aangepaste stijl beschikbaar.
</para>
</sect3>

<sect3>
<title><filename>ldp.dsl</filename></title>
<para>
<figure>
<title>Genereren van HTML-uitvoer met <filename>ldp.dsl</filename></title>
<screen>
bash$ openjade -t sgml -d $SGML_SHARE/dsssl/docbook/html/ldp.dsl#html test.sgml
bash$ ls -l
total 16
-rw-r--r--   1 reaster  users        2006 Dec 31 18:00 index.html
-rw-r--r--   1 reaster  users        1077 Dec 31 16:25 test.sgml
-rw-r--r--   1 reaster  users        1677 Dec 31 18:00 test1.html
-rw-r--r--   1 reaster  users        1598 Dec 31 18:00 test2.html
bash$
</screen>
</figure>
</para>
<para>
Met gebruik van <filename>ldp.dsl</filename> ziet de uitvoer er veel
beter uit:
<ItemizedList>
<ListItem>
<para>
Er wordt een indexbestand aangemaakt met de informatie over het artikel.
</para>
</ListItem>
<ListItem>
<para>
Er wordt automatisch een inhoudsopgave gegenereerd.
</para>
</ListItem>
<ListItem>
<para>
Elke <SGMLTag class="StartTag">sect1</SGMLTag> komt in een eigen bestand.
</para>
</ListItem>
<ListItem>
<para>
Bestandsnamen worden afgeleid van ID-attributen van de
<SGMLTag class="StartTag">sect1</SGMLTag> elementen.
</para>
</ListItem>
<ListItem>
<para>
De bestandsextensie wordt gewijzigd in <filename>html</filename>.
</para>
</ListItem>
<ListItem>
<para>
De <SGMLTag class="StartTag">screen</SGMLTag> elementen zijn geschaduwd.
</para>
</ListItem>
</ItemizedList>
</para>

<para>
Let op hoe het bestand <filename>ldp.dsl</filename> op de opdrachtregel
wordt geschreven, "<filename>#html</filename>" is toegevoegd.  
<filename>ldp.dsl</filename> bevat twee
<SGMLTag class="StartTag">STYLE-SPECIFICATION</SGMLTag> elementen, 
&eacute;&eacute;n met ID="html" en een ander met ID="print".  
Hiermee wordt de <filename>html</filename> stijl uit de ldp.dsl
geselecteerd. De DocBook DSSSL bevat ondersteuning voor het converteren 
van DocBook bestanden naar <filename>html</filename> en print formaten.  
In sectie 3.3 kopieerde we <filename>ldp.dsl</filename> naar zowel de print
als de <filename>html</filename> directory's.  
Bij het genereren van <filename>html</filename> uitvoer, zou de 
<filename>html</filename> style als hierboven moeten worden geselecteerd.
Bij het genereren van andere type bestanden, zoals
<filename>rtf</filename> en <filename>tex</filename>, vallen die 
onder de print stijl en dus zou de print stijl moeten worden geselecteerd uit
<filename>ldp.dsl</filename>.  Het alternatief is een commentaarteken te
plaatsen voor de print of <filename>html</filename> stijl of deze te
verwijderen uit de kopie van het bestand <filename>ldp.dsl</filename> in de
respectieve directory.  
Als zich in een <filename>dsl</filename> bestand meer style-spec bevinden,
en er geen wordt geselecteerd zoals in bovenstaand voorbeeld, dan zal
de eerst aangetroffen stijl in het bestand worden geselecteerd.

In het bestand <filename>ldp.dsl</filename> is de print style-spec het
eerstvoorkomende in het bestand, dus wordt het standaard geselecteerd.
Dus in bovenstaand voorbeeld zonder het toevoegen van 
"<filename>#html</filename>" bij het specificeren van 
<filename>ldp.dsl</filename> als de dsssl stylesheet, zou de "print" style-spec
worden geselecteerd en gebruikt voor het genereren van de 
<filename>html</filename> uitvoer. Het zal wel werken, maar het is bedoeld
voor wanneer de <filename>print/ldp.dsl</filename> wordt geselecteerd en
de opmaak zal anders zijn.
</para>

<para>
Lees de <ulink url="http://nwalsh.com/docbook/dsssl/doc/">documentatie voor de 
Modulaire DocBook Stylesheets</ulink> om meer te leren over hoe de 
aanpassingen op de stylesheet bestanden kunnen worden gemaakt
De aanpasssingen beslaan hoofdzakelijk het instellen van boolean optie
parameters om de style features aan of uit te zetten. Een compleet nieuwe
logicastijl kan worden geprogrammeerd in de
<ulink url="http://www.cs.berkeley.edu/~wilensky/CS294/dsssl/html/index.htm">DSSSL</ulink> taal.
</para>

<para>
De <command>openjade</command> optie "-t output_type" specificeert het
uitvoertype. De "-d dsssl_spec" optie is het pad naar de te gebruiken
dsssl stylesheet. In bovenstaand voorbeeld, is het gespecificeerde uitvoertype
sgml, wat bedoeld is voor SGML naar SGML transformaties. HTML, gedefineerd door
de <ulink url="http://www.w3.org/TR/html4/sgml/dtd.html">HTML Document Type Definition (DTD)</ulink>, is een SGML documenttype net als DocBook is, dus "sgml"
is de correcte output_type optie. De andere twee uitvoertypes die gewoonlijk
worden gebruikt zijn "rtf" en "tex".
Het output_type tex zal later worden gebruikt om een tussenliggend formaat
te cre&euml;ren voor de aanmaak van <filename>pdf</filename> en 
<filename>ps</filename> formaten.
De dsssl_spec moet een <filename>dsl</filename> bestand aangeven, geen
directory.
</para>
</sect3>
</sect2>

<sect2>
<title>Genereren van rtf en tex</title>
<para>
<screen>
bash$ ls -l
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
bash$ openjade -t rtf -d $SGML_SHARE/dsssl/docbook/print/ldp.dsl#print test.sgml
bash$ openjade -t tex -d $SGML_SHARE/dsssl/docbook/print/ldp.dsl#print test.sgml
bash$ ls -l
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
</screen>
</para>
</sect2>

<sect2>
<title>Genereren van dvi en ps</title>
<para>
<figure>
<title>jadetex uitvoeren om een Device Independent (dvi) bestand te genereren</title>
<screen>
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$ jadetex test.tex
This is TeX, Version 3.14159 (Web2C 7.3.1)
(test.tex
JadeTeX 1999/06/29: 2.7
(/usr/share/texmf/tex/latex/psnfss/t1ptm.fd)
(/usr/share/texmf/tex/jadetex/isoents.tex)
Elements will be labelled
Jade begin document sequence at 19
No file test.aux.
(/usr/share/texmf/tex/latex/cyrillic/ot2cmr.fd)
(/usr/share/texmf/tex/latex/base/ts1cmr.fd)
(/usr/share/texmf/tex/latex/lucidabr/lmrhlcm.fd)
(/usr/share/texmf/tex/latex/hyperref/nameref.sty)
(/usr/share/texmf/tex/latex/psnfss/t1phv.fd)

LaTeX Warning: Reference `TEST1' on page 1 undefined on input line 238.


LaTeX Warning: Reference `20' on page 1 undefined on input line 262.


LaTeX Warning: Reference `23' on page 1 undefined on input line 285.


LaTeX Warning: Reference `TEST2' on page 1 undefined on input line 316.


LaTeX Warning: Reference `30' on page 1 undefined on input line 340.


LaTeX Warning: Reference `33' on page 1 undefined on input line 363.

[1.0.46] (/usr/share/texmf/tex/latex/psnfss/t1pcr.fd) [2.0.46] [3.0.46]
(test.aux)

LaTeX Warning: There were undefined references.

 )
Output written on test.dvi (3 pages, 34984 bytes).
Transcript written on test.log.
bash$ ls -l
total 80
-rw-r--r--   1 reaster  users         771 Dec 31 20:55 test.aux
-rw-r--r--   1 reaster  users       34984 Dec 31 20:55 test.dvi
-rw-r--r--   1 reaster  users        5072 Dec 31 20:55 test.log
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$ jadetex test.tex
This is TeX, Version 3.14159 (Web2C 7.3.1)
(test.tex
JadeTeX 1999/06/29: 2.7
(/usr/share/texmf/tex/latex/psnfss/t1ptm.fd)
(/usr/share/texmf/tex/jadetex/isoents.tex)
Elements will be labelled
Jade begin document sequence at 19
(test.aux) (/usr/share/texmf/tex/latex/cyrillic/ot2cmr.fd)
(/usr/share/texmf/tex/latex/base/ts1cmr.fd)
(/usr/share/texmf/tex/latex/lucidabr/lmrhlcm.fd)
(/usr/share/texmf/tex/latex/hyperref/nameref.sty)
(/usr/share/texmf/tex/latex/psnfss/t1phv.fd) [1.0.46]
(/usr/share/texmf/tex/latex/psnfss/t1pcr.fd) [2.0.46] [3.0.46] (test.aux) )
Output written on test.dvi (3 pages, 34148 bytes).
Transcript written on test.log.
You have new mail in /var/spool/mail/reaster
bash$ ls -l
total 80
-rw-r--r--   1 reaster  users         753 Dec 31 20:58 test.aux
-rw-r--r--   1 reaster  users       34148 Dec 31 20:58 test.dvi
-rw-r--r--   1 reaster  users        4433 Dec 31 20:58 test.log
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$
</screen>
</figure>
</para>
<para>
De eerste keer dat <command>jadetex</command> wordt uitgevoerd, worden
waarschuwingen afgedrukt. Deze waarschuwingen kunnen worden genegeerd.
Ze verschijnen niet meer als jadetex een tweede keer wordt uitgevoerd.
</para>
<para>
<figure>
<title><command>dvips</command> uitvoeren om een <ProductName>PostScript</ProductName> (ps) bestand te genereren.</title>
<screen>
bash$ ls -l
total 80
-rw-r--r--   1 reaster  users         753 Dec 31 20:58 test.aux
-rw-r--r--   1 reaster  users       34148 Dec 31 20:58 test.dvi
-rw-r--r--   1 reaster  users        4433 Dec 31 20:58 test.log
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$ dvips test.dvi
This is dvips(k) 5.86 Copyright 1999 Radical Eye Software (www.radicaleye.com)
' TeX output 2000.12.31:2058' -&gt; test.ps
&lt;texc.pro&gt;&lt;8r.enc&gt;&lt;texps.pro&gt;&lt;special.pro&gt;&lt;color.pro&gt;. [1] [2] [3]
bash$ ls -l
total 116
-rw-r--r--   1 reaster  users         753 Dec 31 20:58 test.aux
-rw-r--r--   1 reaster  users       34148 Dec 31 20:58 test.dvi
-rw-r--r--   1 reaster  users        4433 Dec 31 20:58 test.log
-rw-r--r--   1 reaster  users       34817 Dec 31 21:06 test.ps
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$
</screen>
</figure>
</para>

<para>
<figure>
<title><command>htmldoc</command> uitvoeren om een 
<ProductName>PostScript</ProductName> (<filename>ps</filename>) bestand
te genereren</title>
<Screen>
bash$ ls -l
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
bash$ export DSL_HTML=$SGML_SHARE/dsssl/docbook/html/ldp.dsl\#html
bash$ openjade -t sgml -V nochunks -d $DSL_HTML test.sgml | htmldoc -f test-htmldoc.ps -
bash$ ls -l
-rw-r--r--   1 reaster  users        9050 Jan  1 00:44 test-htmldoc.ps
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
bash$
</Screen>
</figure>
Als het <filename>ps</filename> bestand niet naar verwachting wordt
weergegeven, dan kan dit te wijten zijn aan programmeerfouten in
<command>htmldoc</command>. Kijk in het script <command>ldp_print</command>
als je het wilt gebruiken om <filename>ps</filename> te genereren.
</para>
</sect2>

<sect2>
<title>PDF genereren</title>
<para>
<figure>
<title><command>pdfjadetex</command> uitvoeren om een Portable Document Format (<filename>pdf</filename>) bestand te genereren.</title>
<screen>
bash$ ls -l
-rw-r--r--   1 reaster  users         753 Dec 31 20:58 test.aux
-rw-r--r--   1 reaster  users       34148 Dec 31 20:58 test.dvi
-rw-r--r--   1 reaster  users        4433 Dec 31 20:58 test.log
-rw-r--r--   1 reaster  users       34817 Dec 31 21:06 test.ps
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$ pdfjadetex test.tex
This is pdfTeX, Version 3.14159-13d (Web2C 7.3.1)
(test.tex[/usr/share/texmf/pdftex/config/pdftex.cfg]
JadeTeX 1999/06/29: 2.7
(/usr/share/texmf/tex/latex/psnfss/t1ptm.fd)
(/usr/share/texmf/tex/jadetex/isoents.tex)
Elements will be labelled
Jade begin document sequence at 19
(test.aux) (/usr/share/texmf/tex/latex/cyrillic/ot2cmr.fd)
(/usr/share/texmf/tex/latex/base/ts1cmr.fd)
(/usr/share/texmf/tex/latex/lucidabr/lmrhlcm.fd)
(/usr/share/texmf/tex/context/base/supp-pdf.tex
(/usr/share/texmf/tex/context/base/supp-mis.tex
loading : Context Support Macros / Missing
)
loading : Context Support Macros / PDF
) (/usr/share/texmf/tex/latex/hyperref/nameref.sty)
(/usr/share/texmf/tex/latex/psnfss/t1phv.fd) [1.0.46[/usr/share/texmf/dvips/con
fig/pdftex.map]] (/usr/share/texmf/tex/latex/psnfss/t1pcr.fd) [2.0.46] [3.0.46]
 (test.aux) )&lt;8r.enc&gt;
Output written on test.pdf (3 pages, 9912 bytes).
Transcript written on test.log.
bash$ ls -l
total 128
-rw-r--r--   1 reaster  users         753 Dec 31 21:13 test.aux
-rw-r--r--   1 reaster  users       34148 Dec 31 20:58 test.dvi
-rw-r--r--   1 reaster  users        5075 Dec 31 21:13 test.log
-rw-r--r--   1 reaster  users        9912 Dec 31 21:13 test.pdf
-rw-r--r--   1 reaster  users       34817 Dec 31 21:06 test.ps
-rw-r--r--   1 reaster  users        4584 Dec 31 20:51 test.rtf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
-rw-r--r--   1 reaster  users       18719 Dec 31 20:51 test.tex
bash$
bash$ pdfjadetex test.tex
[snip]
bash$ pdfjadetex test.tex
[snip]
</screen>
</figure>
<command>pdfjadetex</command> moet tot drie keer worden uitgevoerd om
alle interne referenties op te lossen voor dingen zoals paginanummers
voor in de TOC (Inhoudsopgave).
</para>

<para>
<figure>
<title><command>htmldoc</command> uitvoeren om een Portable Document Format (<filename>pdf</filename>) bestand te genereren</title>
<Screen>
bash$ ls -l
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
bash$ export DSL_HTML=$SGML_SHARE/dsssl/docbook/html/ldp.dsl\#html
bash$ openjade -t sgml -V nochunks -d $DSL_HTML test.sgml > test-htmldoc.htm
bash$ ldp_print test-htmldoc.htm
bash$ ls -l
-rw-r--r--   1 reaster  users        9050 Jan  1 01:17 test-htmldoc.pdf
-rw-r--r--   1 reaster  users        1143 Dec 31 18:18 test.sgml
bash$
</Screen>
</figure>
Als dit zou zijn geactiveerd in het script <command>ldp_print</command>, 
zou dit ook een <filename>ps</filename> bestand gegeneren.
</para>
</sect2>

<sect2>
<title>Gebruik van <command>make</command></title>

<para>
Het is saai om de opdrachten voor het genereren van de uitvoerbestanden 
te herhalen.
De opdracht <command>make</command> werkt perfect om het proces te
automatiseren.
</para>

<para>
<Figure>
<title>Filename: <filename>Makefile</filename> - automates document generation.</title>

<ProgramListing>
# Genereert online en printversies van SGML bronbestand.

BASENAME=DocBook-Install

# SGML bronbestand.
SGML_FILE=$(BASENAME).sgml

# Stylesheets
DSL_PRINT=$(SGML_SHARE)/dsssl/docbook/print/ldp.dsl\#print
DSL_HTML=$(SGML_SHARE)/dsssl/docbook/html/ldp.dsl\#html

# Gegenereerde bestanden.
HTML_FILE=index.html
HTM_FILE=$(BASENAME).htm
TEX_FILE=$(BASENAME).tex
RTF_FILE=$(BASENAME).rtf
PDF_FILE=$(BASENAME).pdf
DVI_FILE=$(BASENAME).dvi
PS_FILE=$(BASENAME).ps


# Build rules.

html: $(HTML_FILE)

htm: $(HTM_FILE)

tex: $(TEX_FILE)

rtf: $(RTF_FILE)

pdf: $(PDF_FILE)

dvi: $(DVI_FILE)

ps: $(PS_FILE)

all: html htm tex rtf pdf dvi ps

clean:
rm -f $(BASENAME).{htm,log,aux,ps,pdf,tex,dvi,rtf,fot}
rm -f *.html

distclean: clean
rm -f $(BASENAME).tgz

package:
rm -f $(BASENAME).tgz
tar -C .. -czf /tmp/$(BASENAME).tgz $(BASENAME)
mv /tmp/$(BASENAME).tgz .

dist: clean package

distall: all package


# Compileerregels

$(HTML_FILE): $(SGML_FILE)
openjade -t sgml -d $(DSL_HTML) $(SGML_FILE)

$(HTM_FILE): $(SGML_FILE)
openjade -t sgml -V nochunks -d $(DSL_HTML) \
$(SGML_FILE) > $(HTM_FILE)

$(TEX_FILE): $(SGML_FILE)
openjade -t tex -d $(DSL_PRINT) $(SGML_FILE)

$(RTF_FILE): $(SGML_FILE)
openjade -t rtf -d $(DSL_PRINT) $(SGML_FILE)

# [pdf]jadetex is run 3 times to resolve references.
#$(PDF_FILE): $(TEX_FILE)
#pdfjadetex $(TEX_FILE)
#pdfjadetex $(TEX_FILE)
#pdfjadetex $(TEX_FILE)

# This *should* work, but htmldoc has bugs ...
#$(PDF_FILE): $(SGML_FILE)
#openjade -t sgml -V nochunks -d $(DSL_HTML) \
#$(SGML_FILE) | htmldoc -f $(PDF_FILE) -

# Have to use ldp_print to work around htmldoc bugs
# ldp_print can also do the ps file - see script
$(PDF_FILE): $(HTM_FILE)
ldp_print $(HTM_FILE)

$(DVI_FILE): $(TEX_FILE)
jadetex $(TEX_FILE)
jadetex $(TEX_FILE)
jadetex $(TEX_FILE)

$(PS_FILE): $(DVI_FILE)
dvips $(DVI_FILE)

#$(PS_FILE): $(SGML_FILE)
#openjade -t sgml -V nochunks -d $(DSL_HTML) \
#$(SGML_FILE) | htmldoc -f $(PS_FILE) -
</ProgramListing>

</Figure>
</para>
<para>
Het gebruik gaat net als bij de meeste andere projecten:
<figure>
<title><command>make</command> aanroepen om <filename>Makefile</filename>
uit te voeren</title>
<screen>
-- generate html (default)
make
-- generate just pdf
make pdf
-- generate all files
make all
-- delete all generated files
make clean
-- create tgz distribution
-- with no generated files
make dist
-- create tgz distribution
-- containing all generated files
make distall
</screen>
</figure>
</para>
<para>
Let op de becommentarieerde compileregels voor
<filename>pdf</filename> en <filename>ps</filename> die
voorzien in alternatieve middelen voor het genereren van die bestanden.
</para>
</sect2>

<sect2>
<title>Genereren van een <command>man</command> page</title>
<para>
Tijdens de sectie over de installatie van alle packages, installeerden we
de <command>perl</command> versie 5 module <filename>SGMLS.pm</filename>.
Toen installeerden we Docbook2X wat voorziet in de 
<filename>spec.pl</filename> bestanden voor het transformeren van
DocBook <SGMLTag class="StartTag">refentry</SGMLTag> documenten naar
<command>nroff</command> (<command>man</command> page) formaat
met <command>sgmlspl</command>.
</para>
<para>
Een voorbeeld van een DocBook 
<SGMLTag class="StartTag">refentry</SGMLTag> document, voor de opdracht
<command>foo</command> wordt hieronder gegeven.
</para>
<para>
<figure>
<title><command>foo</command> command <command>man</command> page, docbook <SGMLTag class="StartTag">refentry</SGMLTag> source (<filename>foo-ref.sgml</filename>)</title>
<screen>
&lt;!DOCTYPE refentry PUBLIC &quot;-//OASIS//DTD DocBook V4.1//EN&quot;&gt;
&lt;refentry&gt;
&lt;refentryinfo&gt;
&lt;date&gt;2001-01-01&lt;/date&gt;
&lt;/refentryinfo&gt;
&lt;refmeta&gt;
&lt;refentrytitle&gt;
&lt;application&gt;foo&lt;/application&gt;
&lt;/refentrytitle&gt;
&lt;manvolnum&gt;1&lt;/manvolnum&gt;
&lt;refmiscinfo&gt;foo 1.0&lt;/refmiscinfo&gt;
&lt;/refmeta&gt;
&lt;refnamediv&gt;
&lt;refname&gt;
&lt;application&gt;foo&lt;/application&gt;
&lt;/refname&gt;
&lt;refpurpose&gt;
Doet niets nuttigs.
&lt;/refpurpose&gt;
&lt;/refnamediv&gt;
&lt;refsynopsisdiv&gt;
&lt;refsynopsisdivinfo&gt;
&lt;date&gt;2001-01-01&lt;/date&gt;
&lt;/refsynopsisdivinfo&gt;
&lt;cmdsynopsis&gt;
&lt;command&gt;foo&lt;/command&gt;
&lt;arg&gt;&lt;option&gt;-f &lt;/option&gt;&lt;replaceable class=&quot;parameter&quot;&gt;bar&lt;/replaceable&gt;&lt;/arg&gt;
&lt;arg&gt;&lt;option&gt;-d&lt;replaceable class=&quot;parameter&quot;&gt;n&lt;/replaceable&gt;&lt;/option&gt;&lt;/arg&gt;
&lt;arg rep=&quot;repeat&quot;&gt;&lt;replaceable class=&quot;parameter&quot;&gt;file&lt;/replaceable&gt;&lt;/arg&gt;
&lt;/cmdsynopsis&gt;
&lt;/refsynopsisdiv&gt;
&lt;refsect1&gt;
&lt;refsect1info&gt;
&lt;date&gt;2001-01-01&lt;/date&gt;
&lt;/refsect1info&gt;
&lt;title&gt;DESCRIPTION&lt;/title&gt;
&lt;para&gt;
&lt;command&gt;foo&lt;/command&gt; doet niets nuttigs.
&lt;/para&gt;
&lt;/refsect1&gt;
&lt;refsect1&gt;
&lt;title&gt;OPTIONS&lt;/title&gt;
&lt;variablelist&gt;
&lt;varlistentry&gt;
&lt;term&gt;-f &lt;replaceable class=&quot;parameter&quot;&gt;bar&lt;/replaceable&gt;&lt;/term&gt;
&lt;listitem&gt;
&lt;para&gt;
Accepteert &lt;filename&gt;bar&lt;/filename&gt; als zijn besturingsbestand
Als dit een echt programma was, zou er wellicht 
hier meer te zeggen zijn wat bar is en hoe het zal worden gebruikt.
&lt;/para&gt;
&lt;/listitem&gt;
&lt;/varlistentry&gt;
&lt;varlistentry&gt;
&lt;term&gt;-d&lt;replaceable class=&quot;parameter&quot;&gt;n&lt;/replaceable&gt;&lt;/term&gt;
&lt;listitem&gt;
&lt;para&gt;
Doe iets, waar de integer
&lt;replaceable class=&quot;parameter&quot;&gt;n&lt;/replaceable&gt;
aangeeft hoevaak.
&lt;/para&gt;
&lt;/listitem&gt;
&lt;/varlistentry&gt;
&lt;varlistentry&gt;
&lt;term&gt;&lt;replaceable class=&quot;parameter&quot;&gt;file...&lt;/replaceable&gt;&lt;/term&gt;
&lt;listitem&gt;
&lt;para&gt;
Verwerkt de bestanden in de aangegeven volgorde, waarbij het
alle uitvoer naar stdout zendt.
&lt;/para&gt;
&lt;/listitem&gt;
&lt;/varlistentry&gt;
&lt;/variablelist&gt;
&lt;/refsect1&gt;
&lt;refsect1&gt;
&lt;title&gt;USAGE&lt;/title&gt;
&lt;para&gt;
&lt;command&gt;foo&lt;/command&gt; -f foo.conf -d2 foodata.foo
&lt;/para&gt;
&lt;/refsect1&gt;
&lt;refsect1&gt;
&lt;title&gt;CAVEATS&lt;/title&gt;
&lt;para&gt;
Andere programma's met de naam &lt;command&gt;foo&lt;/command&gt; kunnen bestaan in werkelijkheid wel iets doen!
&lt;/para&gt;
&lt;/refsect1&gt;
&lt;refsect1&gt;
&lt;title&gt;BUGS&lt;/title&gt;
&lt;para&gt;
Geen. Programma doets niets.
&lt;/para&gt;
&lt;/refsect1&gt;
&lt;refsect1&gt;
&lt;title&gt;AUTHOR&lt;/title&gt;
&lt;para&gt;
&lt;author&gt;
&lt;firstname&gt;Foo&lt;/firstname&gt;
&lt;othername role=&quot;mi&quot;&gt;E&lt;/othername&gt;
&lt;surname&gt;Bar&lt;/surname&gt;
&lt;contrib&gt;Oorspronkelijke auteur&lt;/contrib&gt;
&lt;/author&gt;
&lt;/para&gt;
&lt;/refsect1&gt;
&lt;/refentry&gt;
</screen>
</figure>
</para>

<para>
<figure>
<title>Genereren van een <command>man</command> page met <command>onsgmls</command>, <command>sgmlspl</command>, en <filename>docbook2man-spec.pl</filename></title>
<screen>
bash$ ls -l
-rw-r--r--   1 reaster  users        2434 Jan  3 03:51 foo-ref.sgml
bash$ onsgmls foo-ref.sgml | sgmlspl $SGML_SHARE/docbook2X/docbook2man-spec.pl
bash$ ls -l
-rw-r--r--   1 reaster  users        2434 Jan  3 03:51 foo-ref.sgml
-rw-r--r--   1 reaster  users        1129 Jan  3 04:03 foo.1
-rw-r--r--   1 reaster  users           0 Jan  3 04:03 manpage.links
-rw-r--r--   1 reaster  users           0 Jan  3 04:03 manpage.log
-rw-r--r--   1 reaster  users          15 Jan  3 04:03 manpage.refs
bash$ groff -mandoc -Tascii foo.1

FOO(1)                                                     FOO(1)


NAME
       foo - Doet niets nuttigs.

SYNOPSIS
       foo [ -f bar ]  [ -dn ]  [ file... ]

DESCRIPTION
       foo doet niets nuttigs.

OPTIONS
       -f bar Accepteert bar als zijn besturingsbestand. Als dit een
              echt programma was, dan zou er wellicht meer te zeggen zijn
              over wat bar is en hoe het zal worden gebruikt.

       -dn    Doe iets,  waar de integer n aangeeft hoevaak.

       file...
              Verwerkt de bestanden in de aangegeven volgorde, waarbij het
	      alle uitvoer naar stdout zendt.

USAGE
       foo -f foo.conf -d2 foodata.foo

CAVEATS
       Anders programma's  met de naam foo kunnen bestaan en in
       werkelijkheid wel iets doen!

BUGS
       Geen. Programma doet niets.

AUTHOR
       Foo E Bar (Oorspronkelijke auteur)

[snip - verscheidene extra witregels die man niet zou moeten tonen]
foo 1.0                     2001-01-01                          1
bash$ groff -mandoc -Tascii foo.1 | less
bash$ less foo.1
</screen>
</figure>
</para>

<para>
De <command>man</command> page, <filename>foo.1</filename>, 
wordt gegeneerd als een Sectie 1 pagina.
De opdracht <command>groff</command> wordt gebruikt om de opgemaakte
verschijning te bekijken.
</para>
<para>
Deze <command>man</command> hoort thuis in een <filename>man/man1</filename>
directory. De directory <filename>man/</filename> moet zijn toegevoegd aan
de omgevingsvariabele <envar>$MANPATH</envar>.
De standaardlokatie is <filename>/usr/local/man/man1</filename>.
De standaardsecties in het systeem met <command>man</command> pages 
bestaan uit de secties 1 tot en met 9. Elk is bedoeld voor het
bijhouden van specifieke catagori&euml;n documentatie.
</para>

<table>
<title>Manual Pages Secties</title>
<tgroup cols="2" align="center">
<thead>
<row>
<entry>Sectie</entry>
<entry>Doel</entry>
</row>
</thead>
<tbody>
<row>
<entry>man1</entry>
<entry>Gebruikersprogramma's</entry>
</row>
<row>
<entry>man2</entry>
<entry>Systeemaanroepen</entry>
</row>
<row>
<entry>man3</entry>
<entry>Library functies en subroutines</entry>
</row>
<row>
<entry>man4</entry>
<entry>Devices</entry>
</row>
<row>
<entry>man5</entry>
<entry>Bestandsformaten</entry>
</row>
<row>
<entry>man6</entry>
<entry>Games</entry>
</row>
<row>
<entry>man7</entry>
<entry>Diversen</entry>
</row>
<row>
<entry>man8</entry>
<entry>Systeembeheer</entry>
</row>
<row>
<entry>man9</entry>
<entry>Kernel interne variabelen en functies</entry>
</row>
</tbody>
</tgroup>
</table>

<tip>
<para>
Het bronbestand voor een <command>man</command> page, zoals 
<filename>foo-ref.sgml</filename>, kan net als elk ander DocBook bestand worden
omgezet in alle andere formaten. Een <command>man</command>page kan met 
dezelfde eerder besproken opdrachten worden omgezet in
<filename>html</filename>, <filename>rtf</filename>, <filename>tex</filename>,
<filename>pdf</filename>, <filename>dvi</filename>, en <filename>ps</filename>
formaten. Dit kan je echt heel veel conversiewerk besparen!
</para>
</tip>

<para>
Veel plezier <emphasis>!</emphasis>
</para>
</sect2>
</sect1>

<appendix id="legal">
<title>Legal</title>
<sect1 id="copyright">
<title>Copyright en licenties</title>

    <blockquote>
  <para>
  Copyright (c)  2001, 2002  Robert B. Easter
  </para>
  <para>
  Permission is granted to copy, distribute and/or modify this document
  under the terms of the GNU Free Documentation License, Version 1.1
  or any later version published by the Free Software Foundation;
  with no Invariant Sections, with no Front-Cover Texts, and with
  no Back-Cover Texts. A copy of the license is included in the
  section entitled "GNU Free Documentation License".
     </para>
    </blockquote>
</sect1>

<sect1 id="disclaimer">
   <title>Disclaimer</title>

   <para>
    Er wordt geen aansprakelijkheid aanvaard voor de inhoud van dit document.
    Gebruik de concepten, voorbeelden en andere inhoud op eigen risico.
   </para>

   <para>
    Alle copyrights vallen in handen van hun respectieve eigenaren, tenzij
    specifiek anders vermeld. Gebruik van een term in dit document moet
    niet wordt aangemerkt als van invloed zijnde op de geldigheid van 
    enig handels- of servicemerk.
   </para>

   <para>
    Het benoemen van bepaalde producten of merken moet niet worden gezien
    als onderkenning daarvan.
   </para>
</sect1>
</appendix>


<appendix id="gfdl">
<title>GNU Free Documentation License</title>
<!-- - GNU Project - Free Software Foundation (FSF) -->
<!-- LINK REV="made" HREF="mailto:webmasters@gnu.org" -->


  <!-- sect1>
    <title>GNU Free Documentation License</title -->

    <para>Version 1.1, March 2000</para>

    <blockquote>
      <para>Copyright (C) 2000  Free Software Foundation, Inc.
59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.</para>
    </blockquote>

  <sect1 label="0">
    <title>PREAMBLE</title>

    <para>The purpose of this License is to make a manual, textbook,
    or other written document "free" in the sense of freedom: to
    assure everyone the effective freedom to copy and redistribute it,
    with or without modifying it, either commercially or
    noncommercially.  Secondarily, this License preserves for the
    author and publisher a way to get credit for their work, while not
    being considered responsible for modifications made by
    others.</para>

    <para>This License is a kind of "copyleft", which means that
    derivative works of the document must themselves be free in the
    same sense.  It complements the GNU General Public License, which
    is a copyleft license designed for free software.</para>

    <para>We have designed this License in order to use it for manuals
    for free software, because free software needs free documentation:
    a free program should come with manuals providing the same
    freedoms that the software does.  But this License is not limited
    to software manuals; it can be used for any textual work,
    regardless of subject matter or whether it is published as a
    printed book.  We recommend this License principally for works
    whose purpose is instruction or reference.</para>
  </sect1>

  <sect1 label="1">
    <title>APPLICABILITY AND DEFINITIONS</title>

    <para>This License applies to any manual or other work that
    contains a notice placed by the copyright holder saying it can be
    distributed under the terms of this License.  The "Document",
    below, refers to any such manual or work.  Any member of the
    public is a licensee, and is addressed as "you".</para>

    <para>A "Modified Version" of the Document means any work
    containing the Document or a portion of it, either copied
    verbatim, or with modifications and/or translated into another
    language.</para>

    <para>A "Secondary Section" is a named appendix or a front-matter
    section of the Document that deals exclusively with the
    relationship of the publishers or authors of the Document to the
    Document's overall subject (or to related matters) and contains
    nothing that could fall directly within that overall subject.
    (For example, if the Document is in part a textbook of
    mathematics, a Secondary Section may not explain any mathematics.)
    The relationship could be a matter of historical connection with
    the subject or with related matters, or of legal, commercial,
    philosophical, ethical or political position regarding
    them.</para>

    <para>The "Invariant Sections" are certain Secondary Sections
    whose titles are designated, as being those of Invariant Sections,
    in the notice that says that the Document is released under this
    License.</para>

    <para>The "Cover Texts" are certain short passages of text that
    are listed, as Front-Cover Texts or Back-Cover Texts, in the
    notice that says that the Document is released under this
    License.</para>

    <para>A "Transparent" copy of the Document means a
    machine-readable copy, represented in a format whose specification
    is available to the general public, whose contents can be viewed
    and edited directly and straightforwardly with generic text
    editors or (for images composed of pixels) generic paint programs
    or (for drawings) some widely available drawing editor, and that
    is suitable for input to text formatters or for automatic
    translation to a variety of formats suitable for input to text
    formatters.  A copy made in an otherwise Transparent file format
    whose markup has been designed to thwart or discourage subsequent
    modification by readers is not Transparent.  A copy that is not
    "Transparent" is called "Opaque".</para>

    <para>Examples of suitable formats for Transparent copies include
    plain ASCII without markup, Texinfo input format, LaTeX input
    format, SGML or XML using a publicly available DTD, and
    standard-conforming simple HTML designed for human modification.
    Opaque formats include PostScript, PDF, proprietary formats that
    can be read and edited only by proprietary word processors, SGML
    or XML for which the DTD and/or processing tools are not generally
    available, and the machine-generated HTML produced by some word
    processors for output purposes only.</para>

    <para>The "Title Page" means, for a printed book, the title page
    itself, plus such following pages as are needed to hold, legibly,
    the material this License requires to appear in the title page.
    For works in formats which do not have any title page as such,
    "Title Page" means the text near the most prominent appearance of
    the work's title, preceding the beginning of the body of the
    text.</para>
  </sect1>

  <sect1 label="2">
    <title>VERBATIM COPYING</title>

    <para>You may copy and distribute the Document in any medium,
    either commercially or noncommercially, provided that this
    License, the copyright notices, and the license notice saying this
    License applies to the Document are reproduced in all copies, and
    that you add no other conditions whatsoever to those of this
    License.  You may not use technical measures to obstruct or
    control the reading or further copying of the copies you make or
    distribute.  However, you may accept compensation in exchange for
    copies.  If you distribute a large enough number of copies you
    must also follow the conditions in section 3.</para>

    <para>You may also lend copies, under the same conditions stated
    above, and you may publicly display copies.</para>
  </sect1>

  <sect1 label="3">
    <title>COPYING IN QUANTITY</title>

    <para>If you publish printed copies of the Document numbering more
    than 100, and the Document's license notice requires Cover Texts,
    you must enclose the copies in covers that carry, clearly and
    legibly, all these Cover Texts: Front-Cover Texts on the front
    cover, and Back-Cover Texts on the back cover.  Both covers must
    also clearly and legibly identify you as the publisher of these
    copies.  The front cover must present the full title with all
    words of the title equally prominent and visible.  You may add
    other material on the covers in addition.  Copying with changes
    limited to the covers, as long as they preserve the title of the
    Document and satisfy these conditions, can be treated as verbatim
    copying in other respects.</para>

    <para>If the required texts for either cover are too voluminous to
    fit legibly, you should put the first ones listed (as many as fit
    reasonably) on the actual cover, and continue the rest onto
    adjacent pages.</para>

    <para>If you publish or distribute Opaque copies of the Document
    numbering more than 100, you must either include a
    machine-readable Transparent copy along with each Opaque copy, or
    state in or with each Opaque copy a publicly-accessible
    computer-network location containing a complete Transparent copy
    of the Document, free of added material, which the general
    network-using public has access to download anonymously at no
    charge using public-standard network protocols.  If you use the
    latter option, you must take reasonably prudent steps, when you
    begin distribution of Opaque copies in quantity, to ensure that
    this Transparent copy will remain thus accessible at the stated
    location until at least one year after the last time you
    distribute an Opaque copy (directly or through your agents or
    retailers) of that edition to the public.</para>

    <para>It is requested, but not required, that you contact the
    authors of the Document well before redistributing any large
    number of copies, to give them a chance to provide you with an
    updated version of the Document.</para>
  </sect1>

  <sect1 label="4">
    <title>MODIFICATIONS</title>

    <para>You may copy and distribute a Modified Version of the
    Document under the conditions of sections 2 and 3 above, provided
    that you release the Modified Version under precisely this
    License, with the Modified Version filling the role of the
    Document, thus licensing distribution and modification of the
    Modified Version to whoever possesses a copy of it.  In addition,
    you must do these things in the Modified Version:</para>

    <orderedlist numeration="upperalpha">
      <listitem><para>Use in the Title Page
      (and on the covers, if any) a title distinct from that of the
      Document, and from those of previous versions (which should, if
      there were any, be listed in the History section of the
      Document).  You may use the same title as a previous version if
      the original publisher of that version gives permission.</para>
      </listitem>

      <listitem><para>List on the Title Page,
      as authors, one or more persons or entities responsible for
      authorship of the modifications in the Modified Version,
      together with at least five of the principal authors of the
      Document (all of its principal authors, if it has less than
      five).</para>
      </listitem>

      <listitem><para>State on the Title page
      the name of the publisher of the Modified Version, as the
      publisher.</para>
      </listitem>

      <listitem><para>Preserve all the
      copyright notices of the Document.</para>
      </listitem>

      <listitem><para>Add an appropriate
      copyright notice for your modifications adjacent to the other
      copyright notices.</para>
      </listitem>

      <listitem><para>Include, immediately
      after the copyright notices, a license notice giving the public
      permission to use the Modified Version under the terms of this
      License, in the form shown in the Addendum below.</para>
      </listitem>

      <listitem><para>Preserve in that license
      notice the full lists of Invariant Sections and required Cover
      Texts given in the Document's license notice.</para>
      </listitem>

      <listitem><para>Include an unaltered
      copy of this License.</para>
      </listitem>

      <listitem><para>Preserve the section
      entitled "History", and its title, and add to it an item stating
      at least the title, year, new authors, and publisher of the
      Modified Version as given on the Title Page.  If there is no
      section entitled "History" in the Document, create one stating
      the title, year, authors, and publisher of the Document as given
      on its Title Page, then add an item describing the Modified
      Version as stated in the previous sentence.</para>
      </listitem>

      <listitem><para>Preserve the network
      location, if any, given in the Document for public access to a
      Transparent copy of the Document, and likewise the network
      locations given in the Document for previous versions it was
      based on.  These may be placed in the "History" section.  You
      may omit a network location for a work that was published at
      least four years before the Document itself, or if the original
      publisher of the version it refers to gives permission.</para>
      </listitem>

      <listitem><para>In any section entitled
      "Acknowledgements" or "Dedications", preserve the section's
      title, and preserve in the section all the substance and tone of
      each of the contributor acknowledgements and/or dedications
      given therein.</para>
      </listitem>

      <listitem><para>Preserve all the
      Invariant Sections of the Document, unaltered in their text and
      in their titles.  Section numbers or the equivalent are not
      considered part of the section titles.</para>
      </listitem>

      <listitem><para>Delete any section
      entitled "Endorsements".  Such a section may not be included in
      the Modified Version.</para>
      </listitem>

      <listitem><para>Do not retitle any
      existing section as "Endorsements" or to conflict in title with
      any Invariant Section.</para>
      </listitem>
    </orderedlist>

    <para>If the Modified Version includes new front-matter sections
    or appendices that qualify as Secondary Sections and contain no
    material copied from the Document, you may at your option
    designate some or all of these sections as invariant.  To do this,
    add their titles to the list of Invariant Sections in the Modified
    Version's license notice.  These titles must be distinct from any
    other section titles.</para>

    <para>You may add a section entitled "Endorsements", provided it
    contains nothing but endorsements of your Modified Version by
    various parties--for example, statements of peer review or that
    the text has been approved by an organization as the authoritative
    definition of a standard.</para>

    <para>You may add a passage of up to five words as a Front-Cover
    Text, and a passage of up to 25 words as a Back-Cover Text, to the
    end of the list of Cover Texts in the Modified Version.  Only one
    passage of Front-Cover Text and one of Back-Cover Text may be
    added by (or through arrangements made by) any one entity.  If the
    Document already includes a cover text for the same cover,
    previously added by you or by arrangement made by the same entity
    you are acting on behalf of, you may not add another; but you may
    replace the old one, on explicit permission from the previous
    publisher that added the old one.</para>

    <para>The author(s) and publisher(s) of the Document do not by
    this License give permission to use their names for publicity for
    or to assert or imply endorsement of any Modified Version.</para>
  </sect1>

  <sect1 label="5">
    <title>COMBINING DOCUMENTS</title>

    <para>You may combine the Document with other documents released
    under this License, under the terms defined in section 4 above for
    modified versions, provided that you include in the combination
    all of the Invariant Sections of all of the original documents,
    unmodified, and list them all as Invariant Sections of your
    combined work in its license notice.</para>

    <para>The combined work need only contain one copy of this
    License, and multiple identical Invariant Sections may be replaced
    with a single copy.  If there are multiple Invariant Sections with
    the same name but different contents, make the title of each such
    section unique by adding at the end of it, in parentheses, the
    name of the original author or publisher of that section if known,
    or else a unique number.  Make the same adjustment to the section
    titles in the list of Invariant Sections in the license notice of
    the combined work.</para>

    <para>In the combination, you must combine any sections entitled
    "History" in the various original documents, forming one section
    entitled "History"; likewise combine any sections entitled
    "Acknowledgements", and any sections entitled "Dedications".  You
    must delete all sections entitled "Endorsements."</para>
  </sect1>

  <sect1 label="6">
    <title>COLLECTIONS OF DOCUMENTS</title>

    <para>You may make a collection consisting of the Document and
    other documents released under this License, and replace the
    individual copies of this License in the various documents with a
    single copy that is included in the collection, provided that you
    follow the rules of this License for verbatim copying of each of
    the documents in all other respects.</para>

    <para>You may extract a single document from such a collection,
    and distribute it individually under this License, provided you
    insert a copy of this License into the extracted document, and
    follow this License in all other respects regarding verbatim
    copying of that document.</para>
  </sect1>

  <sect1 label="7">
    <title>AGGREGATION WITH INDEPENDENT WORKS</title>

    <para>A compilation of the Document or its derivatives with other
    separate and independent documents or works, in or on a volume of
    a storage or distribution medium, does not as a whole count as a
    Modified Version of the Document, provided no compilation
    copyright is claimed for the compilation.  Such a compilation is
    called an "aggregate", and this License does not apply to the
    other self-contained works thus compiled with the Document, on
    account of their being thus compiled, if they are not themselves
    derivative works of the Document.</para>

    <para>If the Cover Text requirement of section 3 is applicable to
    these copies of the Document, then if the Document is less than
    one quarter of the entire aggregate, the Document's Cover Texts
    may be placed on covers that surround only the Document within the
    aggregate.  Otherwise they must appear on covers around the whole
    aggregate.</para>
  </sect1>

  <sect1 label="8">
    <title>TRANSLATION</title>

    <para>Translation is considered a kind of modification, so you may
    distribute translations of the Document under the terms of section
    4.  Replacing Invariant Sections with translations requires
    special permission from their copyright holders, but you may
    include translations of some or all Invariant Sections in addition
    to the original versions of these Invariant Sections.  You may
    include a translation of this License provided that you also
    include the original English version of this License.  In case of
    a disagreement between the translation and the original English
    version of this License, the original English version will
    prevail.</para>
  </sect1>

  <sect1 label="9">
    <title>TERMINATION</title>

    <para>You may not copy, modify, sublicense, or distribute the
    Document except as expressly provided for under this License.  Any
    other attempt to copy, modify, sublicense or distribute the
    Document is void, and will automatically terminate your rights
    under this License.  However, parties who have received copies, or
    rights, from you under this License will not have their licenses
    terminated so long as such parties remain in full
    compliance.</para>
  </sect1>

  <sect1 label="10">
    <title>FUTURE REVISIONS OF THIS LICENSE</title>

    <para>The Free Software Foundation may publish new, revised
    versions of the GNU Free Documentation License from time to time.
    Such new versions will be similar in spirit to the present
    version, but may differ in detail to address new problems or
    concerns.  See <ulink
    url="http://www.gnu.org/copyleft/">http://www.gnu.org/copyleft/</ulink>.</para>

    <para>Each version of the License is given a distinguishing
    version number.  If the Document specifies that a particular
    numbered version of this License "or any later version" applies to
    it, you have the option of following the terms and conditions
    either of that specified version or of any later version that has
    been published (not as a draft) by the Free Software Foundation.
    If the Document does not specify a version number of this License,
    you may choose any version ever published (not as a draft) by the
    Free Software Foundation.</para>
  </sect1>

  <sect1 label="">
    <title>How to use this License for your documents</title>

    <para>To use this License in a document you have written, include
    a copy of the License in the document and put the following
    copyright and license notices just after the title page:</para>

<blockquote><para>
      Copyright (c)  YEAR  YOUR NAME.
      Permission is granted to copy, distribute and/or modify this document
      under the terms of the GNU Free Documentation License, Version 1.1
      or any later version published by the Free Software Foundation;
      with the Invariant Sections being LIST THEIR TITLES, with the
      Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
      A copy of the license is included in the section entitled "GNU
      Free Documentation License".
</para></blockquote>

    <para>If you have no Invariant Sections, write "with no Invariant
    Sections" instead of saying which ones are invariant.  If you have
    no Front-Cover Texts, write "no Front-Cover Texts" instead of
    "Front-Cover Texts being LIST"; likewise for Back-Cover
    Texts.</para>

    <para>If your document contains nontrivial examples of program
    code, we recommend releasing these examples in parallel under your
    choice of free software license, such as the GNU General Public
    License, to permit their use in free software.</para>
  </sect1>

</appendix>

</article>

<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:nil
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:2
sgml-parent-document: ("referenz.sgml" "appendix")
sgml-exposed-tags:nil
sgml-local-ecat-files:nil
sgml-local-catalogs: CATALOG
sgml-validate-command: "nsgmls -s referenz.sgml"
ispell-skip-sgml: t
End:
-->
