From fd7a2278b99d71a49dfe3aec1721745a0e8806e6 Mon Sep 17 00:00:00 2001 From: Robbe De Greef Date: Sat, 26 Sep 2020 14:58:23 +0200 Subject: [PATCH] Documentation: Debian gcc-9 installation instructions We already have installation instructions for ubuntu but not yet for Debian. Gcc-9 is not available on Debian stable so instructions for switching to and from Debian testing are added. --- Documentation/BuildInstructions.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Documentation/BuildInstructions.md b/Documentation/BuildInstructions.md index 4981454305..1f555cc9b1 100644 --- a/Documentation/BuildInstructions.md +++ b/Documentation/BuildInstructions.md @@ -37,6 +37,24 @@ sudo apt-get install gcc-9 g++-9 sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 900 --slave /usr/bin/g++ g++ /usr/bin/g++-9 ``` +On Debian you can install it by switching to the Debian testing branch: +```bash +sudo echo "deb http://http.us.debian.org/debian/ testing non-free contrib main" >> /etc/apt/sources.list +sudo apt update +``` + +Afterwards you can install gcc-9 with apt like: +```bash +sudo apt install gcc-9 g++-9 +sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 900 --slave /usr/bin/g++ g++ /usr/bin/g++-9 +``` + +If you don't want to stay on the testing branch you can switch back by running: +```bash +sudo sed -i '$d' /etc/apt/sources.list +sudo apt update +``` + Ensure your CMake version is >= 3.16 with `cmake --version`. If your system doesn't provide a suitable version of CMake, you can download a binary release from the [CMake website](https://cmake.org/download). #### macOS prerequisites