Eclipse4.5.1 c++11 Operation not permitted异常解决方案

来源:互联网 发布:淘宝评价修改链接 编辑:程序博客网 时间:2024/06/12 00:26
异常信息如下:
terminate called after throwing an instance of 'std::system_error'
  what():  Enable multithreading to use std::thread: Operation not permitted


解决方案如下:
 
    右键项目:
                  Properties -> C/C++ Build -> Settings -> Tool Settings -> GCC C++ Linker -> Miscellaneous
把Linker flags文本框中写上:-Wl,--no-as-needed -pthread

大功成!!!!!!!!!!!!!!!!!!!!!!!!
0 0