From a930370b81936afcedbbec4c93ddb672766d6568 Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Tue, 10 Jun 2008 16:47:38 +0000 Subject: [PATCH] 2008-06-10 Emmanuele Bassi * autogen.sh: Check for, and run glib-gettextize. * configure.ac: Set up the localization support. * clutter/clutter-main.c: Do not define the GETTEXT_PACKAGE, but use the one from the configure script. * po/POTFILES.in: Template for the translatable files. --- ChangeLog | 11 +++++++++++ autogen.sh | 8 ++++++++ clutter/clutter-main.c | 1 - configure.ac | 9 +++++++++ po/POTFILES.in | 0 5 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 po/POTFILES.in diff --git a/ChangeLog b/ChangeLog index c7f9babb9..377117647 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2008-06-10 Emmanuele Bassi + + * autogen.sh: Check for, and run glib-gettextize. + + * configure.ac: Set up the localization support. + + * clutter/clutter-main.c: Do not define the GETTEXT_PACKAGE, + but use the one from the configure script. + + * po/POTFILES.in: Template for the translatable files. + 2008-06-10 Chris Lord * clutter/clutter-main.c: (pre_parse_hook): diff --git a/autogen.sh b/autogen.sh index 6918b140c..05dd2897e 100755 --- a/autogen.sh +++ b/autogen.sh @@ -20,6 +20,14 @@ else gtkdocize || exit $? fi +GLIB_GETTEXTIZE=`which glib-gettextize` +if test -z $GLIB_GETTEXTIZE; then + echo "*** No glib-gettextize ***" + exit 1 +else + glib-gettextize || exit $? +fi + autoreconf -v --install || exit $? ./configure "$@" && echo "Now type 'make' to compile $PROJECT." diff --git a/clutter/clutter-main.c b/clutter/clutter-main.c index dbc8ce6b5..1e64f65c1 100644 --- a/clutter/clutter-main.c +++ b/clutter/clutter-main.c @@ -35,7 +35,6 @@ #endif #include -#define GETTEXT_PACKAGE "clutter" #include #include "clutter-event.h" diff --git a/configure.ac b/configure.ac index 4348a4be8..f640591a7 100644 --- a/configure.ac +++ b/configure.ac @@ -593,6 +593,14 @@ CLUTTER_LIBS="$SDL_LIBS $EGL_LIBS $GLX_LIBS $OSX_LIBS $WIN32_LIBS $CLUTTER_DEPS_ AC_SUBST(CLUTTER_CFLAGS) AC_SUBST(CLUTTER_LIBS) +GETTEXT_PACKAGE="clutter-$CLUTTER_API_VERSION" +AC_SUBST(GETTEXT_PACKAGE) +AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", + [The prefix for our gettext translation domains.]) + +ALL_LINGUAS="" +AM_GLIB_GNU_GETTEXT + AC_CONFIG_FILES([ Makefile clutter/Makefile @@ -625,6 +633,7 @@ AC_CONFIG_FILES([ doc/reference/cogl/Makefile doc/manual/clutter-manual.xml doc/manual/Makefile + po/Makefile.in clutter.pc ]) diff --git a/po/POTFILES.in b/po/POTFILES.in new file mode 100644 index 000000000..e69de29bb