vcpkg/ports/assimp/fix_minizip.patch
Phoebe 73c3e33c4a [minizip assimp] export minizip cmake targets and fix minizip dependency in assimp (#9075)
* [minizip assimp] export minizip cmake targets and fix minizip dependency in assimp

* Update CMakeList.txt

* Update obsolete functions
2019-11-25 15:54:49 -08:00

33 lines
1.1 KiB
Diff

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6c3d03e..4cb6927 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -470,12 +470,12 @@ ENDIF(HUNTER_ENABLED)
IF( NOT IOS )
IF( NOT ASSIMP_BUILD_MINIZIP )
- use_pkgconfig(UNZIP minizip)
+ find_package(minizip CONFIG REQUIRED)
ENDIF( NOT ASSIMP_BUILD_MINIZIP )
ELSE ( NOT IOS )
IF( NOT BUILD_SHARED_LIBS )
IF( NOT ASSIMP_BUILD_MINIZIP )
- use_pkgconfig(UNZIP minizip)
+ find_package(minizip CONFIG REQUIRED)
ENDIF( NOT ASSIMP_BUILD_MINIZIP )
ENDIF ( NOT BUILD_SHARED_LIBS )
ENDIF ( NOT IOS )
diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt
index 55538d9..30568ff 100644
--- a/code/CMakeLists.txt
+++ b/code/CMakeLists.txt
@@ -1125,7 +1125,7 @@ IF(HUNTER_ENABLED)
zip::zip
)
ELSE(HUNTER_ENABLED)
- TARGET_LINK_LIBRARIES(assimp ${ZLIB_LIBRARIES} ${OPENDDL_PARSER_LIBRARIES} ${IRRXML_LIBRARY} )
+ TARGET_LINK_LIBRARIES(assimp ${ZLIB_LIBRARIES} ${OPENDDL_PARSER_LIBRARIES} ${IRRXML_LIBRARY} minizip::minizip)
ENDIF(HUNTER_ENABLED)
if(ASSIMP_ANDROID_JNIIOSYSTEM)