Re: gettext

On Tue, May 17, 2016 at 2:36 AM Daiki Ueno <ueno gnu org> wrote:
philip chimento gmail com writes:

> After trying it out, it's very unfortunate that msgfmt doesn't have an
> argument allowing you to specify a custom ITS rule; it only detects
> ones that have been installed into the Gettext data directories.

The xgettext's --its option was originally added for testing purpose (to
check if a given ITS file works as expected).  The suggested way to
specify custom ITS rules is to install those files in
/usr/share/gettext, because of ...

> Also, if you use xgettext's --its option to specify a custom ITS rule,
> then it seems not to pick up translatable strings from C sources
> anymore; but without it, it won't pick them up from the XML
> files. I'll check again tomorrow and otherwise report this as a bug.

... this.  It is the same limitation that -L, -k, --flags options are
effective for all input files.  There was a discussion to support
per-file options, but it is not implemented yet:

Anyway, thanks for writing up the document!

Thanks for the clarification!

Do you know of an Autotools workflow with xgettext / msgfmt that could replace the one I described with itstool in the document?

I'm thinking specifically of a case where the XML format is ad-hoc to the package (such as gtksourceview), and therefore the ITS rule can't be installed into /usr/share/gettext because then the package would require itself to be installed in order to be able to run make dist, for example. 


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