[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Debhelper - docbookxml manpages

Am Freitag, den 17.08.2007, 12:11 +0200 schrieb Carl Fürstenberg:
> On 8/17/07, Sylvain Le Gall <gildor@debian.org> wrote:

> > Maybe you could split the thing as this :
> > * define a debian/XXX.docbookxmlmanpages file, it contains all
> >   the toplevel xml file to install (firt column) and the generated manpage
> >   (optional, second column).

When you use a make-snippet, you could also define the manpages to
create and write a rule, howto create e.g. .1 from .1.xml. In make:

	xsltproc ... $< ...

> >   If the generated manpage is not defined, it
> >   is assumed that it will be generated in the same directory of the
> >   source XML and using the name you can guess out of the XML file (just
> >   as you do in your debhelper script)
> > * the CDBS class will use the debian/*.docbookxmlmanpages as an input to
> >   guess what file to generate

See above.

> > * the debhelper script will use the debian/*.docbookxmlmanpages as an
> >   input to install the generated manpage.

Here you could use the option to create a manifest file and then simply
grep the contents of this file. I do it this way to not bother the user
with another file to maintain. See my solution at:
http://debian.wgdd.de/temp/dbxsl/dbxsl/debian/contrib/dh_db-man.make. My
idea was to automatically update a file (and the user could set this
file to package.manpages, so the file is automatically created).

> > People who don't want to use the CDBS class, can generate the manpage by
> > another way and still use everything (except the CDBS class).
> >
> > People who want to use the CDBS class, just have to write the manpage
> > ;-)
> >
> > If i am missing something, let me know. In particular, i don't have
> > followed the IRC talk about this (maybe you can send me a quick
> > summary).
> >
> > If you are interested in providing a full support of docbook XML
> > manpage, just tell me and i will give you a copy of my DARCS repository
> > so we can work on a good solution (before proposing to integrate it into
> > debhelper/cdbs).
> A thing to remember is that one xml file can result in multiple man
> pages, that's why I'm using libxml to grab all the manpages from the
> xml file,

This is not necessary. Check the man.output.manifest.enabled parameter
of docbook-xsl. The created file contains the names and paths (the
latter if subdirs are enabled) of all created manpages. You can safely
use this this option and then check the created manifest (change the
filename of this file via the man.output.manifest.filename parameter).

> in the cdbs version to know what to remove, and in the
> debhelper version to know what file to install.

See above.

Regards, Daniel

Reply to: