]> git.ipfire.org Git - thirdparty/gettext.git/log
thirdparty/gettext.git
15 hours agoUpdate after gnulib changed on 2025-12-02. master
Bruno Haible [Thu, 29 Jan 2026 17:49:53 +0000 (18:49 +0100)] 
Update after gnulib changed on 2025-12-02.

33 hours agoRelease 1.0 v1.0
Bruno Haible [Thu, 29 Jan 2026 00:13:11 +0000 (01:13 +0100)] 
Release 1.0

33 hours agoexamples: Use infrastructure from gettext version 1.0.
Bruno Haible [Wed, 28 Jan 2026 23:47:27 +0000 (00:47 +0100)] 
examples: Use infrastructure from gettext version 1.0.

* gettext-tools/examples/hello-*/configure.ac: Use AM_GNU_GETTEXT_VERSION with
version 1.0.
* gettext-tools/examples/hello-c++-kde/configure.in.in: Likewise.
* gettext-tools/examples/hello-*/autogen.sh: Copy remove-potcdate.sed from the
new location in the source tree. Copy also the no-op fetch-po.
* gettext-tools/examples/hello-*/autoclean.sh: Remove also fetch-po.

33 hours agoPrepare for 1.0 release.
Bruno Haible [Wed, 28 Jan 2026 16:16:54 +0000 (17:16 +0100)] 
Prepare for 1.0 release.

* gettext-runtime/doc/matrix.texi: Update from TP.
* gettext-runtime/doc/nls.texi (STATUS): Update.
* gettext-runtime/intl/libgnuintl.in.h (LIBINTL_VERSION): Bump.
* libtextstyle/version.sh: Update VERSION_NUMBER, RELEASE_DATE.
* gettext-tools/libgettextpo/gettext-po.in.h (LIBGETTEXTPO_VERSION): Bump.
* gettext-tools/wizard/po-templates/traditional/Makefile.in.in: Update Origin.
* gettext-runtime/intl/Makefile.am (LTV_*): Bump to 12:6:4.
* libtextstyle/lib/Makefile.am (LTV_*): Bump to 2:7:2.
* gettext-tools/libgettextpo/Makefile.am (LTV_*): Bump to 6:0:6.
* gettext-tools/autotools/autopoint.in: Accept version 1.0.
* gettext-tools/configure.ac (ARCHIVE_VERSION): Bump to 1.0.
* gettext-tools/autotools/archive.dir.tar: Regenerated.

33 hours agoUpdate translations from TP.
Bruno Haible [Wed, 28 Jan 2026 17:23:55 +0000 (18:23 +0100)] 
Update translations from TP.

33 hours agomsginit: Don't backup when mergeing a PO file and --no-translator is given.
Bruno Haible [Wed, 28 Jan 2026 23:06:13 +0000 (00:06 +0100)] 
msginit: Don't backup when mergeing a PO file and --no-translator is given.

* gettext-tools/src/msginit.c (main): Don't create a backup file if
--no-translator is specified.

33 hours agomsginit: Fix handling of --properties-output when producing a merged PO file.
Bruno Haible [Wed, 28 Jan 2026 22:51:50 +0000 (23:51 +0100)] 
msginit: Fix handling of --properties-output when producing a merged PO file.

* gettext-tools/src/msgl-merge.h (merge): Add definitions_file_syntax parameter.
Rename input_syntax parameter to references_file_syntax.
* gettext-tools/src/msgl-merge.c (merge): Likewise.
* gettext-tools/src/msginit.c (main): New variable output_file_input_syntax.
Fix merge() call.
* gettext-tools/src/msgmerge.c (main): Update merge() call.

36 hours agopo: Distribute the fetch-po file.
Bruno Haible [Wed, 28 Jan 2026 20:51:24 +0000 (21:51 +0100)] 
po: Distribute the fetch-po file.

This is somewhat tricky, because it is also a phony Makefile target.

* gettext-tools/wizard/po-templates/traditional/Makefile.in.in (dist2):
Distribute 'fetch-po'.
* gettext-tools/examples/po/Makefile.am (distdir1): Distribute 'fetch-po'.
* gettext-tools/examples/hello-*/po/Makefile.am (distdir1): Likewise.

44 hours agoUpdate to the newest gnulib.
Bruno Haible [Wed, 28 Jan 2026 12:56:56 +0000 (13:56 +0100)] 
Update to the newest gnulib.

44 hours agoxgettext: PHP: Fix parsing of strings and heredocs with embedded expressions.
Bruno Haible [Wed, 28 Jan 2026 12:50:21 +0000 (13:50 +0100)] 
xgettext: PHP: Fix parsing of strings and heredocs with embedded expressions.

Reported by Gert Jan Schoneveld <gertjan@facilityapps.com> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-08/msg00007.html>
and by Benoit Waldmann <benoit.waldmann@siagilus.fr>
at <https://savannah.gnu.org/bugs/index.php?item_id=67948>.

* gettext-tools/src/x-php.c (enum token_type_ty): New enum values
token_type_lbrace, token_type_rbrace.
(struct php_extractor): New field brace_nesting_depth.
(php_extractor_init_rest): Initialize it.
(extract_balanced): Forward-declare.
(process_dquote_or_heredoc): Change handling of embedded expressions.
(phase4_get): Recognize token_type_lbrace, token_type_rbrace.
(extract_balanced): Recurse also for token_type_lbrace.
(extract_php_input): Remove function.
(extract_php): Inline it here.
* gettext-tools/tests/xgettext-php-1: Add more tests of embedded expressions.

2 days agoUpdate "Written by ..." lines in --version output.
Bruno Haible [Wed, 28 Jan 2026 02:12:04 +0000 (03:12 +0100)] 
Update "Written by ..." lines in --version output.

* gettext-tools/src/msgfmt.c (main): Add me and Daiki Ueno as co-authors.
* gettext-runtime/src/ngettext.c (main): Add me as co-author.
* gettext-tools/src/msgmerge.c (main): Likewise.
* gettext-tools/src/msgunfmt.c (main): Likewise.
* gettext-tools/src/xgettext.c (main): Likewise.
* gettext-tools/wizard/gettextize.in (func_version): Likewise. Terminate the
'Written by' line with a '.'.
* gettext-tools/autotools/autopoint.in (func_version): Terminate the
'Written by' line with a '.'.
* gettext-tools/autotools/convert-archive.in (func_version): Likewise.
* gettext-tools/misc/po-fetch.in (func_version): Likewise.
* gettext-runtime/src/gettext.sh.in (func_version): Likewise.
* libtextstyle/gnulib-local/build-aux/moopp (func_version): Likewise.

3 days agopo-mode: Prepare for inclusion in GNU ELPA.
Bruno Haible [Tue, 27 Jan 2026 05:03:04 +0000 (06:03 +0100)] 
po-mode: Prepare for inclusion in GNU ELPA.

Suggested by Stefan Monnier <monnier@iro.umontreal.ca> in
<https://lists.gnu.org/archive/html/bug-gettext/2026-01/msg00086.html>.

* gettext-tools/emacs/po-mode.el: Add meta-information field 'Version:',
required by ELPA. Move meta-information after the copyright and license notice.
(po-mode-version-string): Move definition.
* gettext-tools/emacs/po-compat.el: Move meta-information after the copyright
and license notice. Convert the file to UTF-8 encoding.

3 days agoUpdate "Written by ..." lines and authorship notices in source files.
Bruno Haible [Tue, 27 Jan 2026 04:43:26 +0000 (05:43 +0100)] 
Update "Written by ..." lines and authorship notices in source files.

3 days agoUpdate email address in copyright notices.
Bruno Haible [Mon, 26 Jan 2026 21:08:15 +0000 (22:08 +0100)] 
Update email address in copyright notices.

3 days agoUse the common comment style.
Bruno Haible [Wed, 21 Jan 2026 17:44:07 +0000 (18:44 +0100)] 
Use the common comment style.

4 days agoFix a small memory leak in libgettextpo.
Bruno Haible [Sun, 25 Jan 2026 18:17:48 +0000 (19:17 +0100)] 
Fix a small memory leak in libgettextpo.

Reported by <gemmaro.dev@gmail.com> at
<https://savannah.gnu.org/bugs/index.php?item_id=67892>
and by Albert Astals Cid <aacid@kde.org> in
<https://lists.gnu.org/archive/html/bug-gettext/2026-01/msg00071.html>.

* gettext-tools/src/read-po-lex.h: Include str-list.h.
(lex_start): Add arena parameter.
* gettext-tools/src/read-po-lex.c (lex_start): Add arena parameter. Add the
heap-allocated file_name to the arena.
* gettext-tools/src/read-catalog-abstract.h: Include str-list.h.
(struct catalog_input_format): Add arena parameter to parse() method.
(catalog_reader_parse): Add arena parameter.
* gettext-tools/src/read-properties.c (properties_parse): Add arena parameter.
* gettext-tools/src/read-stringtable.c (stringtable_parse): Add arena parameter.
* gettext-tools/src/read-po.c (po_parse): Add arena parameter. Update lex_start
call.
* gettext-tools/src/read-catalog-abstract.c (catalog_reader_parse): Add arena
parameter. Update parse() method call.
* gettext-tools/src/read-catalog.h: Include str-list.h.
(read_catalog_stream): Add arena parameter.
* gettext-tools/src/read-catalog.c (read_catalog_stream): Add arena parameter.
Update catalog_reader_parse call.
* gettext-tools/src/read-catalog-file.c: Include str-list.h.
(read_catalog_file): Update read_catalog_stream call.
* gettext-tools/src/read-csharp.c: Include str-list.h.
(execute_and_read_po_output): Update read_catalog_stream call.
* gettext-tools/src/read-java.c: Include str-list.h.
(execute_and_read_po_output): Update read_catalog_stream call.
* gettext-tools/src/read-resources.c: Include str-list.h.
(execute_and_read_po_output): Update read_catalog_stream call.
* gettext-tools/src/read-tcl.c: Include str-list.h.
(msgdomain_read_tcl): Update read_catalog_stream call.
* gettext-tools/libgettextpo/gettext-po.c: Include str-list.h.
(struct po_file): Add field 'arena'.
(po_file_create): Initialize it.
(po_file_read): Likewise. Update read_catalog_stream call.
(po_file_free): Destroy the arena.
* gettext-tools/src/msgfmt.c (read_catalog_file_msgfmt): Update
catalog_reader_parse call.
* gettext-tools/src/x-po.c: Include str-list.h.
(extract): Update catalog_reader_parse call.
* gettext-tools/src/xgettext.c (read_exclusion_file): Update
catalog_reader_parse call.

