[Insight-developers] [PATCH] Send warning when ITK_DATA_ROOT is not found.
Matt McCormick (thewtex)
matt at mmmccormick.com
Fri Sep 3 10:54:34 EDT 2010
If the developer forgets to set ITK_DATA_ROOT or has not downloaded the git
submodule, ctest will start up and some XOR tests will start consuming all the
system memory.
---
CMakeLists.txt | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7ec1165..058e8e4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -629,6 +629,9 @@ ENDIF(HAVE_UNISTD_H)
#-----------------------------------------------------------------------------
# Configure the default ITK_DATA_ROOT for the location of ITK Data.
FIND_PATH(ITK_DATA_ROOT ITKData.readme ${ITK_SOURCE_DIR}/Testing/Data $ENV{ITK_DATA_ROOT})
+IF(NOT ITK_DATA_ROOT)
+ MESSAGE(WARNING "ITK_DATA_ROOT was not found. ctest will not run properly.")
+ENDIF()
MARK_AS_ADVANCED(ITK_DATA_ROOT)
#-----------------------------------------------------------------------------
--
1.7.1
More information about the Insight-developers
mailing list