This is the mail archive of the gcc-bugs@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]

[Bug libstdc++/52300] New: Gthreads functions linking error at dynamic linking with libstdc++ when using MinGW.


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52300

             Bug #: 52300
           Summary: Gthreads functions linking error at dynamic linking
                    with libstdc++ when using MinGW.
    Classification: Unclassified
           Product: gcc
           Version: 4.6.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: i.nixman@gmail.com


When using std::threads for example, the program is compiled correctly. But
when running I get segfolts. If the program is linked with -static - all the
problem disappears.

If in the file gthr-posix.h I change this line:
> # If SUPPORTS_WEAK && GTHREAD_USE_WEAK
on this:
> # If SUPPORTS_WEAK && GTHREAD_USE_WEAK && !defined(__MINGW32__)
- the problem is solved.

Is there any way to fix this?

niXman.


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