4 days agodoc: Explain translation projects.
Bruno Haible [Sun, 25 Jan 2026 10:13:43 +0000 (11:13 +0100)] 
doc: Explain translation projects.

* gettext-tools/doc/gettext.texi (Interfacing with the Translators): New
section.

5 days agoFix warnings with gcc 15 and glibc 2.43.
Bruno Haible [Sun, 25 Jan 2026 03:51:32 +0000 (04:51 +0100)] 
Fix warnings with gcc 15 and glibc 2.43.

* libtextstyle/gnulib-local/lib/glib/gstrfuncs.in.h (g_strstr_len): Change
return type to 'const gchar *'.
* libtextstyle/gnulib-local/lib/glib/gstrfuncs.c (g_strstr_len): Likewise.
* libtextstyle/gnulib-local/lib/libcroco/cr-rgb.c (cr_rgb_set_from_name): Change
type of 'result'.
* gettext-tools/src/cldr-plurals.c (extract_rules): Cast the sb_xcontents_c
result to 'char *'.

13 days agoFix some -Wzero-as-null-pointer-constant warnings.
Bruno Haible [Sat, 17 Jan 2026 03:39:12 +0000 (04:39 +0100)] 
Fix some -Wzero-as-null-pointer-constant warnings.

* gnulib-local/lib/backupfile.c (max_backup_version, backup_args, get_version):
Write NULL instead of 0.
* gettext-tools/src/x-go.c (add_to_hash_table): Likewise.

2 weeks agobuild: Fix "make installcheck" on MSVC.
Bruno Haible [Thu, 15 Jan 2026 11:32:43 +0000 (12:32 +0100)] 
build: Fix "make installcheck" on MSVC.

Reported by Kirill Makurin <maiddaisuki@outlook.com> in
<https://lists.gnu.org/archive/html/bug-gettext/2026-01/msg00042.html>.

* gettext-runtime/m4/gettext.m4 (AM_GNU_GETTEXT): New variable
INTL_WINDOWS_LIBS. Add it to LIBINTL and LTLIBINTL.
* gettext-runtime/configure.ac (INSTALLED_LIBINTL): Add $INTL_WINDOWS_LIBS.
* gettext-tools/configure.ac (INSTALLED_LIBINTL): Likewise.
* libtextstyle/configure.ac (INSTALLED_LIBTEXTSTYLE): New variable.
* libtextstyle/install-tests/Makefile.am (installcheck-local): Link with
$INSTALLED_LIBTEXTSTYLE instead of -ltextstyle.

2 weeks agoPrepare for 1.0-pre2 prerelease.
Bruno Haible [Tue, 13 Jan 2026 06:16:30 +0000 (07:16 +0100)] 
Prepare for 1.0-pre2 prerelease.

* gettext-runtime/src/envsubst.c (main): Update copyright year in --version
output.
* gettext-runtime/src/gettext.c (main): Likewise.
* gettext-runtime/src/gettext.sh.in (func_version): Likewise.
* gettext-runtime/src/ngettext.c (main): Likewise.
* gettext-runtime/src/printf_gettext.c (main): Likewise.
* gettext-runtime/src/printf_ngettext.c (main): Likewise.
* gettext-tools/src/cldr-plurals.c (main): Likewise.
* gettext-tools/src/hostname.c (main): Likewise.
* gettext-tools/src/msgattrib.c (main): Likewise.
* gettext-tools/src/msgcat.c (main): Likewise.
* gettext-tools/src/msgcmp.c (main): Likewise.
* gettext-tools/src/msgcomm.c (main): Likewise.
* gettext-tools/src/msgconv.c (main): Likewise.
* gettext-tools/src/msgen.c (main): Likewise.
* gettext-tools/src/msgexec.c (main): Likewise.
* gettext-tools/src/msgfilter.c (main): Likewise.
* gettext-tools/src/msgfmt.c (main): Likewise.
* gettext-tools/src/msggrep.c (main): Likewise.
* gettext-tools/src/msginit.c (main): Likewise.
* gettext-tools/src/msgmerge.c (main): Likewise.
* gettext-tools/src/msgpre.c (main): Likewise.
* gettext-tools/src/msgunfmt.c (main): Likewise.
* gettext-tools/src/msguniq.c (main): Likewise.
* gettext-tools/src/recode-sr-latin.c (main): Likewise.
* gettext-tools/src/spit.c (main): Likewise.
* gettext-tools/src/spit.py.in (main): Likewise.
* gettext-tools/src/urlget.c (main): Likewise.
* gettext-tools/src/xgettext.c (main): Likewise.
* gettext-tools/autotools/convert-archive.in (func_version): Likewise.
* gettext-tools/autotools/autopoint.in (func_version): Likewise.
* gettext-tools/wizard/gettextize.in (func_version): Likewise.

2 weeks agocldr-plurals: Fix parsing of plurals.xml from CLDR 38 or newer.
Michele Locati [Tue, 13 Jan 2026 10:23:14 +0000 (11:23 +0100)] 
cldr-plurals: Fix parsing of plurals.xml from CLDR 38 or newer.

Reported by Michele Locati at <https://savannah.gnu.org/bugs/?66378>.

* gettext-tools/src/cldr-plural-exp.c (eval_relation): Accept operands 'c', 'e'.
* gettext-tools/src/cldr-plural.y (yylex): Likewise.
* gettext-tools/src/cldr-plurals.c (extract_rules): Test for type='cardinal'.
(get_XcY_end, force_spaces, remove_XcY, remove_empty_examples): New functions.
(main): Invoke force_spaces, remove_XcY, remove_empty_examples.
* gettext-tools/tests/cldr-plurals-1: Add more tests.
* AUTHORS: Add Michele Locati.

2 weeks agoDocument a libcurl requirement.
Bruno Haible [Mon, 12 Jan 2026 11:43:29 +0000 (12:43 +0100)] 
Document a libcurl requirement.

Reported by Michele Locati <michele@locati.it> in
<https://lists.gnu.org/archive/html/bug-gettext/2026-01/msg00029.html>.

* DEPENDENCIES: Mention special requirements of libcurl on Windows.

2 weeks agoImprove support for clang on native Windows.
Bruno Haible [Sun, 11 Jan 2026 00:22:52 +0000 (01:22 +0100)] 
Improve support for clang on native Windows.

* gettext-tools/src/write-mo.c (roundup): Treat clang like GCC.

2 weeks agoImprove support for clang on native Windows.
Bruno Haible [Sun, 11 Jan 2026 00:22:29 +0000 (01:22 +0100)] 
Improve support for clang on native Windows.

* gettext-runtime/intl/libgnuintl.in.h (_INTL_REDIRECT_ASM): Treat clang like
GCC.

2 weeks agoImprove support for clang on native Windows.
Bruno Haible [Sun, 11 Jan 2026 00:21:58 +0000 (01:21 +0100)] 
Improve support for clang on native Windows.

Reported by Kirill Makurin <maiddaisuki@outlook.com> in
<https://lists.gnu.org/archive/html/bug-gettext/2026-01/msg00021.html>.

* libtextstyle/gnulib-local/lib/ostream.oo.h (ostream_printf, ostream_vprintf):
Treat clang like GCC.
* gettext-runtime/libasprintf/vasprintf.h (__attribute__, __format__,
__printf__): Likewise.
* gettext-runtime/libasprintf/autosprintf.in.h (_AUTOSPRINTF_ATTRIBUTE_FORMAT):
Likewise.
* gettext-tools/src/format.h (formatstring_error_logger_t): Likewise.
* gettext-tools/src/if-error.h (if_error, if_verror): Likewise.
* gettext-tools/src/msgl-check.c (formatstring_error_logger): Likewise.
* gettext-tools/src/msgl-merge.c (silent_error_logger): Likewise.
* gettext-tools/src/po-error.h (__attribute__, __format__, __printf__, po_error,
po_error_at_line): Likewise.
* gettext-tools/src/read-po-lex.h (__attribute__, __format__, __printf__):
Likewise.
* gettext-tools/src/xg-check.c (formatstring_error_logger): Likewise.
* gettext-tools/libgettextpo/gettext-po.in.h (struct po_error_handler):
Likewise.

2 weeks agolibtextstyle: Assume a working <stdbool.h>.
Bruno Haible [Sat, 10 Jan 2026 21:17:40 +0000 (22:17 +0100)] 
libtextstyle: Assume a working <stdbool.h>.

* libtextstyle/lib/textstyle.h: Include <stdbool.h> instead of
<textstyle/stdbool.h>.
* libtextstyle/lib/Makefile.am (nobase_nodist_include_HEADERS): Don't add
textstyle/stdbool.h.
(textstyle/stdbool.h): Remove rule.
(BUILT_SOURCES, MOSTLYCLEANFILES, CLEANFILES): Update accordingly.
(EXTRA_DIST): Remove stdbool.mini.h.
* libtextstyle/lib/stdbool.mini.h: Remove file.
* gettext-tools/src/Makefile.am (textstyle/stdbool.h): Remove target.
(BUILT_SOURCES, MOSTLYCLEANFILES): Remove textstyle/stdbool.h.

2 weeks agoxgettext: Allow inhibiting the warnings about URLs and email addresses.
Bruno Haible [Sat, 10 Jan 2026 19:16:46 +0000 (20:16 +0100)] 
xgettext: Allow inhibiting the warnings about URLs and email addresses.

Reported at <https://savannah.gnu.org/bugs/?67672>.

* gettext-tools/src/message.h (enum syntax_check_type): Add sc_url, sc_email.
(NSYNTAXCHECKS): Increase by 2.
* gettext-tools/src/message.c (syntax_check_name): Update.
* gettext-tools/src/xgettext.h (default_syntax_check): Add comment.
* gettext-tools/src/xgettext.c (default_syntax_check): Add initializer.
(main): Recognize --no-check option.
(usage): Document --no-check option.
* gettext-tools/src/xg-message.c (decide_syntax_check): Assume that
default_syntax_check[i] != undecided.
* gettext-tools/src/xg-check.c (syntax_check_function): Remove the second
argument.
(string_has_ascii_ellipsis): New function, extracted from
syntax_check_ellipsis_unicode.
(message_has_ascii_ellipsis): New function.
(syntax_check_ellipsis_unicode): Remove the second argument. Simplify. Emit only
a single error for both msgid and msgid_plural.
(string_has_space_ellipsis): New function, extracted from
syntax_check_space_ellipsis.
(message_has_space_ellipsis): New function.
(syntax_check_space_ellipsis): Remove the second argument. Simplify. Emit only
a single error for both msgid and msgid_plural.
(syntax_check_quote_unicode): Remove the second argument.
(syntax_check_bullet_unicode_string): New function, extracted from
syntax_check_bullet_unicode.
(syntax_check_bullet_unicode): Remove the second argument. Simplify.
(string_has_url): Don't recognize 'mailto:' URLs.
(syntax_check_url, syntax_check_email): New functions, extracted from
url_check_message.
(url_check_message): Remove function.
(sc_funcs): Add syntax_check_url, syntax_check_email.
(syntax_check_message): Simplify.
(xgettext_check_message_list): Don't invoke url_check_message.
* gettext-tools/tests/xgettext-14: Update after xg-check.c changesd.
* gettext-tools/tests/xgettext-20: Add more testcases.
* gettext-tools/doc/xgettext.texi: Document the --no-check option.
* gettext-tools/doc/gettext.texi: Bump copyright year.
* NEWS: Mention the change.

2 weeks agoDocument libjson-c version needed with MSVC.
Bruno Haible [Sat, 10 Jan 2026 09:19:02 +0000 (10:19 +0100)] 
Document libjson-c version needed with MSVC.

* DEPENDENCIES (libjson-c): Add note regarding MSVC.

3 weeks agolibtextstyle: Fix compilation error on platforms without working iconv.
Bruno Haible [Thu, 8 Jan 2026 09:32:43 +0000 (10:32 +0100)] 
libtextstyle: Fix compilation error on platforms without working iconv.

* libtextstyle/gnulib-local/lib/iconv-ostream.oo.c (iconv_ostream::flush): Add
second parameter.

3 weeks agobuild: Fix build failure in VPATH builds outside of the source tree.
Bruno Haible [Wed, 7 Jan 2026 21:00:50 +0000 (22:00 +0100)] 
build: Fix build failure in VPATH builds outside of the source tree.

* build-aux/jar-cf: Unset CDPATH. Run 'git log' from $top_srcdir, not from the
current directory.

4 weeks agopo-mode: Tweak.
Bruno Haible [Fri, 2 Jan 2026 04:09:01 +0000 (05:09 +0100)] 
po-mode: Tweak.

* gettext-tools/emacs/po-mode.el: Require Emacs >= 23, like before.
(po-mode-version-string): Bump to 2.32.

4 weeks agopo-mode: Add po-subedit-mode-hook.
gemmaro [Thu, 1 Jan 2026 13:47:52 +0000 (22:47 +0900)] 
po-mode: Add po-subedit-mode-hook.

Reported by <KAction@gnu.org> at
<https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=890295>.

* gettext-tools/emacs/po-mode.el (po-subedit-mode-hook): Add the
customize variable.

4 weeks agopo-mode: Use define-derived-mode for po-subedit-mode.
gemmaro [Thu, 1 Jan 2026 13:29:08 +0000 (22:29 +0900)] 
po-mode: Use define-derived-mode for po-subedit-mode.

* gettext-tools/emacs/po-mode.el (po-subedit-mode): Define as derived
mode from text mode using define-derived-mode.
(po-subedit-mode-syntax-table, po-mode-abbrev-table): Remove these
variables, as define-derived-mode creates them automatically.
(po-edit-string): Use po-subedit-mode instead of text-mode.  Remove
local abbrev table, keymap, syntax table, and hook invocation, since
define-derived-mode handles these automatically.  Move easy-menu
definition to the define-derived-mode body.
(Package-Requires): Add minimum Emacs version requirement. The
define-derived-mode was probably introduced in Emacs 19.23, and commit
7797a29e9 dropped support for Emacs versions before 23.

4 weeks agomsgfmt: Don't overflow the stack with large values for --alignment.
Collin Funk [Wed, 31 Dec 2025 18:11:47 +0000 (19:11 +0100)] 
msgfmt: Don't overflow the stack with large values for --alignment.

Reported by <maxtodeath@gmail.com> at <https://savannah.gnu.org/bugs/?67743>.

* gettext-tools/src/write-mo.c (write_table): Use xmalloca instead of
alloca to allocate the buffer to fill with NUL bytes.

4 weeks agodoc: Mention the issue of LLM licenses.
Bruno Haible [Wed, 31 Dec 2025 17:10:11 +0000 (18:10 +0100)] 
doc: Mention the issue of LLM licenses.

* gettext-tools/doc/gettext.texi (Installing an LLM): Discuss LLM license and
size.

4 weeks agopo-fetch: Clarify the directory.
Bruno Haible [Wed, 31 Dec 2025 01:03:38 +0000 (02:03 +0100)] 
po-fetch: Clarify the directory.

Reported by Simon Josefsson in
<https://lists.gnu.org/archive/html/bug-gettext/2025-12/msg00030.html>.

* gettext-tools/misc/po-fetch.in (func_usage): Mention the output files
location.
* gettext-tools/doc/po-fetch.texi: Likewise.

4 weeks agoDocument the relation between fetch-po and version control.
Bruno Haible [Wed, 31 Dec 2025 00:58:57 +0000 (01:58 +0100)] 
Document the relation between fetch-po and version control.

Reported by Simon Josefsson in
<https://lists.gnu.org/archive/html/bug-gettext/2025-12/msg00030.html>.

* gettext-tools/doc/gettext.texi (po/fetch-po): Add a reference.
(Translations under Version Control): Remove subsection.
(PO Template File under Version Control?): New subsection.
(Translations under Version Control?): New subsection.

4 weeks agobuild: Avoid link error on native Windows with --enable-shared.
Bruno Haible [Tue, 30 Dec 2025 23:37:14 +0000 (00:37 +0100)] 
build: Avoid link error on native Windows with --enable-shared.

Reported by Michele Locati <michele@locati.it> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-12/msg00038.html>.

* gettext-tools/src/country-table.h (country_table, country_table_size): Remove
LIBGETTEXTSRC_DLL_VARIABLE annotation.

4 weeks agopo-fetch: Add man page.
Bruno Haible [Tue, 30 Dec 2025 23:11:05 +0000 (00:11 +0100)] 
po-fetch: Add man page.

Reported by Simon Josefsson in
<https://lists.gnu.org/archive/html/bug-gettext/2025-12/msg00030.html>.

* gettext-tools/man/po-fetch.x: New file.
* gettext-tools/man/po-fetch.1.diff: New file.
* gettext-tools/man/Makefile.am (man_aux): Add po-fetch.x.
(man_MAN1MISC): New variable.
(man_MAN1): Include it.
(man_HTML): Add po-fetch.1.html.
($(man_MAN1MISC)): New rule.
(po-fetch.1, po-fetch.1.html): State dependencies.
* PACKAGING: Update.

4 weeks agobuild: Fix generation of man pages on native Windows.
Bruno Haible [Tue, 30 Dec 2025 23:10:38 +0000 (00:10 +0100)] 
build: Fix generation of man pages on native Windows.

* gettext-tools/man/Makefile.am ($(man_MAN1WIZARD), $(man_MAN1AUTOTOOLS)): Write
$${progname}, not $${progname}$(EXEEXT).

4 weeks agobuild: Reject libjson-c versions older than 0.13.
Bruno Haible [Tue, 30 Dec 2025 21:09:03 +0000 (22:09 +0100)] 
build: Reject libjson-c versions older than 0.13.

Reported by Michele Locati <michele@locati.it> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-12/msg00036.html>.

* DEPENDENCIES: Require libjson-c >= 0.13.
* gettext-tools/configure.ac (LIBJSON_C): Reject libjson-c versions older than
0.13.

