This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] libstdc++/66030 fix codecvt exports for mingw32
- From: Martin Sebor <msebor at redhat dot com>
- To: Jonathan Wakely <jwakely at redhat dot com>, libstdc++ at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Mon, 08 Jun 2015 09:59:45 -0600
- Subject: Re: [patch] libstdc++/66030 fix codecvt exports for mingw32
- Authentication-results: sourceware.org; auth=none
- References: <20150608151218 dot GY12728 at redhat dot com>
On 06/08/2015 09:12 AM, Jonathan Wakely wrote:
The linker script assumes that std::mbstate_t has the name __mbstate_t
for linkage purposes, but that's not necessarily true. For mingw32
it's just a typedef for int, so the patterns don't match.
This adds a new mingw32-specific pattern for codecvt_byname's
constructors and destructors, and relaxes the patterns for
codecvt<charNN_t, char, mbstate_t> so they match __mbstate_t or int.
As a data point, in case other targets have a similar issue,
mbstate_t is a typedef for char* on AIX, and (based on my
old notes) typedef struct mbstate_t on HP-UX.
(It is a typedef struct __mbstate_t on Darwin and Solaris.)
Martin