CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Compile error undefined reference to

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 29, 2008, 11:46
Default Hi I am using the OpenFOAM
  #1
New Member
 
Andreas Mehrle
Join Date: Mar 2009
Posts: 3
Rep Power: 17
braveandi is on a distinguished road
Hi

I am using the OpenFOAM standard solvers for some now and did also modify them slightly and recompile. In order to understand the capabilities of OpenFOAM a little better I am about to build my own solver including lagrangian particles. But when I include some code used in "dieselSpray" or Bernhard Gschaider's "icoLagrangianFoam" I get the error message:

Make/linuxGccDPOpt/lagrangianFoam.o: In function `Foam::IOPtrList<foam::particleinjector>::type() const':
lagrangianFoam.C.text._ZNK4Foam9IOPtrListINS_16particleInjectorEE4 typeEv[Foam::IOPtrList<foam::p articleinjector>::type() const]+0x11): undefined reference to `Foam::IOPtrList<foam::particleinjector>::typeName '


when using a IOPtrList.

I did #include "IOPtrList.H" in the header file and my options file looks like

EXE_INC = \
-I$(LIB_SRC)/cfdTools/incompressible \
-I$(LIB_SRC)/cfdTools/general/lnInclude \
-I$(LIB_SRC)/OpenFOAM/lnInclude \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/lagrangian/basic/lnInclude

EXE_LIBS = \
-lfiniteVolume \
-llagrangian

what is going wrong?

Andreas
braveandi is offline   Reply With Quote

Old   March 1, 2008, 10:04
Default hi, i am not sure but as fa
  #2
Senior Member
 
Stephan Gerber
Join Date: Mar 2009
Location: Germany
Posts: 118
Rep Power: 17
stephan is on a distinguished road
hi,

i am not sure but as far as i remember the injector is part of the lagrangian/dieselspray and not of lagrangian/basic. that would explain the undef. ref. .
br
stephan
stephan is offline   Reply With Quote

Old   March 1, 2008, 12:08
Default Hi Andreas, As far as I can t
  #3
Senior Member
 
dmoroian's Avatar
 
Dragos
Join Date: Mar 2009
Posts: 648
Rep Power: 20
dmoroian is on a distinguished road
Hi Andreas,
As far as I can tell, there is a class in your code, called "particleinjector" for which I could not find any reference in OpenFOAM. Is this class developed by you?
If it is, you need to include the object particleinjector.o in your options file.

Dragos
dmoroian is offline   Reply With Quote

Old   March 3, 2008, 04:49
Default Thx As Dragos suspected "pa
  #4
New Member
 
Andreas Mehrle
Join Date: Mar 2009
Posts: 3
Rep Power: 17
braveandi is on a distinguished road
Thx

As Dragos suspected "particleInjector" is a self defined class so no need to include "lagrangian/dieselspray". So I will try to include the objectfile.

Andreas
braveandi is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Undefined reference mateusz_slowikowski OpenFOAM Running, Solving & CFD 7 February 27, 2015 15:35
Undefined reference to %60mainb seang OpenFOAM Installation 8 February 1, 2014 14:48
Undefined reference to %60yyFlexLexeryywrapb zhoubinwx OpenFOAM Bugs 1 May 28, 2008 06:57
Undefined reference mateusz_slowikowski OpenFOAM Running, Solving & CFD 3 March 11, 2008 13:19
MPICH : undefined reference to.. Vincent Siemens 3 March 24, 2005 13:30


All times are GMT -4. The time now is 09:28.