4 weeks agoFix "make dist" error when BUILT_SPIT_IN_C is false.
Bruno Haible [Tue, 30 Dec 2025 00:26:21 +0000 (01:26 +0100)] 
Fix "make dist" error when BUILT_SPIT_IN_C is false.

* gettext-tools/src/Makefile.am (noinst_SCRIPTS): Add 'spit'.
(spit): New rule.
(BUILT_SOURCES, MOSTLYCLEANFILES): Add it.

4 weeks agoStart preparing for 1.0 release.
Bruno Haible [Mon, 29 Dec 2025 18:53:54 +0000 (19:53 +0100)] 
Start preparing for 1.0 release.

* gettext-runtime/m4/gettext.m4: Bump version.

4 weeks agoNew program 'msgpre'.
Bruno Haible [Mon, 29 Dec 2025 18:51:19 +0000 (19:51 +0100)] 
New program 'msgpre'.

* gettext-tools/src/msgpre.c: New file, based on gettext-tools/src/msgfilter.c.
* gettext-tools/src/FILES: Describe msgpre.c.
* gettext-tools/src/Makefile.am (bin_PROGRAMS): Add msgpre.
(msgpre_SOURCES, msgpre_LDADD, msgpre_DEPENDENCIES, msgpre_CPPFLAGS,
msgpre_LDFLAGS): New variables.
* gettext-tools/po/POTFILES.in: Add msgpre.c.
* gettext-tools/man/msgpre.x: New file.
* gettext-tools/man/Makefile.am (man_aux): Add msgpre.x.
(man_MAN1SRC): Add msgpre.1.
(man_HTML): Add msgpre.1.html.
(msgpre.1, msgpre.1.html): Add dependencies.
* gettext-tools/doc/gettext.texi (msgpre Invocation): New section.
* gettext-tools/doc/msgpre.texi: New file.
* gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it.
* gettext-tools/Makefile.am (programs-for-distdir): Create msgpre.
(distdir1, gen-man1): Update for the msgpre.1 manual page.
* NEWS: Mention the new program.

4 weeks agoWhitespace tweaks.
Bruno Haible [Sun, 28 Dec 2025 11:32:56 +0000 (12:32 +0100)] 
Whitespace tweaks.

