Linux platform installation package python's psutil

In the Linux platform, pip install psutil install python psutil package, the following error:

psutil/_psutil_common.c:9:20: fatal error: Python.h: No such file or directory

 

The reason is not installed python-devel (ubuntu is python-dev) package.

If you need to install python3 python3-devel, (Ubuntu is python3-dev)

After installation is complete, you can perform pip install psutil.

Guess you like

Origin www.cnblogs.com/StitchSun/p/11927877.html