Wednesday, 15 August 2012

c++ - How to provide a given symbol using Clang and MacOSX -



c++ - How to provide a given symbol using Clang and MacOSX -

i have issue when launching application:

dyld: symbol not found: __zn5mongo2lte referenced from: /usr/local/lib/libcrails-mongodb.dylib expected in: flat namespace in /usr/local/lib/libcrails-mongodb.dylib

if search symbol __zn5mongo2lte using nm, find these matches:

$: nm -a /usr/local/lib/libcrails-mongodb.dylib | grep __zn5mongo2lte /usr/local/lib/libcrails-mongodb.dylib: u __zn5mongo2lte

if understanding correct, means symbol referenced, not solved.

now if @ other library linked project:

$: nm -a /usr/lib/libmongoclient.a | grep __zn5mongo2lte /usr/lib/libmongoclient.a:jsobj.o: 00000000000eca00 s __zn5mongo2lte

again, in understanding, means symbol exists in same library @ given address.

am wrong somewhere ? if not, why symbol "not found" ?

it seems accessible libmongoclient.dylib or libmongoclient.so required. the libcrails-mongodb.dylib linked dynamically libmongoclient, can not find symbol, though there's static libmongoclient.a. you may seek recompile libcrails-mongodb statically libmongoclient.a, or find dynamic library of libmongoclient, typically libmongoclient.dylib or libmongoclient.so.

c++ osx clang

No comments:

Post a Comment