Skip to content

Commit

Permalink
link to external minizip with full path
Browse files Browse the repository at this point in the history
This let's cmake create config files that allow linking to minizip even when
in an unrelated prefix. This can happen with package managers that install
every package into their own prefix, such as [Spack](https://spack.io).
  • Loading branch information
aumuell authored and kimkulling committed Nov 6, 2023
1 parent 108e319 commit a521b23
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion code/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1380,7 +1380,12 @@ ENDIF()
IF(NOT ASSIMP_HUNTER_ENABLED)
if (UNZIP_FOUND)
INCLUDE_DIRECTORIES(${UNZIP_INCLUDE_DIRS})
TARGET_LINK_LIBRARIES(assimp ${UNZIP_LIBRARIES})
# TODO if cmake required version has been updated to >3.12.0, collapse this to the second case only
if(${CMAKE_VERSION} VERSION_LESS "3.12.0")
TARGET_LINK_LIBRARIES(assimp ${UNZIP_LIBRARIES})
else()
TARGET_LINK_LIBRARIES(assimp ${UNZIP_LINK_LIBRARIES})
endif()
else ()
INCLUDE_DIRECTORIES("../")
endif ()
Expand Down

0 comments on commit a521b23

Please sign in to comment.