在raspbian上编译pybind11测试用例时发生致命错误

时间:2020-01-28 20:57:38

标签: c++ compiler-errors raspbian pybind11

this question之后,我现在尝试按照here在Raspberry Pi上编译pybind11测试用例。到目前为止,我所做的事情:

  • the official page安装了Raspbian Raspbian Buster Lite
  • 更新/升级了所有软件包
  • 按照说明here
  • 更新/升级的python软件包
  • 按照说明here编译并安装pybind11

我的环境是:

  • Raspbian buster版本10
  • python 3.7.3
  • 点20.0.2
  • gcc 8.3.0

然后运行命令make check -j 4,编译器将在以下位置停止

[68%]构建CXX对象CmakeFiles / pybind11_tests.dir / test_numpy_dtypes.cpp.o

,错误是:

c ++:致命错误:信号终止程序cplusplus被杀死

编译终止。

make [3]:*** [CMakeFiles / pybind11_tests.dir / build.make:297:CMakeFiles / pybind11_tests.dir / test_local_bindings.cpp.o]错误1

make [3]:***等待未完成的工作...

make [2]:*** [CMakeFiles / Makefile2:110:CMakeFiles / pybind11_tests.dir / all]错误2

make [1]:*** [CMakeFiles / Makefile2:191:CMakeFile / check.dir / rule]错误2

make:*** [Makefile:157:检查]错误2

如果您能帮助我了解问题所在以及如何解决,我将不胜感激。

2 个答案:

答案 0 :(得分:1)

做更多的研究并使用the right keyword query,看来此问题与bypynd11或Raspbian无关。如之前的许多帖子所述(包括herehere),该问题似乎与内存溢出有关。解决方案可能是使用较少的并行进程-j <n>,其中n < 4,或者根本不使用建议的here。例如,我测试了

make check -j 3

,并且有效。或者,也可以按照here所述创建交换文件。

答案 1 :(得分:0)

是的,您必须创建第一个交换文件。之后,您可以执行此操作。正确地交换文件将增加您的RAM内存。它将使用rom空间来提高ram性能。

请点击下面的链接,它将为您提供帮助。

https://youtu.be/Cr5mDFxvsb0