gcc & g++

Some useful flags for gcc and g++ explained.

The most commonly used gcc & g++ flags

Most options and flags are the same for gcc and g++. In this article, I will use examples of gcc and g++ interchangeably, but keep in mind it most likely works for the other one as well.

Step by step compilation of gcc/g++

Errors and Warnings

Good to have:

Optional but still good: