Created
March 31, 2019 12:42
-
-
Save orenyomtov/7dc59d121d8405f710711e6008cfa1bb to your computer and use it in GitHub Desktop.
Update clang to 8.0 and gcc to 8.0 on Ubuntu xenial 16.04
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if [ ! -f /usr/bin/gcc-8 ]; then | |
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test | |
sudo apt-get update | |
sudo apt-get install -y gcc-8 g++-8 | |
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 1000 | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 1000 | |
fi | |
if [ ! -f /usr/bin/gcc-8 ]; then | |
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - | |
sudo apt-add-repository -y "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-8 main" | |
sudo apt-get update | |
sudo apt-get install -y clang-8 | |
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-8 1000 | |
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-8 1000 | |
fi | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
line 10 should be:
if [ ! -f /usr/bin/clang-8 ]; then