windows Fix build.

This commit is contained in:
Joakim Soderberg 2014-04-07 11:28:08 +02:00 committed by Andy Green
parent e9b61b5ba5
commit d2f5b199bc
2 changed files with 12 additions and 1 deletions

View file

@ -486,7 +486,11 @@ if (LWS_WITH_SSL)
message("OpenSSL libraries: ${OPENSSL_LIBRARIES}")
include_directories("${OPENSSL_INCLUDE_DIR}")
list(APPEND LIB_LIST ${OPENSSL_LIBRARIES} dl)
list(APPEND LIB_LIST ${OPENSSL_LIBRARIES})
# Link against dynamic linking functions.
# (Don't link directly to libdl since it is not needed on all platforms, it's now a part of libc).
list(APPEND LIB_LIST ${CMAKE_DL_LIBS})
endif()
endif(LWS_WITH_SSL)

View file

@ -82,6 +82,13 @@
#define lws_set_blocking_send(wsi) wsi->sock_send_blocking = TRUE
#include <winsock2.h>
#include <windows.h>
#include <tchar.h>
#include <mstcpip.h>
#ifndef __func__
#define __func__ __FUNCTION__
#endif
#define LWS_INVALID_FILE INVALID_HANDLE_VALUE
#else /* not windows --> */
#include <errno.h>