thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lingfeng Zhuang <>
Subject Re: Thrift C++ on windows reports WSAPoll error
Date Thu, 03 May 2012 16:42:20 GMT
I just checked out latest code from SVN.

As README_WINDOWS said, I defined HAVE_CONFIG_H. When building, compiler

“config.h”: No such file or directory c:\thrift\lib\cpp\src\thrift\thrift.h
28 1 server

I have to change all
#include "config.h"


#include "windows/config.h"

After it, compiling succeed. But console reports the error when running.

Starting the server...
Thrift: Fri May 04 00:37:23 2012 TServerSocket::listen() socketpair() errno
= 10093
Thrift: Fri May 04 00:37:23 2012 getaddrinfo 10093: application does not
call WSAStartup, or WSAStartup failed.

It runs fine after changing TServerSocket::listen to (as Denis said)

void TServerSocket::listen() {
#ifdef _WIN32
#endif // _WIN32



On Thu, May 3, 2012 at 10:41 PM, Peace <> wrote:

> Thrift explicitly defines WSAPoll() since XP does not support that call. It
> was introduced in Vista. There was a bug in the Thrift Windows code that
> caused it to never follow the XP path to define WSAPoll(). The patch in
> THRIFT-1512 fixes this and should be available in the current Thrift 0.9
> development code on the SVN trunk.
>  ------------------------------
> *From:* Lingfeng Zhuang
> *To:*
> *Sent:* Thursday, May 3, 2012 8:25 AM
> *Subject:* Thrift C++ on windows reports WSAPoll error
>  Hi all,
> I create an empty C++ project with VS2010. Config boost and thrift
> include/lib folders. Add cpp tutorials files into
> project(CppServer.cpp, Calculator.cpp, shared_types.cpp, SharedService.cpp
> and tutorial_types.cpp)
> But when running it, it reports error "The procedure entry point WSAPoll
> could not be located in the dynamic link library WS2_32.dll"
> I tested it against both of boost 1.47 and 1.49. None of them works. My
> test environment is 32bit windows xp.
> VS project file is attached.
> Regards,
> zlf

  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message