From c7f01157ddf50ee6f7ae8f837325e3f377f35a1b Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Sun, 12 Dec 2010 13:10:00 +0100 Subject: enforce compilation of blas unit tests when running ctest --- CMakeLists.txt | 6 +++++- blas/CMakeLists.txt | 5 +++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6f027cb44..8eee0a0eb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -294,7 +294,11 @@ add_subdirectory(unsupported) add_subdirectory(demos EXCLUDE_FROM_ALL) -add_subdirectory(blas EXCLUDE_FROM_ALL) +if(EIGEN_LEAVE_TEST_IN_ALL_TARGET) + add_subdirectory(blas) +else() + add_subdirectory(blas EXCLUDE_FROM_ALL) +endif() # must be after test and unsupported, for configuring buildtests.in add_subdirectory(scripts EXCLUDE_FROM_ALL) diff --git a/blas/CMakeLists.txt b/blas/CMakeLists.txt index 8c6792ad1..c8d5c241f 100644 --- a/blas/CMakeLists.txt +++ b/blas/CMakeLists.txt @@ -38,5 +38,10 @@ install(TARGETS eigen_blas ARCHIVE DESTINATION lib) +if(EIGEN_LEAVE_TEST_IN_ALL_TARGET) + add_subdirectory(testing) # can't do EXCLUDE_FROM_ALL here, breaks CTest +else() add_subdirectory(testing) +endif() + endif(CMAKE_Fortran_COMPILER_WORKS) -- cgit v1.2.3