GNOME Bugzilla – Bug 129482
meld should use intltool
Last modified: 2009-08-15 18:40:50 UTC
meld in GNOME cvs should use intltool so that desktop files (and possibly other stuff as well) can be translated from within the regular po files. See http://developer.gnome.org/doc/tutorials/gnome-i18n/developer.html#use-intltool for reasons why intltool should be used and http://www.gnome.org/~malcolm/i18n/ for instructions on how to intltoolize. The most pressing problem right now is though that not even tools like intltool-update works with meld.
In the meanwhile, you can run "make update-po" from the po directory.
That doesn't work for me -- I only get "pygettext: command not found". Also, as long as meld doesn't work with intltool-update, it will be difficult to provide any translations for it for the majority of GNOME translators. The translation status pages that GNOME translators use for example requires intltool-update to work, so it currently not working with meld is the reason for meld showing up broken and yellow and without a pot file on the status pages: http://developer.gnome.org/projects/gtp/status/gnome-2.6/sv/extras/
Yes, should have made more clear that I definitely plan to support intltool. Strange about pygettext - maybe it's called pygettext2.2 or the like on your distro?
Nope. Can't find it anywhere (tested distros are Red Hat Linux and Fedora).
If you don't want to have any autotools dependencies and keep your current slim build system, you could simply do: mv POTFILES POTFILES.in; echo "#!/bin/bash" > update && echo "" >> update && echo "intltool-update -g meld $*" >> update && chmod +x update Calling ./update -p would generate meld.pot, ./update sr would update the Serbian po file. regs, CHris
Added meld.desktop.in to POTFILES.in as suggested. Added two scripts to po directory update-lang.sh and update-pot.sh. meld now shows up in the gnome translation status pages. Can I close this bug or is there something else required?
Strange; meld still shows up as a yellow bar on http://developer.gnome.org/projects/gtp/status/gnome-2.6/sv/extras/ (meaning that the pot file generation failed), and sure enough, when I check with intltool-update in the meld po directory, I still get an error: $ intltool-update --pot readline() on closed filehandle IN at /home/menthos/bin/intltool-update line 846. Cannot find top_srcdir in Makefile. at /home/menthos/bin/intltool-update line 861. So everything in this bug report still applies. As for the two added scripts, I'm not sure what problem they are intended to solve, since the translation status pages can't use them. They, as all our translators, depend on the fact that intltool-update works in the module.
Re: yellow bar - it seems that any language with a .po file shows up fine, and any which don't get a yellow bar. http://developer.gnome.org/projects/gtp/status/gnome-2.6/fr/extras/ Re: $ intltool-update --pot Try "intltool-update -g meld --pot" instead. intltool is only able to determine the package if autoconf is used (by reading configure.in). I've opened up a bug on this issue. http://bugzilla.gnome.org/show_bug.cgi?id=131114
I'm the translation status pages author. The yellow bar tells you that the .pot file does not exists. About the configure.in "problem", the future status pages implementation will not need the configure.in file because we give directly our own name, but the new version will not be ready until next month.
As carlos said, the yellow bar tells that the pot file couldn't be successfully created, i.e. there is an error somewhere. As you point out, the languages for which translations already exist show a green bar anyway but upon closer inspection you'll see that those po files also weren't successfully regenerated (look at the old POT-Creation-Date), something which is a direct consequence of the current pot file not being possible to generate. I consider this behavior of still showing a green bar in these cases a bug in the current status pages code, btw. Thanks for opening a new intltool bug report though.
When new intltool-update (from CVS HEAD) is installed on Carlos' machine, I believe there should be no action whatsoever required for this bug to be resolved. You may still want to provide a Makevars file so intltool-update produces something like "meld.pot" instead of "untitled.pot", but that's up to you.
Theres been a Makevars checked in for ages in anticipation of this feature, so I'll test when a new intltool is released and close the bug then. Thanks.
Just a note Stephen -- I can't see "po/Makevars" in meld repository. Are you sure it's checked in?
Sorry, my bad. It's checked in now.
Confirmed that it works with intltool-0.31. Thanks Danilo.
Closing old bugs.