From e0461bbcbcae66769766ede75de735de76455e48 Mon Sep 17 00:00:00 2001 From: David Cole Date: Fri, 24 Jul 2009 16:31:33 -0400 Subject: BUG: Close endif statements with same string as if so that it still configures with CMake 2.4 -- also check for existence of FindCVS.cmake before doing find_package(CVS QUIET) also for CMake 2.4 sake... --- Tests/CMakeLists.txt | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt index e461170..9cc3824 100644 --- a/Tests/CMakeLists.txt +++ b/Tests/CMakeLists.txt @@ -39,18 +39,21 @@ IF(BUILD_TESTING) # Should tests that use CVS be run? # - find_package(CVS) set(do_cvs_tests 0) - if(CVS_EXECUTABLE) - set(do_cvs_tests 1) - endif() + if(EXISTS ${CMAKE_ROOT}/Modules/FindCVS.cmake) + find_package(CVS QUIET) + + if(CVS_EXECUTABLE) + set(do_cvs_tests 1) + endif(CVS_EXECUTABLE) + endif(EXISTS ${CMAKE_ROOT}/Modules/FindCVS.cmake) if(do_cvs_tests AND NOT UNIX) if("${CVS_EXECUTABLE}" MATCHES "cygwin") set(do_cvs_tests 0) - endif() - endif() + endif("${CVS_EXECUTABLE}" MATCHES "cygwin") + endif(do_cvs_tests AND NOT UNIX) # Should CPack tests be run? By default, yes, but... # -- cgit v0.12