aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVollstrecker <werner@vollstreckernet.de>2024-12-01 11:23:35 +0100
committerMark Adler <madler@alumni.caltech.edu>2025-01-31 19:59:10 -0800
commit902f6eedf31d198dcc47abb89a99f5cead9ad6f7 (patch)
tree2ec61888f6d1e62df602384df9950b40fc168f1c
parent2b2eec69b52ae600441f6ffb2f545b7833caa842 (diff)
downloadzlib-902f6eedf31d198dcc47abb89a99f5cead9ad6f7.tar.gz
zlib-902f6eedf31d198dcc47abb89a99f5cead9ad6f7.tar.bz2
zlib-902f6eedf31d198dcc47abb89a99f5cead9ad6f7.zip
CMake: Remove checks for sys/types.h, stdint.h and stddef.h.
This is done by check_type_size.
Diffstat (limited to '')
-rw-r--r--CMakeLists.txt17
1 files changed, 1 insertions, 16 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 814df18..00fe464 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -20,26 +20,11 @@ include(CheckCSourceCompiles)
20include(GNUInstallDirs) 20include(GNUInstallDirs)
21enable_testing() 21enable_testing()
22 22
23check_include_file(sys/types.h HAVE_SYS_TYPES_H)
24check_include_file(stdint.h HAVE_STDINT_H)
25check_include_file(stddef.h HAVE_STDDEF_H)
26
27# 23#
28# Check to see if we have large file support 24# Check to see if we have large file support
29# 25#
30set(CMAKE_REQUIRED_DEFINITIONS -D_LARGEFILE64_SOURCE=1) 26set(CMAKE_REQUIRED_DEFINITIONS -D_LARGEFILE64_SOURCE=1)
31# We add these other definitions here because CheckTypeSize.cmake 27
32# in CMake 2.4.x does not automatically do so and we want
33# compatibility with CMake 2.4.x.
34if(HAVE_SYS_TYPES_H)
35 list(APPEND CMAKE_REQUIRED_DEFINITIONS -DHAVE_SYS_TYPES_H)
36endif()
37if(HAVE_STDINT_H)
38 list(APPEND CMAKE_REQUIRED_DEFINITIONS -DHAVE_STDINT_H)
39endif()
40if(HAVE_STDDEF_H)
41 list(APPEND CMAKE_REQUIRED_DEFINITIONS -DHAVE_STDDEF_H)
42endif()
43check_type_size(off64_t OFF64_T) 28check_type_size(off64_t OFF64_T)
44if(HAVE_OFF64_T) 29if(HAVE_OFF64_T)
45 add_definitions(-D_LARGEFILE64_SOURCE=1) 30 add_definitions(-D_LARGEFILE64_SOURCE=1)