相关疑难解决方法(0)

Raspberry Pi工具链上的std :: shared_future

我正在尝试为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工具链中的错误吗?有解决方法吗?如何才能成功编译?

c++ cross-compiling c++11 raspberry-pi

5
推荐指数
1
解决办法
653
查看次数

标签 统计

c++ ×1

c++11 ×1

cross-compiling ×1

raspberry-pi ×1