EttercapLibCheck.cmake (ettercap-0.8.3) | : | EttercapLibCheck.cmake (ettercap-0.8.3.1) | ||
---|---|---|---|---|
skipping to change at line 148 | skipping to change at line 148 | |||
set(EC_LIBS ${EC_LIBS} ${CMAKE_DL_LIBS}) | set(EC_LIBS ${EC_LIBS} ${CMAKE_DL_LIBS}) | |||
else() | else() | |||
# included in libc | # included in libc | |||
check_function_exists(dlopen HAVE_DLOPEN) | check_function_exists(dlopen HAVE_DLOPEN) | |||
if(HAVE_DLOPEN) | if(HAVE_DLOPEN) | |||
set(HAVE_PLUGINS 1) | set(HAVE_PLUGINS 1) | |||
endif() | endif() | |||
endif() | endif() | |||
endif() | endif() | |||
if(HAVE_PLUGINS) | # Fake target for curl | |||
# Fake target for curl | add_custom_target(curl) | |||
add_custom_target(curl) | ||||
# sslstrip has a requirement for libcurl >= 7.26.0 | ||||
if(SYSTEM_CURL) | ||||
message(STATUS "CURL support requested. Will look for curl >= 7.26.0") | ||||
find_package(CURL 7.26.0) | ||||
if(NOT CURL_FOUND) | # sslstrip has a requirement for libcurl >= 7.26.0 | |||
message(STATUS "Couldn't find a suitable system-provided version of | if(SYSTEM_CURL) | |||
Curl") | message(STATUS "CURL support requested. Will look for curl >= 7.26.0") | |||
endif() | find_package(CURL 7.26.0) | |||
endif() | ||||
if(BUNDLED_CURL AND (NOT CURL_FOUND)) | ||||
message(STATUS "Using bundled version of Curl") | ||||
add_subdirectory(bundled_deps/curl) # EXCLUDE_FROM_ALL) | ||||
add_dependencies(curl bundled_curl) | ||||
add_dependencies(bundled bundled_curl) | ||||
endif() | ||||
# Still haven't found curl? Bail! | ||||
if(NOT CURL_FOUND) | if(NOT CURL_FOUND) | |||
message(FATAL_ERROR "Could not find Curl!") | message(STATUS "Couldn't find a suitable system-provided version of Curl ") | |||
endif() | endif() | |||
endif() | ||||
if(BUNDLED_CURL AND (NOT CURL_FOUND)) | ||||
message(STATUS "Using bundled version of Curl") | ||||
add_subdirectory(bundled_deps/curl) # EXCLUDE_FROM_ALL) | ||||
add_dependencies(curl bundled_curl) | ||||
add_dependencies(bundled bundled_curl) | ||||
endif() | ||||
# Still haven't found curl? Bail! | ||||
if(NOT CURL_FOUND) | ||||
message(STATUS "Could not find Curl, sslstrip and curl support will be disab | ||||
led!") | ||||
endif() | endif() | |||
check_function_exists(poll HAVE_POLL) | check_function_exists(poll HAVE_POLL) | |||
check_function_exists(strtok_r HAVE_STRTOK_R) | check_function_exists(strtok_r HAVE_STRTOK_R) | |||
check_function_exists(select HAVE_SELECT) | check_function_exists(select HAVE_SELECT) | |||
check_function_exists(scandir HAVE_SCANDIR) | check_function_exists(scandir HAVE_SCANDIR) | |||
check_function_exists(strlcat HAVE_STRLCAT_FUNCTION) | check_function_exists(strlcat HAVE_STRLCAT_FUNCTION) | |||
check_function_exists(strlcpy HAVE_STRLCPY_FUNCTION) | check_function_exists(strlcpy HAVE_STRLCPY_FUNCTION) | |||
End of changes. 6 change blocks. | ||||
22 lines changed or deleted | 19 lines changed or added |