How do I downgrade gcc version?

How do I downgrade gcc version?

2 Answers

  1. Uninstall gcc5.4. sudo apt-get remove gcc g++ Check gcc again: gcc –version.
  2. Install gcc 4.9/g++ 4.9. sudo apt-get install gcc-4.9 g++-4.9. Checking Version: g++-4.9 –version.
  3. Link to gcc g++ ln -s /usr/bin/g++-4.9 /usr/bin/g++ ln -s /usr/bin/gcc-4.9 /usr/bin/gcc.
  4. Checking Version: g++ –v gcc –v.

How do I change my GNU version?

Direct link to this answer

  1. Open the terminal window in LINUX and execute the command:
  2. $ which gcc.
  3. This will provide the symbolic link (softlink) to the default version of GCC.
  4. Navigate to the directory which has this softlink.
  5. Change the softlink to point to the version of GCC that you want to use.

How do I completely remove gcc?

–purge Use purge instead of remove for anything that would be removed. An asterisk (“*”) will be displayed next to packages which are scheduled to be purged. remove –purge is equivalent to the purge command. Configuration Item: APT::Get::Purge.

How do I find gcc version?

Type “gcc –version” in command prompt to check whether C compiler is installed in your machine. Type “g++ –version” in command prompt to check whether C++ compiler is installed in your machine.

How do I set gcc version?

You can specify the version number by sending the full path: greg@greg-mint ~ $ gcc –version gcc (Ubuntu/Linaro 4.7.

Should I uninstall TDM GCC?

That said, in either case, uninstalling isn’t mandatory. For the command line, you can simply edit your Window PATH/Path variables (Control Panel\System and Security\System → Advanced system settings -> Environment Variables…).

Is it possible to downgrade GCC in Ubuntu?

Downgrading GCC and G++ compilers in Ubuntu is mandatory to build some packages (like IRSTLM, Giza++, Moses, etc.). In this tutorial, I will present an easy way to install gcc-4.4, gcc-4.6, gcc-4.9, g++-4.4, g++-4.6, and, g++-4.9. First of all, you need to update the sources repository using a text editor like vi as follow:

How can I change the default version of GCC?

To change the default gcc version, just run the command: and select through the keypad (1, 2, 3, 4, etc.) the version of gcc and same for g++ as follow: I hope that you enjoyed this tutorial. Don’t forget to visit my channel on YouTube for more tutorials.

Why is GCC version 6 has no installation candidate?

This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package ‘gcc-6’ has no installation candidate Please do not remove / change the system gcc : You can have as many gcc versions as you want, installed at the same time.

Do you need GCC 4.9 or 4.8?

Exactly step 3 on this question. Since at this point 4.9 is 4.9.3, which is not supported, you’ll need 4.8. and after, to switch back to having gcc-5 by default. (Since you’re doing it to install the CUDA SDK, I’ll add that if you want to test the samples, you may want to read this .)