On this page
    
    Installing C Compiler (GCC)
Windows
- 
Install MinGW: - Download the MinGW installer from MinGW website and run it.
- Select “Basic Setup” and choose the GCC compiler suite during installation.
 
- 
Set Path (Optional): - Add MinGW bindirectory to system PATH variable for command line access.
 
- Add MinGW 
- 
Verify Installation: - Open Command Prompt and type:
  
  
  
  
  
  
  
  
  gcc --version
 
- Open Command Prompt and type:
  
  
  
  
  
  
  
  
  
macOS
- 
Install Xcode Command Line Tools: - Open Terminal and run:
  
  
  
  
  
  
  
  
  xcode-select --install
 
- Open Terminal and run:
  
  
  
  
  
  
  
  
  
- 
Verify Installation: - Open Terminal and type:
  
  
  
  
  
  
  
  
  gcc --version
 
- Open Terminal and type:
  
  
  
  
  
  
  
  
  
Linux (CentOS/RHEL using yum) 
- 
Install GCC: - Update package list and install GCC:
  
  
  
  
  
  
  
  
  sudo yum update sudo yum install -y gcc
 
- Update package list and install GCC:
  
  
  
  
  
  
  
  
  
- 
Verify Installation: - Open Terminal and type:
  
  
  
  
  
  
  
  
  gcc --version
 
- Open Terminal and type:
  
  
  
  
  
  
  
  
  
Linux (Ubuntu/Debian using apt) 
- 
Install GCC: - Update package list and install GCC:
  
  
  
  
  
  
  
  
  sudo apt update sudo apt install -y gcc
 
- Update package list and install GCC:
  
  
  
  
  
  
  
  
  
- 
Verify Installation: - Open Terminal and type:
  
  
  
  
  
  
  
  
  gcc --version
 
- Open Terminal and type: