🌐
GitHub
github.com › gcc-mirror › gcc
GitHub - gcc-mirror/gcc
This directory contains the GNU Compiler Collection (GCC). The GNU Compiler Collection is free software. See the files whose names start with COPYING for copying permission. The manuals, and some of the runtime libraries, are under different ...
Starred by 10.7K users
Forked by 4.7K users
Languages   C++ 30.1% | C 29.3% | Ada 14.0% | D 5.9% | Go 5.3% | HTML 3.6%
🌐
GNU
gcc.gnu.org › git.html
GCC: Anonymous read-only Git access - GNU Project
August 31, 2025 - Anonymous read-only access to the GCC project Git source repository.
Discussions

svn - GCC branches vs Subversion and Git - Stack Overflow
now here it says that there are even 3 "mirrors" of the svn repository hosted on gnu.org, repo.or.cz and github, the problem is that : More on stackoverflow.com
🌐 stackoverflow.com
August 26, 2020
c++ - What is the difference between g++ and gcc? - Stack Overflow
What is the difference between g++ and gcc? Which one of them should be used for general c++ development? More on stackoverflow.com
🌐 stackoverflow.com
GCC or Clang
You need both. Clang has much more features, less bugs and better warnings. GCC is the standard. More on reddit.com
🌐 r/C_Programming
46
107
February 9, 2022
GitHub - hanoglu/TermiC: GCC powered interactive C/C++ terminal created with BASH

Pretty cool stuff. The usage of output to decide whether something is to be kept is a pretty clever one, keeping things simple, while allowing functions and structs. (It would be really nice, if they could be replaced, but probably not worth it).

