CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Compiling turbulenceModels (http://www.cfd-online.com/Forums/openfoam-solving/60177-compiling-turbulencemodels.html)

kumar2 June 8, 2006 00:28

Hello dear friends I want t
 
Hello dear friends

I want to modify the SpalartAllmaras turbulence model. i thought i will add this to the library of turbulence models. But before i got into any trouble i wanted to check how the turbulence models that i downloaded from openFoam website behaved during wmake. ( this is version 1.2) BUT THE PROBLEM IS I AM GETTING ERRORS WHEN I WMAKE THIS from /src/turbulenceModel/incompressible

error
---[yoshikiy@kai incompressible]$ wmake
make: Nothing to be done for `allFiles'.
make: `Make/linuxAMD64Gcc4Opt/dependencies' is up to date.

/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/wmake/bashScripts/mkObjectDir OpenFOAM.out
g++ -m64 -DlinuxAMD64 -Wall -W -Wno-unused-parameter -Wold-style-cast -march=opteron -O3 -ffast-math -DNoRepository -ftemplate-depth-30 -I/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/src/cfdTools/general/lnInclude -I/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/src/cfdTools/general/wallDist -I/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/src/meshTools/lnInclude -I/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/src/transportModels -I/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/src/OpenFOAM/lnInclude -IlnInclude -I. -fPIC Make/linuxAMD64Gcc4Opt/turbulenceModel.o Make/linuxAMD64Gcc4Opt/newTurbulenceModel.o -L/home/yoshikiy/OpenFOAM/OpenFOAM-1.2/lib/linuxAMD64Gcc4Opt \
-lOpenFOAM -lm -o OpenFOAM.out
/usr/lib/../lib64/crt1.o(.text+0x20): In function `_start':
: undefined reference to `main'
Make/linuxAMD64Gcc4Opt/turbulenceModel.o(.text+0xed1): In function `Foam::turbulenceModel::~turbulenceModel()':
turbulenceModel.C: undefined reference to `Foam::nearWallDist::~nearWallDist()'
Make/linuxAMD64Gcc4Opt/turbulenceModel.o(.text+0x13b1): In function `Foam::turbulenceModel::~turbulenceModel()':
turbulenceModel.C: undefined reference to `Foam::nearWallDist::~nearWallDist()'
Make/linuxAMD64Gcc4Opt/turbulenceModel.o(.text+0x1881): In function `Foam::turbulenceModel::~turbulenceModel()':
turbulenceModel.C: undefined reference to `Foam::nearWallDist::~nearWallDist()'
Make/linuxAMD64Gcc4Opt/turbulenceModel.o(.text+0x2aa8): In function `Foam::turbulenceModel::turbulenceModel(Foam::word const&, Foam::GeometricField<foam::vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double,> const&, Foam::transportModel&)':
turbulenceModel.C: undefined reference to `Foam::nearWallDist::nearWallDist(Foam::fvMesh const&)'
Make/linuxAMD64Gcc4Opt/turbulenceModel.o(.text+0x3308): In function `Foam::turbulenceModel::turbulenceModel(Foam::word const&, Foam::GeometricField<foam::vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double,> const&, Foam::transportModel&)':
turbulenceModel.C: undefined reference to `Foam::nearWallDist::nearWallDist(Foam::fvMesh const&)'
Make/linuxAMD64Gcc4Opt/turbulenceModel.o(.text+0x7a): In function `Foam::turbulenceModel::correct()':
turbulenceModel.C: undefined reference to `Foam::nearWallDist::correct()'
collect2: ld returned 1 exit status
make: *** [OpenFOAM.out] Error 1
---

////////////END OF ERROR///////////////

The problem seems to be with nearWallDist. But i have made sure this file is available by copying this file ( both .H & .C ) into the /turbulenceModel . Also i have rechecked the options file in /Make and that also looks good. i wonder what the problem is.

Please help me.

Thanks

Kumar

mattijs June 8, 2006 04:03

Use 'wmake libso' when compili
 
Use 'wmake libso' when compiling a library (creating a .so). Use 'wmake' when compiling an application (creating an executable).

See the 'Allwmake' script in the directory or one up.

kumar2 June 8, 2006 06:15

Hi Mattijis Thanks a lot fo
 
Hi Mattijis

Thanks a lot for the info. I am able to make the new library now.

Regards

kumar


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