Site icon Ryadel

CentOS / Linux - make: g++: Command not found - How to fix

CentOS / Linux - make: g++: Command not found - How to fix

If you've stumbled upon this post it probably means that you were trying to compile a C++ program using the linux make  terminal command and ran into the following error:

> make: g++: Command not found

Or maybe the following one, depending on the Linux version and distribution you're using:

> "/bin/sh: g++: command not found"

Luckily enough, the fix is really simple: all you have to do is to install GCC, the GNU Compiler Collection package, which enables full C++ compilation support for most modern Linux distributions (here's the last changelog).

Here's the command that will solve your issue for good:

If you're not running CentOS or another yum-based distribution, you can achieve the following results

That's it for now: happy building!

Exit mobile version