From bea4fbbd052dce288ad4b2c71a924b38df2b3d67 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Tue, 16 May 2006 16:47:03 +0000 Subject: [PATCH] Make the test work on Cygwin. --- gettext-tools/tests/ChangeLog | 6 ++++++ gettext-tools/tests/gettext-4-prg.c | 7 ++----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/gettext-tools/tests/ChangeLog b/gettext-tools/tests/ChangeLog index 61ddc4599..af1099ded 100644 --- a/gettext-tools/tests/ChangeLog +++ b/gettext-tools/tests/ChangeLog @@ -1,3 +1,9 @@ +2006-05-16 Bruno Haible + + * gettext-4-prg.c: Set the LC_ALL environment variable, not just LANG. + Needed on non-glibc Unix systems where !HAVE_LOCALE_NULL and + _nl_locale_name_default() = "C". + 2006-05-14 Bruno Haible * xgettext-php-2: New file. diff --git a/gettext-tools/tests/gettext-4-prg.c b/gettext-tools/tests/gettext-4-prg.c index 67a9bb8e7..dea6d48f2 100644 --- a/gettext-tools/tests/gettext-4-prg.c +++ b/gettext-tools/tests/gettext-4-prg.c @@ -46,11 +46,8 @@ main (void) unsetenv ("LANG"); unsetenv ("OUTPUT_CHARSET"); - setlocale (LC_ALL, "de_DE.ISO-8859-1"); - /* Need to set LANGUAGE explicitly, because on MacOS X, when no LC_* - environment variable is set, LANGUAGE defaults to the value of - _nl_language_preferences_default (), which is not under our control. */ - xsetenv ("LANGUAGE", "de_DE", 1); + xsetenv ("LC_ALL", "de_DE.ISO-8859-1", 1); + setlocale (LC_ALL, ""); textdomain ("codeset"); bindtextdomain ("codeset", "."); -- 2.47.3