Some ideas for the script (even if this is C, not (ba)sh subreddit)

  • sh's case supports string matching (unlike C's select)

  • cmd && x=true; if $x can be written simply as if cmd

  • mktemp on *BSD and MacOS expect (at least according to documentation) the X's to be at the end

  • echo "\cat $sourceFile`"can be simplified to justcat $sourceFile`

  • a here-doc could be more readable for the initial header

  • hey, a real C comment: using "" (instead of <>) for standard includes is semantically wrong

  • two strings can be joined by a newline with: "$str1"$'\n'"$str2", no need to use echos and backticks

  • string literals probably mustn't include (unbalanced) curly braces, but not sure it makes sense to add complexity to handle that case

  • I like the yes ... | head trick, but I'd use | tr -d '\n' instead of running echo

Anyway, the idea is great, and the implementation looks like it works. Will probably try it out at some point; wouldn't leave all those test.cs and asdf.cs lying around everywhere. Thanks!

(Sorry for the earlier noise, my pocket's LLM is not very good).

More on reddit.com
🌐 r/C_Programming
2
6
March 4, 2022
🌐
GitHub
github.com › topics › gcc-compiler
gcc-compiler · GitHub Topics · GitHub
c99 gcc-compiler abstract-syntax-tree ... mm32 · Updated · Dec 23, 2021 · C · Star 4 · An Application based on Probability Prediction using Randomization Algorithms....
🌐
GitHub
github.com › riscv-collab › riscv-gnu-toolchain
GitHub - riscv-collab/riscv-gnu-toolchain: GNU toolchain for RISC-V, including GCC
GNU toolchain for RISC-V, including GCC. Contribute to riscv-collab/riscv-gnu-toolchain development by creating an account on GitHub.
Starred by 4.4K users
Forked by 1.4K users
Languages   C
🌐
GitHub
github.com › oracle › gcc
GitHub - oracle/gcc: Unofficial mirror of https://gcc.gnu.org/ ...
This is an unofficial mirror of the http://gcc.gnu.org/git/ GCC repository.
Author   oracle
🌐
Googlesource
gnu.googlesource.com › gcc
gcc - Git at Google
gnu/gcc · Mirrored from git://gcc.gnu.org/git/gcc.git · Clone this repo: trunk · devel/analyzer · devel/autopar_devel · devel/autopar_europar_2021 · devel/bypass-asm · devel/c++-contracts · devel/c++-coroutines · devel/c++-modules · devel/c++-name-lookup ·
🌐
GNU
gcc.gnu.org
GCC, the GNU Compiler Collection - GNU Project
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Objective-C++, Fortran, Ada, Go, D, Modula-2, COBOL, Rust, and Algol 68 as well as libraries for these languages (libstdc++,...). GCC was originally written as the compiler for the GNU operating system.
🌐
GitHub
github.com › aixoss › gcc
GitHub - aixoss/gcc: GNU Compiler Collection (GCC)
GNU Compiler Collection (GCC). Contribute to aixoss/gcc development by creating an account on GitHub.
Forked by 2 users
Languages   C 36.9% | Ada 17.0% | Java 16.1% | C++ 14.7% | Go 4.2% | HTML 3.1%
🌐
GitHub
gist.github.com › yosoufe › ad45f45c10fe08abecbf53000d0d199f
Compile and install gcc-9.3.0 · GitHub
or download and extract it from here: https://ftp.gnu.org/gnu/gcc/gcc-9.3.0/ # requirements sudo apt-get install flex bison mkdir build ./contrib/download_prerequisites --directory=build cd build ../configure \ --prefix=/usr \ --disable-multilib \ --with-system-zlib \ --enable-languages=c,c++,d,fortran,go,objc,obj-c++ \ --program-suffix=-9.3.0 make -j$(nproc) sudo make install -j$(nproc) Copy link ·
Find elsewhere
🌐
Stack Overflow
stackoverflow.com › questions › 26140413 › gcc-branches-vs-subversion-and-git
svn - GCC branches vs Subversion and Git - Stack Overflow
August 26, 2020 - @user2485710 - I'm too lazy to clone Git-repo locally, but gcc.gnu.org/wiki/GitMirror says clearly "Our clone contains all the gcc branches.
🌐
Linaro
git.linaro.org › toolchain › gcc.git
devel/analyzer devel/autopar_devel ...
Code Review Sign In · review.linaro.org / toolchain / gcc.git · Mirror of https://gcc.gnu.org/git/?p=gcc.git + linaro-local branches · Clone this repo: · Branches · master · devel/analyzer · devel/autopar_devel · devel/autopar_europar_2021 · devel/bypass-asm
🌐
Arm Developer
developer.arm.com › tools-and-software › open-source-software › developer-tools › gnu-toolchain › gnu-rm
Arm GNU Toolchain
February 15, 2022 - Use new features from recent Arm Architecture and from open-source projects GCC, Binutils, glibc, Newlib, and GDB.
🌐
Jmeubank
jmeubank.github.io › tdm-gcc › download
Download | tdm-gcc
Older versions are still available on SourceForge: TDM-GCC files.
🌐
GNU
gnu.org › software › gcc
GCC, the GNU Compiler Collection - GNU Project
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran, Ada, Go, D, Modula-2, and COBOL as well as libraries for these languages (libstdc++,...). GCC was originally written as the compiler for the GNU operating system. The GNU system was developed to be 100% free software, ...
🌐
Wikipedia
en.wikipedia.org › wiki › GNU_Compiler_Collection
GNU Compiler Collection - Wikipedia
3 weeks ago - The GNU Compiler Collection (GCC) (formerly GNU C Compiler) is a collection of compilers from the GNU Project that support various programming languages, hardware architectures, and operating systems.
Top answer
1 of 11
979

gcc and g++ are compiler-drivers of the GNU Compiler Collection (which was once upon a time just the GNU C Compiler).

Even though they automatically determine which backends (cc1 cc1plus ...) to call depending on the file-type, unless overridden with -x language, they have some differences.

The probably most important difference in their defaults is which libraries they link against automatically.

According to GCC's online documentation link options and how g++ is invoked, g++ is roughly equivalent to gcc -xc++ -lstdc++ -shared-libgcc (the 1st is a compiler option, the 2nd two are linker options). This can be checked by running both with the -v option (it displays the backend toolchain commands being run).

By default (and unlike gcc), g++ also adds linker option -lm -- to link against libm which contains implementations for math.h.

2 of 11
592

GCC: GNU Compiler Collection

  • Referrers to all the different languages that are supported by the GNU compiler.

gcc: GNU C      Compiler
g++: GNU C++ Compiler

The main differences:

  1. gcc will compile: *.c\*.cpp files as C and C++ respectively.
  2. g++ will compile: *.c\*.cpp files but they will all be treated as C++ files.
  3. Also if you use g++ to link the object files it automatically links in the std C++ libraries (gcc does not do this).
  4. gcc compiling C files has fewer predefined macros.
  5. gcc compiling *.cpp and g++ compiling *.c\*.cpp files has a few extra macros.

Extra Macros when compiling *.cpp files:

#define __GXX_WEAK__ 1
#define __cplusplus 1
#define __DEPRECATED 1
#define __GNUG__ 4
#define __EXCEPTIONS 1
#define __private_extern__ extern
🌐
GitHub
github.com › gcc-mirror › gcc › blob › master › README
gcc/README at master · gcc-mirror/gcc
This directory contains the GNU Compiler Collection (GCC).
Author   gcc-mirror
🌐
Ohio Supercomputer Center
osc.edu › resources › available_software › software_list › gnu_compilers
GNU Compilers | Ohio Supercomputer Center
July 29, 2025 - Fortran, C and C++ compilers produced by the GNU Project. Availability and Restrictions Versions The GNU Compiler Collection (GCC) are available on all our clusters. These are the versions currently available: Version Pitzer Ascend Cardinal Notes 11.4.1 X# X# X# 12.3.0 X X X* 13.2.0 X X X * ...
🌐
Reddit
reddit.com › r/c_programming › gcc or clang
r/C_Programming on Reddit: GCC or Clang
February 9, 2022 -

I primarily program on Linux and have always used GCC, but have recently been interested in switching over to using Clang. It seems like the runtime performance of the two compilers is similar, but I am also interested in C standards compliance going into the future, as well as things like error messaging, memory-leak checking, etc.

If anyone here is knowledgeable about compilers and the differences or advantages of one or the other, I'd like to hear your opinion.