mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-19 11:30:06 +00:00
0200214b28
* limits.h: Change MB_LEN_MAX to 6. A 31-bit ISO 10646 character in UTF-8 encoding has that many bytes. * locale/langinfo.h: New element _NL_CTYPE_MB_CUR_MAX. * locale/categories.def: Add description of field _NL_CTYPE_MB_CUR_MAX. * locale/Makefile (routines): Add mb_cur_max. * locale/mb_cur_max.c: New file. This function gets called when the macro MB_CUR_MAX is used. * locale/C-ctype.c: Initialize new mb_cur_max field. * locale/localeinfo.h: Change magic value because of incompatible change. * locale/programs/ld-ctype.c: Determine value of mb_cur_max according to current character set and write it out with the rest. * stdlib/stdlib.h (MB_CUR_MAX): Not constant anymore. Get value according to currently used locale for catefory LC_CTYPE by calling the function __ctype_get_mb_cur_max. Tue May 28 03:27:46 1996 Ulrich Drepper <drepper@cygnus.com> * FAQ: Fix some typos. Tell that for Linux the kernel header files are necessary. * PROJECTS: New file. List of open jobs for glibc. * Makefile (distribute): Add PROJECTS. * crypt/GNUmakefile (headers): New variable. Mention crypt.h. * crypt/crypt.h: Header for crypt functions. * elf/elf.h: Add some new constants from recent Cygnus ELF header files. * login/getutid_r.c: Test for correct type. Don't depend on ut_type and ut_id unless _HAVE_UT_TYPE and _HAVE_UT_ID resp. are defined. Make really compliant with specification. * login/getutline_r.c, login/pututline_r.c: Don't depend on ut_type and ut_id unless _HAVE_UT_TYPE and _HAVE_UT_ID resp. are defined. Make really compliant with specification. * login/setutent_r.c: Don't depend on ut_type and ut_id unless _HAVE_UT_TYPE and _HAVE_UT_ID resp. are defined. * login/login.c, login/logout.c, login/logwtmp.c: Complete rewrite. Now based on getut*/setut* functions. * stdlib/strtol.c: Undo changes of Wed May 22 01:48:54 1996. This prevented using this file in other GNU packages. * sysdeps/gnu/utmpbits.h: Define _HAVE_UT_TYPE, _HAVE_UT_ID, and _HAVE_UT_TV because struct utmp has these members. * sysdeps/libm-i387/e_exp.S: Correct exp(+-Inf) case. * utmp.h: New file. Wrapper around login/utmp.h. * elf/dl-error.c (struct catch): New type. (catch): New static variable, struct catch *. (catch_env, signalled_errstring, signalled_objname): Variables removed. (_dl_signal_error): If CATCH is non-null, set its errstring and objname members and jump to CATCH->env. If it is null, call _dl_sysdep_fatal with a standard message. * elf/rtld.c (dl_main): Explode `doit' function into dl_main's body. No longer use _dl_catch_error.
144 lines
6.4 KiB
C
144 lines
6.4 KiB
C
/* Definition of all available locale categories and their items. -*- C -*-
|
|
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
|
|
|
|
The GNU C Library is free software; you can redistribute it and/or
|
|
modify it under the terms of the GNU Library General Public License as
|
|
published by the Free Software Foundation; either version 2 of the
|
|
License, or (at your option) any later version.
|
|
|
|
The GNU C Library is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Library General Public License for more details.
|
|
|
|
You should have received a copy of the GNU Library General Public
|
|
License along with the GNU C Library; see the file COPYING.LIB. If
|
|
not, write to the Free Software Foundation, Inc., 675 Mass Ave,
|
|
Cambridge, MA 02139, USA. */
|
|
|
|
/* These definitions are used by the locale-related files in the C library
|
|
and the programs `localedef' and `locale'.
|
|
|
|
The general format of the descriptions is like this:
|
|
|
|
DEFINE_CATEGORY (ID, name, ( items ), setlocale-postload,
|
|
locale-input, locale-check, locale-output)
|
|
|
|
where items itself is an array of entries in the form
|
|
|
|
{ ID, name, standard, value-type, min, max }
|
|
|
|
The usage of the load, check, output functions depends on the individual
|
|
program code which loads this file.
|
|
|
|
The various value types for the items are `string', `stringarray', `byte'
|
|
`bytearray', and `word'. These cover all possible values in the current
|
|
locale definitions. `min' and `max' can be individually used again. */
|
|
|
|
#ifndef NO_POSTLOAD
|
|
#define NO_POSTLOAD NULL
|
|
#endif
|
|
|
|
DEFINE_CATEGORY
|
|
(
|
|
LC_COLLATE, "LC_COLLATE",
|
|
(
|
|
DEFINE_ELEMENT (_NL_COLLATE_NRULES, "collate-nrules", std, word)
|
|
DEFINE_ELEMENT (_NL_COLLATE_RULES, "collate-rules", std, string)
|
|
DEFINE_ELEMENT (_NL_COLLATE_HASH_SIZE, "collate-hash-size", std, word)
|
|
DEFINE_ELEMENT (_NL_COLLATE_HASH_LAYERS, "collate-hash-layers", std, word)
|
|
DEFINE_ELEMENT (_NL_COLLATE_TABLE_EB, "collate-table-eb", std, string)
|
|
DEFINE_ELEMENT (_NL_COLLATE_TABLE_EL, "collate-table-el", std, string)
|
|
DEFINE_ELEMENT (_NL_COLLATE_UNDEFINED, "collate-undefined", std, word)
|
|
DEFINE_ELEMENT (_NL_COLLATE_EXTRA_EB, "collate-extra-eb", std, string)
|
|
DEFINE_ELEMENT (_NL_COLLATE_EXTRA_EL, "collate-extra-el", std, string)
|
|
), _nl_postload_collate, collate_input, NULL, NULL)
|
|
|
|
|
|
/* The actual definition of ctype is meaningless here. It is hard coded in
|
|
the code because it has to be handled very specially. Only the names of
|
|
the functions and the value types are important. */
|
|
DEFINE_CATEGORY
|
|
(
|
|
LC_CTYPE, "LC_CTYPE",
|
|
(
|
|
DEFINE_ELEMENT (_NL_CTYPE_CLASS, "ctype-class", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_TOUPPER_EB, "ctype-toupper-eb", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_TOLOWER_EB, "ctype-tolower-eb", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_TOUPPER_EL, "ctype-toupper-el", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_TOLOWER_EL, "ctype-tolower-el", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_NAMES_EB, "ctype-names-eb", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_NAMES_EL, "ctype-names-eb", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_HASH_SIZE, "ctype-hash-size", std, word)
|
|
DEFINE_ELEMENT (_NL_CTYPE_HASH_LAYERS, "ctype-hash-layers", std, word)
|
|
DEFINE_ELEMENT (_NL_CTYPE_CLASS_NAMES, "ctype-class-names", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_MAP_NAMES, "ctype-map-names", std, string)
|
|
DEFINE_ELEMENT (_NL_CTYPE_WIDTH, "ctype-width", std, bytearray)
|
|
DEFINE_ELEMENT (_NL_CTYPE_MB_CUR_MAX, "ctype-mb-cur-max", std, word)
|
|
), _nl_postload_ctype, ctype_input, ctype_check, ctype_output)
|
|
|
|
|
|
DEFINE_CATEGORY
|
|
(
|
|
LC_MONETARY, "LC_MONETARY",
|
|
(
|
|
DEFINE_ELEMENT (INT_CURR_SYMBOL, "int_curr_symbol", std, string)
|
|
DEFINE_ELEMENT (CURRENCY_SYMBOL, "currency_symbol", std, string)
|
|
DEFINE_ELEMENT (MON_DECIMAL_POINT, "mon_decimal_point", std, string)
|
|
DEFINE_ELEMENT (MON_THOUSANDS_SEP, "mon_thousands_sep", std, string)
|
|
DEFINE_ELEMENT (MON_GROUPING, "mon_grouping", std, bytearray)
|
|
DEFINE_ELEMENT (POSITIVE_SIGN, "positive_sign", std, string)
|
|
DEFINE_ELEMENT (NEGATIVE_SIGN, "negative_sign", std, string)
|
|
DEFINE_ELEMENT (INT_FRAC_DIGITS, "int_frac_digits", std, byte)
|
|
DEFINE_ELEMENT (FRAC_DIGITS, "frac_digits", std, byte)
|
|
DEFINE_ELEMENT (P_CS_PRECEDES, "p_cs_precedes", std, byte, 0, 1)
|
|
DEFINE_ELEMENT (P_SEP_BY_SPACE, "p_sep_by_space", std, byte, 0, 2)
|
|
DEFINE_ELEMENT (N_CS_PRECEDES, "n_cs_precedes", std, byte, 0, 1)
|
|
DEFINE_ELEMENT (N_SEP_BY_SPACE, "n_sep_by_space", std, byte, 0, 2)
|
|
DEFINE_ELEMENT (P_SIGN_POSN, "p_sign_posn", std, byte, 0, 4)
|
|
DEFINE_ELEMENT (N_SIGN_POSN, "n_sign_posn", std, byte, 0, 4)
|
|
), NO_POSTLOAD, NULL, monetary_check, NULL)
|
|
|
|
|
|
DEFINE_CATEGORY
|
|
(
|
|
LC_NUMERIC, "LC_NUMERIC",
|
|
(
|
|
DEFINE_ELEMENT (DECIMAL_POINT, "decimal_point", std, string)
|
|
DEFINE_ELEMENT (THOUSANDS_SEP, "thousands_sep", std, string)
|
|
DEFINE_ELEMENT (GROUPING, "grouping", std, bytearray)
|
|
), NO_POSTLOAD, NULL, numeric_check, NULL)
|
|
|
|
|
|
DEFINE_CATEGORY
|
|
(
|
|
LC_TIME, "LC_TIME",
|
|
(
|
|
DEFINE_ELEMENT (ABDAY_1, "abday", std, stringarray, 7, 7)
|
|
DEFINE_ELEMENT (DAY_1, "day", std, stringarray, 7, 7)
|
|
DEFINE_ELEMENT (ABMON_1, "abmon", std, stringarray, 12, 12)
|
|
DEFINE_ELEMENT (MON_1, "mon", std, stringarray, 12, 12)
|
|
DEFINE_ELEMENT (AM_STR, "am_pm", std, stringarray, 2, 2)
|
|
DEFINE_ELEMENT (D_T_FMT, "d_t_fmt", std, string)
|
|
DEFINE_ELEMENT (D_FMT, "d_fmt", std, string)
|
|
DEFINE_ELEMENT (T_FMT, "t_fmt", std, string)
|
|
DEFINE_ELEMENT (T_FMT_AMPM, "t_fmt_ampm", std, string)
|
|
DEFINE_ELEMENT (ERA, "era", opt, string)
|
|
DEFINE_ELEMENT (ERA_YEAR, "era_year", opt, string)
|
|
DEFINE_ELEMENT (ERA_D_FMT, "era_d_fmt", opt, string)
|
|
DEFINE_ELEMENT (ALT_DIGITS, "alt_digits", opt, stringarray, 0, 100)
|
|
DEFINE_ELEMENT (ERA_D_T_FMT, "era_d_t_fmt", opt, string)
|
|
DEFINE_ELEMENT (ERA_T_FMT, "era_t_fmt", opt, string)
|
|
), NO_POSTLOAD, NULL, NULL, NULL)
|
|
|
|
|
|
DEFINE_CATEGORY
|
|
(
|
|
LC_MESSAGES, "LC_MESSAGES",
|
|
(
|
|
DEFINE_ELEMENT (YESEXPR, "yesexpr", std, string)
|
|
DEFINE_ELEMENT (NOEXPR, "noexpr", std, string)
|
|
DEFINE_ELEMENT (YESSTR, "yesstr", opt, string)
|
|
DEFINE_ELEMENT (NOSTR, "nostr", opt, string)
|
|
), NO_POSTLOAD, NULL, messages_check, NULL)
|