Search code examples
boostvisual-studio-2008

Cant compile Boost C++ Network Library 0.5


Boost Network

I am trying out this code in a small console app on windows (VS2008) but cant compile it. Have linked to the boost.system library. Am i missing a header, #define or another library?

Headers

#include <boost/network/protocol/http/client.hpp>
#include <iostream>

Errors

using native typeof
1>c:\dev\3rdparty\boostproposed\cpp-netlib-0.5\boost\network\uri\http\detail\parse_specific.hpp(74) : error C2065: 'not' : undeclared identifier
1>c:\dev\3rdparty\boostproposed\cpp-netlib-0.5\boost\network\uri\http\detail\parse_specific.hpp(74) : error C2143: syntax error : missing ')' before 'iequals'
1>c:\dev\3rdparty\boostproposed\cpp-netlib-0.5\boost\network\uri\http\detail\parse_specific.hpp(74) : error C2059: syntax error : ')'

Solution

  • This is a problem with a missing include inside the library itself. There are plenty of other compilation issues with cpp-netlib 0.5 on Windows so I suggest you use the "bleeding edge" code, which can be found here:

    http://github.com/mikhailberis/cpp-netlib/tree/0.6-devel