jeudi 25 septembre 2008
Building PDF for PostGIS using dblatex
Par david techer, jeudi 25 septembre 2008 à 12:45 :: PostGIS et PostgreSQL
By default when you want to have the postgis.pdf taken from the source, you have to install fo or db2pdf. However, you can use a tool like dblatex. The solution is available at http://dblatex.sourceforge.net/. This project is maintaned by Benoà ®t Guillon (a French guy too like me
).
The main goal is as followed

Install dblatex >=0.2.7
First of all you need dblatex. Please read the instructions taken from the dblatex's site. You need to have python, latex and so on..
When you're ready. It is time to install
./setup.py install
Building the pdf doc from PostGIS
- Download the sources from svn
wget http://www.postgis.org/postgis-svn.tar.gz
- Untar the sources
tar xvf postgis-svn.tar.gz
- Go to postgis directory, run configure and go to doc directory
./configure && cd doc && make
- The file
reference.xml
must be change. We have to replace the term entry by listitem before using dbaltexcp reference.xml reference.xml.orig; cat reference.xml.orig |sed -e "s:term:listitem:g" > reference.xml
- It's time to use dblatex. Here is the command and the output
root@olivia:/mnt/sources/tmp/postgis-svn/doc#
dblatex -T native -t pdf -o postgis-svn-1.4.0.pdf -I "$PWD/html" postgis-out.xml
Build the listings... XSLT stylesheets DocBook - LaTeX 2e (0.2.9) =================================================== convert "/mnt/sources/tmp/postgis-svn/doc/html/images/st_crosses-math.gif" fig0.pdf convert "/mnt/sources/tmp/postgis-svn/doc/html/images/st_crosses01.gif" fig1.pdf convert "/mnt/sources/tmp/postgis-svn/doc/html/images/st_crosses02.gif" fig2.pdf convert "/mnt/sources/tmp/postgis-svn/doc/html/images/st_crosses03.gif" fig3.pdf convert "/mnt/sources/tmp/postgis-svn/doc/html/images/st_crosses04.gif" fig4.pdf convert "/mnt/sources/tmp/postgis-svn/doc/html/images/st_touches-math.gif" fig5.pdf Build postgis-out.pdf This is pdfeTeX, Version 3.141592-1.30.5-2.2 (Web2C 7.5.5) entering extended mode This is pdfeTeX, Version 3.141592-1.30.5-2.2 (Web2C 7.5.5) entering extended mode 'postgis-svn-1.4.0.pdf' successfully built
Here is the final PDF http://www.davidgis.fr/download/postgis-svn-1.4.0.pdf...Beautifull isn't it ???