summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2016-10-10 11:02:15 +0000
committervrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2016-10-10 11:02:15 +0000
commitd1ec002edb5b3e1d72770418e55665cca58131c9 (patch)
tree3fa1427efe533f01b41434d34e351c30fb7bb1b7
parent724b438df782cd736c1a72f64a68a6c2e8d35026 (diff)
Fix cmake issues
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/relaxed-witness@1682 636b058d-ea47-450e-bf9e-a15bfbe3eedb Former-commit-id: e2570097e2fe1091b9beb5ef7e44d6dbd01d0ced
-rw-r--r--src/Witness_complex/example/CMakeLists.txt15
-rw-r--r--src/Witness_complex/test/test_simple_witness_complex.cpp3
2 files changed, 16 insertions, 2 deletions
diff --git a/src/Witness_complex/example/CMakeLists.txt b/src/Witness_complex/example/CMakeLists.txt
index 38cfa821..848239b5 100644
--- a/src/Witness_complex/example/CMakeLists.txt
+++ b/src/Witness_complex/example/CMakeLists.txt
@@ -7,12 +7,23 @@ if(CGAL_FOUND)
if (EIGEN3_FOUND)
add_executable( Witness_complex_example_off example_witness_complex_off.cpp )
add_executable ( Witness_complex_example_sphere example_witness_complex_sphere.cpp )
+
add_executable ( Witness_complex_example_witness_persistence example_witness_complex_persistence.cpp )
target_link_libraries(Witness_complex_example_witness_persistence ${Boost_PROGRAM_OPTIONS_LIBRARY})
- add_test(Witness_complex_test_torus_persistence src/Witness_complex/example/Witness_complex_example_witncess_complex_persistence ../data/points/tore3D_1307.off -l 20 -a 0.5)
+
add_executable ( Witness_complex_example_strong_witness_persistence example_strong_witness_persistence.cpp )
target_link_libraries(Witness_complex_example_strong_witness_persistence ${Boost_PROGRAM_OPTIONS_LIBRARY})
- add_test(Witness_complex_test_torus_persistence src/Witness_complex/example/Witness_complex_example_strong_witness_persistence ../data/points/tore3D_1307.off -l 20 -a 0.5)
+ if (TBB_FOUND)
+ target_link_libraries(Witness_complex_example_witness_persistence ${TBB_LIBRARIES})
+ target_link_libraries(Witness_complex_example_strong_witness_persistence ${TBB_LIBRARIES})
+ endif()
+
+ add_test(Witness_complex_test_torus_persistence
+ ${CMAKE_CURRENT_BINARY_DIR}/Witness_complex_example_witness_persistence
+ ${CMAKE_SOURCE_DIR}/data/points/tore3D_1307.off -l 20 -a 0.5)
+ add_test(Witness_complex_test_torus_persistence
+ ${CMAKE_CURRENT_BINARY_DIR}/Witness_complex_example_strong_witness_persistence
+ ${CMAKE_SOURCE_DIR}/data/points/tore3D_1307.off -l 20 -a 0.5)
endif(EIGEN3_FOUND)
endif (NOT CGAL_VERSION VERSION_LESS 4.6.0)
endif()
diff --git a/src/Witness_complex/test/test_simple_witness_complex.cpp b/src/Witness_complex/test/test_simple_witness_complex.cpp
index abd0a0dd..759ee14d 100644
--- a/src/Witness_complex/test/test_simple_witness_complex.cpp
+++ b/src/Witness_complex/test/test_simple_witness_complex.cpp
@@ -85,10 +85,12 @@ BOOST_AUTO_TEST_CASE(simple_witness_complex) {
witnesses.end());
witness_complex.create_complex(complex, 0);
+ std::cout << "complex.num_simplices() = " << complex.num_simplices() << std::endl;
BOOST_CHECK(complex.num_simplices() == 24);
witness_complex.create_complex(relaxed_complex, 8.01);
+ std::cout << "relaxed_complex.num_simplices() = " << relaxed_complex.num_simplices() << std::endl;
BOOST_CHECK(relaxed_complex.num_simplices() == 239);
StrongWitnessComplex strong_witness_complex(landmarks.begin(),
@@ -98,6 +100,7 @@ BOOST_AUTO_TEST_CASE(simple_witness_complex) {
strong_witness_complex.create_complex(strong_relaxed_complex, 9.1);
+ std::cout << "strong_relaxed_complex.num_simplices() = " << strong_relaxed_complex.num_simplices() << std::endl;
BOOST_CHECK(strong_relaxed_complex.num_simplices() == 239);
}