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 sanitizer/55374] [asan] -static-libasan -static-libstdc++ doesn't work


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

--- Comment #19 from Kostya Serebryany <kcc at gcc dot gnu.org> 2013-01-29 09:18:49 UTC ---
> 
> As with the patch for this PR -lasan is linked before -lstdc++, the wrapper
> should kick in.  But the patch is still unreviewed.

How?
If we are linking both libraries statically, only one version of 
__cxa_throw will exist in the binary. 

The current code works like this (assuming dynamic linkage of stdc++): 
__cxa_throw in asan-rt calls __cxa_throw from libc++ (found using dlsym)

The same is true for various libc interceptors in asan,
that's why asan does not support fully static linkage.


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