Code::Blocks Forums

User forums => Help => Topic started by: Peter_APIIT on September 28, 2009, 09:45:53 am

Title: Execution g++ Failed
Post by: Peter_APIIT on September 28, 2009, 09:45:53 am
Hello to all , i have configure the code block to use cygwin g++ 4.3.2.2 compiler but when i build a project

This error display

-------------- Build: Debug in XXX ---------------

Compiling: main.cpp
Execution of 'g++-4.exe -Wall -fexceptions  -g     -c "C:/Documents and Settings/nicholas_tse/Desktop/XXX/main.cpp" -o obj/Debug/main.o' in 'C:\Documents and Settings\nicholas_tse\Desktop\XXX' failed.
Nothing to be done.

Please help.


Thanks.
Title: Re: Execution g++ Failed
Post by: MortenMacFly on September 28, 2009, 10:38:08 am
Execution of 'g++-4.exe -Wall -fexceptions  -g     -c "C:/Documents and Settings/nicholas_tse/Desktop/XXX/main.cpp" -o obj/Debug/main.o' in
Does the file "'g++-4.exe" really exists in the path you setup in the compiler options? I've never seen g++ named that way.
Title: Re: Execution g++ Failed
Post by: stahta01 on September 28, 2009, 04:05:44 pm
Does the file "'g++-4.exe" really exists in the path you setup in the compiler options? I've never seen g++ named that way.

My CygwinPortable is named "g++-4.exe" I would guess it is a path issue. Spaces in path or something like that. I will try it right now to see if the CB Trunk works with Cygwin. Cygwin is broken sometime.

Tim S.
Title: Re: Execution g++ Failed
Post by: stahta01 on September 28, 2009, 04:35:52 pm
My PortableCygWin works with CB SVN 5824; My install path has no spaces in it. The project path also has no spaces.

Warning: The project file must be on the same drive as the source code and use relative path to source code.

NOTE: I had to remove all search directories under Code::Blocks Compiler Settings.

The "Hello World" Command line program compiles and runs.

Build Log Below
Code
g++-4.exe -Wall -fexceptions  -g     -c main.cpp -o obj/Debug/main.o
g++-4.exe  -o bin/Debug/TestCygwin.exe obj/Debug/main.o    
/usr/lib/gcc/i686-pc-cygwin/4.3.2/../../../../i686-pc-cygwin/bin/ld: warning: auto-importing has been activated without --enable-auto-import specified on the command line.
This should work unless it involves constant data structures referencing symbols from auto-imported DLLs.
Info: resolving std::cout  by linking to __imp___ZSt4cout (auto-import)
Output size is 42.37 KB
Process terminated with status 0 (0 minutes, 9 seconds)
0 errors, 1 warnings

Tim S.