http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55693
--- Comment #28 from Jack Howarth <howarth at nitro dot med.uc.edu> 2013-01-23 17:32:34 UTC --- Iain, The ELF style weak ref issue appears to be red herring. I find that both darwin10 with Xcode 4.2 (whose build of libitm has a config.h with HAVE_ELF_STYLE_WEAKREF undefined) and darwin11/12 with Xcode 4.5.2 (which results in config.h having HAVE_ELF_STYLE_WEAKREF defined) exhibit this regression. In both cases, removing the trailing linkage on -lcrttme.o eliminates the segfaults in the test case. Is there some way to modify darwin.h's SPEC handling so that the linkage on -lcrttme.o isn't passed for the g++ compiler? As I understand this, we are only linking in crttme.o to provide stub symbols when libstdc++ linkage isn't present to provide those symbols.