[Groonga-commit] groonga/groonga at 88b4592 [master] windows: assume that ws2_32.lib is always available on Windows

Back to archive index

Kouhei Sutou null+****@clear*****
Mon Nov 18 12:40:40 JST 2013


Kouhei Sutou	2013-11-18 12:40:40 +0900 (Mon, 18 Nov 2013)

  New Revision: 88b45923a1bec87f9a49a0aec0353f4e711edcca
  https://github.com/groonga/groonga/commit/88b45923a1bec87f9a49a0aec0353f4e711edcca

  Message:
    windows: assume that ws2_32.lib is always available on Windows
    
    Redmine: refs #1964
    
    link.exe can't find ws2_32.lib on 64-bit Windows 8. But devenv.exe can
    find it. So we don't find ws2_32.lib. We assume that ws2_32.lib is
    always available on Windows.

  Modified files:
    CMakeLists.txt

  Modified: CMakeLists.txt (+10 -4)
===================================================================
--- CMakeLists.txt    2013-11-18 12:11:57 +0900 (32c64c9)
+++ CMakeLists.txt    2013-11-18 12:40:40 +0900 (c7a923a)
@@ -180,10 +180,16 @@ if(WIN32)
   if(NOT ${HAVE_WINSOCK2_H})
     message(FATAL_ERROR "No winsock2.h found")
   endif()
-  ac_check_lib(ws2_32 select)
-  if(NOT ${HAVE_LIBWS2_32})
-    message(FATAL_ERROR "select() isn't found in ws2_32.lib")
-  endif()
+
+  # FIXME: CMake couldn't detect ws2_32.lib on Windows 8 64bit.
+  # It may be caused by missing library search path for ws2_32.lib.
+  # It seems that Visual Studio (devenv.exe) can find it but link.exe
+  # can't. "cmake --build" can find it because it uses Visual Studio
+  # internally. So we assume that we always have ws2_32.lib on Windows.
+  # ac_check_lib(ws2_32 select)
+  set(HAVE_LIBWS2_32 TRUE)
+  set(WS2_32_LIBS "ws2_32.lib")
+
   set(USE_SELECT TRUE)
 else()
   ac_check_headers(sys/epoll.h)
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index