Commit graph

13 commits

Author SHA1 Message Date
jlam
0f4967eb59 Overhaul the way packages can ask for "msgfmt". If a package needs
msgfmt, then it should set the following in the package Makefile:

	USE_TOOLS+=	msgfmt

To deal with message files that use the "msgid_plural" statement,
which isn't supported in NetBSD<=3.x and also in gettext<=0.10.35, we
determine if the built-in "msgfmt" is sufficiently new enough to
understand "msgid_plural".  If it isn't, then we use the msgfmt.sh
script to transform the msgid_plural statements to an equivalent
construct that's understood by older msgfmt tools.

The msgfmt.sh script is a straightforward translation of the original
perl script msgfmt.pl script by Julio M. Merino Vidal into shell and
awk, which are more lightweight dependencies than perl.

We remove the USE_MSGFMT_PLURALS bits in gettext-lib/builtin.mk as they
are made obsolete by the new code in mk/tools/msgfmt.mk.

BUILD_USE_MSGFMT is still supported but will be removed in a separate
commit.
2006-04-13 16:35:57 +00:00
jmmv
350bfb7e78 Skip blank lines after msgid so that "incorrectly formatted" po files do
not break when using this script.  This should avoid having to patch some
po files to "fix" them.
2006-04-06 21:42:23 +00:00
jmmv
5774296b7a Fix the msgfmt.pl script to deal with messages with plurals whose strings
are identical (e.g., msgid == msgid_plural) by ignoring the duplicates.
In fact, this is a rewrite of the script, since I couldn't understand the
old one (ew).

Also change the way we use it to only pull it in the build if the real
msgfmt does not support plurals (i.e., it's older than 0.10.36).

Fixes PR pkg/30596 and PR pkg/30938 (both related to epiphany).
It also fixes the build of evolution-data-server and probably others.
2005-08-20 12:04:09 +00:00
jmmv
cf490c2b62 Add a script to workaround uses of msgid_plural, which is not yet supported
by our native libintl.  While it is not implemented, this allows us to build
programs against the native libintl, loosing very few functionality (some
translations of plural messages on few languages), and avoiding runtime
conflicts between native libintl and the gnu one (coming from the gettext
package).

Packages including .po files with uses of msgid_plural should define the
USE_MSGFMT_PLURALS variable to 'yes', so that the msgfmt wrapper is used.
(Do not use it when not really needed, as it will pull in perl5 as a build
dependancy).
2004-04-01 18:33:20 +00:00
agc
d7d36b3561 + move the distfile digest/checksum value from files/md5 to distinfo
+ move the patch digest/checksum values from files/patch-sum to distinfo
2001-04-17 10:57:56 +00:00
itojun
1ca82b0d3b move installation of gettextize files to devel/gettext.
repair gettext build on fresh install.  re-introduce gettextize file
installation.  reported by: mycroft
2000-11-29 05:05:28 +00:00
itojun
6859c75478 split devel/gettext into devel/gettext and devel/gettext-lib.
TODO: gettext-lib can be omitted if we have /usr/lib/libintl.a.
2000-10-31 17:06:17 +00:00
danw
1ccea032cc Add bugfixes from glibc and build a shared library version of libintl.
Bump version to 0.10.35nb1.
2000-06-30 17:07:35 +00:00
agc
a910a6fd62 Add package patch-sum files 1999-07-09 13:50:05 +00:00
tron
c4dfccdcd7 Move "gettext" package from "misc" to "devel" category. 1998-12-28 20:17:39 +00:00
tron
ed484a6e92 Update "gettext" package to version 0.10.35. 1998-12-23 00:14:16 +00:00
agc
877ca9ccf4 Modify for NetBSD:
+ add NetBSD RCS Ids.
+ modify comments and descriptions
+ add INFO files in Makefile
etc.
1998-09-04 12:38:53 +00:00
agc
e1c6bd0534 Initial import of GNU gettext 0.10, tools for providing messages in
different languages, into the NetBSD packages collection.  This is
taken from the FreeBSD port.
1998-09-04 12:33:38 +00:00