-
Notifications
You must be signed in to change notification settings - Fork 122
Link order of Clang's Libraries
loarabia edited this page Sep 8, 2012
·
1 revision
This trick should work for nearly any make based build.
- Build Clang
- Go into the bin directory you just build (something like
/buildroot/Debug+Asserts/bin
) - Delete the
clang
binary you'll find there - Run a make dry run from your build root (
make -n
) - Look for the line where the LLVM Build system is rebuilding clang (something like
echo llvm[4]: Linking Debug+Asserts executable clang
) - The list of libraries will be contained in the next few lines below that.
As of the current writing (during clang 3.2) this list is:
-lclangFrontendTool -lclangFrontend -lclangDriver -lclangSerialization -lclangCodeGen
-lclangParse -lclangSema -lclangStaticAnalyzerFrontend -lclangStaticAnalyzerCheckers
-lclangStaticAnalyzerCore -lclangAnalysis -lclangARCMigrate -lclangRewriteFrontend -lclangRewriteCore
-lclangEdit -lclangAST -lclangLex -lclangBasic