Re: Compile docs on ArchLinux

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: depesz(at)depesz(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Compile docs on ArchLinux
Date: 2012-04-20 04:00:59
Message-ID: CAB7nPqT2Y3wvWn8tW3MTv_1610sS9CjauxTNeR66xcqVy22zMg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Apr 18, 2012 at 6:51 PM, hubert depesz lubaczewski <
depesz(at)depesz(dot)com> wrote:

> On Wed, Apr 18, 2012 at 01:25:14PM +0900, Michael Paquier wrote:
> > Hi all,
> >
> > Under Arch, I am not able to compile Postgres docs.
> >
> > By having a look at config.log, it cannot find the docbook folder:
> > configure:29356: checking for DocBook V4.2
> > onsgmls:/etc/xml/catalog:2:78:E: name expected
> > onsgmls:/etc/xml/catalog:2:18:E: cannot find "PUBLIC"; tried
> > "/etc/xml/PUBLIC", "/usr/share/sgml/PUBLIC", "/usr/share/xml/PUBLIC"
> > onsgmls:conftest.sgml:1:54:W: cannot generate system identifier for
> public
> > text "-//OASIS//DTD DocBook V4.2//EN"
> >
> > The stylesheets are correctly set up.
> > configure:29391: checking for DocBook stylesheets
> > configure:29427: result: /usr/share/sgml/stylesheets/dsssl/docbook
> >
> > It looks that the correct packages are installed:
> > $ pacman -Q | grep docbook
> > docbook-dsssl 1.79-3
> > docbook-sgml 4.5-1
> > docbook-xml 4.5-5
> > docbook-xsl 1.76.1-2
> > docbook2x 0.8.8-11
> > Well, docbook-sgml 4.5 is installed, not 4.2, but I would suppose that it
> > is enough.
> >
> > Is it necessary to setup a variable like DOCBOOKSTYLE?
> > Thanks in advance!
>
> I don't think it will be solved - I reported it in november 2009
> : http://archives.postgresql.org/pgsql-general/2009-11/msg00325.php
> then asked on serverfault
> :
> http://serverfault.com/questions/83206/how-to-build-docbook-4-2-docs-on-arch-linux
>

I found a solution to compile the docs on Arch.
That's tricky, but I get html and man compilation working.
There were 2 issues:
1) docbook-sgml 4.2 was not taken into account
To solve that I downloaded docbook-sgml 4.2 here:
http://www.oasis-open.org/docbook/sgml/4.2/
and installed it manually with those commands to include them in catalogs:
cp docbook.cat docbook.cat.orig &&
sed -e '/ISO 8879/d' docbook.cat.orig > docbook.cat &&
cp docbook.cat docbook.cat.orig &&
sed -e '/gml/d' docbook.cat.orig > docbook.cat &&
install -d /usr/share/sgml/docbook/sgml-dtd-4.2 &&
chown -R root:root . &&
chmod -R 755 . &&
install docbook.cat /usr/share/sgml/docbook/sgml-dtd-4.2/catalog &&
cp -af *.dtd *.mod *.dcl /usr/share/sgml/docbook/sgml-dtd-4.2 &&
install-catalog --add /etc/sgml/sgml-docbook-dtd-4.2.cat \
/usr/share/sgml/docbook/sgml-dtd-4.2/catalog &&
install-catalog --add /etc/sgml/sgml-docbook-dtd-4.2.cat \
/etc/sgml/sgml-docbook.cat

Not sure though if it is the cleanest way to do though... I am not a
packager.

2) There is an error in the package jade of ArchLinux. For a reason I don't
know why, the catalog files of Jade are not included in package, so html
compilation caouldn't work.
So I picked them up from another place, and copied them somewhere, here
/usr/share/sgml/jade/ as it is where they should normally be.
I attach them to this email for convenience.

Then you need only to setup SGML_CATALOG_FILES to redirect to catalogs just
before configure, here:
export SGML_CATALOG_FILES=/etc/sgml/catalog:/usr/share/sgml/jade/catalog

And you're done! I have "make world" working correctly, man and html are
compiled.
That's tricky but efficient.
--
Michael Paquier
http://michael.otacoo.com

Attachment Content-Type Size
jade_catalog_postgres.tar.gz application/x-gzip 4.9 KB

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Thom Brown 2012-04-20 08:15:53 Unaccent characters
Previous Message tuanhoanganh 2012-04-20 03:25:05 Re: pgstat wait timeout