From fe35fc4c2c9ea545ba1086781b3f07d48d60fc46 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:02:48 -0500 Subject: Setting up the gettext stuff. --- src/messages-service.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/messages-service.c b/src/messages-service.c index 0ba0deb..4911124 100644 --- a/src/messages-service.c +++ b/src/messages-service.c @@ -22,6 +22,7 @@ with this program. If not, see . #include #include +#include #include #include #include @@ -1220,7 +1221,11 @@ main (int argc, char ** argv) return 1; } - setlocale(LC_ALL,""); + /* Setting up i18n and gettext. Apparently, we need + all of these. */ + setlocale (LC_ALL, ""); + bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR); + textdomain (GETTEXT_PACKAGE); dbus_interface = message_service_dbus_new(); -- cgit v1.2.3 From a1c5c2a79818b456532e568cb94473e734ca80c3 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:02:58 -0500 Subject: Adding a po directory with a list of files. --- po/POTFILES.in | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 po/POTFILES.in diff --git a/po/POTFILES.in b/po/POTFILES.in new file mode 100644 index 0000000..0e37af8 --- /dev/null +++ b/po/POTFILES.in @@ -0,0 +1,6 @@ +src/messages-service-dbus.c +src/indicator-messages.c +src/messages-service.c +src/launcher-menu-item.c +src/im-menu-item.c +src/app-menu-item.c -- cgit v1.2.3 From a96ee29bd978743128d743d5baedc2e9365f0b25 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:04:34 -0500 Subject: Adding configure stuff in to set up gettext --- configure.ac | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/configure.ac b/configure.ac index 174aec6..2470482 100644 --- a/configure.ac +++ b/configure.ac @@ -67,6 +67,33 @@ else fi AC_SUBST(DBUSSERVICEDIR) +############################## +# Custom Junk +############################## + +AC_DEFUN([AC_DEFINE_PATH], [ + test "x$prefix" = xNONE && prefix="$ac_default_prefix" + test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + ac_define_path=`eval echo [$]$2` + ac_define_path=`eval echo [$]ac_define_path` + $1="$ac_define_path" + AC_SUBST($1) + ifelse($3, , + AC_DEFINE_UNQUOTED($1, "$ac_define_path"), + AC_DEFINE_UNQUOTED($1, "$ac_define_path", $3)) +]) + +########################### +# Internationalization +########################### + +GETTEXT_PACKAGE=indicator-session +AC_SUBST(GETTEXT_PACKAGE) +AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Name of the default get text domain]) +AC_DEFINE_PATH(GNOMELOCALEDIR, "${datadir}/locale", [locale directory]) + +AM_GLIB_GNU_GETTEXT + ########################### # Files ########################### -- cgit v1.2.3 From edd1898503d99afa6bec65b8ae03dff9554f4ac6 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:06:55 -0500 Subject: Making it so the po directory is connected in. --- Makefile.am | 3 ++- configure.ac | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile.am b/Makefile.am index 7d58c6b..26c2a33 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,7 +1,8 @@ SUBDIRS = \ src \ - data + data \ + po DISTCHECK_CONFIGURE_FLAGS = --enable-localinstall diff --git a/configure.ac b/configure.ac index 2470482..f9f4fe3 100644 --- a/configure.ac +++ b/configure.ac @@ -115,6 +115,7 @@ data/icons/48x48/Makefile data/icons/48x48/status/Makefile data/icons/scalable/Makefile data/icons/scalable/status/Makefile +po/Makefile.in ]) ########################### -- cgit v1.2.3 From 17df48a68405b137f9245919e18fa0f8132e3a56 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:11:15 -0500 Subject: Oops, teach me to cut and paste :) --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index f9f4fe3..ce3e9e9 100644 --- a/configure.ac +++ b/configure.ac @@ -87,7 +87,7 @@ AC_DEFUN([AC_DEFINE_PATH], [ # Internationalization ########################### -GETTEXT_PACKAGE=indicator-session +GETTEXT_PACKAGE=indicator-messages AC_SUBST(GETTEXT_PACKAGE) AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE", [Name of the default get text domain]) AC_DEFINE_PATH(GNOMELOCALEDIR, "${datadir}/locale", [locale directory]) -- cgit v1.2.3 From b196e9b6ec66689cdfe4ed1163f5ef5b32302f0c Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:13:51 -0500 Subject: Adding in some encoding to make things fun. --- po/POTFILES.in | 1 + 1 file changed, 1 insertion(+) diff --git a/po/POTFILES.in b/po/POTFILES.in index 0e37af8..0d88e74 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -1,3 +1,4 @@ +[encoding: UTF-8] src/messages-service-dbus.c src/indicator-messages.c src/messages-service.c -- cgit v1.2.3 From 20dddacbcac7e047a9165782318a72c4bb4cab31 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:17:44 -0500 Subject: Adding in header for gettext --- src/messages-service.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/messages-service.c b/src/messages-service.c index 4911124..e37a721 100644 --- a/src/messages-service.c +++ b/src/messages-service.c @@ -22,6 +22,7 @@ with this program. If not, see . #include #include +#include #include #include #include -- cgit v1.2.3 From 62a047790465aaee453f1cb1cbd9042762f0486b Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 15 Sep 2009 16:32:42 -0500 Subject: Forgot intltool --- configure.ac | 2 ++ 1 file changed, 2 insertions(+) diff --git a/configure.ac b/configure.ac index ce3e9e9..ee44f91 100644 --- a/configure.ac +++ b/configure.ac @@ -8,6 +8,8 @@ AM_INIT_AUTOMAKE(indicator-messages, 0.2.2) AM_MAINTAINER_MODE +IT_PROG_INTLTOOL([0.35.0]) + AC_ISC_POSIX AC_PROG_CC AM_PROG_CC_C_O -- cgit v1.2.3 From 40a0102f12f2c355d32394a8480fe953726b65c9 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Thu, 17 Sep 2009 09:58:02 -0500 Subject: Making a purdy 0.2.3 --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index ee44f91..7c83506 100644 --- a/configure.ac +++ b/configure.ac @@ -4,7 +4,7 @@ AC_INIT(src/indicator-messages.c) AC_PREREQ(2.53) AM_CONFIG_HEADER(config.h) -AM_INIT_AUTOMAKE(indicator-messages, 0.2.2) +AM_INIT_AUTOMAKE(indicator-messages, 0.2.3) AM_MAINTAINER_MODE -- cgit v1.2.3