1
0
mirror of https://git.savannah.gnu.org/git/gnulib.git synced 2025-09-11 11:50:52 +03:00
Files
gnulib/modules/setlocale
Bruno Haible 40b7c218d7 setlocale-messages: Rename to setlocale-fixes and add Android support.
* lib/setlocale-fixes.h: Renamed from lib/setlocale-messages.h.
(setlocale_fixed, setlocale_fixed_null): New declarations.
* lib/setlocale-fixes.c: Renamed from lib/setlocale-messages.h.
(lc_cat_name): New variable.
(cat_to_index, index_to_cat): New macro.
(lc_all_name): New variable.
(cat_names): New constant.
(fill_lc_all_name, extract_single_name, setlocale_fixed,
setlocale_fixed_null): New functions.
* m4/setlocale.m4 (gl_FUNC_SETLOCALE): Set NEED_SETLOCALE_IMPROVED to 1
on Android.
* lib/setlocale.c: Include setlocale-fixes.h instead of
setlocale-messages.h.
(setlocale_unixlike) [__ANDROID__]: Use setlocale_fixed instead of
setlocale_mtsafe.
(setlocale_improved): On Android, use setlocale_fixed_null instead of
setlocale.
* lib/getlocalename_l-unsafe.c: Include setlocale-fixes.h instead of
setlocale-messages.h.
(getlocalename_l_unsafe): On Android, use setlocale_fixed_null instead
of setlocale_null.
* modules/setlocale-fixes: Renamed from modules/setlocale-messages.
(Files): Update.
(configure.ac): Compile the .c file also on Android.
(Include): Include setlocale-fixes.h instead of setlocale-messages.h.
* modules/setlocale (Depends-on): Add setlocale-fixes. Remove
setlocale-messages.
* modules/getlocalename_l-unsafe (Depends-on): Likewise.
* doc/posix-functions/setlocale.texi: Mention the Android problem.
2025-03-22 13:04:26 +01:00

39 lines
698 B
Plaintext

Description:
setlocale() function: set the current locale.
Files:
lib/setlocale.c
m4/setlocale.m4
Depends-on:
locale-h
setlocale-fixes [test $NEED_SETLOCALE_IMPROVED = 1]
localename [test $NEED_SETLOCALE_IMPROVED = 1]
localename-environ [test $NEED_SETLOCALE_IMPROVED = 1]
setlocale-null [test $NEED_SETLOCALE_MTSAFE = 1]
configure.ac:
gl_FUNC_SETLOCALE
gl_CONDITIONAL([GL_COND_OBJ_SETLOCALE], [test $REPLACE_SETLOCALE = 1])
AM_COND_IF([GL_COND_OBJ_SETLOCALE], [
gl_PREREQ_SETLOCALE
])
gl_LOCALE_MODULE_INDICATOR([setlocale])
Makefile.am:
if GL_COND_OBJ_SETLOCALE
lib_SOURCES += setlocale.c
endif
Include:
<locale.h>
Link:
$(SETLOCALE_LIB)
License:
LGPLv2+
Maintainer:
all