News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

Won't let me build?

Started by Skipt, August 05, 2013, 03:08:18 AM

Previous topic - Next topic

stahta01

Quote from: Skipt on August 08, 2013, 08:35:08 PM
You are correct, there is no g++ file. So what do I do? Would uninstalling and re-downloading it fix this issue?

Me, I would uninstall the MinGW in that folder. And then, setup CB to use a different MinGW this might require installing another MinGW installation.

NOTE: CB did NOT install MinGW in that folder!
So, uninstalling and re-installing CB will NOT fix the problem!!!!!

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

Skipt

So I uninstalled mingw and downloaded the file from this link (This is only thing I downloaded)

http://sourceforge.net/projects/mingw/files/MinGW/Base/gcc/Version4/gcc-4.7.2-1/

Ran a new project, I clicked ReBuild, and this comes up at the bottom, which is new



When I click over to Build Log it displays this


BlueHazzard

your compiler installation is a mess...

i would recommend you to uninstall all:
mingw
codeblocks

then search for "mingw" and delete all folders with this name (especially the folder c:\Mingw)

delete the MingW entry of your PATH environment variable:
http://www.7tutorials.com/simple-questions-what-are-environment-variables
and
http://www.7tutorials.com/how-edit-or-delete-environment-variables-windows-7-windows-8
!!! Warning !!! only edit the PATH variable, dont delete it. Push the "edit" button, search for the part with the Mingw path and delete the part between the two ";"

then download http://sourceforge.net/projects/codeblocks/files/Binaries/12.11/Windows/codeblocks-12.11mingw-setup.exe/download
and install it...
this c::b installer comes with a mingw installation...

greetings


Skipt

I uninstalled and deleted everything. THen I did the environment thing. This is what came up, I don't see a MinGW entry or anything like that so I assume it's fine. Here is a pic in case you wanted to see


Currently working on the download of C:B. 95.9 MB. I'm at 4 so far lol

Skipt

I installed it and there was a little popup in the bottom right corner of the program which read "Can't find compiler executable for GNU GCC Compiler" or something like that. I haven't figured out how to get the popups/error messages to display.

I just did a rebuild now, after seeing that message. This is the build log

"lkjk - Debug": The compiler's setup (GNU GCC Compiler) is invalid, so Code::Blocks cannot find/run the compiler.
Probably the toolchain path within the compiler options is not setup correctly?!
Goto "Settings->Compiler and debugger...->Global compiler settings->GNU GCC Compiler->Toolchain executables" and fix the compiler's setup.
Skipping...
Nothing to be done (all items are up-to-date).


I'm leaving now to go to the store, but I assume I just need to fix the path like it says? When I go to settings, there is no "Compiler and debugger" option. There is only "Compiler" and "Debugger", two seperate entities.

Screw it, I didn't wanna waste time. Ok so I went to where it said, and it had installation path at C:/MinGW, so I changed it to code blocks > MinGW and it worked! I got a rebuild successful, then I did buld and run and got hello world!

Thanks a lot everyone, it seems like it is working. You all are very patient with me. I can't thank you enough

BlueHazzard

Quote from: Skipt on August 08, 2013, 10:22:35 PM
I installed it and there was a little popup in the bottom right corner of the program which read "Can't find compiler executable for GNU GCC Compiler" or something like that. I haven't figured out how to get the popups/error messages to display.

I just did a rebuild now, after seeing that message. This is the build log

"lkjk - Debug": The compiler's setup (GNU GCC Compiler) is invalid, so Code::Blocks cannot find/run the compiler.
Probably the toolchain path within the compiler options is not setup correctly?!
Goto "Settings->Compiler and debugger...->Global compiler settings->GNU GCC Compiler->Toolchain executables" and fix the compiler's setup.
Skipping...
Nothing to be done (all items are up-to-date).



this is because you have the path to the old Mingw installation in your PATH environment variable.

Quote from: Skipt on August 08, 2013, 09:57:13 PM
I uninstalled and deleted everything. THen I did the environment thing. This is what came up, I don't see a MinGW entry or anything like that so I assume it's fine.

No this was wrong: you have to mask the Path in the "System variables" window and hit "edit" then a window pops up and there you have to search for the first Mingw path and delete it (but this was described in the links, so i want go into detail)

greetings

Skipt

Quote from: BlueHazzard on August 08, 2013, 10:31:13 PM
Quote from: Skipt on August 08, 2013, 10:22:35 PM
I installed it and there was a little popup in the bottom right corner of the program which read "Can't find compiler executable for GNU GCC Compiler" or something like that. I haven't figured out how to get the popups/error messages to display.

I just did a rebuild now, after seeing that message. This is the build log

"lkjk - Debug": The compiler's setup (GNU GCC Compiler) is invalid, so Code::Blocks cannot find/run the compiler.
Probably the toolchain path within the compiler options is not setup correctly?!
Goto "Settings->Compiler and debugger...->Global compiler settings->GNU GCC Compiler->Toolchain executables" and fix the compiler's setup.
Skipping...
Nothing to be done (all items are up-to-date).



this is because you have the path to the old Mingw installation in your PATH environment variable.

Quote from: Skipt on August 08, 2013, 09:57:13 PM
I uninstalled and deleted everything. THen I did the environment thing. This is what came up, I don't see a MinGW entry or anything like that so I assume it's fine.

No this was wrong: you have to mask the Path in the "System variables" window and hit "edit" then a window pops up and there you have to search for the first Mingw path and delete it (but this was described in the links, so i want go into detail)

greetings


Either way, I got it working with their help

riadhbh

I've got the same issue even I've installed the latest version CodeBlocks 17.12 under "C:\Program Files\CodeBlocks" , but It seems that the CodeBlocks have an issue with Windows PowerShell 2.0, that why it couldn't call  g++, gcc, gdb .. under "C:\MinGW\bin" so I've managed to uninstall it:

Control Panel->Programs and Features->Turn Windows features on or off->Windows PowerShell 2.0 (disable it).

and Its works fine for me now.