cfdem solver link error

Submitted by sbateman on
cgoniva

Hi!

Thanks for reporting that! For some reason some people need this setting?
For most 2.1.x installations it works perfectly fine...

Cheers,
Chris

Thu, 2 Aug 2012 - 08:49 Permalink
sbateman

In reply to by anonymous_stub (not verified)

It might have something to do with Mac OS X, and using .dylib linking instead of .so linking. But that's just a guess; I'm not familiar with the details.

Thu, 2 Aug 2012 - 17:41 Permalink
qzt

In reply to by anonymous_stub (not verified)

I confirm this, adding -lincompressibleTurbulenceModel to the options files of every solvers does get rid of the error when compiling CFDEM on mac.

Thu, 6 Sep 2012 - 14:57 Permalink

When compiling any of the cfdem solvers (cfdemSolverIB, cfdemSolverPiso, cfdemSolverPisoScalar), I get this error:


g++-mp-4.6 -m64 -fsignaling-nans -ftrapping-math -DdarwinIntel64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O2 -DNoRepository -ftemplate-depth-100 -I/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/src/turbulenceModels/incompressible/turbulenceModel -I/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/src/transportModels -I/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/src/transportModels/incompressible/singlePhaseTransportModel -I/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/src/finiteVolume/lnInclude -I/Users/sbateman/projects/lammps/cfdem-git/src/lagrangian/cfdemParticle/lnInclude -I/Users/sbateman/projects/lammps/cfdem-git/src/lagrangian/cfdemParticle/cfdTools -IlnInclude -I. -I/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/src/OpenFOAM/lnInclude -I/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/src/OSspecific/POSIX/lnInclude -fPIC -Ddarwin -lpthread -L/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/platforms/darwinIntel64Gcc46DPOpt/lib/openmpi-system -lPstream Make/darwinIntel64Gcc46DPOpt/cfdemSolverPiso.o -L/Users/sbateman/OpenFOAM/OpenFOAM-2.1.1/platforms/darwinIntel64Gcc46DPOpt/lib \
-L/Users/sbateman/OpenFOAM/sbateman-2.1.1/platforms/darwinIntel64Gcc46DPOpt/lib -lincompressibleRASModels -lincompressibleLESModels -lincompressibleTransportModels -lfiniteVolume -llagrangianCFDEM-PUBLIC-2.1.1 -lOpenFOAM -ldl -lpthread -lm -o /Users/sbateman/OpenFOAM/sbateman-2.1.1/platforms/darwinIntel64Gcc46DPOpt/bin/cfdemSolverPiso
Undefined symbols for architecture x86_64:
"Foam::incompressible::turbulenceModel::typeName", referenced from:
_main in cfdemSolverPiso.o
"Foam::incompressible::turbulenceModel::New(Foam::GeometricField, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField const&, Foam::transportModel&, Foam::word const&)", referenced from:
_main in cfdemSolverPiso.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [/Users/sbateman/OpenFOAM/sbateman-2.1.1/platforms/darwinIntel64Gcc46DPOpt/bin/cfdemSolverPiso] Error 1

Adding -lincompressibleTurbulenceModel to Make/options resolves this error. I think this has been brought up on the forum before, but it hasn't been added to the git repository for some reason.

I am using Mac OS X 10.6.8 with Macports, gcc 4.6.3, OpenFOAM 2.1.1, LIGGGHTS 2.0.4, and CFDEMcoupling 2.4.4.