Likely the same issue as described in https://code.google.com/p/include-what-you-use/issues/detail?id=92 . Right now it's needed to put -lclangEdit before -lclangLex to link with GCC under Linux.
@@ -44,9 +44,9 @@
clangdao_exe.AddLinkingFlag( "-lclangSema" )
clangdao_exe.AddLinkingFlag( "-lclangAnalysis" )
clangdao_exe.AddLinkingFlag( "-lclangAST" )
+clangdao_exe.AddLinkingFlag( "-lclangEdit" )
clangdao_exe.AddLinkingFlag( "-lclangLex" )
clangdao_exe.AddLinkingFlag( "-lclangBasic" )
-clangdao_exe.AddLinkingFlag( "-lclangEdit" )
clangdao_exe.AddLinkingFlag( "-lclangSerialization" )
clangdao_exe.AddLinkingFlag( "-lclangStaticAnalyzerCheckers" )
clangdao_exe.AddLinkingFlag( "-lclangStaticAnalyzerCore" )
Also, in my case I'm using LLVM 3.5.1 and Clang 3.5.1 and I need to add the whole output of llvm-config --libs after the linking flag -lclangStaticAnalyzerFrontend to link properly (otherwise symbols are missing etc.). According to my understanding, it has something to do with including symbols from clang (which in turn includes symbols from llvm) and llvm at the same time into one object file. I couldn't come up with better solution :(
Likely the same issue as described in https://code.google.com/p/include-what-you-use/issues/detail?id=92 . Right now it's needed to put
-lclangEditbefore-lclangLexto link with GCC under Linux.Also, in my case I'm using LLVM 3.5.1 and Clang 3.5.1 and I need to add the whole output of
llvm-config --libsafter the linking flag-lclangStaticAnalyzerFrontendto link properly (otherwise symbols are missing etc.). According to my understanding, it has something to do with including symbols from clang (which in turn includes symbols from llvm) and llvm at the same time into one object file. I couldn't come up with better solution :(