This is the mail archive of the gcc-prs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: libstdc++/7097: _GLIBCPP_HAVE_MBSTATE_T breaks non-GLIB systems


Synopsis: _GLIBCPP_HAVE_MBSTATE_T breaks non-GLIB systems

Responsible-Changed-From-To: unassigned->bkoz
Responsible-Changed-By: bkoz
Responsible-Changed-When: Wed Jul  3 10:13:23 2002
Responsible-Changed-Why:
    Mine.
State-Changed-From-To: open->feedback
State-Changed-By: bkoz
State-Changed-When: Wed Jul  3 10:13:23 2002
State-Changed-Why:
    I'm surprised that you are using --enable-cheaders=c. Please provide more details on how you got this working for NetBSD. It is not a supported default configuration, although it does work for some targets (newlib crosses, perhaps QNX.)
    
    In any case, this patch below should do the trick. If it doesn't, you'll have to add more description to your bug report, including compiler error, sample code that goes wrong, and includes used...
    
    
    -benjamin
    2002-07-03  Benjamin Kosnik  <bkoz@redhat.com>
    
    	PR libstdc++/7097
    	* include/c/std_cwchar.h: Fix.
    
    Index: include/c/std_cwchar.h
    ===================================================================
    RCS file: /cvs/gcc/gcc/libstdc++-v3/include/c/std_cwchar.h,v
    retrieving revision 1.5
    diff -c -p -r1.5 std_cwchar.h
    *** include/c/std_cwchar.h	21 Jun 2002 20:20:41 -0000	1.5
    --- include/c/std_cwchar.h	3 Jul 2002 17:11:43 -0000
    ***************
    *** 47,64 ****
      // Need to do a bit of trickery here with mbstate_t as char_traits
      // assumes it is in wchar.h, regardless of wchar_t specializations.
      #ifndef _GLIBCPP_HAVE_MBSTATE_T
    ! extern "C" 
      {
    !   typedef struct 
        {
    !     int __fill[6];
    !   } mbstate_t;
      }
      #endif
    - 
    - namespace std 
    - {
    -   using ::mbstate_t;
    - }
      
      #endif 
    --- 47,62 ----
      // Need to do a bit of trickery here with mbstate_t as char_traits
      // assumes it is in wchar.h, regardless of wchar_t specializations.
      #ifndef _GLIBCPP_HAVE_MBSTATE_T
    ! namespace std
      {
    !   extern "C" 
        {
    !     typedef struct 
    !     {
    !       int __fill[6];
    !     } mbstate_t;
    !   }
      }
      #endif
      
      #endif 
    
    
    

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=7097


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]