CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   Linker Problem?? (https://www.cfd-online.com/Forums/openfoam-programming-development/114987-linker-problem.html)

Peter Müller March 21, 2013 04:47

Linker Problem??
 
Hi

I created a boundary condition and was able to compile and use it with OF1.5 OF1.6 and OF2.1 but I get problems since I tried to port it to OF2.2.

I want to compile an application which is using the boundary condition that I implemented but during compilation I always get the error:

OpenFOAM-2.2.x/OpenFOAM-2.2.x/platforms/linux64GccDPOpt/lib/libMPImp.so: undefined reference to `vtable for Foam::impMPPolyPatch'

OpenFOAM-2.2.x/OpenFOAM-2.2.x/platforms/linux64GccDPOpt/lib/libMPImp.so: undefined reference to `typeinfo for Foam::impMPPolyPatch'

Does anybody have an idea why this happens?

Thanks in advance
Peter

JimKnopf March 22, 2013 12:03

Hi Peter,

your question is a bit difficult to answer.
Does your BC use the libMPImp in any way?
Did you include the correct libs in Make/option?
What is your BC doing?
Is the Bc compiled as a dynamic library or just included in the solver?

Best regards,
Jim

Peter Müller April 3, 2013 07:02

Hi Jim

I thought its a bit tricky but I could not figure out where to start since I completely did/do not understand the problem. I created a boundary condition (a mixing plane for turbomachinery) which is compiled as a shared library named libMPImp.so.
In my solver and some utilities I need to include this boundary condition. But when I tried to compile the solver/utility I always got this error.

I do not know where the error came from. Finally I cleaned my boundary to more or less empty, compiled it and also the solver and got no error. I put in the rest piece by piece and as far as I know ended up with the same as I had before removing and now it works. No idea where the problem was. Compilation issue, directory of the libMPImp.so (FOAM_LIBBIN or FOAM_USER_LIBBIN) no idea.

Thank you anyway
Peter

JimKnopf April 3, 2013 09:58

Hi Peter,

sounds a bit strange, but if it works, it works. Maybe you missed a removal of .dep files or something.

Greetz
Jim


All times are GMT -4. The time now is 00:50.