Update to 0.60. From the changelog: 0.60: Asciidoc: * Introduce "compat" option to parse like asciidoc or asciidoctor. Text (and Markdown): * Fix the support of nested lists (GitHub's #131). Other: * Remove the experimental C extension that was never built, distributed, tested nor modified since 2007. XML: * Provide a meaningful message when the translators butcher the <placeholder> attributes instead of truncating the file. (GitHub's #254) 0.59.1: po4a tool: * Really fix --srcdir and --destdir handling (Debian's #960892 again). Even with the previous fix, the aptitude package was still broken. Documentation: * Clarify the syntax of -o parameters (GitHub's #233). Sgml: * Sort the attributes. Without this, msgids are randomly fuzzied. (Debian's #725931 and Debian's #810988) 0.59: po4a tool: * Fix --srcdir handling (GitHub's #237 and Debian's #960892). This bug was breaking the build of several packages, including dpkg. Addendum: * New mode 'eof' to easily add at the end of the file (Debian's #960949). Documentation: * Fix many typos and glitches * Start a section about external projects using po4a Tests: * po4a: Add a test for the [po_directory] feature Overall: * Improve the displayed messages, don't translate debug messages. 0.58.1: Documentation: * Document an option of the XML parser (GitHub's #223). * Small glitches found during the translations. Tests: * Also ignore 'Project-Id-Version' when diffing PO files (GitHub's #224) * asciidoc: reactivate tablecells tests AsciiDoc: * Fix management of images in tables (Github's #226) * Tolerate underline length variations in two lines titles (Github's #212) 0.58: AsciiDoc: * Accept numbered list items beginning with any number of dots (GitHub's #210) Markdown: * Avoid translating Markdown fenced code block info string (GitHub's #194) * List Markdown fenced code block info string as text type (GitHub's #195) * Support YAML Front Matter (GitHub's #196). This requires YAML::Tiny. * Introduce options yfm_keys and yfm_skip_array to respectively specify which YAML keys should be translated, and that the array content should not be translated. * Work around a bug in YAML::Tiny that quotes numbers (GitHub's #217) * Add gettext flag "markdown-text" for relevant entries (GitHub's #208) Text: * Honor the (existing) --neverwrap option to handle every content verbatim. Texinfo: * Add the comments starting with 'TRANSLATORS:' to the po file (GitHub's #162) XHTML: * Don't fail nor warn when a closing tag is missing, that's legit in HTML. (GitHub's #179) XML and DocBook: * Allow attributes with no value (GitHub's #178). * Processing Instructions are handled as inline tags by default, but you can change them back to breaking with '-o break-pi' (GitHub's #170) Yaml: * Introduce option to skip array values. (GitHub's #187) po4a tool: * Cleanups and fixups about options' parsing (now tested and documented) _ / \ You may need to upgrage your po4a.conf if you were using /_!_\ "unwanted features" (ie, bugs) of the previous implementation. * Do not touch source dir when --destdir is provided (Debian #602387) * Pass --add-location=file to msgmerge when receiving option porefs. (requires gettext >= 0.19 -- June 2014) * Option --master-charset sets the charset of the generated POT file. * Option --master-language sets the language of the generated POT file. * Add support for addendum path in po4a_paths (Debian #823189) * Stop pretending that --porefs can control the wrapping of reference comments, as the gettext tools used internally always rewrap them. Scripts: * Rename po4aman-display-po to po4a-display-man * Rename po4apod-display-po to po4a-display-pod Core: * Use UTF-8 by default (the 20th century is over -- Debian #862460) po4a used to prefer ascii unless it proved impossible. But the underlying detection would fail, possibly for document containing UTF-8 chars composed on printable ascii chars only. * Add a --wrap-po option to control how the po file is wrapped, and chose between either nicely wrapped files that tend to produce git conflicts, or ugly files that are easy to automatically deal with. Tests: * Completely refactor most tests. They are now more reliable and the error messages are much more useful to understand the issues. * Many bugs to po4a and the core were ironed out in the process. * PO files content are now tested too (GitHub's #67) Documentation: * Various cleanups by Golubev Alexander (GitHub's #190 & #191)diff -r1.42 -r1.43 pkgsrc/textproc/po4a/Makefile
(schmonz)
@@ -1,17 +1,16 @@ | @@ -1,17 +1,16 @@ | |||
1 | # $NetBSD: Makefile,v 1.42 2020/09/04 10:38:13 wiz Exp $ | 1 | # $NetBSD: Makefile,v 1.43 2020/09/17 21:13:18 schmonz Exp $ | |
2 | 2 | |||
3 | DISTNAME= po4a-0.57 | 3 | DISTNAME= po4a-0.60 | |
4 | PKGREVISION= 3 | |||
5 | CATEGORIES= textproc | 4 | CATEGORIES= textproc | |
6 | MASTER_SITES= ${MASTER_SITE_GITHUB:=mquinson/} | 5 | MASTER_SITES= ${MASTER_SITE_GITHUB:=mquinson/} | |
7 | GITHUB_RELEASE= v${PKGVERSION_NOREV} | 6 | GITHUB_RELEASE= v${PKGVERSION_NOREV} | |
8 | 7 | |||
9 | MAINTAINER= pkgsrc-users@NetBSD.org | 8 | MAINTAINER= pkgsrc-users@NetBSD.org | |
10 | HOMEPAGE= https://po4a.org/ | 9 | HOMEPAGE= https://po4a.org/ | |
11 | COMMENT= Tool for using gettext where it was not intended to be used | 10 | COMMENT= Tool for using gettext where it was not intended to be used | |
12 | LICENSE= gnu-gpl-v2 | 11 | LICENSE= gnu-gpl-v2 | |
13 | 12 | |||
14 | DEPENDS+= docbook-xsl-[0-9]*:../../textproc/docbook-xsl | 13 | DEPENDS+= docbook-xsl-[0-9]*:../../textproc/docbook-xsl | |
15 | DEPENDS+= p5-gettext>=1.01:../../devel/p5-gettext | 14 | DEPENDS+= p5-gettext>=1.01:../../devel/p5-gettext | |
16 | DEPENDS+= p5-SGMLS-[0-9]*:../../textproc/p5-SGMLS | 15 | DEPENDS+= p5-SGMLS-[0-9]*:../../textproc/p5-SGMLS | |
17 | DEPENDS+= p5-Term-ReadKey-[0-9]*:../../devel/p5-Term-ReadKey | 16 | DEPENDS+= p5-Term-ReadKey-[0-9]*:../../devel/p5-Term-ReadKey | |
@@ -20,27 +19,27 @@ DEPENDS+= p5-Text-WrapI18N-[0-9]*:../../ | @@ -20,27 +19,27 @@ DEPENDS+= p5-Text-WrapI18N-[0-9]*:../../ | |||
20 | DEPENDS+= p5-PerlIO-utf8_strict-[0-9]*:../../devel/p5-PerlIO-utf8_strict | 19 | DEPENDS+= p5-PerlIO-utf8_strict-[0-9]*:../../devel/p5-PerlIO-utf8_strict | |
21 | DEPENDS+= p5-Unicode-LineBreak-[0-9]*:../../textproc/p5-Unicode-LineBreak | 20 | DEPENDS+= p5-Unicode-LineBreak-[0-9]*:../../textproc/p5-Unicode-LineBreak | |
22 | DEPENDS+= p5-YAML-Tiny-[0-9]*:../../textproc/p5-YAML-Tiny | 21 | DEPENDS+= p5-YAML-Tiny-[0-9]*:../../textproc/p5-YAML-Tiny | |
23 | # kpsewhich | 22 | # kpsewhich | |
24 | DEPENDS+= kpathsea-[0-9]*:../../print/kpathsea | 23 | DEPENDS+= kpathsea-[0-9]*:../../print/kpathsea | |
25 | # article.cls | 24 | # article.cls | |
26 | DEPENDS+= tex-latex-[0-9]*:../../print/tex-latex | 25 | DEPENDS+= tex-latex-[0-9]*:../../print/tex-latex | |
27 | 26 | |||
28 | USE_TOOLS+= pkg-config perl:run msgmerge:run msgfmt:run | 27 | USE_TOOLS+= pkg-config perl:run msgmerge:run msgfmt:run | |
29 | 28 | |||
30 | PERL5_MODULE_TYPE= Module::Build | 29 | PERL5_MODULE_TYPE= Module::Build | |
31 | PERL5_PACKLIST= auto/po4a/.packlist | 30 | PERL5_PACKLIST= auto/po4a/.packlist | |
32 | 31 | |||
33 | REPLACE_PERL= scripts/msguntypot po4a po4a-gettextize po4a-normalize | 32 | REPLACE_PERL= msguntypot po4a po4a-gettextize po4a-normalize | |
34 | REPLACE_PERL+= po4a-translate po4a-updatepo | 33 | REPLACE_PERL+= po4a-translate po4a-updatepo | |
35 | REPLACE_PERL+= lib/Locale/Po4a/* | 34 | REPLACE_PERL+= lib/Locale/Po4a/* | |
36 | 35 | |||
37 | MAKE_ENV+= COLUMNS=76 | 36 | MAKE_ENV+= COLUMNS=76 | |
38 | 37 | |||
39 | # work around not to set PATH to msgmerge, please somebody to fix correctly | 38 | # work around not to set PATH to msgmerge, please somebody to fix correctly | |
40 | SUBST_CLASSES+= path | 39 | SUBST_CLASSES+= path | |
41 | SUBST_FILES.path= po4a | 40 | SUBST_FILES.path= po4a | |
42 | SUBST_MESSAGE.path= Fix msgmerge command path (not found) | 41 | SUBST_MESSAGE.path= Fix msgmerge command path (not found) | |
43 | SUBST_STAGE.path= pre-configure | 42 | SUBST_STAGE.path= pre-configure | |
44 | SUBST_SED.path= -e 's|\"msgmerge\"|\"${PREFIX}/bin/msgmerge\"|;' | 43 | SUBST_SED.path= -e 's|\"msgmerge\"|\"${PREFIX}/bin/msgmerge\"|;' | |
45 | 44 | |||
46 | .include "../../devel/gettext-tools/buildlink3.mk" | 45 | .include "../../devel/gettext-tools/buildlink3.mk" |
@@ -1,7 +1,7 @@ | @@ -1,7 +1,7 @@ | |||
1 | $NetBSD: distinfo,v 1.18 2020/03/05 14:02:37 schmonz Exp $ | 1 | $NetBSD: distinfo,v 1.19 2020/09/17 21:13:18 schmonz Exp $ | |
2 | 2 | |||
3 | SHA1 (po4a-0.57.tar.gz) = e04773a3fdf8fa9ab260435e3022da708a76af4d | 3 | SHA1 (po4a-0.60.tar.gz) = fd076e28461fee9e61d90ae9f61622c69f417f0a | |
4 | RMD160 (po4a-0.57.tar.gz) = 66738abe4e00e31fe4291953b45345ad762e2b9a | 4 | RMD160 (po4a-0.60.tar.gz) = dc0429780f54153840d8b09be1749d0b7b1f1d1b | |
5 | SHA512 (po4a-0.57.tar.gz) = 7ac2e614c126b049feeb8edbafb71a875cee78fb85d8cd74f3bf5b555cc8b2d19d5e4606b732e714e937c34e178729d73edfe559de594c5ffe811b5162b27d81 | 5 | SHA512 (po4a-0.60.tar.gz) = b1e32169221d6aaf49fa0e6a42e45a858c8608a62470e5d5b769da985e4d03e09a220384400fe36f740447770331f7b8b821f00dc9ce68d3c7b00178c146c6a9 | |
6 | Size (po4a-0.57.tar.gz) = 3079550 bytes | 6 | Size (po4a-0.60.tar.gz) = 3799018 bytes | |
7 | SHA1 (patch-Po4aBuilder.pm) = 642d3155c5ebd1d85d70dc3359651c602b17fb56 | 7 | SHA1 (patch-Po4aBuilder.pm) = 7a39eaf25bf956386cc707be7f1b9af6219192e5 |
@@ -1,46 +1,46 @@ | @@ -1,46 +1,46 @@ | |||
1 | $NetBSD: patch-Po4aBuilder.pm,v 1.4 2020/03/05 14:02:37 schmonz Exp $ | 1 | $NetBSD: patch-Po4aBuilder.pm,v 1.5 2020/09/17 21:13:18 schmonz Exp $ | |
2 | 2 | |||
3 | (1) ryoon: remove gzip at initial import | 3 | (1) ryoon: remove gzip at initial import | |
4 | (2) mef: Add PerlIO::F_UTF8 () macro | 4 | (2) mef: Add PerlIO::F_UTF8 () macro | |
5 | (3) mef: to avoid --previous option is said unknown to msgmerge | 5 | (3) mef: to avoid --previous option is said unknown to msgmerge | |
6 | (but sounds strange) | 6 | (but sounds strange) | |
7 | 7 | |||
8 | --- Po4aBuilder.pm.orig 2013-08-22 05:11:04.000000000 +0900 | 8 | --- Po4aBuilder.pm.orig 2020-07-15 21:56:35.000000000 +0000 | |
9 | +++ Po4aBuilder.pm 2015-03-18 11:10:49.000000000 +0900 | 9 | +++ Po4aBuilder.pm | |
10 | @@ -8,6 +8,8 @@ use File::stat; | 10 | @@ -9,6 +9,8 @@ use File::stat; | |
11 | 11 | |||
12 | @ISA = qw(Module::Build); | 12 | @ISA = qw(Module::Build); | |
13 | 13 | |||
14 | +sub PerlIO::F_UTF8 () { 0x00008000 } # from perliol.h | 14 | +sub PerlIO::F_UTF8 () { 0x00008000 } # from perliol.h | |
15 | + | 15 | + | |
16 | sub ACTION_build { | 16 | sub ACTION_build { | |
17 | my $self = shift; | 17 | my $self = shift; | |
18 | $self->depends_on('code'); | 18 | $self->depends_on('code'); | |
19 | @@ -104,7 +106,7 @@ sub ACTION_binpo { | 19 | @@ -81,7 +83,7 @@ sub ACTION_binpo { | |
20 | my $lang = fileparse($_, qw{.po}); | 20 | my $lang = fileparse($_, qw{.po}); | |
21 | unless ($self->up_to_date("po/bin/po4a.pot", $_)) { | 21 | unless ($self->up_to_date("po/bin/po4a.pot", $_)) { | |
22 | print "XX Sync $_: "; | 22 | print "XX Sync $_: "; | |
23 | - system("msgmerge --previous $_ po/bin/po4a.pot -o $_.new") && die; | 23 | - system("msgmerge --previous $_ po/bin/po4a.pot -o $_.new") && die; | |
24 | + system("msgmerge $_ po/bin/po4a.pot -o $_.new") && die; | 24 | + system("msgmerge $_ po/bin/po4a.pot -o $_.new") && die; | |
25 | # Typically all that changes was a date. I'd | 25 | # Typically all that changes was a date. I'd | |
26 | # prefer not to commit such changes, so detect | 26 | # prefer not to commit such changes, so detect | |
27 | # and ignore them. | 27 | # and ignore them. | |
28 | @@ -253,8 +255,6 @@ sub ACTION_man { | 28 | @@ -232,8 +234,6 @@ sub ACTION_man { | |
29 | } | 29 | } | |
30 | $parser->parse_from_file ($file, $out); | 30 | $parser->parse_from_file ($file, $out); | |
31 | 31 | |||
32 | - system("gzip -9 -f $out") and die; | 32 | - system("gzip -9 -f $out") and die; | |
33 | - unlink "$file" || die; | 33 | - unlink "$file" || die; | |
34 | } | 34 | } | |
35 | 35 | |||
36 | # Install the manpages written in XML DocBook | 36 | # Install the manpages written in XML DocBook | |
37 | @@ -265,9 +265,7 @@ sub ACTION_man { | 37 | @@ -250,9 +250,7 @@ sub ACTION_man { | |
38 | if ($file =~ m,(.*/man(.))/([^/]*)\.xml$,) { | 38 | print "Convert $outdir/$outfile.$section (online docbook.xsl file). "; | |
39 | my ($outdir, $section, $outfile) = ($1, $2, $3); | 39 | system("xsltproc -o $outdir/$outfile.$section --nonet http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $file") and die; | |
40 | system("xsltproc -o $outdir/$outfile.$section --nonet http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $file") and die; | 40 | } | |
41 | - system ("gzip -9 -f $outdir/$outfile.$section") and die; | 41 | - system ("gzip -9 -f $outdir/$outfile.$section") and die; | |
42 | } | 42 | } | |
43 | - unlink "$file" || die; | 43 | - unlink "$file" || die; | |
44 | } | 44 | } | |
45 | } | 45 | } | |
46 | 46 |