CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Programming & Development (
-   -   OpenFoam & Eclipse (

gary7 March 16, 2012 13:02

OpenFoam & Eclipse
Hi all,

I just followed the openfoamwiki tutorial on using openfoam with eclipse, thanks to great explanation of A. Mahrla. I brought icoFoam into eclipse and could run a cavity case in there. But for debugging when I set everything up as it's described in the openfoamwiki I get the

No source available for "main() at 0x417f40"
This how I made the projects in eclipse based on the tutorial:
1. Made a project for icoFoam from its source directory under
2. Used "lnInclude" under .../src/OpenFoam/lnInclude and .../src/finiteVolume/lnInclude for header files
3. Made another project for my case which is .../incompressible/icoFoam/cavity

I did compile the openfoam with WM_COMPILE_OPTION = Debug in the bashrc and I executed Allwmake from openfoam base directory .../openfoam210/ to compile the whole package again with Debug mode which took 3 hours to compile on my machine.

Any idea where the problem lies?


gary7 March 18, 2012 18:45

Has anyone tried OpenFoam in eclipse? Can you address my problem I'd appreciate it.

akidess March 19, 2012 03:57

Are you sure icoFoam has been recompiled with the debug flag, and even more important, are you sure Eclipse is executing the correct executable? The debug executable are in a different folder than the regular ones.

gary7 March 19, 2012 12:22

Thanks Anton, well I didn't know that debug version are in a different place! because all I did was to set WM_COMPILE_OPTION=Debug in the $WM_PROJECT_DIR/etc/bashrc
and I ran Allwmake from $WM_PROJECT_DIR/applications/ which recompiled and built the code again which took a long time, is that the right thing to do? or can I just recompile the solver that I want in debug mode? :o. I looked for executables in the same place as before which is $WM_PROJECT_DIR//platforms/linux64GccDPOpt/bin/ I checked the files date and they were all made new so I assumed they are in the same place as before... :confused:

Cheers :)

akidess March 19, 2012 12:29

The debug builds will end up in linux64GccDPDebug. You could just compile the solver in debug mode by adding -g to the Make/options file of your solver. You won't be able to "see" where you are once you step into the libraries though. The thorough option is to recompile everything with the debug flag. Did you re-source the bashrc after changing it?

- Anton

All times are GMT -4. The time now is 21:10.