Closed ghost closed 6 years ago
-lgtest_main
should be added. It might be gtest
version problem.
$ g++ -o bin/unittest -pthread \
> build/test/main.o build/test/test_diffusionSystem.o build/test/test_interp2d.o build/test/test_mathUtils.o build/test/tridiagonalIntegrator.o build/core/callback.os build/core/chemistry0d.os build/core/convectionSystem.os build/core/debugUtils.os build/core/diffusionSystem.os build/core/flameSolver.os build/core/grid.os build/core/integrator.os build/core/mathUtils.os build/core/perfTimer.os build/core/qssintegrator.os build/core/quasi2d.os build/core/readConfig.os build/core/scalarFunction.os build/core/sourceSystem.os build/core/splitSolver.os build/core/sundialsUtils.os \
> -Llib \
> -L/home/dic17007/share/cantera/2.4.0/gcc540a/lib -lcantera \
> -L/apps2/sundials/2.6.2/lib -lsundials_nvecserial -lsundials_ida -lsundials_cvode \
> -L/apps2/boost/1.66.0/lib -L/apps2/tbb/2017_U6/lib -ltbb \
> -L/apps2/lapack/3.8.0-gcc540a/lib64 -llapack -lblas -lgfortran \
> -L/home/dic17007/share/gtest/1.8.0/lib64 -lgtest -lgtest_main \
> -L/home/dic17007/miniconda3/lib -lpython3.6m \
# no error
modify 515th line of SConstruct
to
# testenv.Append(LIBS=['gtest']
testenv.Append(LIBS=['gtest','gtest_main']
And then the unittest is OK.
If you use the git submodule for gtest, it will provide you with gtest 1.7.0, which is the currently-supported version. You can check the submodule using git submodule update
, and then remove your local installation of gtest from the linker path.
Thank you very much for your reply. I am sorry for that I thought I have run git submodule update
.
it seems a
gtest
problem. However, the ext folder is empty. I do not know how to handle it.OS: RHEL6.8 cantera 2.4 build, test and load.
ember
test output: