当前位置:   article > 正文

#include <Python.h> compilation terminated. error: command ‘x86_64-linux-gnu-gcc‘ failed_error: command 'x86_64-linux-gnu-gcc' failed with

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

在使用cuda、torch、python编译一些库时可能出现以下问题:

#include <Python.h>    compilation terminated. error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

本质上是缺少安装的环境,故执行以下操作:

apt-get install python-dev python3-dev build-essential libssl-dev libffi-dev libxml2-dev libxslt1-dev zlib1g-dev

安装之后,发现再次运行编译的项目(比如:python setup.py install),不再报错。

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/我家小花儿/article/detail/189267?site
推荐阅读
相关标签
  

闽ICP备14008679号