You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
cpp-netlib 0.12.0 build error with visual studio 2015 and boost 1.60 #648
I don't have a solution yet because I don't have access to MSVC 2015 -- and I don't know where exactly to start here. Any tips for debugging this would be really helpful.
As a fast & dirty workaround you can change that true_type@ is_const.hpp:37 to std::true_type to avoid ambiguous declaration.
It's (almost) the same type.
@burannah That quick and dirty workaround seems to work. Thanks! @deanberris Maybe you guys can add the change in the official cpp-netlib? (See my above comment about getting VS2015 for free.)
Activity
snap9 commentedon May 6, 2016
I'm having exactly this problem.
Anyone found a solution yet?
ytong3 commentedon May 6, 2016
If you can live without 0.12, you may want to try 0.11.
Sent using Email (https://itunes.apple.com/app/apple-store/id922793622?pt=814382&ct=Email&mt=8)
deanberris commentedon May 10, 2016
I don't have a solution yet because I don't have access to MSVC 2015 -- and I don't know where exactly to start here. Any tips for debugging this would be really helpful.
snap9 commentedon May 12, 2016
@deanberris I downloaded VS2015 for free on Microsoft's page. It's right here: https://www.visualstudio.com/en-us/products/visual-studio-express-vs.aspx (I clicked on Download under "Express for Desktop").
burannah commentedon May 19, 2016
As a fast & dirty workaround you can change that
true_type@ is_const.hpp:37 tostd::true_typeto avoid ambiguous declaration.It's (almost) the same type.
snap9 commentedon May 21, 2016
@burannah That quick and dirty workaround seems to work. Thanks! @deanberris Maybe you guys can add the change in the official cpp-netlib? (See my above comment about getting VS2015 for free.)
enricodetoma commentedon Sep 27, 2016
@burannah @snap9 but is_const.hpp:37 is in Boost, not in cpp-netlib! It can't be a valid fix...
enricodetoma commentedon Sep 27, 2016
I have create pull request #685 to solve the compilation problem with Visual Studio 2015
Merge pull request #685 from enricodetoma/master
enricodetoma commentedon Oct 13, 2016
I can confirm that this issue can be closed for milestone 0.13 too.
mjfryc commentedon Nov 30, 2016
It was needed to compile
cppnetlib-server-parsers.Solution: in my case I had to modify:
[cpp-netlib-0.11.2_dir]\boost\network\protocol\http\server\impl\parsers.ippby:
BOOST_NETWORK_INLINE void parse_versionto anonymous namespace and rename it e.g. toparse_version_hack.parse_versionfunction do NOT useusing namespace boost::spirit::qi;and delegate this function to anonymous namespace function.Below example (sorry for identation lack):
`namespace
{
BOOST_NETWORK_INLINE void parse_headers_hack(
std::string const& input, std::vectorboost::network::http::request_header_narrow& container) {
using namespace boost::spirit::qi;
boost::u8_to_u32_iteratorstd::string::const_iterator begin = input.begin(), end = input.end();
typedef boost::spirit::qi::asboost::spirit::traits::u32_string as_u32_string;
parse(begin, end,
*(+((alnum | punct) - ':') >> lit(": ") >>
as_u32_string()[+((unicode::alnum | space | punct) - '\r' - '\n')] >>
lit("\r\n")) >>
lit("\r\n"),
container);
}
}
namespace boost {
namespace network {
namespace http {
BOOST_NETWORK_INLINE void parse_version(
std::string const& partial_parsed, boost::fusion::tuple<boost::uint8_t, boost::uint8_t>& version_pair)
{
boost::spirit::qi::parse
(
partial_parsed.begin(),
partial_parsed.end(),
(
boost::spirit::qi::lit("HTTP/") >> boost::spirit::qi::ushort_ >> '.' >> boost::spirit::qi::ushort_
),
version_pair
);
}`