zlib 1.2.3.9
This commit is contained in:
@@ -50,7 +50,7 @@ endif()
|
||||
#
|
||||
# Check for unistd.h
|
||||
#
|
||||
check_include_file(unistd.h HAVE_UNISTD_H)
|
||||
check_include_file(unistd.h Z_HAVE_UNISTD_H)
|
||||
|
||||
#
|
||||
# Check for errno.h
|
||||
@@ -65,6 +65,21 @@ if(MSVC)
|
||||
add_definitions(-D_CRT_NONSTDC_NO_DEPRECATE)
|
||||
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(FATAL_ERROR "You must remove zconf.h from the source tree. This f
|
||||
ile is generated by the ./configure script shipped with zlib. CMake generates t
|
||||
his file for you automatically in the build directory")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/zconf.h.in
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/zconf.h @ONLY)
|
||||
include_directories(${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
|
||||
#============================================================================
|
||||
# zlib
|
||||
#============================================================================
|
||||
@@ -90,7 +105,6 @@ set(ZLIB_SRCS
|
||||
crc32.c
|
||||
deflate.c
|
||||
gzclose.c
|
||||
gzio.c
|
||||
gzlib.c
|
||||
gzread.c
|
||||
gzwrite.c
|
||||
|
||||
Reference in New Issue
Block a user