Switched to ENABLE_NLS macro instead of rolling our own

This commit is contained in:
Snaipe 2015-04-10 00:30:34 +02:00
parent 55bef02069
commit e255e5dead
3 changed files with 4 additions and 4 deletions

View file

@ -1,6 +1,6 @@
#include "i18n.h"
#ifdef I18N
#if ENABLE_NLS
__attribute__ ((constructor))
void init_i18n(void) {
bindtextdomain (PACKAGE, LOCALEDIR);

View file

@ -3,7 +3,7 @@
# include "config.h"
# ifndef I18N
# if !ENABLE_NLS
# define _(String) String
# define _s(String, Plural, Quantity) ((Quantity) == 1 ? String : Plural)
# else

View file

@ -32,7 +32,7 @@
#include "runner.h"
#include "config.h"
#ifdef I18N
#if ENABLE_NLS
# include <libintl.h>
#endif
@ -136,7 +136,7 @@ int main(int argc, char *argv[]) {
|| !strcmp("dumb", getenv("TERM") ?: "dumb");
setlocale(LC_ALL, "");
#ifdef I18N
#if ENABLE_NLS
textdomain (PACKAGE "-test");
#endif