我正在尝试为Raspberry Pi交叉编译一个大型项目.我正在使用由crosstool-ng,gcc版本4.7.3构建的工具链.当编译看到std :: shared_future时,编译会产生阻塞.我收到此错误:
test.cpp:5:27: error: aggregate 'std::shared_future<int> xxx' has incomplete type and cannot be defined
Run Code Online (Sandbox Code Playgroud)
这是生成该错误的源文件:
#include <future>
int main()
{
std::shared_future<int> xxx;
return 0;
}
Run Code Online (Sandbox Code Playgroud)
这个相同的源文件在Rapsberry Pi本身上成功编译.这是crosstool工具链中的错误吗?有解决方法吗?如何才能成功编译?