]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Cleanup after ZLIB_WINAPI check
authorBrad King <brad.king@kitware.com>
Wed, 11 Jan 2012 13:15:49 +0000 (08:15 -0500)
committerBrad King <brad.king@kitware.com>
Wed, 11 Jan 2012 13:15:49 +0000 (08:15 -0500)
Clear CMAKE_REQUIRED_(INCLUDES|LIBRARIES) so that the rest of the checks
after this one do not try to link zlib.

SVN-Revision: 4133

CMakeLists.txt

index 2a313ff08ff8b76697718b13ae514319c7843b95..070def7b59b666229b569d32ad753e00b142c545 100644 (file)
@@ -181,6 +181,8 @@ IF(ZLIB_FOUND)
     CHECK_C_SOURCE_Runs(
       "#ifndef ZLIB_WINAPI\n#define ZLIB_WINAPI\n#endif\n#include <zlib.h>\nint main() {uLong f = zlibCompileFlags(); return (f&(1U<<10))?0:-1; }"
       ZLIB_WINAPI)
+    SET(CMAKE_REQUIRED_INCLUDES)
+    SET(CMAKE_REQUIRED_LIBRARIES)
   ENDIF(WIN32 AND NOT CYGWIN)
 ENDIF(ZLIB_FOUND)
 MARK_AS_ADVANCED(CLEAR ZLIB_INCLUDE_DIR)