vcpkg/ports/gdcm/use-openjpeg-config.patch
Stefano Sinigardi f2e1c52db8 [gdcm,jbig2dec] move patches from #5169 (#6710)
* [gdcm,jbig2dec] minor fixes

* [libmupdf] remove wrong vs define

* [gdcm] internal libs do not export symbols and fail to build when non-static
2019-05-31 16:14:23 -07:00

17 lines
482 B
Diff

diff --git a/CMakeLists.txt b/CMakeLists.txt
index f82bfd2..a062170 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -375,7 +375,10 @@ else()
endif()
if(GDCM_USE_SYSTEM_OPENJPEG)
- find_package(OpenJPEG 2.0.0 REQUIRED)
+ find_package(OpenJPEG REQUIRED)
+ if(OPENJPEG_MAJOR_VERSION VERSION_LESS 2)
+ message( FATAL_ERROR "You need at least OpenJPEG 2")
+ endif()
set(GDCM_OPENJPEG_LIBRARIES ${OPENJPEG_LIBRARIES})
else()
set(GDCM_OPENJPEG_LIBRARIES gdcmopenjp2)