Closed hobbes1069 closed 7 years ago
@hobbes1069 I enabled smesh testing by default, maybe this causes a compilation failure. Maybe a missing lib.
@hobbes1069 Try to force smesh testing to false -DSMESH_TESTING=OFF
Disabling testing got a good build. What library linkage is missing?
gtest is used to run the tests
@hobbes1069 I don't know exactly what happens on your machine, it's a specific linking issue that does not occur on travis osx and linux, or my mingw32 windows.
Not surprisingly I'm still seeing this in 6.7. Do you have a link handy for an automatic build I can use to compare build flags?
Thanks for your feedback @hobbes1069 What is your os/gcc version ? I did not test smesh build on linux/osx (I use to trust travis builds), I'll be back to work on August 15th, I'll try to see what's going on. I'll release an smesh 6.8 before september, I noticed another issue with oce-0.17 support.
Fedora 23 x86_64 $ gcc --version gcc (GCC) 5.3.1 20160406 (Red Hat 5.3.1-6)
Haven't tried a Rawhide build yet, it's running GCC 6.
I think i have figured out part of the problem.
The test application STL2Mesh_test is being linked prior to libStdMeshers being created. I tried adding it as a required library for STL2Mesh_test in the macro:
--- a/test/STL2Mesh_test/CMakeLists.txt
+++ b/test/STL2Mesh_test/CMakeLists.txt
@@ -5,4 +5,4 @@ configure_file( ${CMAKE_CURRENT_SOURCE_D
include_directories(${CMAKE_BINARY_DIR}/test_inc)
-add_smesh_test(STL2Mesh_test "SMESH")
+add_smesh_test(STL2Mesh_test "SMESH" StdMeshers)
But it didn't seem to get added to the linking line.
Helps if you understand how the parameters are passed to the macro :)
--- a/test/MeshBasicGeometries_test/CMakeLists.txt
+++ b/test/MeshBasicGeometries_test/CMakeLists.txt
@@ -1 +1 @@
-add_smesh_test(MeshBasicGeometries_test "TKPrim;SMESH")
+add_smesh_test(MeshBasicGeometries_test "TKPrim;SMESH;StdMeshers")
--- a/test/STL2Mesh_test/CMakeLists.txt
+++ b/test/STL2Mesh_test/CMakeLists.txt
@@ -5,4 +5,4 @@ configure_file( ${CMAKE_CURRENT_SOURCE_D
include_directories(${CMAKE_BINARY_DIR}/test_inc)
-add_smesh_test(STL2Mesh_test "SMESH")
+add_smesh_test(STL2Mesh_test "SMESH;StdMeshers")
Now everything builds but one of the tests fail...
Ping... Any help with the build dependencies? Maybe I'm running into this because of parallel build (make -jX)?
@hobbes1069 please try latest 6.7.1 release https://github.com/tpaviot/smesh/releases/tag/6.7.1
I'm not sure what different between patched 6.5.3.1 and 6.6 but I get the following error when trying to build:
CMakeFiles/MeshBasicGeometries_test.dir/MeshBasicGeometries_test.cpp.o: In function
MeshBasicGeometriesSuite_testMeshBox_Test::TestBody()': /builddir/build/BUILD/smesh-6.6/test/MeshBasicGeometries_test/MeshBasicGeometries_test.cpp:28: undefined reference toStdMeshers_AutomaticLength::StdMeshers_AutomaticLength(int, int, SMESH_Gen*)' /builddir/build/BUILD/smesh-6.6/test/MeshBasicGeometries_test/MeshBasicGeometries_test.cpp:29: undefined reference to
StdMeshers_TrianglePreference::StdMeshers_TrianglePreference(int, int, SMESHGen)' collect2: error: ld returned 1 exit status test/MeshBasicGeometries_test/CMakeFiles/MeshBasicGeometries_test.dir/build.make:132: recipe for target 'test/MeshBasicGeometries_test/MeshBasicGeometriestest' failed make[2]: Leaving directory '/builddir/build/BUILD/smesh-6.6/build' make[2]: ** [test/MeshBasicGeometries_test/MeshBasicGeometries_test] Error 1 `