[cfe-dev] JIT fails linking to libc++ symbols...

Fons Rademakers Fons.Rademakers at cern.ch
Mon Nov 18 14:13:34 PST 2013


Hi,

   since moving to OSX 10.9 with libc++ our code which uses the JIT to 
compile C++ code on the fly fails to link with certain libc++ symbols that 
are reported by nm to be of type t (small t, i.e. defined but not exported, 
if I understand correctly). So, why does the JITted code want to link with 
these symbols? How to avoid that or how to make these symbols available in 
one way or another. Prior with libstdc++ (on OSX and Linux) no problems.

This are some of the symbols that fail linking:

ExecutionContext: use of undefined symbol 
'_ZNKSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE13get_allocatorEv'!
ExecutionContext: use of undefined symbol 
'_ZNSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEEC1ERKS4_'!
ExecutionContext: use of undefined symbol 
'_ZNKSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE4sizeEv'!
ExecutionContext: use of undefined symbol 
'_ZNKSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE4dataEv'!

That is:

std::__1::basic_string<char, std::__1::char_traits<char>, 
std::__1::allocator<char> >::basic_string(std::__1::allocator<char> const&)
std::__1::basic_string<char, std::__1::char_traits<char>, 
std::__1::allocator<char> >::size() const
std::__1::basic_string<char, std::__1::char_traits<char>, 
std::__1::allocator<char> >::data() const
std::__1::basic_string<char, std::__1::char_traits<char>, 
std::__1::allocator<char> >::get_allocator() const

Any help appreciated.

Cheers, Fons.

-- 
Org:    CERN, European Laboratory for Particle Physics.
Mail:   1211 Geneve 23, Switzerland
E-Mail: Fons.Rademakers at cern.ch              Phone: +41 22 7679248
WWW:    http://fons.rademakers.org           Fax:   +41 22 7669640

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4161 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20131118/c77a888d/attachment.bin>


More information about the cfe-dev mailing list