* gettext-tools/src/msgfilter.c: Fix indentation.
* gettext-tools/src/*.c: GNU coding style.
* gettext-tools/tests/*.c: Likewise.

4 weeks agoNew program 'spit'.
Bruno Haible [Sat, 27 Dec 2025 22:53:53 +0000 (23:53 +0100)] 
New program 'spit'.

* gettext-tools/machine-translation/README: New file.
* gettext-tools/machine-translation/prototype/README: New file.
* gettext-tools/machine-translation/prototype/OllamaSpit.java: New file.
* gettext-tools/machine-translation/prototype/ollama-spit.c: New file.
* gettext-tools/machine-translation/prototype/ollama-spit.go: New file.
* gettext-tools/machine-translation/prototype/ollama-spit.py: New file.
* gettext-tools/machine-translation/prototype/ollama-spit.sh: New file.
* gettext-tools/configure.ac (INCJSON_C, LIBJSON_C, INCCURL, LIBCURL): New
variables.
(BUILD_SPIT_IN_C): New conditional.
(AC_CONFIG_FILES): Add src/spit.py.
* gettext-tools/src/country-table.h: New file.
* gettext-tools/src/country-table.c: New file.
* gettext-tools/src/spit.c: New file.
* gettext-tools/src/spit.py.in: New file.
* gettext-tools/src/FILES: Mention the new files.
* gettext-tools/src/Makefile.am (bin_PROGRAMS): Conditionally add 'spit'.
(noinst_SCRIPTS): New variable.
(noinst_HEADERS): Add country-table.h.
(spit_SOURCES, spit_CFLAGS, spit_LDADD, spit_DEPENDENCIES, spit_CPPFLAGS,
spit_LDFLAGS): New variables.
(install-exec-local): Conditionally install spit.py.
(installdirs-local, uninstall-local): Update accordingly.
(DISTCLEANFILES): Add spit.py.
* gettext-tools/po/POTFILES.in: Add spit.c.
* gettext-tools/man/spit.x: New file.
* gettext-tools/man/Makefile.am (man_aux): Add spit.x.
(man_MAN1SRC): Add spit.1.
(man_HTML): Add spit.1.html.
(spit.1, spit.1.html): Add dependencies.
* gettext-tools/doc/gettext.texi (Pretranslating): New chapter.
* gettext-tools/doc/spit.texi: New file.
* gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it.
* DEPENDENCIES: Update URLs for libxml2. Add libjson-c, libcurl, Python, the
Python module 'requests'.
* PACKAGING: Mention the 'spit' program and its manual page.
* NEWS: Mention the change.

4 weeks agoUpdate ISO 3166 country codes list.
Bruno Haible [Fri, 26 Dec 2025 21:50:10 +0000 (22:50 +0100)] 
Update ISO 3166 country codes list.

* gettext-tools/doc/ISO_3166: Update to match current Wikipedia.
* gettext-tools/doc/iso-3166.texi: Likewise.
* gettext-tools/src/msginit.c (catalogname_for_locale): Likewise.

5 weeks agoFix compilation error with MSVC 14 (regression 2025-12-19).
Bruno Haible [Mon, 22 Dec 2025 20:00:39 +0000 (21:00 +0100)] 
Fix compilation error with MSVC 14 (regression 2025-12-19).

* gettext-tools/src/msgl-merge.c (match_domain): Move variable declaration out
of an OpenMP 'for' loop. Reduce scope of local variables.

5 weeks agoFix compilation errors with older C compilers (regression 2025-12-19).
Bruno Haible [Mon, 22 Dec 2025 14:05:13 +0000 (15:05 +0100)] 
Fix compilation errors with older C compilers (regression 2025-12-19).

* gnulib-local/lib/xerror.c (multiline_internal): Add a semicolon between
a label and a declaration.
* gettext-tools/src/write-po.c (wrap): Likewise.
* gettext-tools/src/format-go.c (format_parse): Likewise.

5 weeks agoSimplify code.
Bruno Haible [Fri, 19 Dec 2025 20:50:39 +0000 (21:50 +0100)] 
Simplify code.

* gettext-tools/src/its.c (_its_encode_special_chars,
_its_encode_special_chars_for_merge): Remove unnecessary memory store.

5 weeks agoUpdate file list.
Bruno Haible [Fri, 19 Dec 2025 20:47:24 +0000 (21:47 +0100)] 
Update file list.

* gettext-tools/src/FILES: Update.

5 weeks agoModernize coding style: Reduce scope of local variables.
Bruno Haible [Fri, 19 Dec 2025 20:46:43 +0000 (21:46 +0100)] 
Modernize coding style: Reduce scope of local variables.

* HACKING (Coding Style): New section, copied from gnulib/HACKING.
* gettext-runtime/src/envsubst.c: Reduce scope of local variables.
* gettext-runtime/src/escapes.h: Likewise.
* gettext-runtime/src/gettext.c: Likewise.
* gettext-runtime/src/ngettext.c: Likewise.
* gettext-runtime/src/printf-command.c: Likewise.
* gettext-runtime/src/printf_gettext.c: Likewise.
* gettext-runtime/src/printf_ngettext.c: Likewise.
* gnulib-local/lib/addext.c: Likewise.
* gnulib-local/lib/backupfile.c: Likewise.
* gnulib-local/lib/gettext.h: Likewise.
* gnulib-local/lib/markup.c: Likewise.
* gnulib-local/lib/xerror.c: Likewise.
* libtextstyle/gnulib-local/lib/file-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/html-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/html-styled-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/iconv-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/memory-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/noop-styled-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/term-ostream.oo.c: Likewise.
* libtextstyle/gnulib-local/lib/term-styled-ostream.oo.c: Likewise.
* libtextstyle/lib/color.c: Likewise.
* libtextstyle/lib/misc.c: Likewise.
* gettext-tools/src/cldr-plural-exp.c: Likewise.
* gettext-tools/src/cldr-plurals.c: Likewise.
* gettext-tools/src/file-list.c: Likewise.
* gettext-tools/src/filter-quote.c: Likewise.
* gettext-tools/src/format-awk.c: Likewise.
* gettext-tools/src/format-boost.c: Likewise.
* gettext-tools/src/format-c++-brace.c: Likewise.
* gettext-tools/src/format-c.c: Likewise.
* gettext-tools/src/format-c-parse.h: Likewise.
* gettext-tools/src/format-csharp.c: Likewise.
* gettext-tools/src/format-d.c: Likewise.
* gettext-tools/src/format-elisp.c: Likewise.
* gettext-tools/src/format-gcc-internal.c: Likewise.
* gettext-tools/src/format-gfc-internal.c: Likewise.
* gettext-tools/src/format-go.c: Likewise.
* gettext-tools/src/format-java-printf.c: Likewise.
* gettext-tools/src/format-java.c: Likewise.
* gettext-tools/src/format-javascript.c: Likewise.
* gettext-tools/src/format-kde-kuit.c: Likewise.
* gettext-tools/src/format-kde.c: Likewise.
* gettext-tools/src/format-librep.c: Likewise.
* gettext-tools/src/format-lisp.c: Likewise.
* gettext-tools/src/format-lua.c: Likewise.
* gettext-tools/src/format-modula2.c: Likewise.
* gettext-tools/src/format-ocaml.c: Likewise.
* gettext-tools/src/format-pascal.c: Likewise.
* gettext-tools/src/format-perl-brace.c: Likewise.
* gettext-tools/src/format-perl.c: Likewise.
* gettext-tools/src/format-php.c: Likewise.
* gettext-tools/src/format-python-brace.c: Likewise.
* gettext-tools/src/format-python.c: Likewise.
* gettext-tools/src/format-qt-plural.c: Likewise.
* gettext-tools/src/format-qt.c: Likewise.
* gettext-tools/src/format-ruby.c: Likewise.
* gettext-tools/src/format-rust.c: Likewise.
* gettext-tools/src/format-scheme.c: Likewise.
* gettext-tools/src/format-sh-printf.c: Likewise.
* gettext-tools/src/format-sh.c: Likewise.
* gettext-tools/src/format-smalltalk.c: Likewise.
* gettext-tools/src/format-tcl.c: Likewise.
* gettext-tools/src/format.c: Likewise.
* gettext-tools/src/hostname.c: Likewise.
* gettext-tools/src/if-error.c: Likewise.
* gettext-tools/src/its.c: Likewise.
* gettext-tools/src/locating-rules.c: Likewise.
* gettext-tools/src/message.c: Likewise.
* gettext-tools/src/msgattrib.c: Likewise.
* gettext-tools/src/msgcat.c: Likewise.
* gettext-tools/src/msgcmp.c: Likewise.
* gettext-tools/src/msgcomm.c: Likewise.
* gettext-tools/src/msgconv.c: Likewise.
* gettext-tools/src/msgen.c: Likewise.
* gettext-tools/src/msgexec.c: Likewise.
* gettext-tools/src/msgfilter.c: Likewise.
* gettext-tools/src/msgfmt.c: Likewise.
* gettext-tools/src/msggrep.c: Likewise.
* gettext-tools/src/msginit.c: Likewise.
* gettext-tools/src/msgl-ascii.c: Likewise.
* gettext-tools/src/msgl-cat.c: Likewise.
* gettext-tools/src/msgl-charset.c: Likewise.
* gettext-tools/src/msgl-check.c: Likewise.
* gettext-tools/src/msgl-english.c: Likewise.
* gettext-tools/src/msgl-equal.c: Likewise.
* gettext-tools/src/msgl-fsearch.c: Likewise.
* gettext-tools/src/msgl-header.c: Likewise.
* gettext-tools/src/msgl-iconv.c: Likewise.
* gettext-tools/src/msgl-merge.c: Likewise.
* gettext-tools/src/msgl-ofn.c: Likewise.
* gettext-tools/src/msgmerge.c: Likewise.
* gettext-tools/src/msgunfmt.c: Likewise.
* gettext-tools/src/msguniq.c: Likewise.
* gettext-tools/src/open-catalog.c: Likewise.
* gettext-tools/src/plural-count.c: Likewise.
* gettext-tools/src/po-charset.c: Likewise.
* gettext-tools/src/po-time.c: Likewise.
* gettext-tools/src/read-catalog.c: Likewise.
* gettext-tools/src/read-catalog-abstract.c: Likewise.
* gettext-tools/src/read-catalog-file.c: Likewise.
* gettext-tools/src/read-catalog-special.c: Likewise.
* gettext-tools/src/read-csharp.c: Likewise.
* gettext-tools/src/read-desktop.c: Likewise.
* gettext-tools/src/read-java.c: Likewise.
* gettext-tools/src/read-mo.c: Likewise.
* gettext-tools/src/read-po-lex.c: Likewise.
* gettext-tools/src/read-properties.c: Likewise.
* gettext-tools/src/read-resources.c: Likewise.
* gettext-tools/src/read-stringtable.c: Likewise.
* gettext-tools/src/read-tcl.c: Likewise.
* gettext-tools/src/recode-sr-latin.c: Likewise.
* gettext-tools/src/search-path.c: Likewise.
* gettext-tools/src/str-list.c: Likewise.
* gettext-tools/src/urlget.c: Likewise.
* gettext-tools/src/write-catalog.c: Likewise.
* gettext-tools/src/write-csharp.c: Likewise.
* gettext-tools/src/write-desktop.c: Likewise.
* gettext-tools/src/write-java.c: Likewise.
* gettext-tools/src/write-mo.c: Likewise.
* gettext-tools/src/write-po.c: Likewise.
* gettext-tools/src/write-properties.c: Likewise.
* gettext-tools/src/write-qt.c: Likewise.
* gettext-tools/src/write-resources.c: Likewise.
* gettext-tools/src/write-stringtable.c: Likewise.
* gettext-tools/src/write-tcl.c: Likewise.
* gettext-tools/src/write-xml.c: Likewise.
* gettext-tools/src/x-awk.c: Likewise.
* gettext-tools/src/x-c.c: Likewise.
* gettext-tools/src/x-csharp.c: Likewise.
* gettext-tools/src/x-d.c: Likewise.
* gettext-tools/src/x-desktop.c: Likewise.
* gettext-tools/src/x-elisp.c: Likewise.
* gettext-tools/src/x-go.c: Likewise.
* gettext-tools/src/x-java.c: Likewise.
* gettext-tools/src/x-javascript.c: Likewise.
* gettext-tools/src/x-librep.c: Likewise.
* gettext-tools/src/x-lisp.c: Likewise.
* gettext-tools/src/x-lua.c: Likewise.
* gettext-tools/src/x-modula2.c: Likewise.
* gettext-tools/src/x-ocaml.c: Likewise.
* gettext-tools/src/x-perl.c: Likewise.
* gettext-tools/src/x-php.c: Likewise.
* gettext-tools/src/x-po.c: Likewise.
* gettext-tools/src/x-python.c: Likewise.
* gettext-tools/src/x-rst.c: Likewise.
* gettext-tools/src/x-ruby.c: Likewise.
* gettext-tools/src/x-rust.c: Likewise.
* gettext-tools/src/x-scheme.c: Likewise.
* gettext-tools/src/x-sh.c: Likewise.
* gettext-tools/src/x-smalltalk.c: Likewise.
* gettext-tools/src/x-tcl.c: Likewise.
* gettext-tools/src/x-typescript-impl.h: Likewise.
* gettext-tools/src/x-vala.c: Likewise.
* gettext-tools/src/x-ycp.c: Likewise.
* gettext-tools/src/xerror-handler.c: Likewise.
* gettext-tools/src/xg-arglist-callshape.c: Likewise.
* gettext-tools/src/xg-arglist-context.c: Likewise.
* gettext-tools/src/xg-arglist-parser.c: Likewise.
* gettext-tools/src/xg-check.c: Likewise.
* gettext-tools/src/xg-encoding.c: Likewise.
* gettext-tools/src/xg-message.c: Likewise.
* gettext-tools/src/xg-mixed-string.c: Likewise.
* gettext-tools/src/xgettext.c: Likewise.

6 weeks agoxgettext: Optimize vc-mtime usage.
Bruno Haible [Fri, 12 Dec 2025 18:25:15 +0000 (19:25 +0100)] 
xgettext: Optimize vc-mtime usage.

* gettext-tools/src/xgettext.c (extract_from_xml_file): Don't augment
files_for_vc_mtime twice.

6 weeks agoModernize coding style: Avoid 'goto' statements where possible.
Bruno Haible [Fri, 12 Dec 2025 10:28:00 +0000 (11:28 +0100)] 
Modernize coding style: Avoid 'goto' statements where possible.

* gettext-tools/src/msgfmt.c (get_languages): Use if/else instead of 'goto'.

6 weeks agoModernize coding style: Avoid 'continue;' statements where possible.
Bruno Haible [Fri, 12 Dec 2025 10:24:14 +0000 (11:24 +0100)] 
Modernize coding style: Avoid 'continue;' statements where possible.

* gnulib-local/lib/backupfile.c (max_backup_version): Use if/else instead of
'continue;'.
* gnulib-local/lib/markup.c (emit_start_element): Likewise.

7 weeks agoModernize coding style: Avoid 'continue;' statements where possible.
Bruno Haible [Thu, 11 Dec 2025 09:38:17 +0000 (10:38 +0100)] 
Modernize coding style: Avoid 'continue;' statements where possible.

* gettext-tools/src/cldr-plurals.c (extract_rules): Use if/else instead of
'continue;'.
* gettext-tools/src/msgfmt.c (msgfmt_operand_list_add_from_directory): Likewise.
* gettext-tools/src/read-po-lex.c (po_gram_lex): Likewise.
* gettext-tools/src/sentence.c (sentence_end): Likewise.
* gettext-tools/src/x-awk.c (extract_parenthesized): Use 'break;' instead of
'continue;'.
* gettext-tools/src/x-c.c (extract_parenthesized): Likewise.
* 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-lua.c (extract_balanced): Likewise.
* gettext-tools/src/x-modula2.c (extract_parenthesized): Likewise.
* gettext-tools/src/x-php.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-ycp.c (extract_parenthesized): Likewise.

8 weeks agotests: Remove a left-over debugging trace.
Bruno Haible [Mon, 1 Dec 2025 18:56:59 +0000 (19:56 +0100)] 
tests: Remove a left-over debugging trace.

* gettext-tools/tests/xgettext-20: Remove a 'set -x' statement.

2 months agolibasprintf: Document need to use g++ option -Wall.
Bruno Haible [Tue, 11 Nov 2025 11:24:10 +0000 (12:24 +0100)] 
libasprintf: Document need to use g++ option -Wall.

* gettext-runtime/libasprintf/autosprintf.texi (Using autosprintf): Expand text.
(Source code changes, Build system changes): New nodes.

2 months agoautopoint: Diagnose multiple invocations of AM_GNU_GETTEXT_VERSION.
Bruno Haible [Wed, 5 Nov 2025 14:01:12 +0000 (15:01 +0100)] 
autopoint: Diagnose multiple invocations of AM_GNU_GETTEXT_VERSION.

Reported by Santiago Vila in
<https://lists.gnu.org/archive/html/bug-gettext/2025-11/msg00001.html>.

* gettext-tools/autotools/autopoint.in: Report an error if "$xreq" or "$xver"
consists of more than one line.

3 months agoUpdate translations from TP.
Bruno Haible [Fri, 24 Oct 2025 13:18:53 +0000 (15:18 +0200)] 
Update translations from TP.

* gettext-runtime/po/*.po: Update from TP.
* gettext-tools/po/*.po: Update from TP.
* gettext-tools/examples/po/*.po: Update from TP.

3 months agobuild: Add scripts for fetching the PO files.
Bruno Haible [Fri, 24 Oct 2025 12:13:44 +0000 (14:13 +0200)] 
build: Add scripts for fetching the PO files.

* gettext-runtime/po/fetch-po: New file.
* gettext-tools/po/fetch-po: New file.
* gettext-tools/examples/po/fetch-po: New file.
* check-copyright-headers (func_check_file): Don't complain about the LINGUAS
files, that will now have more than 10 lines.

3 months agopo: Add customizable 'fetch-po' script.
Bruno Haible [Fri, 24 Oct 2025 11:03:43 +0000 (13:03 +0200)] 
po: Add customizable 'fetch-po' script.

* gettext-tools/wizard/po-templates/traditional/fetch-po: New file.
* gettext-tools/wizard/Makefile.am (po_SCRIPTS): New variable.
(EXTRA_DIST): Add the po_SCRIPTS.
* gettext-tools/wizard/gettextize.in: Copy but don't overwrite po/fetch-po.
* gettext-tools/wizard/po-templates/traditional/Makefile.in.in (fetch-po): New
target.
* gettext-tools/examples/po/Makefile.am (fetch-po): New target.
* gettext-tools/examples/hello-*/po/Makefile.am (fetch-po): New target.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile (fetch-po): New
target.
* gettext-tools/doc/gettext.texi (po/fetch-po): New subsection.
(po/LINGUAS): Explain how it related to the 'fetch-po' script.
(Release Management): Document how to fetch the PO files before a release.
* NEWS: Mention the change.

