Skip to content

Commit cd237cb

Browse files
jamesobutlerjcfr
authored andcommitted
COMP: Update DCMTK targets based on new DCMTK namespace
Exported targets now have the DCMTK namespace as of DCMTK/dcmtk@c684bb3. Co-authored-by: Jean-Christophe Fillion-Robin <[email protected]
1 parent 4b7886a commit cd237cb

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

Modules/ThirdParty/DCMTK/CMakeLists.txt

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,14 @@ if(ITK_USE_SYSTEM_DCMTK)
9393
set(ITKDCMTK_SYSTEM_INCLUDE_DIRS ${DCMTK_INCLUDE_DIRS})
9494

9595
# Module standard library var
96-
set(ITKDCMTK_LIBRARIES ${DCMTK_LIBRARIES})
96+
set(ITKDCMTK_LIBRARIES)
97+
foreach(lib IN LISTS DCMTK_LIBRARIES)
98+
if(TARGET DCMTK::${lib})
99+
list(APPEND ITKDCMTK_LIBRARIES DCMTK::${lib})
100+
else()
101+
list(APPEND ITKDCMTK_LIBRARIES ${lib})
102+
endif()
103+
endforeach()
97104

98105
# When this module is loaded by an app, load DCMTK too.
99106
set(ITKDCMTK_EXPORT_CODE_INSTALL "

0 commit comments

Comments
 (0)