How to Install GCC ( GNU C Compiler ) on Linux Mint

Linux Mint is a popular distro of Linux Operating System. It is similar with most Linux Debian and Linux Ubuntu distros. Surveys show that Linux Mint is the most popular and widely used distro among all the other distros. In this tutorial, we will learn How to Install GCC ( GNU C Compiler ) – a popular light-weight C compiler on Linux Mint. And it has been marked the best light-weight distro.

How to Check if GCC Installed or Not

Almost every time you setup Linux Mint on your system, C compiler is installed by default. To check if GCC or GNU C compiler is already installed or not, run the following command on your terminal.

$ gcc -v     // check C compiler is installed or not

After running the above command if you get the following response like the image below in your terminal then, it means GCC C compiler is installed on your machine otherwise install the GNU C Compiler on your machine by following ways.

Check if GCC C compiler is istalled or not on Linux Mint

You May Learn: Check if a Package is Installed or Not on Linux Mint

Install GCC – GNU C compiler on Linux Mint

You can Install the GNU C Compiler using two different ways on your Linux Mint System. These ways also will work for nearly similar distros like Linux Ubuntu, Linux Debian, etc.

Install from Command Line

To install the C compiler, first, open up your terminal by pressing CTRL + Alt + T from your keyboard and then type:

$ sudo apt-get install gcc

 

After running that command, your terminal will perform the following activities as the image below.

Install GCC GNU C Compiler from Command Line

If the terminal performs the above activities the GNU C Compiler should be installed successfully. To check, if the compiler is installed properly, follow the first step.

Install from Software Manager

You can also install C compiler from the Linux Mint default software manager. To install GCC first, open up your software manager from the installed program list. Then search for GCC. Click on the first search result and click on the GCC. Then on the next screen. click on the Install button and enter your password to authenticate the installation.

Install GCC GNU C Compiler fro Software Manager
Install GCC From the Software Manager

Now you have successfully installed the GNU C Compiler or GCC

Further Readings: Compile and Run Your First C Program on Linux Mint

{Linux & C case studies}

Linux Tutorial C Tutorial Linux Tutorial Index

Tags