Pavel Raiskup [Wed, 21 Nov 2018 08:53:53 +0000 (09:53 +0100)]
format-kde-kuit: really use fallback markup
* gettext-tools/src/format-kde-kuit.c (format_parse): Use markup.h
methods when FORMAT_KDE_KUIT_USE_FALLBACK_MARKUP is defined. Also
free buffer if there's no support for XML.
Bruno Haible [Sat, 17 Nov 2018 22:04:17 +0000 (23:04 +0100)]
Make 'make distcheck' work in a VPATH build.
* Makefile.am (distcheck-hook): Compare files in $(srcdir).
* gettext-tools/examples/po/xsmallpot.sh: Put the resulting POT file in the
source dir, not in the build dir.
* gettext-tools/examples/po/Makefile.am (update-po): Execute sub-make in the
build dir, not in the source dir.
(SMALLPOFILES_FOR_lang): Prefix file names with $(srcdir).
(hello-*/po/*.po): Likewise. Execute mmsmallpo.sh in $(srcdir).
Bruno Haible [Sun, 11 Nov 2018 12:48:56 +0000 (13:48 +0100)]
gettextize: Require automake >= 1.9.
* gettext-tools/misc/gettextize.in: Signal an error if 'aclocal' from
automake >= 1.9 is not found. Stop installing intldir.m4, intl.m4 and its
dependencies.
* gettext-tools/doc/gettext.texi (mkinstalldirs, aclocal): State the requirement
to have automake >= 1.9.
* gettext-tools/m4/Makefile.am (aclocal_DATA): Don't install codeset.m4,
extern-inline.m4, fcntl-o.m4, glibc2.m4, glibc21.m4, intdiv0.m4, intl.m4,
intl-thread-locale.m4, intldir.m4, intmax.m4, inttypes_h.m4, inttypes-pri.m4,
lcmessage.m4, lock.m4, longlong.m4, printf-posix.m4, size_max.m4, stdint_h.m4,
threadlib.m4, uintmax_t.m4, visibility.m4, wchar_t.m4, wint_t.m4, xsize.m4.
* PACKAGING: Remove the *.m4 files that are no longer installed.
Bruno Haible [Sun, 11 Nov 2018 12:48:44 +0000 (13:48 +0100)]
gettextize: Remove --intl option.
* gettext-tools/misc/gettextize.in (func_usage): Don't mention --intl option.
Signal an error if the --intl option is specified.
Simplify main code accordingly.
* gettext-tools/doc/gettextize.texi: Remove --intl option description.
* gettext-tools/doc/gettext.texi (Prerequisites): Remove mention of intl/
directory.
(configure.ac): Suggest to use AM_GNU_GETTEXT([external]) always. Remove mention
of intl/ directory.
(config.guess): Suggest them always.
(aclocal): Shrink the list of .m4 files.
(acconfig): Remove subsection.
(config.h.in): Remove mention of intl/ directory.
(Makefile, src/Makefile, lib/gettext.h): Likewise.
(AM_GNU_GETTEXT): First argument must be 'external'. Remove third argument.
(AM_GNU_GETTEXT_INTL_SUBDIR): Remove subsection.
(Language Implementors): Remove mention of intl/ directory. Mention that
Solaris 11 gettext works like GNU gettext.
(Maintainers for other Languages): Remove mention of intl/ directory.
* gettext-tools/doc/autopoint.texi: Update explanation of name.
* NEWS: Mention the change.
Bruno Haible [Sun, 4 Nov 2018 22:28:58 +0000 (23:28 +0100)]
xgettext: Delay calls to from_current_source_encoding, part 2.
* gettext-tools/src/xg-arglist-parser.h: Include xg-mixed-string.h.
(struct partial_call): Change type of fields msgctxt, msgid, msgid_plural to
'mixed_string_ty *'.
(arglist_parser_remember, arglist_parser_remember_msgctxt): Take a
'mixed_string_ty *' argument instead of a 'char *' argument.
* gettext-tools/src/xg-arglist-parser.c (arglist_parser_clone): Update
accordingly.
(arglist_parser_remember, arglist_parser_remember_msgctxt): Take a
'mixed_string_ty *' argument.
(arglist_parser_done): Convert the mixed_string to UTF-8 encoded 'char *' here.
This is where from_current_source_encoding gets invoked now: immediately before
invoking remember_a_message, that is, only when we really need to know the
--from-source encoding.
* gettext-tools/src/x-c.c (extract_parenthesized): Pass the mixed_string to
arglist_parser_remember. Don't set xgettext_current_source_encoding around
arglist_parser_done calls.
* gettext-tools/src/x-csharp.c (extract_parenthesized): Likewise.
* gettext-tools/src/x-java.c (extract_parenthesized): Likewise.
* gettext-tools/src/x-javascript.c (extract_balanced): Likewise.
* gettext-tools/src/x-python.c (extract_balanced): Likewise.
* gettext-tools/src/x-vala.c (extract_balanced): Likewise.
* gettext-tools/src/x-lisp.c: Include xg-mixed-string.h.
(read_object): Convert the string to a mixed_string_ty before passing it to
arglist_parser_remember.
* gettext-tools/src/x-elisp.c: Likewise.
* gettext-tools/src/x-librep.c: Likewise.
* gettext-tools/src/x-scheme.c: Likewise.
* gettext-tools/src/x-awk.c: Include xg-mixed-string.h.
(extract_parenthesized): Convert the string to a mixed_string_ty before passing
it to arglist_parser_remember.
* gettext-tools/src/x-lua.c: Include xg-mixed-string.h.
(extract_balanced): Convert the string to a mixed_string_ty before passing it to
arglist_parser_remember.
* gettext-tools/src/x-php.c: Include xg-mixed-string.h.
(extract_balanced): Convert the string to a mixed_string_ty before passing it to
arglist_parser_remember.
* gettext-tools/src/x-sh.c: Include xg-mixed-string.h.
(read_command): Convert the string to a mixed_string_ty before passing it to
arglist_parser_remember.
* gettext-tools/src/x-tcl.c: Include xg-mixed-string.h.
(read_command): Convert the string to a mixed_string_ty before passing it to
arglist_parser_remember.
* gettext-tools/src/x-perl.c (extract_balanced): Convert the string to a
mixed_string_ty before passing it to arglist_parser_remember. Don't set
xgettext_current_source_encoding around arglist_parser_done calls.
Bruno Haible [Sun, 4 Nov 2018 19:23:31 +0000 (20:23 +0100)]
xgettext: Delay calls to from_current_source_encoding, part 1.
* xg-mixed-string.h (enum segment_type, struct mixed_string_segment,
struct mixed_string, mixed_string_ty): New types.
(mixed_string_alloc_simple, mixed_string_alloc_utf8, mixed_string_clone,
mixed_string_contents, mixed_string_free, mixed_string_contents_free1,
mixed_string_concat, mixed_string_concat_free1): New declarations.
(struct mixed_string_buffer): Change internal representation to use segments.
(mixed_string_buffer_result): Change return type to 'mixed_string_ty *'.
* xg-mixed-string.c: Include flexmember.h, msgl-ascii.h, po-charset.h.
(segment_alloc, segment_clone, mixed_string_alloc_simple,
mixed_string_alloc_utf8, mixed_string_clone, mixed_string_contents,
mixed_string_free, mixed_string_contents_free1, mixed_string_concat,
mixed_string_concat_free1): New functions.
(mixed_string_buffer_init, mixed_string_buffer_is_empty): Change to match new
internal representation.
(mixed_string_buffer_grow_curr_buffer): New function.
(mixed_string_buffer_grow_utf8_buffer): Remove function.
(mixed_string_buffer_append_to_utf8_buffer): Update accordingly.
(mixed_string_buffer_flush_curr_buffer): Remove function.
(mixed_string_buffer_add_segment, mixed_string_buffer_flush_curr): New
functions.
(mixed_string_buffer_append_char, mixed_string_buffer_append_unicode,
mixed_string_buffer_destroy, mixed_string_buffer_result): Change to match new
internal representation.
* x-c.c (struct token_ty): New field 'mixed_string'.
(free_token): Update accordingly.
(phase5_get, phase6_get, phase8a_get): For tokens of type
token_type_string_literal, use a mixed_string.
(phase8_get): Use mixed_string_concat_free1.
(struct xgettext_token_ty): New field 'mixed_string'.
(x_c_lex, extract_parenthesized): For tokens of type
xgettext_token_type_string_literal, use a mixed_string.
* x-csharp.c (comment_line_end): Update.
(struct token_ty): New field 'mixed_string'.
(free_token): Update accordingly.
(phase6_get): For tokens of type token_type_string_literal, use a mixed_string.
(phase7_get): Use mixed_string_concat_free1.
(extract_parenthesized): For tokens of type token_type_string_literal, use a
mixed_string.
* x-java.c (comment_line_end): Update.
(struct token_ty): New field 'mixed_string'.
(free_token): Update accordingly.
(phase5_get): For tokens of type token_type_string_literal, use a mixed_string.
(phase6_get): Use mixed_string_concat_free1.
(extract_parenthesized): For tokens of type token_type_string_literal, use a
mixed_string.
* x-javascript.c (comment_line_end): Update.
(struct token_ty): New field 'mixed_string'.
(free_token): Update accordingly.
(phase5_get): For tokens of type token_type_string, use a mixed_string.
(x_javascript_lex): Use mixed_string_concat_free1.
(extract_balanced): For tokens of type token_type_string, use a mixed_string.
* x-python.c (comment_line_end): Update.
(struct token_ty): New field 'mixed_string'.
(free_token): Update accordingly.
(phase5_get): For tokens of type token_type_string, use a mixed_string.
(x_python_lex): Use mixed_string_concat_free1.
(extract_balanced): For tokens of type token_type_string, use a mixed_string.
* x-rst.c (extract_rsj): Update.
* x-vala.c (struct token_ty): New field 'mixed_string'.
(free_token): Update accordingly.
(phase3_get): For tokens of type token_type_string_literal, use a mixed_string.
For tokens of type token_type_string_template, fix a memory leak.
(x_vala_lex): Use mixed_string_concat_free1.
(extract_balanced): For tokens of type token_type_string_literal, use a
mixed_string.
Bruno Haible [Sun, 4 Nov 2018 19:20:30 +0000 (20:20 +0100)]
xgettext: Change the Java extractor to make use of mixed_string_buffer.
* gettext-tools/src/xg-mixed-string.h: Include <stdbool.h>.
(mixed_string_buffer_init, mixed_string_buffer_is_empty,
mixed_string_buffer_destroy, mixed_string_buffer_result): New declarations.
* gettext-tools/src/xg-mixed-string.c: Include xg-pos.h.
(mixed_string_buffer_init): New function.
(mixed_string_buffer_alloc): Invoke it.
(mixed_string_buffer_is_empty): New function, based on comment_at_start in
x-java.c.
(mixed_string_buffer_append_lone_surrogate): New function, based on
string_buffer_append_lone_surrogate in x-java.c.
(mixed_string_buffer_flush_utf16_surr, mixed_string_buffer_append_unicode): Use
it.
(mixed_string_buffer_destroy, mixed_string_buffer_result): New functions.
(mixed_string_buffer_done): Invoke mixed_string_buffer_result.
* gettext-tools/src/x-java.c: Include xg-mixed-string.h.
(struct string_buffer): Remove type.
(init_string_buffer, string_buffer_append_byte,
string_buffer_append_unicode_grow, string_buffer_append_unicode,
string_buffer_append_lone_surrogate, string_buffer_flush_utf16_surr,
string_buffer_flush_curr_buffer): Remove functions.
(mixed_string_buffer_append): Renamed from string_buffer_append. Use
mixed_string_buffer.
(string_buffer_result, free_string_buffer): Remove functions.
(comment_buffer, comment_start, comment_at_start, comment_add,
comment_line_end): Use mixed_string_buffer API.
(accumulate_escaped, phase5_get): Likewise.
Bruno Haible [Sun, 4 Nov 2018 19:09:47 +0000 (20:09 +0100)]
xgettext: Fix result for concatenation of strings with escape sequences.
Reported by Morten Welinder <mwelinder@gmail.com>
in <https://lists.gnu.org/archive/html/bug-gettext/2015-12/msg00017.html>
and <https://savannah.gnu.org/bugs/?46756>.
Revert commits from
2014-05-07 xgettext: Provide a way to interpret string literals lazily
2014-05-07 c: Interpret string literals lazily
2014-05-09 vala: Interpret string literals lazily
2014-12-02 c: Support C++11 string literals
and subsequent fixes of these.
Bruno Haible [Sun, 4 Nov 2018 18:42:32 +0000 (19:42 +0100)]
xgettext: Enhance test for NUL byte handling.
* gettext-tools/tests/xg-c-21.c: Add some more test cases.
* gettext-tools/tests/xgettext-c-21: Update expected result accordingly. Change
expected result for backslash-NUL.
Bruno Haible [Sun, 4 Nov 2018 18:41:53 +0000 (19:41 +0100)]
xgettext: New test of concatenation of strings with escape sequences.
Reported by Morten Welinder <mwelinder@gmail.com>
in <https://lists.gnu.org/archive/html/bug-gettext/2015-12/msg00017.html>
and <https://savannah.gnu.org/bugs/?46756>.
* gettext-tools/tests/xgettext-c-23: New file.
* gettext-tools/tests/Makefile.am (TESTS): Add it.
Bruno Haible [Wed, 24 Oct 2018 23:41:42 +0000 (01:41 +0200)]
po, examples: Change .po -> .gmo rules to consider the newest changes to the POT file.
Reported by Claude Paroz <claude@2xlibre.net>
in <https://savannah.gnu.org/bugs/?50910>.
* gettext-runtime/m4/po.m4 (AM_PO_SUBDIRS): Set MSGMERGE_FOR_MSGFMT_OPTION.
* gettext-runtime/po/Makefile.in.in (MSGMERGE): Use GNU msgmerge, even if not
first in $PATH.
(MSGMERGE_FOR_MSGFMT_OPTION): New variable.
(.po.gmo): Depend on the POT file. Use msgmerge on the fly, to take into
account the most recent POT file changes.
* gettext-tools/examples/hello-*/po/Makefile.am: Likewise, also for the .po.qm,
update-properties, update-classes targets.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile
(MSGMERGE_FOR_MSGFMT_OPTION): New variable.
($(STRINGSFILES)): Depend on the POT file. Use msgmerge on the fly, to take
into account the most recent POT file changes.
Bruno Haible [Wed, 24 Oct 2018 23:09:38 +0000 (01:09 +0200)]
msgmerge: New option --for-msgfmt.
* gettext-tools/src/msgmerge.c (for_msgfmt): New variable.
(long_options): Add option --for-msgfmt.
(main): Handle option --for-msgfmt.
(usage): Document option --for-msgfmt.
(match_domain): When --for-msgfmt is given, omit untranslated and fuzzy messages
from the result.
(merge): When --for-msgfmt is given, don't add obsolete messages to the result.
* gettext-tools/tests/msgmerge-26: New file.
* gettext-tools/tests/Makefile.am (TESTS): Add it.
* gettext-tools/doc/msgmerge.texi: Mention the option --for-msgfmt.
* NEWS: Mention the change.
Bruno Haible [Wed, 24 Oct 2018 23:03:32 +0000 (01:03 +0200)]
Add ability to write PO files without translator comment lines.
* gettext-tools/src/write-po.h (message_print_style_comment): New declaration.
* gettext-tools/src/write-po.c (print_comment): New variable.
(message_print_style_comment): New function.
(message_print_comment): Output nothing if print_comment is false.
* gettext-runtime/po/Makefile.in.in: Use $(srcdir)/stamp-po instead of stamp-po.
Talk about "version control system", not CVS.
* gettext-tools/examples/hello-*/po/Makefile.am: Likewise.
* gettext-tools/examples/po/Makefile.am: Likewise.
* gettext-tools/examples/check-examples (func_check_dist_vpath): Verify the
stamp-po file does not exist in the build dir, except when using the older
Makefile.in.in infrastructure.
* NEWS: Mention the change.
* gettext-runtime/po/Makefile.in.in (maintainer-clean): Remove the .pot file.
* gettext-tools/examples/hello-*/po/Makefile.am (MAINTAINERCLEANFILES): Add
the .pot file.
* gettext-tools/examples/po/Makefile.am (MAINTAINERCLEANFILES): Likewise.
* gettext-tools/examples/check-examples (func_check_maintainerclean,
func_check_maintainerclean_vpath): Verify the .pot file is removed after
'make maintainer-clean', except when using the older Makefile.in.in
infrastructure.
Bruno Haible [Tue, 23 Oct 2018 22:46:52 +0000 (00:46 +0200)]
examples: Add support for msgmerge --previous.
This mirrors the Makefile.in.in change from 2016-07-01.
* gettext-tools/examples/hello-*/po/Makefile.am ($(POFILES), update-po): Use
option --previous when the msgmerge program supports it.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile: Likewise.
Bruno Haible [Tue, 23 Oct 2018 22:45:52 +0000 (00:45 +0200)]
examples: Support reading header comments from file.
This mirrors the Makefile.in.in change from 2015-09-01 with the amendment
from today.
* gettext-tools/examples/hello-*/po/Makefile.am ($(DOMAIN).pot-update):
Replace header entry with the content of $(DOMAIN).pot-header, if exists.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile: Likewise.
Bruno Haible [Tue, 23 Oct 2018 22:31:23 +0000 (00:31 +0200)]
examples: Avoid grepping through monster files.
This mirrors the Makefile.in.in change from 2010-06-12.
Reported by Jim Meyering <jim@meyering.net>.
* gettext-tools/examples/hello-*/po/Makefile.am (($(DOMAIN).pot-update): When
GNU find is available, avoid grepping through monster files.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile: Likewise.
Bruno Haible [Tue, 23 Oct 2018 22:21:31 +0000 (00:21 +0200)]
po: When doing msgmerge --version, use the correct msgmerge program.
This reverts the patch from
<https://lists.gnu.org/archive/html/bug-gettext/2015-06/msg00000.html>.
Rationale:
<https://lists.gnu.org/archive/html/bug-gettext/2018-10/msg00000.html>.
* gettext-runtime/po/Makefile.in.in ($(POFILES)): Use $(MSGMERGE_UPDATE),
not $(MSGMERGE).
Bruno Haible [Tue, 23 Oct 2018 20:48:46 +0000 (22:48 +0200)]
intl: Improve support for per-thread locales on Solaris 11.4.
* gettext-runtime/intl/localename.c: Update from gnulib:
Handle HAVE_SOLARIS114_LOCALES through Solaris specific code.
* gettext-runtime/intl/localename-table.in.h: Update from gnulib's
localename-table.h.
* gettext-runtime/intl/localename-table.c: Update from gnulib.
* gettext-runtime/m4/intl-thread-locale.m4: Renamed from
gettext-runtime/m4/intlsolaris.m4.
(gt_INTL_THREAD_LOCALE_NAME): Renamed from gt_INTL_SOLARIS. Define
HAVE_SOLARIS114_LOCALES instead of HAVE_NAMELESS_LOCALES.
* gettext-runtime/m4/intl.m4: Update from gnulib:
(AM_INTL_SUBDIR): Require gt_INTL_THREAD_LOCALE_NAME. Test for 'uselocale'. Set
HAVE_NAMELESS_LOCALES.
(gt_INTL_SUBDIR_CORE): Don't invoke gt_INTL_SOLARIS. Don't set
HAVE_NAMELESS_LOCALES here.
* gettext-runtime/m4/Makefile.am (EXTRA_DIST): List intl-thread-locale.m4, not
intlsolaris.m4.
* gettext-tools/m4/Makefile.am (aclocal_DATA): List intl-thread-locale.m4, not
intlsolaris.m4.
* gettext-tools/misc/gettextize.in (m4filelist): List intl-thread-locale.m4, not
intlsolaris.m4.
* Makefile.am (distcheck-hook): Check intl-thread-locale.m4, not intlsolaris.m4.
* gettext-tools/doc/gettext.texi (aclocal): List intl-thread-locale.m4, not
intlsolaris.m4.
* PACKAGING: List intl-thread-locale.m4, not intlsolaris.m4.
Bruno Haible [Mon, 22 Oct 2018 23:02:02 +0000 (01:02 +0200)]
intl: Add support for per-thread locales on Solaris 11.4.
Relies on the recent changes to the 'localename' module in gnulib.
* gettext-runtime/intl/localename.c: Apply changes from gnulib.
* gettext-runtime/intl/localename-table.h: New file, from gnulib.
* gettext-runtime/intl/localename-table.c: New file, from gnulib.
* gettext-runtime/intl/libgnuintl.in.h (newlocale, duplocale, freelocale): New
overriding declarations.
* gettext-runtime/intl/Makefile.in (HEADERS): Add localename-table.h.
(SOURCES): Add localename-table.c.
(OBJECTS): Add localename-table.$lo.
(localename-table.lo): New target.
(libgnuintl.h, libintl.h): Substitute also HAVE_NAMELESS_LOCALES.
* gettext-runtime/m4/intl.m4: Apply changes from gnulib:
(gt_INTL_SUBDIR_CORE): Don't test for 'uselocale' and 'getlocalename_l'.
Instead, invoke gt_INTL_SOLARIS. Set HAVE_NAMELESS_LOCALES.
* gettext-runtime/m4/intlsolaris.m4: New file, from gnulib.
* gettext-runtime/m4/Makefile.am (EXTRA_DIST): Add it.
* gettext-tools/m4/Makefile.am (aclocal_DATA): Add intlsolaris.m4.
* gettext-tools/misc/gettextize.in (m4filelist): Add intlsolaris.m4.
* Makefile.am (distcheck-hook): Verify that intlsolaris.m4 is consistent with
gnulib.
* gettext-tools/doc/gettext.texi (aclocal): Add intlsolaris.m4 to the file list.
* PACKAGING: Add intlsolaris.m4 to the list of installed files.
* NEWS: Mention the change.
Bruno Haible [Sun, 21 Oct 2018 08:35:25 +0000 (10:35 +0200)]
New subdirectory system-tests.
* gettext-tools/system-tests/Makefile.am: New file.
* gettext-tools/system-tests/README: New file.
* gettext-tools/system-tests/run-test: New file.
* gettext-tools/system-tests/testlocale.c: New file.
* gettext-tools/system-tests/intl-1-prg.c: New file.
* gettext-tools/system-tests/intl-3-prg.c: New file.
* gettext-tools/system-tests/intl-4-prg.c: New file.
* gettext-tools/system-tests/intl-5-prg.c: New file.
* gettext-tools/system-tests/intl-setlocale-1-prg.c: New file.
* gettext-tools/system-tests/intl-setlocale-2-prg.c: New file.
* gettext-tools/system-tests/intl-thread-1-prg.c: New file.
* gettext-tools/system-tests/intl-thread-2-prg.c: New file.
* gettext-tools/system-tests/intl-thread-3-prg.c: New file.
* gettext-tools/system-tests/format-c-3-prg.c: New file.
* gettext-tools/system-tests/format-c-4-prg.c: New file.
* gettext-tools/system-tests/format-c-5-prg.c: New file.
* gettext-tools/system-tests/plural-1-prg.c: New file.
* gettext-tools/Makefile.am (SUBDIRS): Add system-tests.
* gettext-tools/configure.ac (TEST_SYSTEM_LIBINTL): New conditional.
(AC_CONFIG_FILES): Add system-tests/Makefile.
* gettext-tools/tests/init.cfg: Include init-env from the tests/ directory.
* gettext-tools/tests/intl-5-prg.c: When USE_SYSTEM_LIBINTL is defined, use the
system's <libintl.h>.
* gettext-tools/tests/intl-setlocale-1-prg.c: Likewise.
* gettext-tools/tests/intl-setlocale-2-prg.c: Likewise.
* gettext-tools/tests/intl-thread-1-prg.c: Likewise.
* gettext-tools/tests/intl-thread-2-prg.c: Likewise.
* gettext-tools/tests/intl-thread-3-prg.c: Likewise.
* gettext-tools/tests/intl-1-prg.c: When USE_SYSTEM_LIBINTL is defined, use the
system's <libintl.h>.
* gettext-tools/tests/intl-3-prg.c: Likewise.
* gettext-tools/tests/intl-4-prg.c: Likewise.
* gettext-tools/tests/format-c-3-prg.c: Likewise.
* gettext-tools/tests/format-c-4-prg.c: Likewise.
* gettext-tools/tests/plural-1-prg.c: Likewise.
* gettext-tools/tests/format-c-5-prg.c: When USE_SYSTEM_LIBINTL is defined, use
the system's <libintl.h> and setenv instead of xsetenv, and no fake setlocale.
* gettext-tools/tests/format-c-3: When USE_SYSTEM_LIBINTL is defined, try
$LOCALE_FR and $LOCALE_FR_UTF8.
* gettext-tools/tests/format-c-4: Likewise.
* gettext-tools/tests/plural-1: Likewise.
* gettext-tools/tests/format-c-5: When USE_SYSTEM_LIBINTL is defined, try fa_IR
and fa_IR.UTF-8.