Quote:
|
I also obtained several errors with "could not be resolved". I have spend my whole day trying to fix it without success. Are there some progress?
Thank you. |
Hi all,
i tried to figure out the problem of the non resolved problem. Still no solution! |
reg. "Symbol cannot be resolved" error
Hi,
The problem is that Eclipse does not read the header files without the Code:
#ifndef A Work Around : Create a project and then click open file. Open the .C file which is not in the project directory. Now all problems will be resolved. As you can see, i created a project with icoDymFoam.C and opened LaplacianFoam.C ...... Even the auto complete function works!:D https://lh5.googleusercontent.com/-2...Screenshot.jpg |
I have just tried this solution and actually works in the sense that no warning appears within the source.
But I am afraid that in this case will not be possible to compile the code. Moreover in my case the auto complete function did not work. |
Hi Alessandro,
I am familiar neither with openfoam nor eclipse. :( And yes, it cannot be compiled when it is not in the workspace. But when i can open like that, it is very much easier for me to edit it, use autocomplete (in mine it works as shown), double-click on a class and open the file it was declared etc. After editing it in eclipse comfortably, i wmake it from terminal. :rolleyes: Please do tell if you find any other solution! Dheepan |
Quote:
I must check why in my case autocomplete does not work. Which is your eclipse version? Mine is Indigo. Anyway in my case, the auto complete function and search for declaration file works only for the function directly imported with #include. All you have to do is to add manually to the search path the directory containing the included header. Cheers Alessandro |
Hi all,
Im using
I can't seem to do code completion or resolve errors that should be fine since the headers are in my include path. If this is an issue with #ifndef, then how can Eclipse get around its own addition of #ifndef to classes defined in Eclipse? i went through the documents on the wiki....but maybe they are outdated with a new version of Eclipse? Anyone experiencing the same thing? |
It seems that everyone has the same issue.
Anyway, may I ask you if you are able to perform the step by step debug? I tried a lot but at the end I had to give up :( Thanks Alessandro |
Quote:
|
That is a nice temptation... if you manage to do it let's us know the result:D
|
something new here plus Allwmake problem fix
hello,
are there any new ideas about fixing this issue with eclipse? code competion and classbrowser would really be nice.... I tried older versions until eclipse helios, without real success (ubuntu 12.04). Anyway, I also had a problem getting "Allwmake" to run properly (not found-in-Path-error) in eclipse after defining a make-target like explained in the eclipse-foam tutorial. To get the "Allwmake" as make-target run in eclipse try following procedure: properties->c/c++ build ->environment. set PATH variable append a variable to native environment ${ProjDirPath} from variable dropdown list. Now all compilation outputs are passed to eclipse-console (works in helios, but i expect the same for juno) thx dirk |
to follow up, the problem is somehow related to the eclipse indexer which cannot resolve symbols, methods etc from header files. See eg
http://www.eclipse.org/forums/index.php/m/733997/ I tried on eclipse indigo to play around with the properties->c/c++general->Indexer->files to index up-front and added headerfiles here by tracing back in the definitions. This feature does not exist in latest release (juno) because it was only a workaround in the former versions. I could omit many of these "symbol not found remarks", but unfortunately not all. |
Hi,
I am also having problems with using wmake, I always get the two warnings, and an error at the end, saying that ld returned a satus of 1, so the application could not be compield: /usr/bin/ld: warning: libPstream.so, needed by /home/niko/OpenFOAM/OpenFOAM-2.1.1/platforms/linux64GccDPOpt/lib/libOpenFOAM.so, not found (try using -rpath or -rpath-link) and /usr/bin/ld: warning: libfileFormats.so, needed by /home/niko/OpenFOAM/OpenFOAM-2.1.1/platforms/linux64GccDPOpt/lib/libtriSurface.so, not found (try using -rpath or -rpath-link) even though I tried to follow the tutorial, and setting up wmake like described. The compilation using wmake in the console is working just fine. Does any one know how to fix this? |
Problem with eclipse indexer solved
The problem with 'scalar' can be solved by adding the variable WM_DP to Properties for (Project) -> Paths and Symbols. Set it to any value, e.g. 1, for the C++ compiler (actully I added it to all configurations and all languages). I guess if you compile OpenFOAM with single precision, you should add the variable WM_SP instead. I didn't find a place in the OpenFOAM source code, where these variables are set, so I guess it is done by wmake somewhere (perhaps related to the environment variable WM_PRECISION_OPTION).
Quote:
|
1 Attachment(s)
Hi all,
I am back in programming with eclipse and OpenFOAM. At the moment I rebuild a thermodynamic model for using it in 2.2.x All variables are resolved and everything is working fine. |
Hello Tobi,
sometimes I also got all the classes resolved, but I am not able to understand why it does not works always. Does it is always reproducible for you? Thanks |
Quote:
|
Hi all,
hmmm,... I am not sure why everything is working there. 1. I copied the thermodynamic files into $FOAM_RUN/../developement/thermodynamics/ 2. I added all the paths (lnInclude) from the Make Files into eclipse 3. finished. At the moment I am not building any stuff so I can not say if everything is resolved all the time. |
I had just opened a new thread about this issue of OF+eclipse, as it seems that information is a bit outdated. The thread can be found here :
http://www.cfd-online.com/Forums/ope...se-kepler.html ================================================== ========== Hi everybody, New to OpenFoam, I'm trying to set up a development environment using Eclipse (Kepler version) and OpenFoam 2.2.2. I have tried many options and also tried to follow the tutorial at http://openfoamwiki.net/index.php/Ho...M_with_Eclipse but was not really successful in having Eclipse to be correctly able to edit OF files. Instructions on the OF Wiki might be out dated with regards to OF 2.X and latest Eclipse versions. The problem are many "symbol 'XXX' could not be resolved" in some (but not all) source files. I have tried to import subdirectories or complete OF root, as an Eclipse C++ project. I have tried to add Symbols (like WM_DP for instance) in the project <Properties> under <C/C++ General>/<Paths and Symbols>/<#Symbols> menu. I have tried to add all or only some lnInclude directories under <C/C++ General>/<Paths and Symbols>/<Includes> menu. None of these worked. It seems Eclipse get lost in indexing the project. Anybody has succeeded in having OF 2.X handled correctly under Eclipse ? Regards Lionel |
Lionel, make sure you complete the following step and wait for the indexer to reach 100% (bottom right of eclipse window)
Quote:
These two steps worked for me. -Louis |
i managed to compile the application with eclipse
but the i get a lot of errors: type <scalar> could not be resolved i tried to add the variable WM_DP in path and symbols/ includes but there is now variable WM_DP where i have to define the variable? best regards Henning |
Dear Henning,
If I remember correctly, you have to create the variable yourself. -Louis |
Debugger jump to wrong line
Dear Foamer,
I would like to step through the source of my own solver and OpenFoam 2.1 . I hope you have some hints for me what to do. I have the following problems with Eclipse: 1) I have to click on the step-over button several times to execute the highlighted line and to jump to the next line. Thereby the debugger jumps often to the wrong line such as a comment line. 2) When the debugger executes a method, the Variable-View will be also refreshed in such a way that for a few minutes the GDB activity is at 100%. I use: OpenFoam 2.1 GDB version 7.6 Eclipse Kepler Ubuntu 12.04 |
Hi all,
I have a problem similar to the last post, only using Ubuntu 14.04. The debugger gets stuck in my case on the first line, when progressing gdb starts running with occupying 1 core at 100%. However it never finishes executing the statement and crashes eventually (after 20 minutes). Given it is very difficult by now to downgrade GDB to 6.x (the crash appears to happen only with GDB 7.x) currently it's not possible to debug openFOAM with Eclipse. Any help on this issue would be greatly appreciated. Currently I'm circumventing the issue by using QtCreator instead of Eclipse, which doesn't seem to have this problem. |
some problem
Hi,
i want to debug icoFoam solver, but i have some problem: after creating a c++ project and importing an icoFoam directory, i've tried to add all includes to the project (properties--> c++ general --> path and symbols). I think that i should include all the includes according to Make/options file. Am i correct ? After that, a lot of errors appeares in Problems window, like "symbol 'mesh' could not be resolved". So how to compile and debug with this problem ? ... __ P.S. I have never used Eclipse before. |
Eclipse 3.6.1
Hi,
I am new to OpenFOAM and eclipse. I am currently using OpenFOAM-2.3.x and eclipse 3.6.1 (Scientific Linux 6, KD Environment). I am using sprayFOAM for my work and I used the tutorial as mentioned in some of the posts above
" /home12233/tariq/OpenFOAM/tariq-2.3.x/platforms/linux64GccDPOpt/bin/mysprayFoam: error while loading shared libraries: libfiniteVolume.so: cannot open shared object file: No such file or directory" and in the problems tab of eclipse, " Invalid project path: Duplicate path entries found (/mysprayFoam [Include path] isSystemInclude:true includePath:/usr/local/intel/composer_xe_2013.4.183/mkl/include), path: [/mysprayFoam]. " The eclipse is able to build the project but not run the project **** Build of configuration Debug for project mysprayFoam **** /home12233/tariq/OpenFOAM/OpenFOAM-2.3.x/bin/foamExec wmake all + wmake make: `/home12233/tariq/OpenFOAM/tariq-2.3.x/platforms/linux64GccDPOpt/bin/mysprayFoam' is up to date. + wmake sprayEngineFoam make: `/home12233/tariq/OpenFOAM/OpenFOAM-2.3.x/platforms/linux64GccDPOpt/bin/sprayEngineFoam' is up to date. I am able to run my case from the konsole terminal but not the eclipse. The eclipse is able to update the libraries but not run the project. Many people posted the above error but no solution to this problem was given. It will be helpful if someone is able to guide me through this. |
Hi Tariq,
Regarding your error in libfiniteVolume.so, it is most likely caused by Eclipse not having the right environment variables set. Perhaps you could try starting a terminal, sourcing the etc/bashrc file in the OpenFOAM folder, and then launching Eclipse from that same terminal? That worked for me. Kind regards, Jeroen |
Eclipse 3.6.1 works
Quote:
Regards, tariq |
'scalar' and 'label' are not recognized in NetBeans
Quote:
If you are using the NetBean as a code editor and use the wmake command on ur Linux terminal to compile your code, those errors actually don't produce any problem in the compilation process. However, if you want to get away from those errors you can define the 'scalar' as a 'double' value by the typedef syntax as follows inside the definition of your class contained in the *.H files. I have also included a similar solution for 'label' types in OpenFOAM using 'int' type, they are also not recognized by NetBeans usually. Code:
|
All times are GMT -4. The time now is 20:11. |