diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt index a88d8f37..f545d581 100644 --- a/cmake/CMakeLists.txt +++ b/cmake/CMakeLists.txt @@ -98,8 +98,9 @@ find_program(UNZIP unzip) find_program(XZ xz) find_program(ZIP zip) +include(CheckIncludeFile) + if(BZIP2_FOUND) - include(CheckIncludeFile) set(CMAKE_REQUIRED_INCLUDES ${BZIP2_INCLUDE_DIRS}) check_include_file(bzlib.h HAVE_BZLIB_H) unset(CMAKE_REQUIRED_INCLUDES) @@ -182,7 +183,6 @@ endif() set(DEFINE_GD_GETDATA_INT_VERSION "#define GD_GETDATA_INT_VERSION ${GETDATA_INT_VERSION}") # Platform-independent configuration checks -include(CheckIncludeFile) include(CheckSymbolExists) include(CheckTypeSize) include(CheckFunctionExists)