summaryrefslogtreecommitdiff
path: root/include/mailutils/nls.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/mailutils/nls.h')
-rw-r--r--include/mailutils/nls.h38
1 files changed, 15 insertions, 23 deletions
diff --git a/include/mailutils/nls.h b/include/mailutils/nls.h
index c183f7d5a..21e765cbc 100644
--- a/include/mailutils/nls.h
+++ b/include/mailutils/nls.h
@@ -20,31 +20,23 @@
#define _MAILUTILS_NLS_H
#include <mailutils/types.h>
-
-/*
- Native Language Support
-*/
-
-#ifdef ENABLE_NLS
-# ifdef WITH_INCLUDED_LIBINTL
-# include <libgnuintl.h>
+#if defined(DEFAULT_TEXT_DOMAIN)
+# include <locale.h>
+# include <gettext.h>
+# define _(string) gettext (string)
+# define N_(string) string
+# ifdef ENABLE_NLS
+# define MU_APP_INIT_NLS() \
+ do \
+ { \
+ setlocale (LC_ALL, ""); \
+ mu_init_nls (); \
+ } \
+ while (0)
# else
-# include <libintl.h>
+# define MU_APP_INIT_NLS()
# endif
-# define _(String) gettext(String)
-# define N_(String) String
-#ifdef HAVE_LOCALE_H
-# include <locale.h>
-#endif /* HAVE_LOCALE_H */
-#else
-# define _(String) (String)
-# define N_(String) String
-# define gettext(msgid) (msgid)
-# define dgettext(domain, msgid) (msgid)
-# define ngettext(sg,pl,cnt) (cnt == 1) ? (sg) : (pl)
-# define textdomain(Domain)
-# define bindtextdomain(Package, Directory)
-#endif /* ENABLE_NLS */
+#endif
#ifdef __cplusplus
extern "C" {

Return to:

Send suggestions and report system problems to the System administrator.