•  Home
  •  Dashboard
  •  Company
    • About Us
    • Blog
    • Careers
    • Contact Us
    • Data Centers
    • Looking Glass
    • Network
    • Reseller
  •  Hosting Services
    • Infrastructure
      • iColocation
    • Compute
      • cMetal
      • cVirtual
    • Storage
      • sObject
      • sBlock
    • Networking
      • nIP Transit
      • nWavelength
    • Protection
      • pBackup
      • pDDoS
  •  Solutions
    • Ecommerce
    • Finance
    • Gaming
    • Hosting
    • Management
    • Security
    • System Integrator
  •  Support
    • Community
    • Knowledge Base
    • Open A Ticket
    • Status
  •  USA & Canada: 800-933-1517
  •  International: 626-549-2801
  •  Email: sales@psychz.net
  • Services
    • new-colocation-header-img
      Infrastructure
      • iColocation
    • new-compute-header-img
      Compute
      • cMetal
      • cVirtual
    • new-storage-header-img
      Storage
      • sObject
      • sBlock
    • new-networking-header-img
      Networking
      • nIP Transit
      • nWavelength
    • new-protection-header-img
      Protection
      • pBackup
      • pDDoS
  • Solutions
    • Ecommerce
    • Security
    • Gaming
    • Hosting
    • Management
    • Finance
    • System Integrator
  • Dashboard

How to install the GCC compiler in CentOS 7?

  • Home
  • Client
  • Knowledgebase
  • Linux
  • Centos 7
  • How to install the GCC compiler in CentOS 7?

Table Of Content

    Related Articles

    • How to configure IP's On Centos 7?
    • Installing MariaDB on Centos 7
    • How to Install SSL Certificate On Centos 7
    • Linux Command Line Tutorial For Git
    • How To Install Git On Centos 7
    • Installation of Lamp Stack on CentOS 7
    • Yum Update Not Working on Centos 7

    How to install the GCC compiler in CentOS 7?

    Publisher: Psychz Networks March 17,2019

    GCC (short for GNU Compiler Collection), is a collection of programming compilers including C, C++, Objective-C, Fortran, Java, and Ada. GCC is a key component of the GNU toolchain and the standard compiler for most Unix-like operating systems. The Free Software Foundation distributes GCC under the GNU General Public License.

    In the following tutorial, we will perform GCC installation on CentOS 7. The installation process is quite simple and should not take more than 10 minutes.

    Step 1: Perform an update on the server

    Note: You need to log in to your CentOS 7 VPS via SSH as user root

    #ssh root@IP_Address -p Port_number

    To update all installed packages on the server you can use the following command

    #yum -y update

    Step 2: Install GCC from the repository

    GCC can be easily installed from the official CentOS repositories. Run the following command to install GCC on your server

    #yum -y install gcc

    Output:

    Running transaction test
    Transaction test succeeded
    Running transaction
    Installing : cpp-4.8.5-36.el7.x86_64 1/5
    Installing : kernel-headers-3.10.0-957.5.1.el7.x86_64 2/5
    Installing : glibc-headers-2.17-260.el7_6.3.x86_64 3/5
    Installing : glibc-devel-2.17-260.el7_6.3.x86_64 4/5
    Installing : gcc-4.8.5-36.el7.x86_64 5/5
    Verifying : glibc-devel-2.17-260.el7_6.3.x86_64 1/5
    Verifying : gcc-4.8.5-36.el7.x86_64 2/5
    Verifying : kernel-headers-3.10.0-957.5.1.el7.x86_64 3/5
    Verifying : cpp-4.8.5-36.el7.x86_64 4/5
    Verifying : glibc-headers-2.17-260.el7_6.3.x86_64 5/5

    Installed:
    gcc.x86_64 0:4.8.5-36.el7
    Dependency Installed:
    cpp.x86_64 0:4.8.5-36.el7 glibc-devel.x86_64 0:2.17-260.el7_6.3 glibc-headers.x86_64 0:2.17-260.el7_6.3 kernel-headers.x86_64 0:3.10.0-957.5.1.el7
    Complete!

    Step 3: Verify GCC installation on CentOS 7

    After the compilation process is completed. You can check if GCC is properly installed.

    # gcc --version

    Output:

    gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-36)
    Copyright (C) 2015 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions. There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

    Thank you for referring to this article. If you find this article helpful, please give us a vote.

    Views: (8443) Votes: (0)

    Related Articles

    • How to configure IP's On Centos 7?
    • Installing MariaDB on Centos 7
    • How to Install SSL Certificate On Centos 7
    • Linux Command Line Tutorial For Git
    • How To Install Git On Centos 7
    • Installation of Lamp Stack on CentOS 7
    • Yum Update Not Working on Centos 7
    Copyright © 2026 Psychz Networks,
    A Profuse Solutions Inc Company
    Hosting Services
    • Catalog
    Infrastructure
    • iColocation
    Compute
    • cMetal
    • cVirtual
    Storage
    • sObject
    • sBlock
    Networking
    • nIP Transit
    • nWavelength
    Protection
    • pBackup
    • pDDoS
    Company
    • About Us
    • Blog
    • Careers
    • Contact Us
    • Data Centers
    • Looking Glass
    • Network
    • Reseller
    Policies
    • Acceptable Usage Policy
    • Privacy Policy
    • Service Level Agreement
    • Terms and Conditions
    Support
    • Community
    • Knowledge Base
    • Open A Ticket
    • Status
    Get In Touch
    • Psychz Networks,
      A Profuse Solutions Company
      611 Wilshire Blvd #300
      Los Angeles,California 90017
      USA
    • US/Canada: 800-933-1517
    • International: 626-549-2801