Skip to content

Commit 2e3744f

Browse files
committed
ENH: Set plural library variables for GDCM system deps
GDCM's CMakeLists.txt guards find_package() calls with checks on ZLIB_LIBRARIES and EXPAT_LIBRARIES (plural forms). Set these from ITK's bundled library targets so the guards work correctly.
1 parent 1bc4436 commit 2e3744f

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

Modules/ThirdParty/GDCM/src/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ set(GDCM_BUILD_TESTING_DEFAULT OFF)
3434
set(GDCM_USE_SYSTEM_EXPAT ON CACHE INTERNAL "")
3535
set(EXPAT_INCLUDE_DIR ${ITKExpat_INCLUDE_DIRS})
3636
set(EXPAT_LIBRARY ${ITKExpat_LIBRARIES})
37+
set(EXPAT_LIBRARIES ${ITKExpat_LIBRARIES})
3738
# OpenJPEG:
3839
set(GDCM_USE_SYSTEM_OPENJPEG ON CACHE INTERNAL "")
3940
set(GDCM_USE_OPENJPEG_V2 ON CACHE INTERNAL "")
@@ -42,7 +43,9 @@ set(OPENJPEG_LIBRARIES "ITK::ITKOpenJPEGModule")
4243
# ZLIB:
4344
set(GDCM_USE_SYSTEM_ZLIB ON CACHE INTERNAL "")
4445
set(ZLIB_INCLUDE_DIR ${ITKZLIB_INCLUDE_DIRS})
46+
set(ZLIB_INCLUDE_DIRS ${ITKZLIB_INCLUDE_DIRS})
4547
set(ZLIB_LIBRARY ${ITKZLIB_LIBRARIES})
48+
set(ZLIB_LIBRARIES ${ITKZLIB_LIBRARIES})
4649

4750
# Configure GDCM privately so its options do not appear to the user.
4851
set(GDCM_LEGACY_REMOVE OFF CACHE INTERNAL "Remove all legacy code completely.")

0 commit comments

Comments
 (0)