本文最后更新于 1829 天前,其中的信息可能已经有所发展或是发生改变。
yum -y install python-devel
yum -y install python-devel
psutil/_psutil_common.c:9:20: fatal error: Python.h: No such file or directory
#include <Python.h>
^
compilation terminated.
error: command 'gcc' failed with exit status 1
出现此错误的原因是没有安装python-devel,python开发包,如果是支持yum的系统,直接yum安装即可:
yum -y install python-devel