Re: [Po4a-devel] Bug#480997: pod2man turns UTF8 into "X"s
by Robert Luberda
On Mon, 12 May 2008, Russ Allbery wrote:
Hi,
> > Package: perl-doc
> > Version: 5.10.0-10
> >
> > UTF8 gets turned into "X" by pod2man, besides other disturbing issues:
>
> pod2man doesn't support non-ISO characters because doing so completely
> breaks (and by breaks, I mean up to and including segfaults) nroff on some
> platforms and the intention is that pod2man output be portable nroff.
Previous version (5.8.8) does support it. Anyway, this bug breaks
po4a package. After rebuilding po4a with new pod2man almast all its
translated man pages are unreadable...
Regards,
robert
16 years, 5 months
podlators 2.1.0 released
by Russ Allbery
This release adds a new --utf8 option to pod2man and corresponding
Pod::Man configuration option to write UTF-8 characters to the resulting
*roff output rather than trying to convert the characters to troff escapes
or just X for unknown characters. This is a separate option rather than
the default since UTF-8 characters are known to break some vendor *roff
implementations and the resulting *roff output is therefore not portable.
Linux distributions may wish to consider enabling this by default,
although there isn't a good way to do that as yet without patching the
module (and the documentation!).
I also fixed various other bugs turned up by Debian's switch to Perl 5.10.
Debian Perl maintainers, you will probably want to switch to this version
of Pod::Man before lenny.
The URL
http://archives.eyrie.org/software/modules/podlators-2.1.0.tar.gz
has entered CPAN as
file: $CPAN/authors/id/R/RR/RRA/podlators-2.1.0.tar.gz
size: 80707 bytes
md5: 9d4283c0975f8dfdedc47ca15ed63496
Changes since the previous release:
2008-06-01 Russ Allbery <rra(a)stanford.edu>
* VERSION: podlators 2.1.0 released.
* Makefile.PL: Add LICENSE.
* lib/Pod/Man.pm (format_text): If the utf8 option is set, don't
convert non-ASCII characters to *roff escapes or X. Document the
utf8 option.
* scripts/pod2man.PL: New option -u or --utf8 says to output
literal UTF-8 characters rather than pure ASCII.
* t/man-options.t: New file. Test the utf8 option.
* t/man.t: Be more cautious about passing an encoding to binmode
to allow for a Perl without PerlIO.
* lib/Pod/Man.pm (switchquotes): Match text between \f(CW and \fP
or \fR in headings non-greedily to get the fonts right with
multiple C<> formatting codes.
* t/man.t: Test =head1 with multiple C<> codes.
2008-05-14 Russ Allbery <rra(a)stanford.edu>
* lib/Pod/Man.pm (preamble_template): Protect .Sh text against
leading *roff control characters since some *roff implementations
apparently "look through" font escapes at the beginning of lines.
2008-05-12 Russ Allbery <rra(a)stanford.edu>
* lib/Pod/Man.pm (format_text): Escape backslashes separately from
processing non-ASCII characters and do that, dash escaping, and
underscore adjustment before processing non-ASCII characters.
Otherwise, we escape the hyphen in eth characters.
* t/man.t: Test for handling of eth.
--
Russ Allbery (rra(a)stanford.edu) <http://www.eyrie.org/~eagle/>
16 years, 6 months
Support for the fortunes format in po4a.
by Nicolas François
Hi,
You can find attached the new version of the Text.pm module for po4a, with
support for the fortunes format.
You can use it by replacing your
/usr/share/perl5/Locale/Po4a/Text.pm
Or just put the file in <one directory>/Locale/Po4a/Text.pm
and run po4a by preceding the command with PERLLIB=<one directory>/
You will have to add "-o fortunes" to the po4a commands to specify that
you want to use the fortunes format.
The support is still limited, but should be sufficient for the Debian
hints fortunes. I would like to add support comments and for references,
like in:
Packages should build-depend on what they should build-depend.
-- Santiago Vila on debian-devel
I will wait at least for po4a to enter testing (in 1 or 2 days), and I
will release a new version.
It would be useful if you could test it to check if it looks OK.
Note: if you add a newline before the URL of hint #9 in the German
hints-de, you will be able to reuse the German translation using:
PERLLIB=<one directory>/ po4a-gettextize -f text -o fortunes \
-m hints -l hints-de -p hints.de.po -L UTF-8
Best Regards,
--
Nekral
16 years, 6 months