I've noticed the message:
/usr/bin/x86_64-pc-linux-gnu-ld: warning: libLLVM-3.2svn.so, needed by /usr/lib64/llvm/libclang.so, not found (try using -rpath or -rpath-link)
After adding this to LDFLAGS,problem fixed.
LDLIBS := $(shell llvm-config --ldflags) $(shell llvm-config --libs all) -lstdc++ -lclang -rpath $(shell llvm-config --libdir)
ld failed when doing make in gentoo amd64
└┌(%:~/.emacs.d/emacs-clang-complete-async)┌- make
"clang" -I/usr/include -DNDEBUG -D_GNU_SOURCE -DSTDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -DSTDC_LIMIT_MACROS -fPIC -Wall -Wextra -pedantic -O3 -I./src -c -o src/obj/completion_serv.o ./src/completion_serv.c "clang" -I/usr/include -DNDEBUG -D_GNU_SOURCE -DSTDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -DSTDC_LIMIT_MACROS -fPIC -Wall -Wextra -pedantic -O3 -I./src -c -o src/obj/parse_results.o ./src/parse_results.c "clang" -I/usr/include -DNDEBUG -D_GNU_SOURCE -DSTDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -DSTDC_LIMIT_MACROS -fPIC -Wall -Wextra -pedantic -O3 -I./src -c -o src/obj/msg_dispatcher.o ./src/msg_dispatcher.c "clang" -I/usr/include -DNDEBUG -D_GNU_SOURCE -DSTDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -DSTDC_LIMIT_MACROS -fPIC -Wall -Wextra -pedantic -O3 -I./src -c -o src/obj/main.o ./src/main.c "clang" -I/usr/include -DNDEBUG -D_GNU_SOURCE -DSTDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -DSTDC_LIMIT_MACROS -fPIC -Wall -Wextra -pedantic -O3 -I./src -c -o src/obj/msg_handlers.o ./src/msg_handlers.c "clang" -I/usr/include -DNDEBUG -D_GNU_SOURCE -DSTDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -DSTDC_LIMIT_MACROS -fPIC -Wall -Wextra -pedantic -O3 -I./src src/obj/completion_serv.o src/obj/parse_results.o src/obj/msg_dispatcher.o src/obj/main.o src/obj/msg_handlers.o -L/usr/lib64/llvm -lpthread -lffi -ldl -lm -lLLVMCppBackendCodeGen -lLLVMCppBackendInfo -lLLVMAsmParser -lLLVMTableGen -lLLVMDebugInfo -lLLVMX86AsmParser -lLLVMX86CodeGen -lLLVMSelectionDAG -lLLVMAsmPrinter -lLLVMX86Disassembler -lLLVMX86Desc -lLLVMX86Info -lLLVMX86AsmPrinter -lLLVMX86Utils -lLLVMJIT -lLLVMMCDisassembler -lLLVMMCParser -lLLVMInstrumentation -lLLVMInterpreter -lLLVMCodeGen -lLLVMipo -lLLVMVectorize -lLLVMScalarOpts -lLLVMInstCombine -lLLVMLinker -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMArchive -lLLVMBitReader -lLLVMBitWriter -lLLVMMCJIT -lLLVMRuntimeDyld -lLLVMExecutionEngine -lLLVMTarget -lLLVMMC -lLLVMObject -lLLVMCore -lLLVMSupport -lstdc++ -lclang -o clang-complete /usr/bin/x86_64-pc-linux-gnu-ld: warning: libLLVM-3.2svn.so, needed by /usr/lib64/llvm/libclang.so, not found (try using -rpath or -rpath-link) /usr/lib64/llvm/libclang.so: undefined reference to&, unsigned int, unsigned int) const'
/usr/lib64/llvm/libclang.so: undefined reference to&) const'
/usr/lib64/llvm/libclang.so: undefined reference to&) const'
/usr/lib64/llvm/libclang.so: undefined reference to&, llvm::sys::path::const_iterator, llvm::sys::path::const_iterator)'
/usr/lib64/llvm/libclang.so: undefined reference to &, long, bool)'
/usr/lib64/llvm/libclang.so: undefined reference to&, unsigned int, bool, bool) const'
/usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::fs::make_absolute(llvm::SmallVectorImpl<char>&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::EnableStatistics()' /usr/lib64/llvm/libclang.so: undefined reference tovtable for llvm::format_object_base' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_ostream::operator<<(llvm::format_object_base const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallPtrSetImpl::FindBucketFor(void const*) const' /usr/lib64/llvm/libclang.so: undefined reference to
vtable for llvm::PrettyStackTraceString' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_ostream::operator<<(unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::fs::is_directory(llvm::sys::fs::file_status)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetNodeID::AddPointer(void const*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::SmallPtrSetImpl::shrink_and_clear()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::APInt(unsigned int, unsigned int, unsigned long const*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::root_path(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::rename(llvm::Twine const&, llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::Profile(llvm::FoldingSetNodeID&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::MutexImpl::acquire()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::EqualSlowCase(unsigned long) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::getAsInteger(unsigned int, llvm::APInt&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::DOT::EscapeString(std::string const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::find_first_not_of(llvm::StringRef, unsigned long) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::add(llvm::APFloat const&, llvm::APFloat::roundingMode)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::yaml::Stream::begin()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::rotr(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::toString(unsigned int, bool) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::urem(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::yaml::Stream::end()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MemoryBuffer::getOpenFile(int, char const_, llvm::OwningPtrllvm::MemoryBuffer&, unsigned long, unsigned long, long, bool)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::remove_filename(llvm::SmallVectorImpl<char>&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::Bogus' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::isArch32Bit() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::report_fatal_error(std::string const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::remove(llvm::Twine const&, bool&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator|=(llvm::APInt const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Twine::toVector(llvm::SmallVectorImpl<char>&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::TimeRecord::getCurrentTime(bool)' /usr/lib64/llvm/libclang.so: undefined reference totypeinfo for llvm::PrettyStackTraceEntry' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::StringRef::find(llvm::StringRef, unsigned long) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::report_fatal_error(char const_)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::sdiv_ov(llvm::APInt const&, bool&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetNodeID::AddInteger(int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::system_temp_directory(bool, llvm::SmallVectorImpl<char>&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::ashr(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::rotl(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::AtomicIncrement(unsigned int volatile)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetNodeID::AddInteger(unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::getVendorName() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_fd_ostream::raw_fd_ostream(int, bool, bool)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::LockFileManager::LockFileManager(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::slt(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::trunc(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallPtrSetImpl::~SmallPtrSetImpl()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Process::StandardErrColumns()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::upper() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::toString(llvm::SmallVectorImplllvm::Regex::isValid(std::string&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Twine::toStringRef(llvm::SmallVectorImplllvm::APInt::operator+=(llvm::APInt const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_fd_ostream::~raw_fd_ostream()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::getAsSignedInteger(llvm::StringRef, unsigned int, long long&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::EqualSlowCase(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Program::ChangeStdoutToBinary()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::divide(llvm::APFloat const&, llvm::APFloat::roundingMode)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::convertFromString(llvm::StringRef, llvm::APFloat::roundingMode)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::system_category()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_svector_ostream::raw_svector_ostream(llvm::SmallVectorImpl<char>&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::convertToDouble() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::native(llvm::Twine const&, llvm::SmallVectorImpl<char>&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MCSectionMachO::ParseSectionSpecifier(llvm::StringRef, llvm::StringRef&, llvm::StringRef&, unsigned int&, bool&, unsigned int&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Twine::str() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::extension(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallPtrSetImpl::erase_imp(void const_)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::getOSVersion(unsigned int&, unsigned int&, unsigned int&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetImpl::GetOrInsertNode(llvm::FoldingSetImpl::Node_)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_ostream::write(char const, unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::getOSName() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::AtomicDecrement(unsigned int volatile)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::MemoryBuffer::getNewMemBuffer(unsigned long, llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::MutexImpl::release()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::PPCDoubleDouble' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::yaml::ScalarNode::getValue(llvm::SmallVectorImplllvm::StringMapImpl::LookupBucketFor(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::ssub_ov(llvm::APInt const&, bool&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::shlSlowCase(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference to
typeinfo for llvm::CrashRecoveryContextCleanup' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::getOSTypeName(llvm::Triple::OSType)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::IEEEsingle' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::compare_lower(llvm::StringRef) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::get64BitArchVariant() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::has_parent_path(llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::CrashRecoveryContext::Enable()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_ostream::operator<<(long)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator-(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::operator=(unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::getDefaultTargetTriple()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::parent_path(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::filename(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::operator-=(llvm::APInt const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::outs()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::CrashRecoveryContext::RunSafelyOnThread(void (_)(void_), void_, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::PrettyStackTraceEntry::PrettyStackTraceEntry()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::smul_ov(llvm::APInt const&, bool&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Timer::stopTimer()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_ostream::operator<<(double)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::setArch(llvm::Triple::ArchType)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::IEEEquad' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MCContext::MCContext(llvm::MCAsmInfo const&, llvm::MCRegisterInfo const&, llvm::MCObjectFileInfo const, llvm::SourceMgr const)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::yaml::Stream::~Stream()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetNodeID::ComputeHash() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::TimeValue::normalize()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator+(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::CrashRecoveryContext::HandleCrash()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::operator=(llvm::APFloat const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::OrSlowCase(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator_=(llvm::APInt const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::unique_file(llvm::Twine const&, int&, llvm::SmallVectorImpl<char>&, bool, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::getiOSVersion(unsigned int&, unsigned int&, unsigned int&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::sext(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::locale::isPrint(int)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Path::Path(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetImpl::clear()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::APFloat(llvm::APInt const&, bool)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::subtract(llvm::APFloat const&, llvm::APFloat::roundingMode)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Path::makeUnique(bool, std::string*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::PathSeparator' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetNodeID::AddInteger(unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MemoryBuffer::getMemBufferCopy(llvm::StringRef, llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::is_directory(llvm::Twine const&, bool&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::APFloat(llvm::fltSemantics const&, llvm::APFloat::fltCategory, bool)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallPtrSetImpl::CopyFrom(llvm::SmallPtrSetImpl const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::x87DoubleExtended' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::get32BitArchVariant() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator--()' /usr/lib64/llvm/libclang.so: undefined reference totypeinfo for llvm::format_object_base' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::const_iterator::operator!=(llvm::sys::path::constiterator const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::setArchName(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MemoryBuffer::getSTDIN(llvm::OwningPtrllvm::MemoryBuffer&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::clearBit(unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::getTotalMemory() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::countLeadingZerosSlowCase() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::makeNaN(llvm::fltSemantics const&, bool, bool, llvm::APInt const)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::setTriple(llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::CrashRecoveryContextCleanup::~CrashRecoveryContextCleanup()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::detail::directory_iterator_increment(llvm::sys::fs::detail::DirIterState&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Path::GetMainExecutable(char const, void)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::countLeadingOnes() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::TargetRegistry::lookupTarget(std::string const&, std::string&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::APFloat(double)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::PrintStats() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::lower() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::countPopulationSlowCase() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::is_separator(char)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetNodeID::AddNodeID(llvm::FoldingSetNodeID const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::getNonStreamedMemoryObject(unsigned char const_, unsigned char const_)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::APFloat(llvm::APFloat const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::hashing::detail::fixed_seed_override' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::fs::create_directory(llvm::Twine const&, bool&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Path::canWrite() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::zextOrTrunc(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::MCAsmParserSemaCallback::~MCAsmParserSemaCallback()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Path::eraseComponent()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::detail::directory_iterator_destruct(llvm::sys::fs::detail::DirIterState&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::StringRef::rfind(llvm::StringRef) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::Profile(llvm::FoldingSetNodeID&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::shl(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::DisablePrettyStackTrace' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::convertToInteger(llvm::APSInt&, llvm::APFloat::roundingMode, bool_) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_string_ostream::~raw_string_ostream()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetImpl::FindNodeOrInsertPos(llvm::FoldingSetNodeID const&, void_&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::stem(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MemoryBuffer::getNewUninitMemBuffer(unsigned long, llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_fd_ostream::close()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::rawostream::operator<<(void const)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::changeSign()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::SmallPtrSetImpl::swap(llvm::SmallPtrSetImpl&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringMapImpl::StringMapImpl(unsigned int, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Timer::init(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::IEEEhalf' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Timer::~Timer()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::BumpPtrAllocator::~BumpPtrAllocator()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::BumpPtrAllocator(unsigned long, unsigned long, llvm::SlabAllocator&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Path::Path(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_ostream::flush_nonempty()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::BumpPtrAllocator::DefaultSlabAllocator' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::bitwiseIsEqual(llvm::APFloat const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::getArchName() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Regex::~Regex()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::detail::directory_iterator_construct(llvm::sys::fs::detail::DirIterState&, llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Path::eraseSuffix()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetIteratorImpl::advance()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::end(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Regex::match(llvm::StringRef, llvm::SmallVectorImpl<llvm::StringRef>*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::Reset()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::udiv(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::LockFileManager::waitForUnlock()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::llvm_start_multithreaded()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::append(llvm::SmallVectorImplllvm::APInt::byteSwap() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_fd_ostream::raw_fdostream(char const, std::string&, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Program::FindProgramByName(std::string const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::SourceMgr::~SourceMgr()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::llvm_execute_on_thread(void (_)(void_), void_, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_fd_ostream::seek(unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::const_iterator::operator++()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::locale::columnWidth(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::errs()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::bitcastToAPInt() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Process::StandardErrHasColors()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::sextOrTrunc(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetNodeID::operator==(llvm::FoldingSetNodeID const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::IEEEdouble' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::Triple(llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetImpl::FoldingSetImpl(unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Path::appendSuffix(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Regex::Regex(llvm::StringRef, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::generic_category()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::initSlowCase(llvm::APInt const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_ostream::SetBufferAndMode(char_, unsigned long, llvm::raw_ostream::BufferKind)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::fs::equivalent(llvm::Twine const&, llvm::Twine const&, bool&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::current_path(llvm::SmallVectorImpl<char>&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::yaml::KeyValueNode::getValue()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::LockFileManager::~LockFileManager()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MemoryBuffer::getFile(llvm::StringRef, llvm::OwningPtrllvm::sys::path::append(llvm::SmallVectorImpl<char>&, llvm::Twine const&, llvm::Twine const&, llvm::Twine const&, llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_svector_ostream::~raw_svectorostream()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::getAsUnsignedInteger(llvm::StringRef, unsigned int, unsigned long long&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::BumpPtrAllocator(unsigned long, unsigned long, llvm::SlabAllocator&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::APInt(unsigned int, llvm::ArrayRef<unsigned long>)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::LockFileManager::getState() const' /usr/lib64/llvm/libclang.so: undefined reference to`llvm::CrashRecoveryContext::RunSafely(void ()(void), void)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_ostream::write_escaped(llvm::StringRef, bool)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::yaml::KeyValueNode::getKey()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::XorSlowCase(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::setOSName(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::BumpPtrAllocator::AlignPtr(char*, unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::TimeRecord::print(llvm::TimeRecord const&, llvm::raw_ostream&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::print(llvm::raw_ostream&, bool) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::CrashRecoveryContext::registerCleanup(llvm::CrashRecoveryContextCleanup_)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::createNullStreamer(llvm::MCContext&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APSInt::Profile(llvm::FoldingSetNodeID&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::zext(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::sadd_ov(llvm::APInt const&, bool&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Twine::print(llvm::raw_ostream&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::CrashRecoveryContext::~CrashRecoveryContext()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::initSlowCase(unsigned int, unsigned long, bool)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::~BumpPtrAllocator()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::compare(llvm::APFloat const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetImpl::~FoldingSetImpl()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::~APFloat()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetNodeID::AddString(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::yaml::MappingNode::increment()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::FoldingSetIteratorImpl::FoldingSetIteratorImpl(void_)' /usr/lib64/llvm/libclang.so: undefined reference to `llvm::sys::Path::eraseFromDisk(bool, std::string) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::yaml::Stream::Stream(llvm::StringRef, llvm::SourceMgr&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::CrashRecoveryContext::unregisterCleanup(llvm::CrashRecoveryContextCleanup_)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::getSmallest(llvm::fltSemantics const&, bool)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::rawostream::write(unsigned char)' /usr/lib64/llvm/libclang.so: undefined reference to `llvm::MemoryBuffer::getFile(char const, llvm::OwningPtrllvm::MemoryBuffer&, long, bool)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::install_fatal_error_handler(void (*)(void*, std::string const&), void*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Path::appendComponent(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallPtrSetImpl::SmallPtrSetImpl(void const**, llvm::SmallPtrSetImpl const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MCAsmParser::setTargetParser(llvm::MCTargetAsmParser&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::ult(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Path::createDirectoryOnDisk(bool, std::string_)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::CrashRecoveryContext::Disable()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::format_object_base::home()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallVectorBase::grow_pod(void_, unsigned long, unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::StringMapImpl::RehashTable()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::APFloat(llvm::fltSemantics const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::BumpPtrAllocator::Allocate(unsigned long, unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::fs::exists(llvm::Twine const&, bool&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Timer::startTimer()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::CrashRecoveryContext::GetCurrent()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::report_fatal_error(llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Twine::toNullTerminatedStringRef(llvm::SmallVectorImpl<char>&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::lshr(unsigned int) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::replace_extension(llvm::SmallVectorImpl<char>&, llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::createMCAsmParser(llvm::SourceMgr&, llvm::MCContext&, llvm::MCStreamer&, llvm::MCAsmInfo const&)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::path::is_absolute(llvm::Twine const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::fs::copy_file(llvm::Twine const&, llvm::Twine const&, llvm::sys::fs::copyoption)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::split(llvm::SmallVectorImplllvm::StringRef&, llvm::StringRef, int, bool) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::AssignSlowCase(llvm::APInt const&)' /usr/lib64/llvm/libclang.so: undefined reference to`llvm::StringMapImpl::RemoveKey(llvm::StringMapEntryBase)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::RemoveFileOnSignal(llvm::sys::Path const&, std::string_)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::begin(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::MutexImpl::MutexImpl(bool)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::raw_ostream::write_hex(unsigned long long)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::MCContext::~MCContext()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::getLargest(llvm::fltSemantics const&, bool)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_svector_ostream::str()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::StringRef::edit_distance(llvm::StringRef, bool, unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::Path::canExecute() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::operator++()' /usr/lib64/llvm/libclang.so: undefined reference totypeinfo for llvm::FoldingSetImpl' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::getHostCPUName()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::error_code::message() const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Path::isRegularFile() const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::PathWithStatus::getFileStatus(bool, std::string_) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::AndSlowCase(llvm::APInt const&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APInt::sshl_ov(unsigned int, bool&) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::convert(llvm::fltSemantics const&, llvm::APFloat::roundingMode, bool)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SourceMgr::FindBufferContainingLoc(llvm::SMLoc) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::PrettyStackTraceEntry::~PrettyStackTraceEntry()' /usr/lib64/llvm/libclang.so: undefined reference totypeinfo for llvm::MCAsmParserSemaCallback' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::Program::ExecuteAndWait(llvm::sys::Path const&, char const, char const, llvm::sys::Path const*, unsigned int, unsigned int, std::string_)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::sys::PrintStackTraceOnErrorSignal()' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APInt::toString(llvm::SmallVectorImplllvm::APFloat::multiply(llvm::APFloat const&, llvm::APFloat::roundingMode)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::MemoryBuffer::getMemBuffer(llvm::StringRef, llvm::StringRef, bool)' /usr/lib64/llvm/libclang.so: undefined reference tovtable for llvm::raw_string_ostream' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::MutexImpl::~MutexImpl()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::APFloat::copySign(llvm::APFloat const&)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::convertFromAPInt(llvm::APInt const&, bool, llvm::APFloat::roundingMode)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringMapImpl::FindKey(llvm::StringRef) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::yaml::Document::parseBlockNode()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::StringRef::find_first_of(llvm::StringRef, unsigned long) const' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::yaml::SequenceNode::increment()' /usr/lib64/llvm/libclang.so: undefined reference tollvm::Triple::normalize(llvm::StringRef)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::APFloat::APFloat(llvm::fltSemantics const&, unsigned long)' /usr/lib64/llvm/libclang.so: undefined reference tollvm::SmallPtrSetImpl::insert_imp(void const*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::fs::directory_entry::status(llvm::sys::fs::file_status&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::FoldingSetImpl::InsertNode(llvm::FoldingSetImpl::Node*, void*)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::Triple::getMacOSXVersion(unsigned int&, unsigned int&, unsigned int&) const' /usr/lib64/llvm/libclang.so: undefined reference tollvm::raw_ostream::indent(unsigned int)' /usr/lib64/llvm/libclang.so: undefined reference to
llvm::sys::path::is_relative(llvm::Twine const&)' clang: error: linker command failed with exit code 1 (use -v to see invocation) make: *\ [clang-complete] 错误 1I've noticed the message: /usr/bin/x86_64-pc-linux-gnu-ld: warning: libLLVM-3.2svn.so, needed by /usr/lib64/llvm/libclang.so, not found (try using -rpath or -rpath-link)
After adding this to LDFLAGS,problem fixed. LDLIBS := $(shell llvm-config --ldflags) $(shell llvm-config --libs all) -lstdc++ -lclang -rpath $(shell llvm-config --libdir)