OK, so I downloaded Codeblocks and I already have a cygwin terminal on my computer that I regularly use to compile and run C programs, but when I try to build a program in CodeBlocks, it gives me an error:
The compiler's setup (GNU GCC Compiler) is invalid, so Code::Blocks cannot find/run the compiler.
I don't know why it can't find my compiler or why it's looking for GNU GCC compiler when I have Cygwin GCC as the default compiler.
I faced the same problem. I have fixed out by going to Setting
-> Compiler
-> Global Compiler Settings
-> Toolchain Execuatables (tab)
. There, click on Program Files
and then rename C compiler
to gcc.exe
and C++ compiler
to g++.exe
.
I know this is an old question but let me see if I can help. First of all, on the download page make sure you downloaded codeblocks-13.12mingw-setup.exe and NOT codeblocks-13.12-setup.exe. Of course the version numbers may change but pay attention to the name. Then after installing codeblocks, go to Settings->Compiler->Toolchain executables. From here, change the C compiler to gcc.exe and C++ compiler to g++.exe. Hope this helps anyone else going through this problem :-)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With