aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-03-12 10:25:36 +0000
committerUlrich Drepper <drepper@redhat.com>2002-03-12 10:25:36 +0000
commit418f17011fd3116c6c199021ad0aeb40ca98e7fa (patch)
tree0ab139f5e99ec0d94942677951871459c645627c
parentUpdate. (diff)
downloadglibc-418f17011fd3116c6c199021ad0aeb40ca98e7fa.tar.gz
glibc-418f17011fd3116c6c199021ad0aeb40ca98e7fa.tar.bz2
glibc-418f17011fd3116c6c199021ad0aeb40ca98e7fa.zip
Update.
2002-03-12 Ulrich Drepper <drepper@redhat.com> * posix/bug-regex5.c (main): Use nl_langinfo instead of _NL_CURRENT. * locale/localeinfo.h: Add attribute_hidden to _nl_current_LC_XXX, _nl_category_names, _nl_category_name_sizes, _nl_current, _nl_C_name, _nl_POSIX_name, _nl_C_codeset, and _nl_C_LC_XXX. * intl/dcigettext.c (_nl_default_default_domain): Define as hidden. (_nl_current_default_domain): Likewise (_nl_state_lock): Likewise. * intl/textdomain.c (_nl_default_default_domain): Declare as hidden. (_nl_current_default_domain): Likewise (_nl_state_lock): Likewise. * intl/bindtextdom.c (_nl_state_lock): Likewise. * stdlib/fpioconst.h (__tens): Add attribute_hidden. (_fpioconst_pow10): Likewise. * include/time.h (_tmbuf): Add attribute_hidden. * time/tzset.c (tzstring_list): Define as static. * include/time.h: Add attribute_hidden to __tzname_cur_max and __use_tzfile declaration. * wcsmbs/wcsmbsload.h: Add attribute_hidden to __wcsmbs_gconv_fcts and __wcsmbs_last_locale declaration.
-rw-r--r--ChangeLog29
-rw-r--r--include/time.h6
-rw-r--r--intl/bindtextdom.c4
-rw-r--r--intl/dcigettext.c9
-rw-r--r--intl/textdomain.c8
-rw-r--r--locale/localeinfo.h20
-rw-r--r--posix/bug-regex5.c10
-rw-r--r--stdlib/fpioconst.h7
-rw-r--r--time/tzset.c2
-rw-r--r--wcsmbs/wcsmbsload.h6
10 files changed, 66 insertions, 35 deletions
diff --git a/ChangeLog b/ChangeLog
index e336ff289a..c2f429f739 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,32 @@
+2002-03-12 Ulrich Drepper <drepper@redhat.com>
+
+ * posix/bug-regex5.c (main): Use nl_langinfo instead of _NL_CURRENT.
+
+ * locale/localeinfo.h: Add attribute_hidden to _nl_current_LC_XXX,
+ _nl_category_names, _nl_category_name_sizes, _nl_current,
+ _nl_C_name, _nl_POSIX_name, _nl_C_codeset, and _nl_C_LC_XXX.
+
+ * intl/dcigettext.c (_nl_default_default_domain): Define as hidden.
+ (_nl_current_default_domain): Likewise
+ (_nl_state_lock): Likewise.
+ * intl/textdomain.c (_nl_default_default_domain): Declare as hidden.
+ (_nl_current_default_domain): Likewise
+ (_nl_state_lock): Likewise.
+ * intl/bindtextdom.c (_nl_state_lock): Likewise.
+
+ * stdlib/fpioconst.h (__tens): Add attribute_hidden.
+ (_fpioconst_pow10): Likewise.
+
+ * include/time.h (_tmbuf): Add attribute_hidden.
+
+ * time/tzset.c (tzstring_list): Define as static.
+
+ * include/time.h: Add attribute_hidden to __tzname_cur_max and
+ __use_tzfile declaration.
+
+ * wcsmbs/wcsmbsload.h: Add attribute_hidden to __wcsmbs_gconv_fcts
+ and __wcsmbs_last_locale declaration.
+
2002-02-25 Paul Eggert <eggert@twinsun.com>
* timezone/Makefile (tzbases): Move systemv from here...
diff --git a/include/time.h b/include/time.h
index f81760e99c..48017c1c4e 100644
--- a/include/time.h
+++ b/include/time.h
@@ -11,16 +11,16 @@ struct tm;
extern const unsigned short int __mon_yday[2][13];
/* Defined in localtime.c. */
-extern struct tm _tmbuf;
+extern struct tm _tmbuf attribute_hidden;
/* Defined in tzset.c. */
extern char *__tzstring (const char *string);
/* Defined in tzset.c. */
-extern size_t __tzname_cur_max;
+extern size_t __tzname_cur_max attribute_hidden;
-extern int __use_tzfile;
+extern int __use_tzfile attribute_hidden;
extern void __tzfile_read (const char *file, size_t extra,
char **extrap);
diff --git a/intl/bindtextdom.c b/intl/bindtextdom.c
index d051ac9f3a..1e6efe2ad0 100644
--- a/intl/bindtextdom.c
+++ b/intl/bindtextdom.c
@@ -1,5 +1,5 @@
/* Implementation of the bindtextdomain(3) function
- Copyright (C) 1995-1998, 2000, 2001 Free Software Foundation, Inc.
+ Copyright (C) 1995-1998, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -64,7 +64,7 @@ extern const char _nl_default_dirname[];
extern struct binding *_nl_domain_bindings;
/* Lock variable to protect the global data in the gettext implementation. */
-__libc_rwlock_define (extern, _nl_state_lock)
+__libc_rwlock_define (extern, _nl_state_lock attribute_hidden)
/* Names for the libintl functions are a problem. They must not clash
diff --git a/intl/dcigettext.c b/intl/dcigettext.c
index f274de81d8..762ec43afd 100644
--- a/intl/dcigettext.c
+++ b/intl/dcigettext.c
@@ -1,5 +1,5 @@
/* Implementation of the internal dcigettext function.
- Copyright (C) 1995-1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright (C) 1995-1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -238,10 +238,11 @@ transcmp (p1, p2)
/* Name of the default domain used for gettext(3) prior any call to
textdomain(3). The default value for this is "messages". */
-const char _nl_default_default_domain[] = "messages";
+const char _nl_default_default_domain[] attribute_hidden = "messages";
/* Value used as the default domain for gettext(3). */
-const char *_nl_current_default_domain = _nl_default_default_domain;
+const char *_nl_current_default_domain attribute_hidden
+ = _nl_default_default_domain;
/* Contains the default location of the message catalogs. */
const char _nl_default_dirname[] = LOCALEDIR;
@@ -323,7 +324,7 @@ typedef unsigned char transmem_block_t;
/* Lock variable to protect the global data in the gettext implementation. */
#ifdef _LIBC
-__libc_rwlock_define_initialized (, _nl_state_lock)
+__libc_rwlock_define_initialized (, _nl_state_lock attribute_hidden)
#endif
/* Checking whether the binaries runs SUID must be done and glibc provides
diff --git a/intl/textdomain.c b/intl/textdomain.c
index b5e6af597f..ecaafb63fa 100644
--- a/intl/textdomain.c
+++ b/intl/textdomain.c
@@ -1,5 +1,5 @@
/* Implementation of the textdomain(3) function.
- Copyright (C) 1995-1998, 2000, 2001 Free Software Foundation, Inc.
+ Copyright (C) 1995-1998, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -52,10 +52,10 @@
/* @@ end of prolog @@ */
/* Name of the default text domain. */
-extern const char _nl_default_default_domain[];
+extern const char _nl_default_default_domain[] attribute_hidden;
/* Default text domain in which entries for gettext(3) are to be found. */
-extern const char *_nl_current_default_domain;
+extern const char *_nl_current_default_domain attribute_hidden;
/* Names for the libintl functions are a problem. They must not clash
@@ -72,7 +72,7 @@ extern const char *_nl_current_default_domain;
#endif
/* Lock variable to protect the global data in the gettext implementation. */
-__libc_rwlock_define (extern, _nl_state_lock)
+__libc_rwlock_define (extern, _nl_state_lock attribute_hidden)
/* Set the current default message catalog to DOMAINNAME.
If DOMAINNAME is null, return the current default.
diff --git a/locale/localeinfo.h b/locale/localeinfo.h
index 6cd7f0dca2..2074569811 100644
--- a/locale/localeinfo.h
+++ b/locale/localeinfo.h
@@ -1,5 +1,5 @@
/* Declarations for internal libc locale interfaces
- Copyright (C) 1995, 96, 97, 98, 99,2000,2001 Free Software Foundation, Inc.
+ Copyright (C) 1995-2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -140,21 +140,23 @@ enum
/* For each category declare the variable for the current locale data. */
+/* XXX _nl_current_LC_CTYPE and _nl_current_LC_COLLATE were exported
+ but where are they used? */
#define DEFINE_CATEGORY(category, category_name, items, a) \
-extern struct locale_data *_nl_current_##category;
+extern struct locale_data *_nl_current_##category attribute_hidden;
#include "categories.def"
#undef DEFINE_CATEGORY
-extern const char *const _nl_category_names[__LC_LAST];
-extern const size_t _nl_category_name_sizes[__LC_LAST];
-extern struct locale_data * *const _nl_current[__LC_LAST];
+extern const char *const _nl_category_names[__LC_LAST] attribute_hidden;
+extern const size_t _nl_category_name_sizes[__LC_LAST] attribute_hidden;
+extern struct locale_data * *const _nl_current[__LC_LAST] attribute_hidden;
/* Name of the standard locales. */
-extern const char _nl_C_name[];
-extern const char _nl_POSIX_name[];
+extern const char _nl_C_name[] attribute_hidden;
+extern const char _nl_POSIX_name[] attribute_hidden;
/* The standard codeset. */
-extern const char _nl_C_codeset[];
+extern const char _nl_C_codeset[] attribute_hidden;
/* Extract the current CATEGORY locale's string for ITEM. */
#define _NL_CURRENT(category, item) \
@@ -170,7 +172,7 @@ extern const char _nl_C_codeset[];
/* This is used in lc-CATEGORY.c to define _nl_current_CATEGORY. */
#define _NL_CURRENT_DEFINE(category) \
- extern struct locale_data _nl_C_##category; \
+ extern struct locale_data _nl_C_##category attribute_hidden; \
struct locale_data *_nl_current_##category = &_nl_C_##category
/* Load the locale data for CATEGORY from the file specified by *NAME.
diff --git a/posix/bug-regex5.c b/posix/bug-regex5.c
index 12bbcffe21..58f487aa84 100644
--- a/posix/bug-regex5.c
+++ b/posix/bug-regex5.c
@@ -20,18 +20,16 @@ main (void)
}
printf ("current locale : %s\n", ca);
- nrules = _NL_CURRENT_WORD (LC_COLLATE, _NL_COLLATE_NRULES);
+ nrules = (size_t) nl_langinfo (_NL_COLLATE_NRULES);
if (nrules == 0)
{
printf("No rule\n");
return 1;
}
- table_size = _NL_CURRENT_WORD (LC_COLLATE, _NL_COLLATE_SYMB_HASH_SIZEMB);
- symb_table = (const int32_t *)
- _NL_CURRENT (LC_COLLATE, _NL_COLLATE_SYMB_TABLEMB);
- extra = (const unsigned char *)
- _NL_CURRENT (LC_COLLATE, _NL_COLLATE_SYMB_EXTRAMB);
+ table_size = (size_t) nl_langinfo (_NL_COLLATE_SYMB_HASH_SIZEMB);
+ symb_table = (const int32_t *) nl_langinfo (_NL_COLLATE_SYMB_TABLEMB);
+ extra = (const unsigned char *) nl_langinfo (_NL_COLLATE_SYMB_EXTRAMB);
found = 0;
for (i = 0; i < table_size; ++i)
diff --git a/stdlib/fpioconst.h b/stdlib/fpioconst.h
index 08bf20c7a1..da7426ce8d 100644
--- a/stdlib/fpioconst.h
+++ b/stdlib/fpioconst.h
@@ -1,5 +1,5 @@
/* Header file for constants used in floating point <-> decimal conversions.
- Copyright (C) 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
+ Copyright (C) 1995,1996,1997,1998,1999,2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -43,7 +43,7 @@
/* The array with the number representation. */
-extern const mp_limb_t __tens[];
+extern const mp_limb_t __tens[] attribute_hidden;
/* Table of powers of ten. This is used by __printf_fp and by
strtof/strtod/strtold. */
@@ -54,7 +54,8 @@ struct mp_power
int p_expo; /* Exponent of the number 10^(2^i). */
int m_expo; /* Exponent of the number 10^-(2^i-1). */
};
-extern const struct mp_power _fpioconst_pow10[LDBL_MAX_10_EXP_LOG + 1];
+extern const struct mp_power _fpioconst_pow10[LDBL_MAX_10_EXP_LOG + 1]
+ attribute_hidden;
/* The constants in the array `_fpioconst_pow10' have an offset. */
#if BITS_PER_MP_LIMB == 32
diff --git a/time/tzset.c b/time/tzset.c
index cdf01bf8d6..c9a9783b2d 100644
--- a/time/tzset.c
+++ b/time/tzset.c
@@ -82,7 +82,7 @@ struct tzstring_l
char data[0];
};
-struct tzstring_l *tzstring_list;
+static struct tzstring_l *tzstring_list;
/* Allocate a permanent home for S. It will never be moved or deallocated,
but may share space with other strings.
diff --git a/wcsmbs/wcsmbsload.h b/wcsmbs/wcsmbsload.h
index 6aa6139f77..dee2c815c2 100644
--- a/wcsmbs/wcsmbsload.h
+++ b/wcsmbs/wcsmbsload.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
@@ -32,11 +32,11 @@ struct gconv_fcts
};
/* Set of currently active conversion functions. */
-extern struct gconv_fcts __wcsmbs_gconv_fcts;
+extern struct gconv_fcts __wcsmbs_gconv_fcts attribute_hidden;
/* Last loaded locale for LC_CTYPE. */
-extern const struct locale_data *__wcsmbs_last_locale;
+extern const struct locale_data *__wcsmbs_last_locale attribute_hidden;
/* Load conversion functions for the currently selected locale. */