diff --git a/CMakeLists.txt b/CMakeLists.txt index 6be6fe59f..8ac710731 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -149,6 +149,13 @@ if (USE_INCLUDED_LIBZIP) endif() target_include_directories(${PROJECT_NAME} PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/libzip) + if (UNIX OR MINGW) + target_compile_options(${PROJECT_NAME} PRIVATE "-DHAVE_FSEEKO") + target_compile_options(${PROJECT_NAME} PRIVATE "-DHAVE_FTELLO") + target_compile_options(${PROJECT_NAME} PRIVATE "-DHAVE_STRCASECMP") + target_compile_options(${PROJECT_NAME} PRIVATE "-DHAVE_UNISTD_H") + endif() + else() find_package(PkgConfig REQUIRED) pkg_check_modules(LIBZIP REQUIRED libzip)