Page 1 of 1

problem with Prebuild

Posted: Fri Nov 06, 2009 2:37 pm
by frank_frl
Hi Eran,

I've found a problem in the build system I think.
I seems that if you are using more then 1 concurrent job in the compiler settings, some jobs are started before pre build has finished.
I have a command line tool to increment my build number in a cpp file and to create a rc2 file with MS version information which is included in my rc file, each time I build. This tool is called in the pre build tab. To force recompiling of this files I delete the according object files. To check that my tool works well I did some output on the console.
When I use only one job that works as expected, the file is recompiled each time I build, but if I use 2 jobs It fails with a g++ error message in the middle of the output of my tool, what means that my tool hasn't finished yet when g++ is called.

1 concurrent job:

Code: Select all

----------Build Started--------
"mingw32-make.exe"  -j 1 -f "AudioMultiMeter_wsp.mk"
----------Building project:[ AudioMultiMeter - Release ]----------
Executing Pre Build commands ...
.\..\..\UpdateVersion.exe "E:\WxWindows\projects_gnu\AudioMultiMeter" MinGWRelease
SVN revision 153
Patching version_info.cpp...
Build incremented from 3533 to 3534
Creating ver.rc2...
Done
g++ -c  "E:/WxWindows/projects_gnu/AudioMultiMeter/version_info.cpp" -O3 -Wall -fno-rtti -fno-pcc-struct-return -fno-strict-aliasing.......
windres -i "E:/WxWindows/projects_gnu/AudioMultiMeter/AudioMultiMeter.rc"    -o ./MinGWRelease/AudioMultiMeter.rc.o "-IE:/wxWidgets-2.8.10/include" 
g++ -o ./MinGWRelease/PG-AMM ./MinGWRelease/audiomultimeterapp.o ./MinGWRelease/mainframe.o ./MinGWRelease/baseframe.o ./MinGWRelease/workspacehandler.o ./MinGWRelease/version_info.o.....
----------Build Ended----------
0 errors, 0 warnings
with 2 concurrent jobs:

Code: Select all

----------Build Started--------
"mingw32-make.exe"  -j 2 -f "AudioMultiMeter_wsp.mk"
----------Building project:[ AudioMultiMeter - Release ]----------
Executing Pre Build commands ...
.\..\..\UpdateVersion.exe "E:\WxWindows\projects_gnu\AudioMultiMeter" MinGWRelease
windres -i "E:/WxWindows/projects_gnu/AudioMultiMeter/AudioMultiMeter.rc"    -o ./MinGWRelease/AudioMultiMeter.rc.o "-IE:/wxWidgets-2.8.10/include" 
SVN revision 153
Patching version_info.cpp...
Build incremented from 3535 to 3536
Creating ver.rc2...
Done
g++ -o ./MinGWRelease/PG-AMM ./MinGWRelease/audiomultimeterapp.o ./MinGWRelease/mainframe.o ./MinGWRelease/baseframe.o ./MinGWRelease/workspacehandler.o ./MinGWRelease/version_info.o....
mingw32-make.exe[1]: *** [MinGWRelease/PG-AMM] Error 1
mingw32-make.exe: *** [All] Error 2
----------Build Ended----------
0 errors, 0 warnings
g++: ./MinGWRelease/version_info.o: No such file or directory
Regards,

Frank

Re: problem with Prebuild

Posted: Fri Nov 13, 2009 5:02 pm
by eranif
Fixed in trunk

Eran