]> Savannah Git Hosting - gnulib.git/commit
getlocalename_l-simple: New module.
authorBruno Haible <bruno@clisp.org>
Fri, 21 Feb 2025 10:25:51 +0000 (11:25 +0100)
committerBruno Haible <bruno@clisp.org>
Fri, 21 Feb 2025 10:25:51 +0000 (11:25 +0100)
commit706178a93b611cc47d305c92c9844e56503e6d5a
tree1ef6ae5c0321c2a16d4798f90072e296f4b64764
parent7f5440ed7453c5556d3f8302b4c5d017c6286fcb
getlocalename_l-simple: New module.

* lib/locale.in.h (newlocale, duplocale, freelocale): Now enabled by
module 'getlocalename_l-simple'.
(getlocalename_l): New declaration.
* lib/getlocalename_l.c: New file, based on lib/localename-unsafe.c,
with modifications for glibc systems, NetBSD, OpenBSD, Android.
* lib/localename-table.h (LCMIN): New macro.
* lib/struniq.h: Update a comment.
* lib/localename-unsafe.c: Don't define the
LOCALENAME_ENHANCE_LOCALE_FUNCS overrides here. Moved to
lib/getlocalename_l.c.
(gl_locale_name_thread_unsafe): Invoke getlocalename_l. Previous code
moved to lib/getlocalename_l.c.
* m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Improve support
for OpenBSD: Set gt_nameless_locales to yes and
gt_localename_enhances_locale_funcs to yes also when $gt_fake_locales is
yes.
* m4/getlocalename_l.m4: New file, based on m4/localename.m4.
* m4/localename.m4 (gl_LOCALENAME_UNSAFE, gl_LOCALENAME_UNSAFE_LIMITED):
Remove code that was moved to m4/getlocalename_l.m4.
* m4/locale_h.m4 (gl_LOCALE_H): Test whether getlocalename_l is
declared.
(gl_LOCALE_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETLOCALENAME_L.
(gl_LOCALE_H_DEFAULTS): Initialize HAVE_GETLOCALENAME_L.
* modules/locale-h (Makefile.am): Substitute GNULIB_GETLOCALENAME_L,
HAVE_GETLOCALENAME_L.
* modules/getlocalename_l-simple: New file.
* modules/localename-unsafe (Files): Remove lib/localename-table.h,
lib/localename-table.c, lib/struniq.h.
(Depends-on): Add getlocalename_l-simple. Remove bool, flexmember,
free-posix, langinfo-h, thread-optim.
(Makefile.am): Don't compile localename-table.c.
* modules/localename-unsafe-limited (Depends-on): Add
getlocalename_l-simple.
* modules/newlocale (Link): New section.
* modules/duplocale (Link): Link with $(GETLOCALENAME_L_LIB).
* modules/freelocale (Link): New section.
* modules/newlocale-tests (Makefile.am): Link the test program with
$(GETLOCALENAME_L_LIB).
* modules/duplocale-tests (Makefile.am): Likewise.
* modules/freelocale-tests (Makefile.am): Likewise.
* modules/is*_l-tests (Makefile.am): Likewise.
* modules/tolower_l-tests (Makefile.am): Likewise.
* modules/toupper_l-tests (Makefile.am): Likewise.
* modules/strcasecmp_l-tests (Makefile.am): Likewise.
* modules/strncasecmp_l-tests (Makefile.am): Likewise.
* modules/strerror_l-tests (Makefile.am): Likewise.
* doc/posix-functions/getlocalename_l.texi: Mention the new module.
38 files changed:
ChangeLog
doc/posix-functions/getlocalename_l.texi
lib/getlocalename_l.c [new file with mode: 0644]
lib/locale.in.h
lib/localename-table.h
lib/localename-unsafe.c
lib/struniq.h
m4/getlocalename_l.m4 [new file with mode: 0644]
m4/intl-thread-locale.m4
m4/locale_h.m4
m4/localename.m4
modules/duplocale
modules/duplocale-tests
modules/freelocale
modules/freelocale-tests
modules/getlocalename_l-simple [new file with mode: 0644]
modules/isalnum_l-tests
modules/isalpha_l-tests
modules/isblank_l-tests
modules/iscntrl_l-tests
modules/isdigit_l-tests
modules/isgraph_l-tests
modules/islower_l-tests
modules/isprint_l-tests
modules/ispunct_l-tests
modules/isspace_l-tests
modules/isupper_l-tests
modules/isxdigit_l-tests
modules/locale-h
modules/localename-unsafe
modules/localename-unsafe-limited
modules/newlocale
modules/newlocale-tests
modules/strcasecmp_l-tests
modules/strerror_l-tests
modules/strncasecmp_l-tests
modules/tolower_l-tests
modules/toupper_l-tests