Search code examples
c++g++mingw

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

  • 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.