Integrate ITS Tool with gettext and Autotools (Was: Re: Death of gnome-common)
- From: Sébastien Wilmet <swilmet gnome org>
- To: desktop-devel-list gnome org
- Cc: shaunm gnome org
- Subject: Integrate ITS Tool with gettext and Autotools (Was: Re: Death of gnome-common)
- Date: Fri, 2 Oct 2015 19:55:01 +0200
Hi,
On Wed, Jun 24, 2015 at 02:17:52PM +0100, Emmanuele Bassi wrote:
On 24 June 2015 at 14:13, Michael Catanzaro <mcatanzaro gnome org> wrote:
On Wed, 2015-06-24 at 08:56 +0100, Emmanuele Bassi wrote:
I do hope that, if you're using glib-gettext or intltool, you spend a
little bit of time to port to upstream gettext instead.
Has anyone written a guide on how to do this?
It's the same guide as using gettext. Upstream gettext recognises
desktop files, GSettings schemas, as well as GtkBuilder XML
definitions.
Sadly, it's still in use for AppData XML, but for that (and any other
XML-based format) there's itstool, which is also used by the
documentation team for the application help:
http://itstool.org/
I have a question about how to integrate ITS Tool with upstream gettext
and Autotools (and Git).
I have a branch in GtkSourceView to use upstream gettext and itstool:
https://git.gnome.org/browse/gtksourceview/log/?h=wip/dont-use-intltool
ITS Tool generates *.pot files that can be added to the POTFILES.in.
I've tried to not add the generated *.pot files to Git, because
generated files should not be added to the version control system. But
then there are problems with builddir != srcdir. For tarballs the
solution is easy: distribute the generated sub *.pot files in the
tarball. But when compiling from the git repository, some make targets
don't work with builddir != srcdir.
So a solution is to add the generated *.pot files to Git.
Is there another solution?
The gettext documentation doesn't recommend to add generated files in
the POTFILES.in:
https://www.gnu.org/software/gettext/manual/html_node/po_002fPOTFILES_002ein.html
When a file is present in POTFILES.in, the make target supposes that the
file is in srcdir. So adding a make target (in a gettext Rules file that
is added to the po/Makefile) to build that file in builddir won't help
when builddir != srcdir.
Maybe a solution is to modify po/Makefile.in.in, like it is done in GTK+
(but not for using ITS Tool). But I'd rather keep things simple.
Is there a recommended way of doing things?
Thanks in advance,
Sébastien
[Date Prev][
Date Next] [Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]