The previous test does not work with ITK > 4.13 at least
mark_as_advanced(CLITK_EXPERIMENTAL)
option(CLITK_MEMORY_INFO "Enable memory info (need libstatgrab >= v.0.90)" OFF)
mark_as_advanced(CLITK_MEMORY_INFO)
+option(CLITK_EXTERNAL_GDCM "Enable features using external GDCM" OFF)
+mark_as_advanced(CLITK_EXTERNAL_GDCM)
option(CLITK_BUILD_TOOLS "Build command-line tools" OFF)
option(CLITK_BUILD_SEGMENTATION "Build command-line segmentation tools" OFF)
option(CLITK_BUILD_REGISTRATION "Build command-line registration tools" OFF)
#=========================================================
-### Check if ITK was compiled with SYSTEM_GDCM = ON
+### Check if ITK was compiled with SYSTEM_GDCM = ON (Not possible anymore with ITK 4.13)
+### Add option to activate external GDCM in clitk
set(CLITK_USE_SYSTEM_GDCM FALSE)
-# ITK4 creates a target for each gdcm library when it compiles GDCM
-get_target_property(GDCMDICTTARG gdcmDICT TYPE )
-if(NOT GDCMDICTTARG)
+if(CLITK_EXTERNAL_GDCM)
+ message("Be sure to use external GDCM with ITK")
set(CLITK_USE_SYSTEM_GDCM TRUE)
endif()