Skip to content
Commit ec80b1f4 authored by Sergei Nikulov's avatar Sergei Nikulov Committed by Daniel Stenberg
Browse files

CMake: fix winsock2 detection on windows



Set CMAKE_REQUIRED_DEFINITIONS to include definitions needed to get
the winsock2 API from windows.h.  Simplify the order of checks to
avoid extra conditions.

Use check_include_file instead of check_include_file_concat to look
for OpenSSL headers.  They do not need to participate in a sequence
of dependent system headers.  Also they may cause winsock.h to be
included before ws2tcpip.h, causing the latter to not be detected
in the sequence.

Reviewed-by: default avatarBrad King <brad.king@kitware.com>
parent 676ac46f
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment