From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30550 invoked by alias); 5 Oct 2002 05:45:23 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 30542 invoked from network); 5 Oct 2002 05:45:19 -0000 Received: from unknown (HELO mailhost.nmt.edu) (129.138.4.52) by sources.redhat.com with SMTP; 5 Oct 2002 05:45:19 -0000 Received: from a117b.rcn.NMT.EDU (a117b.rcn.nmt.edu [129.138.36.78]) by mailhost.nmt.edu (8.12.6/8.12.6) with ESMTP id g955jHiw019065 for ; Fri, 4 Oct 2002 23:45:17 -0600 Subject: gcc-3.2 with glibc-2.3 compile problem From: Quinn Harris To: gcc@gcc.gnu.org Content-Type: text/plain Content-Transfer-Encoding: 7bit Date: Sat, 05 Oct 2002 00:40:00 -0000 Message-Id: <1033797038.27135.79.camel@quinn.rcn.nmt.edu> Mime-Version: 1.0 X-SW-Source: 2002-10/txt/msg00336.txt.bz2 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::classic_table() throw() - { return __ctype_b; } + { return *__ctype_b_loc(); } #if _GLIBCPP_C_LOCALE_GNU ctype::ctype(__c_locale __cloc, const mask* __table, bool __del, @@ -58,14 +58,14 @@ ctype::ctype(__c_locale, const mask* __table, bool __del, size_t __refs) : __ctype_abstract_base(__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::ctype(const mask* __table, bool __del, size_t __refs) : __ctype_abstract_base(__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; }