Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 445284 - cross-i686-mingw32/gcc-4.72 generated binaries crash at start in __dyn_tls_init (tlssup.c).
Summary: cross-i686-mingw32/gcc-4.72 generated binaries crash at start in __dyn_tls_in...
Status: RESOLVED DUPLICATE of bug 436482
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2012-11-30 01:53 UTC by abma
Modified: 2012-11-30 20:03 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
patch found on mingw mailing list (startup.patch,944 bytes, patch)
2012-11-30 01:53 UTC, abma
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description abma 2012-11-30 01:53:45 UTC
Created attachment 331006 [details, diff]
patch found on mingw mailing list

files generated by i686-mingw32 4.72 crash at start.

"The crash occurs in __dyn_tls_init (tlssup.c). I found it by setting a
breakpoint in __mingw_CRTStartup() and executing the startup code
(compiled with optimizations) line by line. "


see http://mingw.5.n7.nabble.com/Re-Mingw-users-MinGW-GCC-4-7-0-released-td26323.html#a34089555



i can't verify if the patch works, will report back if it does.
Comment 1 abma 2012-11-30 02:45:35 UTC
sadly it seems to not work...
Comment 2 abma 2012-11-30 02:49:43 UTC
backtrace of such a program:

Program received signal SIGSEGV, Segmentation fault.
0x011a3019 in _tls_start ()
(gdb) bt
#0  0x011a3019 in _tls_start ()
#1  0x00829b1e in __dyn_tls_init@12 ()
#2  0x00401026 in __mingw_CRTStartup ()
#3  0x75292811 in msvcrt!__setlc_active () from C:\Windows\syswow64\msvcrt.dll
#4  0x77ae9ef2 in ntdll!RtlpNtSetValueKey () from C:\Windows\system32\ntdll.dll
#5  0xfffde000 in ?? ()
#6  0x77ae9ec5 in ntdll!RtlpNtSetValueKey () from C:\Windows\system32\ntdll.dll
#7  0x004012a0 in mainCRTStartup ()
#8  0xfffde000 in ?? ()
#9  0x00000000 in ?? ()
Comment 3 abma 2012-11-30 02:52:34 UTC
note, the patch is for mingwrt-3.20-mingw32
Comment 4 abma 2012-11-30 03:22:02 UTC
upstream there seems to be already a fix for that:


http://sourceforge.net/projects/mingw/files/MinGW/Base/mingw-rt/mingwrt-3.20/

->

mingwrt-3.20-2-mingw32-src.tar.lzma

release notes:

http://mingw.5.n7.nabble.com/Updated-mingwrt-3-20-2-td22942.html


will try out & report back...
Comment 5 abma 2012-11-30 04:04:39 UTC
after recompiling gcc/binutils/... it seems to work with the updated mingwrt-3.20-2-mingw32-src.tar.lzma! (can't say what exactly needs to be recompiled...)
Comment 6 SpanKY gentoo-dev 2012-11-30 20:03:24 UTC

*** This bug has been marked as a duplicate of bug 436482 ***