[cfe-dev] Mac OS X (Darwin) and Symbol not found: __ZTIN10__cxxabiv117__class_type_infoE

Jeffrey Walton noloader at gmail.com
Wed Jul 31 02:03:56 PDT 2013


On Wed, Jul 31, 2013 at 4:56 AM, Konstantin Tokarev <annulen at yandex.ru> wrote:
>
> 31.07.2013, 12:54, "Jeffrey Walton" <noloader at gmail.com>:
>> Hi All,
>>
>> I'm testing another crypto library. This time its a C++ library.
>>
>> $ /usr/local/bin/clang++ -fsanitize=address -fsanitize=undefined -m64
>> -Ibuild/include -O3 -finline-functions  -D_REENTRANT -Wno-long-long -W
>> -Wall -fPIC -fvisibility=hidden -c src/algo_base/symkey.cpp -o
>> build/lib/algo_base_symkey.o
>> /usr/local/bin/clang++ -fsanitize=address -fsanitize=undefined -m64
>> -Ibuild/include -O3 -finline-functions  -D_REENTRANT -Wno-long-long -W
>> -Wall -fPIC -fvisibility=hidden -c src/algo_factory/algo_factory.cpp
>> -o build/lib/algo_factory.o
>> ...
>> $ export DYLD_FALLBACK_LIBRARY_PATH=/usr/local/lib/clang/3.3/lib/darwin/:./
>> $ ./check
>> dyld: Symbol not found: __ZTIN10__cxxabiv117__class_type_infoE
>>   Referenced from: .//libbotan-1.10.dylib.0
>>   Expected in: flat namespace
>>  in .//libbotan-1.10.dylib.0
>> Trace/BPT trap: 5
>>
>> I see the same problem was briefly discussed at
>> http://clang-developers.42468.n3.nabble.com/recent-change-broke-fcatch-undefined-behavior-td4027379i20.html.
>> But I don't see a workaround.
>>
>> Any ideas?
>
> Some library linked to libbotan is not linked to libcxxrt or equivalent library
Thanks Konstantin.

It looks like libcxxrt missing altogether:

    $ find /usr/local  -iname libcxxrt
    $

Let me build Clang from sources again and see if it shows up in the
build directory. Perhaps `make install` missed it.

Related: these sanitizers are awesome - they are finding obscure stuff
throughout all the projects being tested. Every engineering process
should include a Clang scan-build and sanitize run.

Jeff



More information about the cfe-dev mailing list