'gcc: cannot execute 'cc1plus'

I have just downloaded the C++ compiler MinGW, checked everything in the MinGW Installation Manager, and put the \bin location. But when I test the compiler in one of my C++ compilers, I get the following error:

gcc: fatal error: cannot execute 'cc1plus': CreateProcess: No such file or directory
compilation terminated.

I would appreciate it if I would get an idea on how to fix the compiler!



Solution 1:[1]

Install gcc-c++ or g++, and then set the environment variable. You can also run g++ -v to check whether g++ was installed correctly or not.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1