3 months agoNew program 'po-fetch'.
Bruno Haible [Tue, 21 Oct 2025 12:29:27 +0000 (14:29 +0200)] 
New program 'po-fetch'.

* gettext-tools/misc/po-fetch.in: New file.
* gettext-tools/misc/Makefile.am: New file.
* gettext-tools/configure.ac: Add AC_CONFIG_FILES invocations for the misc/
directory.
* gettext-tools/Makefile.am (SUBDIRS): Add misc.
(EXTRA_DIST): Remove misc/disclaim-translations.txt.
(pkgdata_DATA): Remove variable.
* gettext-tools/doc/po-fetch.texi: New file.
* gettext-tools/doc/Makefile.am (gettext_TEXINFOS): Add it.
* gettext-tools/doc/gettext.texi (po-fetch): Add global menu entry.
(po-fetch Invocation): New section.
* PACKAGING: Mention the installed 'po-fetch' program.
* NEWS: Mention 'po-fetch'.

3 months agobuild: Remove duplicate file from version control.
Bruno Haible [Sun, 19 Oct 2025 03:55:33 +0000 (05:55 +0200)] 
build: Remove duplicate file from version control.

* gettext-tools/examples/po/remove-potcdate.sed: Remove file.
* autogen.sh: Copy remove-potcdate.sed to
gettext-tools/examples/po/remove-potcdate.sed.

3 months agobuild: Distribute one more file.
Bruno Haible [Sun, 19 Oct 2025 01:00:18 +0000 (03:00 +0200)] 
build: Distribute one more file.

* gettext-runtime/install-tests/Makefile.am (EXTRA_DIST): Add itest.pot.

3 months agobuild: Distribute all tree-sitter patches.
Bruno Haible [Sun, 19 Oct 2025 00:54:54 +0000 (02:54 +0200)] 
build: Distribute all tree-sitter patches.

* gettext-tools/Makefile.am (EXTRA_DIST): Add
build-aux/tree-sitter-d-optimization-bug.diff, added on 2025-05-03.

3 months agoNew directory gettext-tools/wizard/po-templates/traditional/.
Bruno Haible [Sat, 18 Oct 2025 16:53:20 +0000 (18:53 +0200)] 
New directory gettext-tools/wizard/po-templates/traditional/.

* gettext-tools/wizard/po-templates/traditional/*: New files, moved here from
gettext-runtime/po/.
* gettext-tools/wizard/po-templates/traditional/Makefile.in.in (install-data,
installdirs-data, uninstall-data, dist2): Remove special code for the
'gettext-tools' package.
* gettext-tools/wizard/po-templates/traditional/Makevars.template: Moved here
from gettext-tools/po/.
* autogen.sh: Copy the contents of the gettext-runtime/po/ and gettext-tools/po/
directories from gettext-tools/wizard/po-templates/traditional/.
* gettext-tools/wizard/Makefile.am (pkgdatadir, podir): New variables.
(po_DATA): Add po-templates/traditional/*.
(EXTRA_DIST): Likewise.
(uninstall-sources): Also remove $(podir)/Makevars.
* Makefile.am (distcheck-hook): Update.

3 months agodoc: Mention how to localize other data formats.
Bruno Haible [Fri, 17 Oct 2025 07:28:17 +0000 (09:28 +0200)] 
doc: Mention how to localize other data formats.

* gettext-tools/doc/gettext.texi (Data Formats): Mention po4a. Describe how to
localize LibreOffice documents.

3 months agopo: Don't msgmerge the PO files through Makefile.in.in.
Bruno Haible [Mon, 13 Oct 2025 22:55:27 +0000 (00:55 +0200)] 
po: Don't msgmerge the PO files through Makefile.in.in.

* gettext-runtime/po/Makefile.in.in (MSGMERGE_UPDATE): Remove variable.
(UPDATEPOFILES): Remove variable.
(POFILESDEPS*): Remove variables.
(.SUFFIXES): Add '.gpo'. Remove '.po-update'.
(.po.gpo): New rule.
($(POFILES)): Remove dependencies. Don't invoke MSGMERGE_UPDATE.
(mostlyclean): Add *.gpo.
(update-po): Don't make $(UPDATEPOFILES).
(.nop.po-update): Remove rule.
* gettext-runtime/po/Makevars (PO_DEPENDS_ON_POT): Remove variable.
* gettext-tools/po/Makevars (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/po/Makevars.template (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/examples/hello-c/po/Makevars (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/examples/hello-c-gnome2/po/Makevars (PO_DEPENDS_ON_POT):
Likewise.
* gettext-tools/examples/hello-c-gnome3/po/Makevars (PO_DEPENDS_ON_POT):
Likewise.
* gettext-tools/examples/hello-c-http/po/Makevars (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/examples/hello-c++/po/Makevars (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/examples/hello-c++20/po/Makevars (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/examples/hello-c++-gnome2/po/Makevars (PO_DEPENDS_ON_POT):
Likewise.
* gettext-tools/examples/hello-c++-gnome3/po/Makevars (PO_DEPENDS_ON_POT):
Likewise.
* gettext-tools/examples/hello-c++-kde/po/Makevars (PO_DEPENDS_ON_POT):
Likewise.
* gettext-tools/examples/hello-objc/po/Makevars (PO_DEPENDS_ON_POT): Likewise.
* gettext-tools/examples/hello-objc-gnome2/po/Makevars (PO_DEPENDS_ON_POT):
Likewise.
* gettext-tools/examples/hello-c++-wxwidgets/po/Makefile.am (MSGMERGE_UPDATE):
Remove variable.
(UPDATEPOFILES): Remove variable.
(.SUFFIXES): Add '.gpo'. Remove '.po-update'.
(.po.gpo): New rule.
($(POFILES)): Remove dependencies. Don't invoke MSGMERGE_UPDATE.
(MOSTLYCLEANFILES): Add *.gpo.
(update-po): Don't make $(UPDATEPOFILES).
(.nop.po-update): Remove rule.
* gettext-tools/examples/hello-python/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-guile/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-clisp/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-librep/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-rust/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-go/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-go-http/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-ruby/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-sh/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-gawk/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-pascal/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-modula2/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-d/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-ocaml/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-smalltalk/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-perl/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-php/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-ycp/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-c++-qt/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-java/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-java-awt/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-java-swing/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-java-qtjambi/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-csharp/po/Makefile.am (MSGMERGE_UPDATE): Remove
variable.
(UPDATEPOFILES): Remove variable.
(RESOURCESDLLFILES): Change emitted commands to use an intermediate .gpo file.
(.SUFFIXES): Add '.gpo'. Remove '.po-update'.
(.po.gpo): New rule.
($(POFILES)): Remove dependencies. Don't invoke MSGMERGE_UPDATE.
(MOSTLYCLEANFILES): Add *.gpo.
(update-po): Don't make $(UPDATEPOFILES).
(.nop.po-update): Remove rule.
* gettext-tools/examples/hello-csharp-forms/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-tcl/po/Makefile.am (MSGMERGE_UPDATE): Remove
variable.
(UPDATEPOFILES): Remove variable.
(MSGFILES): Change emitted commands to use an intermediate .gpo file.
(.SUFFIXES): Add '.gpo'. Remove '.po-update'.
(.po.gpo): New rule.
($(POFILES)): Remove dependencies. Don't invoke MSGMERGE_UPDATE.
(MOSTLYCLEANFILES): Add *.gpo.
(update-po): Don't make $(UPDATEPOFILES).
(.nop.po-update): Remove rule.
* gettext-tools/examples/hello-tcl-tk/po/Makefile.am: Likewise.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile (MSGMERGE_UPDATE):
Remove variable.
(UPDATEPOFILES): Remove variable.
(.SUFFIXES): Add '.gpo'. Remove '.po-update'.
($(POFILES)): Remove dependencies. Don't invoke MSGMERGE_UPDATE.
(update-po): Don't make $(UPDATEPOFILES).
(.nop.po-update): Remove rule.
* gettext-tools/examples/po/Makefile.am (MSGMERGE_OPTIONS): Add
--no-fuzzy-matching --quiet.
(MSGMERGE_UPDATE): Remove variable.
(UPDATEPOFILES): Remove variable.
(GPOFILES): New variable.
(.SUFFIXES): Add '.gpo'. Remove '.nop', '.po-update'.
(.po.gpo): New rule.
($(POFILES)): Remove rule.
(DISTCLEANFILES): New variable.
(update-po): Don't make $(UPDATEPOFILES). Make the small PO files.
(.nop.po-update): Remove rule.
* gettext-tools/examples/po/mmsmallpo.sh: Use $language.gpo instead of
$language.po.
* gettext-tools/doc/gettext.texi (Translations under Version Control): Remove
documentation of PO_DEPENDS_ON_POT.
(Release Management): Update wording.
* Admin/release-steps: Don't msgmerge the PO files from translationproject.org.
* NEWS: Mention the change.

3 months agoexamples: Fix hello-tcl* examples (regression 2024-12-06).
Bruno Haible [Mon, 13 Oct 2025 00:15:25 +0000 (02:15 +0200)] 
examples: Fix hello-tcl* examples (regression 2024-12-06).

* gettext-tools/examples/hello-tcl*/po/Makefile.am (CATALOGS): Use suffix .msg,
not .gmo.

3 months agocheck-examples: Update comments.
Bruno Haible [Sun, 12 Oct 2025 20:36:56 +0000 (22:36 +0200)] 
check-examples: Update comments.

* gettext-tools/examples/check-examples: Update comments.

3 months agoexamples: Improve error message when there is a mistake in a PO file.
Bruno Haible [Sun, 12 Oct 2025 17:45:27 +0000 (19:45 +0200)] 
examples: Improve error message when there is a mistake in a PO file.

* gettext-tools/examples/hello-*/po/Makefile.am (.po.gmo): Use suffix .gpo
instead of .1po.
* gettext-tools/examples/hello-java*/po/Makefile.am (update-properties,
update-classes): Likewise.
* gettext-tools/examples/hello-c++-qt/po/Makefile.am (.po.qm): Likewise.
* gettext-tools/examples/hello-objc-gnustep/po/GNUmakefile ($(STRINGSFILES)):
Likewise.

3 months agoxgettext: Rust: Recognize 'gettextrs::gettext' invocations like 'gettext'
Bruno Haible [Sun, 12 Oct 2025 14:31:10 +0000 (16:31 +0200)] 
xgettext: Rust: Recognize 'gettextrs::gettext' invocations like 'gettext'
invocations.

Reported by Schmiddiii <gnu-savannah@schmidhuberj.de>
at <https://savannah.gnu.org/bugs/?67601>.

* gettext-tools/src/x-rust.c (ts_symbol_scoped_identifier): New variable.
(extract_from_function_call): Accept a scoped_identifier as first argument.
(extract_from_node): Allow a scoped_identifier as callee.
(extract_rust): Initialize ts_symbol_scoped_identifier.
* gettext-tools/tests/xgettext-rust-1: Add another test case.
* gettext-tools/tests/xgettext-rust-6: Likewise.
* NEWS: Mention the fix.

3 months agopo: Improve error message when there is a mistake in a PO file.
Bruno Haible [Sun, 12 Oct 2025 11:51:18 +0000 (13:51 +0200)] 
po: Improve error message when there is a mistake in a PO file.

* gettext-runtime/po/Makefile.in.in (.po.gmo): Use suffix .gpo instead of .1po.

3 months agopo: Simplify.
Bruno Haible [Sun, 12 Oct 2025 11:42:46 +0000 (13:42 +0200)] 
po: Simplify.

* gettext-runtime/po/Makefile.in.in (.NOEXPORT): Remove workaround for versions
of GNU make from before 1993.

3 months agobuild: Move more code into libgettextsrc.
Bruno Haible [Sun, 12 Oct 2025 10:50:54 +0000 (12:50 +0200)] 
build: Move more code into libgettextsrc.

* gettext-tools/src/lang-table.h (language_table, language_table_size,
language_variant_table, language_variant_table_size): Mark as
LIBGETTEXTSRC_DLL_VARIABLE.
* gettext-tools/src/Makefile.am (libgettextsrc_la_SOURCES): Add msgl-fsearch.c,
lang-table.c, plural-count.c.
(msgmerge_SOURCES): Remove msgl-fsearch.c, lang-table.c, plural-count.c.
(msginit_SOURCES): Likewise.
* gettext-tools/src/FILES: Update.

3 months agomsginit: Produce a merged PO file instead of failing.
Bruno Haible [Sun, 12 Oct 2025 02:00:26 +0000 (04:00 +0200)] 
msginit: Produce a merged PO file instead of failing.

* gettext-tools/src/msginit.c: Include <omp.h>, msgl-merge.h, backupfile.h,
copy-file.h.
(catalogname): Remove variable.
(main): When the PO file already exists, create a backup file, then merge the
two files.
(usage): Say what happens if the output file already exists.
(struct header_entry_field): New type.
(fresh_fields): Renamed from fields.
(NFIELDS): Remove macro.
(FRESH_FIELDS_LAST_TRANSLATOR): Renamed from FIELD_LAST_TRANSLATOR.
(update_fields): New variable.
(UPDATE_FIELDS_LAST_TRANSLATOR): New macro.
(fill_header): Add 'fresh' parameter. Allocate field_value array on the heap.
* gettext-tools/src/Makefile.am (msginit_SOURCES): Add msgl-fsearch.c,
msgl-merge.c.
(msginit_CFLAGS, msginit_CXXFLAGS): Link with the OpenMP flags.
* gettext-tools/doc/msginit.texi: Say what happens if the output file already
exists.
* gettext-tools/doc/gettext.texi (Creating): Change title. Mention that msginit
can also be used when continuing an existing translation.
* NEWS: Mention the improvement.

3 months agoRefactor: Librarify the core of msgmerge.
Bruno Haible [Sun, 12 Oct 2025 00:12:13 +0000 (02:12 +0200)] 
Refactor: Librarify the core of msgmerge.

* gettext-tools/src/msgl-merge.h: New file, based on
gettext-tools/src/msgmerge.c.
* gettext-tools/src/msgl-merge.c: New file, based on
gettext-tools/src/msgmerge.c.
* gettext-tools/src/msgmerge.c: Include msgl-merge.h. Simplify includes.
Remove definitions that are moved to msgl-merge.c.
* gettext-tools/src/FILES: Update.
* gettext-tools/src/Makefile.am (noinst_HEADERS): Add msgl-merge.h.
(msgmerge_SOURCES): Add msgl-merge.c.
* gettext-tools/po/POTFILES.in: Add src/msgl-merge.c.

3 months agoOCaml: Tweak documentation.
Bruno Haible [Sat, 11 Oct 2025 22:09:13 +0000 (00:09 +0200)] 
OCaml: Tweak documentation.

* gettext-tools/doc/lang-ocaml.texi: Add note regarding format strings.

3 months agoFix failure of lang-javascript on macOS 15.
Bruno Haible [Tue, 7 Oct 2025 11:41:04 +0000 (13:41 +0200)] 
Fix failure of lang-javascript on macOS 15.

3 months agoUpdate after gnulib changed.
Bruno Haible [Sun, 5 Oct 2025 20:22:28 +0000 (22:22 +0200)] 
Update after gnulib changed.

3 months agoRefactor: New subdirectory gettext-tools/wizard/, part 2.
Bruno Haible [Sun, 5 Oct 2025 20:19:36 +0000 (22:19 +0200)] 
Refactor: New subdirectory gettext-tools/wizard/, part 2.

3 months agoRefactor: New subdirectory gettext-tools/autotools/.
Bruno Haible [Sun, 5 Oct 2025 16:41:00 +0000 (18:41 +0200)] 
Refactor: New subdirectory gettext-tools/autotools/.

* gettext-tools/Makefile.am (SUBDIRS): Add autotools. Remove misc.
(distdir2): Update.
* gettext-tools/autotools/Makefile.am: Renamed from
gettext-tools/misc/Makefile.am.
* gettext-tools/autotools/archive.dir.tar: Renamed from
gettext-tools/misc/archive.dir.tar.
* gettext-tools/autotools/add-to-archive: Renamed from
gettext-tools/misc/add-to-archive.
* gettext-tools/autotools/cvsuser.c: Renamed from gettext-tools/misc/cvsuser.c.
* gettext-tools/autotools/convert-archive.in: Renamed from
gettext-tools/misc/convert-archive.in.
* gettext-tools/autotools/autopoint.in: Renamed from
gettext-tools/misc/autopoint.in.
* gettext-tools/configure.ac: Update AC_CONFIG_FILES invocations.
* gettext-tools/man/Makefile.am (man_MAN1AUTOTOOLS): Renamed from man_MAN1MISC.
($(man_MAN1AUTOTOOLS)): Renamed from $(man_MAN1MISC).
(autopoint.1): Update.
* gettext-tools/examples/po/Makefile.am (USE_BUILT_PROGS): Update.
* gettext-tools/tests/autopoint-1: Update.
* gettext-tools/tests/autopoint-2: Likewise.
* gettext-tools/tests/autopoint-3: Likewise.
* check-copyright-headers (func_check_file): Update.

