From: eduardo.davila@creatis.insa-lyon.fr Date: Mon, 18 May 2026 14:56:39 +0000 (+0200) Subject: #3399 gdcm1 -> gdcm2 v3.3.0 X-Git-Url: http://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=ce03e4b2418ab026cab2f328252f55403d2cdded;p=crea.git #3399 gdcm1 -> gdcm2 v3.3.0 --- diff --git a/cmake/CREAMacro_FindAndUseLibraries.cmake b/cmake/CREAMacro_FindAndUseLibraries.cmake index 94dccc0..0b3d133 100644 --- a/cmake/CREAMacro_FindAndUseLibraries.cmake +++ b/cmake/CREAMacro_FindAndUseLibraries.cmake @@ -186,7 +186,7 @@ ENDIF(USE_ITK) #----------------------------------------------------------------------------- -IF(USE_GDCM) +IF(USE_GDCM_UPS_EED) IF (USE_GDCM2) MESSAGE(ERROR "CANNOT USE BOTH gdcm AND gdcm2 !") ENDIF (USE_GDCM2) @@ -234,7 +234,7 @@ IF(USE_GDCM) ENDIF(GDCM_FOUND) ENDIF(NOT GDCM_FOUND) -ENDIF(USE_GDCM) +ENDIF(USE_GDCM_UPS_EED) #----------------------------------------------------------------------------- @@ -242,6 +242,16 @@ IF(USE_GDCM2) IF (USE_GDCM) MESSAGE(ERROR "CANNOT USE BOTH gdcm AND gdcm2 !") ENDIF (USE_GDCM) + CREA_DEFINE( USE_GDCM2 ) +ENDIF(USE_GDCM2) + +#----------------------------------------------------------------------------- + + +IF(USE_GDCM2_UPS_EED) + IF (USE_GDCM) + MESSAGE(ERROR "CANNOT USE BOTH gdcm AND gdcm2 !") + ENDIF (USE_GDCM) # IF(NOT USE_ITK) # JPR : ITK vs GDCM (avoid cmake break) # Search GDCM2 @@ -249,7 +259,7 @@ IF(USE_GDCM2) FIND_PACKAGE(GDCM REQUIRED) INCLUDE(${GDCM_USE_FILE}) - IF(NOT ${GDCM_MAJOR_VERSION} EQUAL 2) + IF(NOT ${GDCM_MAJOR_VERSION} EQUAL 3) MESSAGE(FATAL_ERROR "gdcm version 2 needed. found ${GDCM_MAJOR_VERSION}.${GDCM_MINOR_VERSION}.${GDCM_BUILD_VERSION}. Set GDCM_DIR to the gdcm version 2 directory") ENDIF(NOT ${GDCM_MAJOR_VERSION} EQUAL 2) @@ -269,7 +279,7 @@ IF(USE_GDCM2) LINK_DIRECTORIES( ${GDCM_LIBRARY_DIRS}) SET(GDCM2_LIBRARIES - ${GDCM_LIBRARIES} + ${GDCM_LIBRARIES} ) IF(USE_GDCM_VTK) @@ -305,7 +315,7 @@ IF(USE_GDCM2) ENDIF(USE_GDCM_VTK) # ENDIF(NOT USE_ITK) # JPR : ITK vs GDCM (avoid cmake break) -ENDIF(USE_GDCM2) +ENDIF(USE_GDCM2_UPS_EED) #-----------------------------------------------------------------------------