CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (http://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   compiling SpalartAllmarasIDDES from 2.0.x in 1.6-ext or 1.7.x (http://www.cfd-online.com/Forums/openfoam-programming-development/90106-compiling-spalartallmarasiddes-2-0-x-1-6-ext-1-7-x.html)

gfilip June 30, 2011 13:14

compiling SpalartAllmarasIDDES from 2.0.x in 1.6-ext or 1.7.x
 
Hello,

I am trying to use the OF2.0x SpalartAllmarasIDDES version in either OF1.6-ext or OF1.7.x. I copied and renamed the 2.0.x source folder to the 1.7.x user source folder and get the following error when trying wmake libso:

Code:

wmake libso
wmakeLnInclude: linking include files to ./lnInclude
Making dependency list for source file SpalartAllmarasIDDES_OF2x/IDDESDelta/IDDESDelta.C
Making dependency list for source file SpalartAllmarasIDDES_OF2x/SpalartAllmarasIDDES_OF2x.C
SOURCE=SpalartAllmarasIDDES_OF2x/SpalartAllmarasIDDES_OF2x.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/LES/LESdeltas/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/LES/LESfilters/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/incompressible/LES/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/transportModels -I/home/software/rhel5/OpenFOAM-1.7.x/src/finiteVolume/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/meshTools/lnInclude -IlnInclude -I. -I/home/software/rhel5/OpenFOAM-1.7.x/src/OpenFOAM/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/SpalartAllmarasIDDES_OF2x.o
SOURCE=SpalartAllmarasIDDES_OF2x/IDDESDelta/IDDESDelta.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/LES/LESdeltas/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/LES/LESfilters/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/incompressible/LES/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/transportModels -I/home/software/rhel5/OpenFOAM-1.7.x/src/finiteVolume/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/meshTools/lnInclude -IlnInclude -I. -I/home/software/rhel5/OpenFOAM-1.7.x/src/OpenFOAM/lnInclude -I/home/software/rhel5/OpenFOAM-1.7.x/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/IDDESDelta.o
SpalartAllmarasIDDES_OF2x/SpalartAllmarasIDDES_OF2x.C: In constructor ‘Foam::incompressible::LESModels::SpalartAllmarasIDDES_OF2x::SpalartAllmarasIDDES_OF2x(const Foam::volVectorField&, const Foam::surfaceScalarField&, Foam::transportModel&, const Foam::word&, const Foam::word&)’:
SpalartAllmarasIDDES_OF2x/SpalartAllmarasIDDES_OF2x.C:199: error: no matching function for call to ‘Foam::incompressible::LESModels::SpalartAllmaras::SpalartAllmaras(const Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh>&, const Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh>&, Foam::transportModel&, const Foam::word&, const Foam::word&)’
/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/incompressible/LES/lnInclude/SpalartAllmaras.H:136: note: candidates are: Foam::incompressible::LESModels::SpalartAllmaras::SpalartAllmaras(const Foam::volVectorField&, const Foam::surfaceScalarField&, Foam::transportModel&, const Foam::word&)
/home/software/rhel5/OpenFOAM-1.7.x/src/turbulenceModels/incompressible/LES/lnInclude/SpalartAllmaras.H:65: note:                Foam::incompressible::LESModels::SpalartAllmaras::SpalartAllmaras(const Foam::incompressible::LESModels::SpalartAllmaras&)
make: *** [Make/linux64GccDPOpt/SpalartAllmarasIDDES_OF2x.o] Error 1

Make/files:
SpalartAllmarasIDDES_OF2x/SpalartAllmarasIDDES_OF2x.C
SpalartAllmarasIDDES_OF2x/IDDESDelta/IDDESDelta.C

LIB = $(FOAM_USER_LIBBIN)/libIDDES_OF2x

Make/options:
EXE_INC = \
-I$(LIB_SRC)/turbulenceModels \
-I$(LIB_SRC)/turbulenceModels/LES/LESdeltas/lnInclude \
-I$(LIB_SRC)/turbulenceModels/LES/LESfilters/lnInclude \
-I$(LIB_SRC)/turbulenceModels/incompressible/LES/lnInclude \
-I$(LIB_SRC)/transportModels \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude

LIB_LIBS = \
-lincompressibleTurbulenceModel \
-lLESdeltas \
-lLESfilters\
-lfiniteVolume \
-lmeshTools

I thought the "error: no matching function for call to ‘Foam::incompressible::LESModels::SpalartAllmaras: : ..." part needed the SpalartAllmaras source too, but I attempted copying it into the same folder, and adding it to the Make/files, but the same error occurs.

I feel like this might be a simple mistake somewhere.


Thanks

sleepdeprivation June 30, 2011 15:58

Have you checked your environment? It might be a linker problem.

gfilip July 1, 2011 10:30

Fixed the problem. It was a GCC issues on the cluster.

sleepdeprivation July 1, 2011 12:30

so in SpalartAllmarasIDDES_OF2x.C i changed

SpalartAllmaras(U, phi, transport, turbulenceModelName, modelName)
to
SpalartAllmaras(U, phi, transport, modelName) since the constructors are different

it compiled and ran.


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