[LLVMdev] "lazy symbol binding failed" with dynamically loaded pass in opt
Julian Oppermann
oppermann at esa.informatik.tu-darmstadt.de
Thu Apr 17 15:40:13 PDT 2014
Hello LLVM devs,
I’m running into the following problem when loading my custom passes in opt on OS X 10.9 (which work fine on Linux):
dyld: lazy symbol binding failed: Symbol not found: __ZN4llvm9CalculateINS_8FunctionEPNS_10BasicBlockEEEvRNS_17DominatorTreeBaseINS_11GraphTraitsIT0_E8NodeTypeEEERT_
Referenced from: /Users/julian/Src/llvm/Debug+Asserts/lib/Nymblle.dylib
Expected in: flat namespace
dyld: Symbol not found: __ZN4llvm9CalculateINS_8FunctionEPNS_10BasicBlockEEEvRNS_17DominatorTreeBaseINS_11GraphTraitsIT0_E8NodeTypeEEERT_
Referenced from: /Users/julian/Src/llvm/Debug+Asserts/lib/Nymblle.dylib
Expected in: flat namespace
I’m building the module „in-tree“; the Makefile contains the same settings as the Hello pass. nm tells me the resulting library (Nymblle.dylib) does not contain the missing symbols [U __ZN4llvm9Calculate...], whereas the opt executable (which is from the same LLVM build I use to build the module) does [<some address> t __ZN4llvm9Calculate…].
I think I’m missing some obvious difference in the way Linux and OS X handle dynamic libraries here, so any hints on why the symbols are found to be missing would be welcome. Thanks in advance!
Julian
More information about the llvm-dev
mailing list