mirror of
https://github.com/mkxp-z/mkxp-z.git
synced 2025-08-23 15:23:44 +02:00
22 lines
1,004 B
Diff
22 lines
1,004 B
Diff
# Prevents zlib's build system from renaming zconf.h to zconf.h.included because libzip won't be able to find zconf.h otherwise.
|
|
|
|
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -65,17 +65,6 @@ if(MSVC)
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
|
endif()
|
|
|
|
-if(NOT CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_CURRENT_BINARY_DIR)
|
|
- # If we're doing an out of source build and the user has a zconf.h
|
|
- # in their source tree...
|
|
- if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/zconf.h)
|
|
- message(STATUS "Renaming")
|
|
- message(STATUS " ${CMAKE_CURRENT_SOURCE_DIR}/zconf.h")
|
|
- message(STATUS "to 'zconf.h.included' because this file is included with zlib")
|
|
- message(STATUS "but CMake generates it automatically in the build directory.")
|
|
- file(RENAME ${CMAKE_CURRENT_SOURCE_DIR}/zconf.h ${CMAKE_CURRENT_SOURCE_DIR}/zconf.h.included)
|
|
- endif()
|
|
-endif()
|
|
|
|
set(ZLIB_PC ${CMAKE_CURRENT_BINARY_DIR}/zlib.pc)
|
|
configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/zlib.pc.cmakein
|