dockerfiles icon indicating copy to clipboard operation
dockerfiles copied to clipboard

[ubuntu-dev] install clang with static-analysis headers and stuff

Open tbourvon opened this issue 8 years ago • 4 comments

cd
git clone https://github.com/llvm-mirror/llvm.git
cd llvm/tools
git clone https://github.com/llvm-mirror/clang.git
cd clang/tools
git clone https://github.com/llvm-mirror/clang-tools-extra.git extra
cd ~/llvm/projects
git clone https://github.com/llvm-mirror/libcxx.git

cd
mkdir llvm-build
cd llvm-build
cmake -G "Unix Makefiles" ../llvm
make
sudo make install

tbourvon avatar Jul 06 '17 12:07 tbourvon

Thanks a lot for these instructions! We should definitely add them to our ubuntu-dev.dockerfile if they're useful for other developers as well.

Also, thanks for suggesting to build with -DCMAKE_BUILD_TYPE=Release in order to avoid Clang's Debug mode.

jankeromnes avatar Jul 06 '17 13:07 jankeromnes

You should probably clone the release_40 branches for all the git clone as this is the version the static analysis is based on.

tbourvon avatar Jul 06 '17 13:07 tbourvon

Second suggestion: we should probably use make -j<a lot> instead of make.

tbourvon avatar Jul 06 '17 13:07 tbourvon

Third suggestion: the libcxx step is only for Mac and I think it should't be used for these containers, sorry about that.

tbourvon avatar Jul 06 '17 13:07 tbourvon