/gettext-tools/tests/fc4.exe
/gettext-tools/tests/fc5
/gettext-tools/tests/fc5.exe
-/gettext-tools/tests/gettext-5-prg
-/gettext-tools/tests/gettext-5-prg.exe
/gettext-tools/tests/gettext-6-prg
/gettext-tools/tests/gettext-6-prg.exe
/gettext-tools/tests/gettext-7-prg
/gettext-tools/tests/intl-4-prg.exe
/gettext-tools/tests/intl-setlocale-1-prg
/gettext-tools/tests/intl-setlocale-1-prg.exe
+/gettext-tools/tests/intl-setlocale-2-prg
+/gettext-tools/tests/intl-setlocale-2-prg.exe
/gettext-tools/tests/sentence-1-prg
/gettext-tools/tests/sentence-1-prg.exe
/gettext-tools/tests/testlocale
TESTS = gettext-1 gettext-2 \
intl-1 intl-2 intl-3 intl-4 \
- intl-setlocale-1 \
- gettext-5 gettext-6 gettext-7 gettext-8 \
+ intl-setlocale-1 intl-setlocale-2 \
+ gettext-6 gettext-7 gettext-8 \
msgattrib-1 msgattrib-2 msgattrib-3 msgattrib-4 msgattrib-5 \
msgattrib-6 msgattrib-7 msgattrib-8 msgattrib-9 msgattrib-10 \
msgattrib-11 msgattrib-12 msgattrib-13 msgattrib-14 msgattrib-15 \
qttest_pl.po qttest_pl.qm \
qttest2_de.po qttest2_de.qm qttest2_de.ts \
intl-1.po intl-2-1.po intl-2-2.po intl-4.po \
- intl-setlocale-1-1.po intl-setlocale-1-2.po \
- gettext-5.po gettext-6-1.po gettext-6-2.po gettext-7.po \
+ intl-setlocale-1-1.po intl-setlocale-1-2.po intl-setlocale-2.po \
+ gettext-6-1.po gettext-6-2.po gettext-7.po \
gettextpo-1.de.po \
xgettext-1 \
xgettext-c-1 xg-c-21.c \
LDADD = $(LDADD_@USE_INCLUDED_LIBINTL@) @INTL_MACOSX_LIBS@
LDADD_yes = ../intl/libintl.la @LTLIBTHREAD@
LDADD_no = ../intl/libgnuintl.la @LTLIBTHREAD@ @LTLIBINTL@
-check_PROGRAMS = tstgettext tstngettext testlocale intl-1-prg intl-3-prg intl-4-prg intl-setlocale-1-prg gettext-5-prg gettext-6-prg gettext-7-prg gettext-8-prg cake fc3 fc4 fc5 gettextpo-1-prg sentence-1-prg
+check_PROGRAMS = tstgettext tstngettext testlocale intl-1-prg intl-3-prg intl-4-prg intl-setlocale-1-prg intl-setlocale-2-prg gettext-6-prg gettext-7-prg gettext-8-prg cake fc3 fc4 fc5 gettextpo-1-prg sentence-1-prg
tstgettext_SOURCES = tstgettext.c setlocale.c
tstgettext_CFLAGS = -DINSTALLDIR=\".\"
tstgettext_LDADD = ../gnulib-lib/libgettextlib.la $(LDADD)
intl_4_prg_LDADD = ../gnulib-lib/libgettextlib.la $(LDADD)
intl_setlocale_1_prg_SOURCES = intl-setlocale-1-prg.c
intl_setlocale_1_prg_LDADD = ../gnulib-lib/libgettextlib.la $(LDADD)
-gettext_5_prg_SOURCES = gettext-5-prg.c
-gettext_5_prg_LDADD = ../gnulib-lib/libgettextlib.la $(LDADD)
+intl_setlocale_2_prg_SOURCES = intl-setlocale-2-prg.c
+intl_setlocale_2_prg_LDADD = ../gnulib-lib/libgettextlib.la $(LDADD)
gettext_6_prg_SOURCES = gettext-6-prg.c
gettext_6_prg_CFLAGS = $(gettext_6_prg_CFLAGS_@HAVE_NEWLOCALE@)
gettext_6_prg_CFLAGS_1 = -DUSE_POSIX_THREADS
#! /bin/sh
. "${srcdir=.}/init.sh"; path_prepend_ . ../src
-# Test that on glibc systems, the gettext() results come out in the correct
-# encoding for locales that differ only in their encoding.
+# Test that a gettext() result comes out in the correct encoding, even when the
+# same message from the same catalog file was already looked up in a locale with
+# a different encoding.
-# This test works only on glibc systems.
+# This test works only on glibc systems, because it relies on HAVE_LOCALE_NULL
+# being set and on the notification by setlocale().
: ${GLIBC2=no}
test "$GLIBC2" = yes || {
echo "Skipping test: not a glibc system"
Exit 77
}
-test -d gt-5 || mkdir gt-5
-test -d gt-5/de_DE || mkdir gt-5/de_DE
-test -d gt-5/de_DE/LC_MESSAGES || mkdir gt-5/de_DE/LC_MESSAGES
+test -d in-sl-2 || mkdir in-sl-2
+test -d in-sl-2/de_DE || mkdir in-sl-2/de_DE
+test -d in-sl-2/de_DE/LC_MESSAGES || mkdir in-sl-2/de_DE/LC_MESSAGES
: ${MSGFMT=msgfmt}
-${MSGFMT} -o gt-5/de_DE/LC_MESSAGES/codeset.mo "$abs_srcdir"/gettext-5.po
+${MSGFMT} -o in-sl-2/de_DE/LC_MESSAGES/tstprog.mo "$abs_srcdir"/intl-setlocale-2.po
-../gettext-5-prg || Exit 1
+../intl-setlocale-2-prg || Exit 1
Exit 0
-/* Test program, used by the gettext-5 test.
- Copyright (C) 2005, 2007, 2015-2016 Free Software Foundation, Inc.
+/* Test program, used by the intl-setlocale-2 test.
+ Copyright (C) 2005, 2007, 2015-2016, 2018 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
unsetenv ("LANGUAGE");
unsetenv ("OUTPUT_CHARSET");
- textdomain ("codeset");
- bindtextdomain ("codeset", "gt-5");
+ textdomain ("tstprog");
+ bindtextdomain ("tstprog", "in-sl-2");
setlocale (LC_ALL, "de_DE.ISO-8859-1");