TBook on UbuntuLinux HowTo
Luca Roversi

Table of Contents

1
2
3
4

1 Setting up a deb archive from a tbook-xx.rpm

Assume tbook-1.5.2-1tb.i586.rpm, be downloaded from TBook project page, to directory /opt/downloads.

Build a deb package from it, by first running:
 alien tbook-xx.rpm
 mkdir debs
 mv tbook*.deb debs/
 dpkg-scanpackages debs /dev/null | gzip > debs/Packages.gz
 
then, by adding the line:
 deb file:/opt/downloads debs/
 
to file /etc/apt/sources.list and, finally, by running
 apt-get install tbook
 

2 Installing saxon

Tbook requires saxon-5.xx, which is provided by:
apt-get install lib-saxon-java
as a jar file in /usr/share/java.
Add the wrapper file saxon in /usr/bin
CLASSPATH=/usr/share/java/saxon.jar:$CLASSPATH
export CLASSPATH
java -ms15000000 com.icl.saxon.StyleSheet $1 $2 $3 $4 $5 $6 $7 $8 $9

3 Updating tetex configuration

Tbook is installed as a part of texmf tree. It effectively becomes a part of the tree by running:
texhash

4 Checking the installation

Then, in the same directory run:
tbprepare test
which will write a bounch of scripts and the file test.xml:


<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE book PUBLIC "-//Torsten Bronger//DTD tbook 1.5.2//EN"
                      "/usr//share/xml/tbook/tbook.dtd">
<book>
  <frontmatter>
    <title><!-- Your title here --></title>
    <author><!-- Your name here --></author>
  </frontmatter>
  <mainmatter>
    <!-- Your book here -->
  </mainmatter>
</book>

Finally try with
tbtolatex -t test
which should produce test.tex, that can be compiled by latex commands.