编译问题 Python.h no such file or directory 解决
方法一:
- 网上大部分人的方法:
sudo apt-get install python-dev
sudo apt-get install python3-dev
- 该方法对我并不适用,因为已安装,
locate Python.h
后可以看到路径:
/usr/include/python2.7/Python.h
/usr/include/python3.5m/Python.h
/usr/include/vtk-6.2/vtkPython.h
- 猜想可能没有locate到真正想要的Python.h 文件
方法二:
- 找到你 #include <Python.h>的地方,按照上图改为:
#include <python3.5m/Python.h>
,work!