-
Notifications
You must be signed in to change notification settings - Fork 0
Install llvm on osx or linux
This is a short instruction how to get llvm. For more information and a more detailed tutorial visit the llvm page
I presume you have installed the following applications: xcode and cmake.
elementaryOS used in this tutorial
You need following tools:
You can install gcc with apt
sudo apt-get install build-essential
Subversion with
sudo apt-get install subversion
Locate a place where you want to clone the llvm sources.
cd where-you-want-llvm-to-live
Then checkout the sources.
svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
Create a new folder and go in it. Then type:
cmake ..
make
make install
This will install llvm on your system.
You can additionally install clang if you want on Linux. Check out the clang documentation
I use gtest as unit testing framework. What is gtest?
clone gtest. Then go in the unzipped folder and create a build folder again. Go in it and then do the same above.
cmake ..
make
Now we have to install the libraries:
cp -r ../include/gtest /usr/local/include
cp lib*.a /usr/local/lib