bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: Feature: msgfmt should not include messages if msgid==msgstr


From: Bruno Haible
Subject: Re: Feature: msgfmt should not include messages if msgid==msgstr
Date: Mon, 10 Sep 2007 23:20:21 +0200
User-agent: KMail/1.5.4

Simos Xenitellis wrote:
> The way I would see this need for a --no-copied option is to provide
> those who make distributions the facility to reduce space on their
> discretion.
> 
> While disk space is cheap on the desktop/laptop, Linux is also being
> used in smaller devices with disk space and memory limits. While a user
> would set a fancy LANGUAGE string, there are cases that only one
> language is desired and can only be used (think for example the N800
> where you can only set the locale from a menu). In addition, the
> developer of a (non-installable) live cd may choose to support only one
> value in LANGUAGE.
> 
> The option to use "--no-copied" is up to the person who produces
> packages for the distribution, therefore it is one-way only (you have
> the option to "strip" the PO files just before you compile them to MO
> files; these stripped PO files are then discarded).
> 
> There are other specific cases that the maintainer can choose to do this
> "stripping" before the processing of the PO files; the weather applet in
> GNOME has over 4000 airports/cities in its database. For many languages
> (=translator coordinators), the majority of these cities are copied to
> msgstr. This specific case can shave off 7MB of uncompressed data from
> specific live CDs. Again, it's up to the distribution to accept or not.

Thanks for explaining this. While for you the small devices may be daily
business, for me they are exotic.

Supporting only 1 language, rather than a precedence list, is something
I can live with. But producing wrong translations is something that I
wish absolutely to avoid.

How about a program 'msgstrip' that strips a _set_ of .mo files, all at
once? When it operates on all .mo files at once, it can guarantee not to
produce translations that the translator had not intended. (Because when
stripping en_GB.mo it can look at en.mo.) If it is clearly documented that
  1) the set of .mo files that are passed to msgstrip has to be the
     *complete* set of .mo files for a given translation domain,
  2) the use of msgstrip kills the language precedence list feature,
I have no objection against such a program. The program should operate
on .mo files, not on .po files, since PO files are meant for translators.

Can you write such a program? You can use read-mo.h and write-mo.h for I/O
and message.h for message manipulation.

Bruno





reply via email to

[Prev in Thread] Current Thread [Next in Thread]