sarojvarma / include-what-you-use

Automatically exported from code.google.com/p/include-what-you-use
Other
0 stars 0 forks source link

iwyu on llvm3.1 #69

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Adapting the compilation command to 
g++ -D_DEBUG -D_GNU_SOURCE -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS 
-fno-rtti -I include -L lib 
/home/broes/software/llvm/tools/clang/tools/include-what-you-use/*.cc -o 
include-what-you-use -lclangRewrite -lclangCodeGen -lclangFrontend 
-lclangSerialization -lclangDriver -lclangParse -lclangSema -lclangAnalysis 
-lclangEdit -lclangAST -lclangLex -lclangBasic -lLLVMipo -lLLVMScalarOpts 
-lLLVMInstCombine -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMTarget 
-lLLVMMC -lLLVMCore -lLLVMSupport -lpthread -ldl -lm

gets iwyu compiled using prebuild llvm3.1 binaries.

Original issue reported on code.google.com by cathe...@gmail.com on 4 Jun 2012 at 9:12

GoogleCodeExporter commented 9 years ago
Thanks for advice how to compile IWYU using prebuilt llvm3.1 binaries. I'll 
check it and plan to include this tip to build instructions.

Original comment by vsap...@gmail.com on 1 Jul 2012 at 11:57

GoogleCodeExporter commented 9 years ago
We are going to improve build outside of Clang source tree (issue #64) and I've 
decided to revise this issue. I was able to build IWYU with Clang+LLVM 3.2 
prebuilt binaries for Ubuntu-12.04 with the following command

g++ -D_DEBUG -D_GNU_SOURCE -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS 
-fno-rtti -I include -L lib path/to/include-what-you-use/*.cc -o 
include-what-you-use -lclangFrontend -lclangSerialization -lclangDriver 
-lclangParse -lclangSema -lclangAnalysis -lclangAST -lclangLex -lclangBasic 
-lclangEdit -lLLVMipo -lLLVMScalarOpts -lLLVMInstCombine -lLLVMTransformUtils 
-lLLVMipa -lLLVMAnalysis -lLLVMTarget -lLLVMMC -lLLVMMCParser -lLLVMCore 
-lLLVMSupport -lpthread -ldl -lm

Note that I've added -lLLVMMCParser, because clangSema uses 
llvm::MCAsmParserSemaCallback.

Original comment by vsap...@gmail.com on 14 Jan 2013 at 9:23