aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakub Zakrzewski <jzakrzewski@e2ebridge.com>2014-08-21 13:37:07 +0200
committerDaniel Stenberg <daniel@haxx.se>2014-10-09 13:48:30 +0200
commitfc61870a1c61fecfdc9d446cbdc3e2c190a5e9e3 (patch)
tree7a289db15e68f35776f7f37d2c2cd0c5b77815a9
parentcb2438ae52ede1888d1aa512bbb169168f96c284 (diff)
Cmake: Fix library list provided to cURL tests.
The list must be set after those nice CMake tests as we mess with CMAKE_REQUIRED_LIBRARIES there.
-rw-r--r--CMakeLists.txt6
1 files changed, 3 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 694c3bc2e..fca42e042 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -367,9 +367,6 @@ check_library_exists_concat("idn" idna_to_ascii_lz HAVE_LIBIDN)
# Check for symbol dlopen (same as HAVE_LIBDL)
check_library_exists("${CURL_LIBS}" dlopen "" HAVE_DLOPEN)
-# For other tests to use the same libraries
-set(CMAKE_REQUIRED_LIBRARIES ${CURL_LIBS})
-
option(CURL_ZLIB "Set to ON to enable building cURL with zlib support." ON)
set(HAVE_LIBZ OFF)
set(HAVE_ZLIB_H OFF)
@@ -417,6 +414,9 @@ if(CMAKE_USE_LIBSSH2)
endif(LIBSSH2_FOUND)
endif(CMAKE_USE_LIBSSH2)
+# For other tests to use the same libraries
+set(CMAKE_REQUIRED_LIBRARIES ${CURL_LIBS})
+
# If we have features.h, then do the _BSD_SOURCE magic
check_include_file("features.h" HAVE_FEATURES_H)