Hi,

From: Nicolas François <[EMAIL PROTECTED]>
Subject: Re: Bug#398711: po4a: Please include xml in the list of valid formats.
Date: Wed, 15 Nov 2006 21:44:18 +0100

> Hello,
> 
> On Wed, Nov 15, 2006 at 05:53:21PM +0900, Kobayashi Noritada wrote:
> > 
> > `po4a-gettextize --help-format' outputs a following list:
> > 
> > List of valid formats:
> >   - kernelhelp: Help messages of each kernel compilation option.
> >   - man: Good old manual page format.
> >   - pod: Perl Online Documentation format.
> >   - sgml: either debiandoc or docbook DTD.
> >   - dia: uncompressed Dia diagrams.
> >   - guide: Gentoo Linux's xml documentation format.
> >   - docbook: Docbook XML.
> >   - latex: LaTeX format.
> >   - texinfo: The info page format.
> > 
> > However, at least an `xml' option is lacking.  Since I don't know
> > which of formats are mature enough to be written here, I cannot
> > provide a patch.
> 
> All the modules distributed in the Debian package are considered mature
> enough.
> However, I don't know whether the xml (and tex) modules should be
> specified in this list.
> These modules are used to defined derivative modules (docbook, guide, dia for
> the xml module and latex and texinfo for the tex module).

Hmm...

Why I sent this bur report is, when I intended to parse an HTML file,
I got a following message:

nori1[11:38]% po4a-gettextize -v -f html -m test.en.html -l test.ja.html -p 
ja.po
Unknown format type: html.
po4a::chooser: Module loading error: Can't locate Locale/Po4a/Html.pm in @INC
               (@INC contains: /etc/perl /usr/local/lib/perl/5.8.4
               /usr/local/share/perl/5.8.4 /usr/lib/perl5 /usr/share/perl5
               /usr/lib/perl/5.8 /usr/share/perl/5.8 /usr/local/lib/site_perl .)
               at (eval 7) line 2.
               BEGIN failed--compilation aborted at (eval 7) line 2.

List of valid formats:
  - kernelhelp: Help messages of each kernel compilation option.
  - man: Good old manual page format.
  - pod: Perl Online Documentation format.
  - sgml: either debiandoc or docbook DTD.
  - dia: uncompressed Dia diagrams.
  - guide: Gentoo Linux's xml documentation format.
  - docbook: Docbook XML.
  - latex: LaTeX format.
  - texinfo: The info page format.

So, I tried to use 'sgml' instead of 'html', but it was also rejected
like this:

nori1[11:38]% po4a-gettextize -v -f sgml -m test.en.html -l test.ja.html -p 
ja.po
po4a::sgml: Trying to handle a XML document as a SGML one. Feel lucky if it
            works, help us implementing a proper XML backend if it does not.
po4a::sgml: DTD of this file is unknown. (supported: debiandoc, docbook). The
            prolog follows:

            <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
               "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"; >

Finally, I see an XML backend in the web page.  So, I tried to use
'xml' and the conversion successed:

nori1[11:38]% po4a-gettextize -v -f xml -m test.en.html -l test.ja.html -p ja.po

This guide was highly indirect, although I know we have no problem if
we get a proper HTML backend. :-)

> I've added the ini and text format which were missing.
> 
> For XML and TeX, I can add something like:
> 
> List of valid formats:
> [...]
> Generic modules for derivative format:
>  * xml: XML based format
>         already derived by the docbook, guide and dia modules
>  * tex: TeX based format
>         already derived by the latex and texinfo modules
> 
> Does it seems OK to you?

How about the status of an HTML backend, which worked well for my
simple document?  Is it too young to be written here, and aren't HTML
documents supported by any modules?

For others, seems OK.

Thanks,

-nori

Reply via email to