--- a/library/CMakeLists.txt
+++ b/library/CMakeLists.txt
@@ -119,7 +119,7 @@
 endif(CMAKE_COMPILER_IS_CLANG)
 
 if(WIN32)
-    set(libs ${libs} ws2_32)
+    set(libs ${libs} ws2_32 winpthread)
 endif(WIN32)
 
 if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
