Visual Studio 2015 c++/CLI boost::thread [duplicate]

人走茶凉 提交于 2019-12-06 06:05:22

I found a workaround that (at least partially) solves the above problem. I post it here, someone else might find it useful.

If the SubSystem option in Linker/System is set to Console and the Entry Point in Linker/Advanced is left blank (important!), then the crash doesn't occur and the app works. The disadvantage of this workaround is that a console window is opened alongside with the GUI application.

I personally can live with this, because my application is just a test program, but for others it might not be acceptable.

The original question remains open if someone can find a better solution.

pianoslum

You can change Properties->Linker->Advanced->Entry Point to ?mainCRTStartupStrArray@@$$FYMHP$01AP$AAVString@System@@@Z (32 bit, see https://bytes.com/topic/net/answers/642179-c-cli-winforms-app-native-static-library-singletons-cra) or

?mainCRTStartupStrArray@@$$FYMHP$01EAPE$AAVString@System@@@Z (64 bit, thanks to @Hans Passant, who answered my question Entry point for C++/CLI x64 WindowsForms App (VS 2015))

Then the application should start normally.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!