diff options
Diffstat (limited to 'locale/lc-collate.c')
-rw-r--r-- | locale/lc-collate.c | 28 |
1 files changed, 26 insertions, 2 deletions
diff --git a/locale/lc-collate.c b/locale/lc-collate.c index 23643b29c8..aefdaa8b0e 100644 --- a/locale/lc-collate.c +++ b/locale/lc-collate.c @@ -20,12 +20,28 @@ Boston, MA 02111-1307, USA. */ #include "localeinfo.h" #include <endian.h> + +extern const u_int32_t _nl_C_LC_COLLATE_symbol_hash[]; +extern const char _nl_C_LC_COLLATE_symbol_strings[]; +extern const u_int32_t _nl_C_LC_COLLATE_symbol_classes[]; + + _NL_CURRENT_DEFINE (LC_COLLATE); -const u_int32_t *__collate_table; -const u_int32_t *__collate_extra; +const u_int32_t *__collate_table = NULL; +const u_int32_t *__collate_extra = NULL; + +const u_int32_t *__collate_element_hash = NULL; +const char *__collate_element_strings = NULL; +const wchar_t *__collate_element_values = NULL; +const u_int32_t *__collate_symbol_hash = _nl_C_LC_COLLATE_symbol_hash; +const char *__collate_symbol_strings = _nl_C_LC_COLLATE_symbol_strings; +const u_int32_t *__collate_symbol_classes = _nl_C_LC_COLLATE_symbol_classes; + +/* We are called after loading LC_CTYPE data to load it into + the variables used by the collation functions and regex. */ void _nl_postload_collate (void) { @@ -44,4 +60,12 @@ _nl_postload_collate (void) __collate_table = current (bo (TABLE)); __collate_extra = current (bo (EXTRA)); + + __collate_element_hash = current (bo (ELEM_HASH)); + __collate_element_strings = (const char *) current (ELEM_STR_POOL); + __collate_element_values = (const wchar_t *) current (bo (ELEM_VAL)); + + __collate_symbol_hash = current (bo (SYMB_HASH)); + __collate_symbol_strings = (const char *) current (SYMB_STR_POOL); + __collate_symbol_classes = current (bo (SYMB_CLASS)); } |