This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
gcc-3.2 with glibc-2.3 compile problem
- From: Quinn Harris <quinn at nmt dot edu>
- To: gcc at gcc dot gnu dot org
- Date: 04 Oct 2002 23:50:38 -0600
- Subject: gcc-3.2 with glibc-2.3 compile problem
I was compiling gcc-3.2 with glibc-2.3 installed and encountered a
compile error. I made the changes as shown in the following patch to
fix the problem. Is this patch sane? I have no knowledge of glibc, I
just figured it out by comparing the /usr/include/ctype.h file from
glibc-2.2.5 with glibc-2.3. What would be the proper way to fix this
problem?
--- /gcc-3.2/libstdc++-v3/config/os/gnu-linux/bits/ctype_noninline.h 2002-04-19 01:59:07.000000000 -0600
+++ /gcc-3.2-fix/libstdc++-v3/config/os/gnu-linux/bits/ctype_noninline.h 2002-10-04 23:03:47.000000000 -0600
@@ -42,7 +42,7 @@
const ctype_base::mask*
ctype<char>::classic_table() throw()
- { return __ctype_b; }
+ { return *__ctype_b_loc(); }
#if _GLIBCPP_C_LOCALE_GNU
ctype<char>::ctype(__c_locale __cloc, const mask* __table, bool __del,
@@ -58,14 +58,14 @@
ctype<char>::ctype(__c_locale, const mask* __table, bool __del,
size_t __refs)
: __ctype_abstract_base<char>(__refs), _M_del(__table != 0 && __del),
- _M_toupper(__ctype_toupper), _M_tolower(__ctype_tolower),
+ _M_toupper(*__ctype_toupper_loc()), _M_tolower(*__ctype_tolower_loc()),
_M_table(__table ? __table : classic_table())
{ _M_c_locale_ctype = _S_c_locale; }
#endif
ctype<char>::ctype(const mask* __table, bool __del, size_t __refs) :
__ctype_abstract_base<char>(__refs), _M_del(__table != 0 && __del),
- _M_toupper(__ctype_toupper), _M_tolower(__ctype_tolower),
+ _M_toupper(*__ctype_toupper_loc()), _M_tolower(*__ctype_tolower_loc()),
_M_table(__table ? __table : classic_table())
{ _M_c_locale_ctype = _S_c_locale; }