Author Topic: Can't find compiler executable Windows 8.1/64bit possible fix  (Read 10356 times)

Offline Urban_Hermit

  • Single posting newcomer
  • *
  • Posts: 8
  • Gaming since 1984
Can't find compiler executable Windows 8.1/64bit possible fix
« on: December 02, 2014, 12:53:44 am »
I haven't had a computer for a few months, and this week I brought a new one. The first thing I did was download Code Blocks, but when I tried to create or run an old project I got the message, "Can't find compiler executable in your configured search path for GNC/GCC". Well after several repeat downloads, and experimentation I got it to work.
I remembered I had  a windows 7/32bit laptop which didn't have "Program Files(x86)", (this is where Code Blocks was extracted and I read that apparently this destination is associated with 64bit programs), so i did the following:

1- Move the File named "CodeBlocks" from "C:\Program Files (x86)" into the normal "C;\Program Files", (I was hoping all the extracted files in the program were associated with this destination as they were unpacked).

2- Then go to the top bar, click "Settings", then "Compiler". A screen should appear saying "Global Compiler Settings." Click on "Toolchain Executables". Look at the bar in the top of the white area called "Compilers Installation Directory", look along to the far right of this bar and click "Auto Detect". The Compilers Installation Directory should now read "C:\Program Files\CodeBlocks\MinGW".

After all this the whole thing worked. I hope this helps any others that have the same problem. I dont know if it is Windows 8.1 or the fact that the computer is 64bit. I'd guess 64bit as it involves "C;\Program Files (x86)"

P.S. Anyone having problems with Kaspersky or other Antivirus Software giving false Positives. The fix I gave before is working on my new computer too. Create a partition in the hard drive and store your saved files in the partition. For whatever reason the Antivirus no longer detects the files as trojons or other types of virus/Malware.
« Last Edit: December 02, 2014, 01:05:47 am by Urban_Hermit »
Cyberbrain sclerosis:
The disease is characterized by hardening of the brain tissues precipitated by the cyberization process. As, officially, no cure exists, cyberbrain sclerosis is always fatal. Anyone that has a cyberbrain  is potentially at risk.

Offline gd_on

  • Lives here!
  • ****
  • Posts: 797
Re: Can't find compiler executable Windows 8.1/64bit possible fix
« Reply #1 on: December 02, 2014, 09:13:47 am »
I think you are on the wrong way.
C:\Program Files (x86) is for 32 bits applications on 64 bits Windows.
C:\Program Files is for 64 bits application.
Normally, Code::Blocks, as it is distributed for Windows, is a 32 bits application, so it should go in C:\Program Files (x86). If MinGW is inside the Code::Blocks folder, the compiler path should point to that folder. Like that, it should work.
On my PC, I have self compiled C::B installations, compiled in 32 bits (within C:\Program Files (x86))  and 64 bits (within C:\Program Files). And it works perfectly like that. Nevertheless, I have 32 bits compilers in C:\MinGW32 and 64 bits compiler in C:\MinGW64 (so not inside Codeblocks folders) as recommanded on TDM web site. Both version of C::B can work with both versions of compilers. 32/64 bits C::B and 32/64 bits compilers are independant. You can work with 4 different combinations.

gd_on
Windows 11 64 bits (23H2), svn C::B (last version or almost!), wxWidgets 3.2.4 (tests with 3.3), Msys2 Compilers 13.2.0, 64 bits (seh, posix : gcc, g++ and gfortran in C:\msys64\mingw64) or 32 bits (dwarf2, posix  in C:\msys64\mingw32).

Offline Urban_Hermit

  • Single posting newcomer
  • *
  • Posts: 8
  • Gaming since 1984
Re: Can't find compiler executable Windows 8.1/64bit possible fix
« Reply #2 on: December 05, 2014, 03:24:38 pm »
Thanks for the info. I'm not going to mess with mine now, it works. I haven't understood OS fully for years.
I'm sure you know a lot more about it than I do, (said with respect not sarcasm), I don't know why it worked as I said I was experimenting. It's something to try if all else has failed.
Cyberbrain sclerosis:
The disease is characterized by hardening of the brain tissues precipitated by the cyberization process. As, officially, no cure exists, cyberbrain sclerosis is always fatal. Anyone that has a cyberbrain  is potentially at risk.