3 months agoPut archive.dir.tar under version control, part 2.
Bruno Haible [Sun, 5 Oct 2025 16:27:03 +0000 (18:27 +0200)] 
Put archive.dir.tar under version control, part 2.

* gettext-tools/misc/Makefile.am ($(srcdir)/archive.dir.tar): Remove rule.

3 months agoRefactor: New subdirectory gettext-tools/wizard/.
Bruno Haible [Sun, 5 Oct 2025 15:33:27 +0000 (17:33 +0200)] 
Refactor: New subdirectory gettext-tools/wizard/.

* gettext-tools/configure.ac: Invoke AC_CONFIG_FILES for wizard/Makefile,
wizard/gettextize, instead of for misc/gettextize.
* gettext-tools/Makefile.am (SUBDIRS): Add wizard.
(distdir2): Recurse into wizard/.
* gettext-tools/wizard/Makefile.am: New file, based on
gettext-tools/misc/Makefile.am.
* gettext-tools/wizard/gettextize.in: Renamed from
gettext-tools/misc/gettextize.in.
* gettext-tools/misc/Makefile.am (bin_SCRIPTS, DISTCLEANFILES): Remove
gettextize.
(install-data-local, uninstall-local, uninstall-sources): Remove rules.
* gettext-tools/man/Makefile.am (man_MAN1WIZARD): New variable.
(man_MAN1MISC): Remove gettextize.1.
($(man_MAN1WIZARD)): New rule.
(gettextize.1): Update.
($(man_MAN1MISC)): Simplify.

3 months agoRestore syntax highlighting in Emacs 30 or newer.
Bruno Haible [Thu, 2 Oct 2025 20:50:11 +0000 (22:50 +0200)] 
Restore syntax highlighting in Emacs 30 or newer.

Reported by Sab Pyrope <sab.pyrope@gmail.com> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-03/msg00017.html>
and by Julien Palard <julien@palard.fr> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-10/msg00000.html>.

It's a regression in Emacs 30, in commit
17e26cf57e18c5df2172a7049591d89fc53b3fb6 .

* gettext-tools/emacs/HACKING: Document how to bisect Emacs regressions.
* gettext-tools/emacs/po-mode.el (po-mode-version-string): Bump to 2.31.
(po-mode): Invoke run-mode-hooks instead of run-hooks.
* NEWS: Mention the fix.

3 months agoxgettext: Java: Remove unjustified warning "'}' found where ')' was expected".
Bruno Haible [Tue, 30 Sep 2025 22:04:45 +0000 (00:04 +0200)] 
xgettext: Java: Remove unjustified warning "'}' found where ')' was expected".

Reported by Alexander Hubmann-Haidvogel <ahubmann@gmail.com> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-09/msg00000.html>
and by Bjoern Voigt <bjoernv@arcor.de> in
<https://lists.gnu.org/archive/html/bug-gettext/2025-09/msg00023.html>.

* gettext-tools/src/x-java.c (extract_parenthesized): When a semicolon is seen
inside braces, start a new argparser instead of returning.
* gettext-tools/tests/xgettext-java-1: Add test cases with inner classes.

3 months agotests: Increase debuggability.
Bruno Haible [Tue, 30 Sep 2025 21:59:22 +0000 (23:59 +0200)] 
tests: Increase debuggability.

* gettext-tools/tests/xgettext-python-9: Show the warnings in the log when
failing.

4 months agolibgettextpo: Add API for the workflow flags and the sticky flags.
Bruno Haible [Tue, 30 Sep 2025 13:35:06 +0000 (15:35 +0200)] 
libgettextpo: Add API for the workflow flags and the sticky flags.

Reported by Alexander Potashev <aspotashev@gmail.com>
at <https://savannah.gnu.org/bugs/?67470>.

* gettext-tools/src/message.h (format_flag, not_format_p): New declarations.
* gettext-tools/src/message.c (format_flag): New variable.
(not_format_p): New function.
* gettext-tools/src/write-po.c (make_format_description_string): Add comments.
(significant_format_p): Likewise.
* gettext-tools/libgettextpo/gettext-po.in.h (po_flag_iterator_t): New type.
(po_message_has_workflow_flag, po_message_set_workflow_flag,
po_message_workflow_flags_iterator): New declarations.
(po_message_has_sticky_flag, po_message_set_sticky_flag,
po_message_sticky_flags_iterator): New declarations.
(po_flag_iterator_free, po_flag_next): New declarations.
* gettext-tools/libgettextpo/gettext-po.c (struct po_flag_iterator): New type.
(po_message_has_workflow_flag, po_message_set_workflow_flag,
po_message_workflow_flags_iterator): New functions.
(po_message_get_format): Simplify by using not_format_p.
(po_message_has_sticky_flag, po_message_set_sticky_flag,
po_message_sticky_flags_iterator): New functions.
(po_flag_iterator_free, po_flag_next): New functions.
* gettext-tools/tests/gettextpo-1-prg.c (main): Add more test cases.
* gettext-tools/doc/gettext.texi (po_message_t API): Document the new functions.
(po_flag_iterator_t API): New subsection.
* NEWS: Mention the new functions.

4 months agolibgettextpo: New function po_message_get_format.
Bruno Haible [Sat, 27 Sep 2025 11:20:39 +0000 (13:20 +0200)] 
libgettextpo: New function po_message_get_format.

Reported by Alexander Potashev <aspotashev@gmail.com> in
<https://savannah.gnu.org/bugs/?67485>.

* gettext-tools/libgettextpo/gettext-po.in.h (po_message_get_format): New
declaration.
* gettext-tools/libgettextpo/gettext-po.c (po_message_get_format): New function.
* gettext-tools/tests/gettextpo-1-prg.c (main): Test the return value of
po_message_get_format. Add a test case of po_message_set_format with value -1.
* gettext-tools/doc/gettext.texi (po_message_t API): Document
po_message_get_format.
* NEWS: Mention the change.

4 months agoUpgrade to libtool 2.6.0.
Bruno Haible [Sun, 21 Sep 2025 22:41:29 +0000 (00:41 +0200)] 
Upgrade to libtool 2.6.0.

* m4/libtool.m4: Update from libtool-2.6.0.
* m4/ltoptions.m4: Likewise.
* m4/ltsugar.m4: Likewise.
* m4/ltversion.m4: Likewise.
* m4/lt~obsolete.m4: Likewise.
* build-aux/ltmain.sh: Likewise.

4 months agogettext.h: Avoid warning with gcc < 4.2.
Bruno Haible [Sun, 14 Sep 2025 16:37:36 +0000 (18:37 +0200)] 
gettext.h: Avoid warning with gcc < 4.2.

Reported by Orgad Shaneh <orgads@gmail.com> in
<https://lists.gnu.org/archive/html/bug-gnulib/2025-09/msg00183.html>.

* gnulib-local/lib/gettext.h (gettext, dgettext, dcgettext): Don't use attribute
__gnu_inline__ with gcc < 4.2.

4 months agolang-javascript: Avoid failure on macOS 13..15.
Bruno Haible [Sun, 14 Sep 2025 07:47:44 +0000 (09:47 +0200)] 
lang-javascript: Avoid failure on macOS 13..15.

* gettext-tools/tests/lang-javascript: On macOS, test only in the UTF-8 locale.

4 months agoUpdate after gnulib changed.
Bruno Haible [Sun, 14 Sep 2025 02:43:06 +0000 (04:43 +0200)] 
Update after gnulib changed.

* gettext-tools/libgrep/gnulib-lib/Makefile.am (AM_CPPFLAGS): Add -I option,
so that libintl.h gets found during the compilation of regex.c.

4 months agoPut archive.dir.tar under version control.
Bruno Haible [Mon, 8 Sep 2025 14:20:17 +0000 (16:20 +0200)] 
Put archive.dir.tar under version control.

This helps reducing CI failures when alpha.gnu.org is not responding.
It also simplifies the branch handling when a bug-fix release is made
on the maintenance branch of an older release.

* gettext-tools/misc/archive.dir.tar: New file.
* autopull.sh: Don't fetch it from alpha.gnu.org any more.

4 months agobuild: Make CI's git hostname rewriting rules apply.
Bruno Haible [Mon, 8 Sep 2025 06:43:32 +0000 (08:43 +0200)] 
build: Make CI's git hostname rewriting rules apply.

* .gitmodules: Canonicalize savannah host name.

4 months agoUpdate after gnulib changed.
Bruno Haible [Wed, 3 Sep 2025 22:40:21 +0000 (00:40 +0200)] 
Update after gnulib changed.

* libtextstyle/tests/Makefile.am (AM_CFLAGS): Initialize.
* gettext-tools/gnulib-tests/Makefile.am (AM_CFLAGS): Initialize.

4 months agoUpdate to the newest gnulib.
Bruno Haible [Wed, 3 Sep 2025 22:30:53 +0000 (00:30 +0200)] 
Update to the newest gnulib.

5 months agodoc: Update table of programming languages.
Bruno Haible [Sat, 23 Aug 2025 23:20:29 +0000 (01:20 +0200)] 
doc: Update table of programming languages.

* gettext-tools/doc/gettext.texi (List of Programming Languages): Update table
in comments.