Skip to content

Instantly share code, notes, and snippets.

@neetjn
Created April 4, 2019 16:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save neetjn/7c28db8a7a31766f0e329590e4de213f to your computer and use it in GitHub Desktop.
Save neetjn/7c28db8a7a31766f0e329590e4de213f to your computer and use it in GitHub Desktop.
if [ -f "/etc/debian_version" ]
then
sudo apt-get install -y software-properties-common
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt update
sudo apt install g++-7 -y
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 60 \
--slave /usr/bin/g++ g++ /usr/bin/g++-7
sudo update-alternatives --config gcc
else
echo "Skipping debian based gcc installation."
exit 1
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment