Hi Theppitak, On 8/27/06, Theppitak Karoonboonyanan <[EMAIL PROTECTED]> wrote: > My language has no plural form. And I recently got some > complaint that having more than one msgstr[] while > declaring nplurals=1 blocks the build due to gettext error. > So, I try to examine if there are other such errors left in > any other packages.
I'm afraid you are using gettext >= 0.15, as it is more strict in checking plural form and mark inconsistent Plural-Forms and actually translation as error. gettext < 0.15 just ignore it and wouldn't complain. For the real fix, you can remove any entry containing msgstr[1], leaving only msgstr[0]. Abel > > Actually, gedit was the one that gave me the impression > of the needs to keep multiple msgstr[] entries, even if > nplurals is 1. > > For example: > > #: ../gedit/dialogs/gedit-close-confirmation-dialog.c:451 > #: ../gedit/dialogs/gedit-close-confirmation-dialog.c:472 > #, c-format > msgid "If you don't save, changes from the last hour will be permanently > lost." > msgid_plural "" > "If you don't save, changes from the last %d hours will be permanently lost." > > This comes from the merge of two string occurrences, one is c-format > and the other is not: > > #: ../gedit/dialogs/gedit-close-confirmation-dialog.c:451 > secondary_msg = g_strdup (_("If you don't save, > changes from the last hour " > "will be > permanently lost.")); > > and: > > #: ../gedit/dialogs/gedit-close-confirmation-dialog.c:472 > secondary_msg = g_strdup_printf ( > ngettext ("If you don't save, > changes from the last hour " > "will be permanently lost.", > "If you don't save, > changes from the last %d hours " > "will be permanently lost.", > hours), > hours); > > So, if I have to choose only one translation, one of the two > will be messed up. That is, with %d in the translation, the former > case will confuse user with "%d" appearing in the string; > without %d, the latter will loose the number information. > > The same appears here as well: > #: ../gedit/gedit-commands-file.c:1184 ../gedit/gedit-commands-file.c:1205 > > How should I do with this? > > -- > Theppitak Karoonboonyanan > http://linux.thai.net/~thep/ > _______________________________________________ > gnome-i18n mailing list > gnome-i18n@gnome.org > http://mail.gnome.org/mailman/listinfo/gnome-i18n > -- Abel Cheung (GPG Key: 0xC67186FF) Key fingerprint: 671C C7AE EFB5 110C D6D1 41EE 4152 E1F1 C671 86FF -------------------------------------------------------------------- * GNOME Hong Kong - http://www.gnome.hk/ * Opensource Application Knowledge Assoc. - http://oaka.org/ _______________________________________________ gnome-i18n mailing list gnome-i18n@gnome.org http://mail.gnome.org/mailman/listinfo/gnome-i18n