I get an error like:
undefined reference to `llvm::APInt::initSlowCase(unsigned int, unsigned long long, bool)
(this function is called by the inline APInt constructor)
The library seems to be found correctly; it doesn't give any other errors. Using nm I can see the mangled function initSlowCase exactly where I expect it to be. I'm out of ideas of that could be wrong.
I'm using kubuntu 12.04. Same error occurs with both clang++ and g++. LLVM libraries are 3.1
Any ideas on what might be the problem?
The output of `llvm-config --cppflags --ldflags --libs core support` and `llvm-config --cppflags --ldflags --libs core` is the same. I've also tried specifying -lLLVMSupport manually. Same result.
(This is resent so as to preserve the thread and newlines in the mailing list.)
--Eugene
Hi Eugene,
I do this, and I've tried a few variations of on it:
clang++ `llvm-config --cppflags --ldflags --libs core` -o clangtest clangtest.cpp
the missing routine is defined in the support library, not the core library, try
--libs core support