Opened 7 years ago

Closed 7 years ago

#11365 closed Bugs (fixed)

execution_context.hpp gives errors when building with VS2015RC

Reported by: robvdnieuwenhof@… Owned by: viboes
Milestone: To Be Determined Component: context
Version: Boost 1.58.0 Severity: Problem
Keywords: Cc:

Description (last modified by viboes)

When building boost 1_58 wirh VS2015RC it gives the following errors:

Unknown compiler version - please run the configure tests and report the results
boost/context/execution_context.hpp(140): error C2492: 'boost::context::execution_context::main_ctx_': data with thread storage duration may not have dll interface
boost/context/execution_context.hpp(140): warning C4251: 'boost::context::execution_context::main_ctx_': struct 'boost::context::execution_context::fcontext' needs to have dll-interface to be used by clients of class 'boost::context::execution_context'
boost/context/execution_context.hpp(59): note: see declaration of 'boost::context::execution_context::fcontext'
boost/context/execution_context.hpp(140): error C2492: 'private: static boost::context::execution_context::fcontext boost::context::execution_context::main_ctx_': data with thread storage duration may not have dll interface
boost/context/execution_context.hpp(141): error C2492: 'boost::context::execution_context::current_ctx_': data with thread storage duration may not have dll interface
boost/context/execution_context.hpp(141): warning C4251: 'boost::context::execution_context::current_ctx_': class 'boost::intrusive_ptr<boost::context::execution_context::fcontext>' needs to have dll-interface to be used by clients of class 'boost::context::execution_context'
boost/context/execution_context.hpp(141): error C2492: 'private: static boost::intrusive_ptr<boost::context::execution_context::fcontext> boost::context::execution_context::current_ctx_': data with thread storage duration may not have dll interface
boost/context/execution_context.hpp(143): warning C4251: 'boost::context::execution_context::ptr_': class 'boost::intrusive_ptr<boost::context::execution_context::fcontext>' needs to have dll-interface to be used by clients of class 'boost::context::execution_context'

Change History (9)

comment:1 by viboes, 7 years ago

Description: modified (diff)

comment:2 by viboes, 7 years ago

Component: threadconfig
Owner: changed from Anthony Williams to John Maddock
Unknown compiler version - please run the configure tests and report the results

This is the message Boost.Config shows as error when the compiler version is not supported.

I don't know if this is a version to support. Anyway, moving the ticket to Boost.Config

comment:3 by John Maddock, 7 years ago

Component: configthread
Owner: changed from John Maddock to viboes

Sorry to ping this back to you - but the Config message is exactly that - an informative message to say you're using a version of Boost released before the compiler you're using. In point of fact we do have some VC2015 support in 1.58, but it might not be up to date with the latest VC RC (which does have a few new features I believe).

The first *error* is definitely a Boost.Thread issue.

comment:4 by John Maddock, 7 years ago

Forgot to say - we don't officially support pre-release compilers.

comment:5 by viboes, 7 years ago

Component: threadcontext

The errors are from Boost.Context :)

moving the ticket to Boost.Context in case there is something to fix there.

comment:6 by anonymous, 7 years ago

then how to solve the problem?

comment:7 by lcarreon@…, 7 years ago

FYI, this same error message is now happening with VS 2015 RTM. I hope this is being fixed in Boost 1.59.0.

comment:8 by John Maddock, 7 years ago

It appears to build fine in the master branch, so I believe this should be fixed in the next release (I haven't checked the release candidate though).

comment:9 by olli, 7 years ago

Resolution: fixed
Status: newclosed

seams to be fixed - so closed

Note: See TracTickets for help on using tickets.