diff --git a/extern/zlib/CMakeLists.txt b/extern/zlib/CMakeLists.txt index 4aeb105..04fed5c 100644 --- a/extern/zlib/CMakeLists.txt +++ b/extern/zlib/CMakeLists.txt @@ -1,7 +1,7 @@ if (APPLE) # use toolchain zlib find_package(ZLIB REQUIRED) -set(ZLIB_LIBRARIES ZLIB::ZLIB) +set(ZLIB_LIBRARIES ZLIB::ZLIB CACHE STRING "zlib libraries" FORCE) else() if(NOT WIN32 AND NOT NX) # remove WIN32 when specter/freetype is gone find_library(ZLIB_LIB NAMES zlib z) @@ -37,11 +37,11 @@ install(TARGETS z DESTINATION lib COMPONENT zlib) else() target_compile_options(z PRIVATE -Wno-implicit-fallthrough) endif() -set(ZLIB_LIBRARIES z CACHE PATH "Zlib libraries" FORCE) -set(ZLIB_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR} CACHE PATH "Zlib include path" FORCE) +set(ZLIB_LIBRARIES z CACHE STRING "zlib libraries" FORCE) +set(ZLIB_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR} CACHE PATH "zlib include directory" FORCE) else() -set(ZLIB_LIBRARIES ${ZLIB_LIB} CACHE PATH "Zlib libraries" FORCE) +set(ZLIB_LIBRARIES ${ZLIB_LIB} CACHE PATH "zlib libraries" FORCE) find_path(ZLIB_INCLUDE_DIR zlib.h PATHS "${PNG_LIB}/../../include") message(STATUS "Using zlib at ${ZLIB_LIB}, include: ${ZLIB_INCLUDE_DIR}") endif() -endif() \ No newline at end of file +endif()