【发布时间】:2017-02-10 06:18:56
【问题描述】:
尝试使用 pip + Python 3.6 在 Ubuntu 16.04 Xenial 上安装 mysqlclient 时遇到一个奇怪的错误>:
pip install mysqlclient
输出:
_mysql.c:40:20: fatal error: Python.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
按照installation requirements,我已经尝试安装所需的库,但到目前为止还没有运气。
sudo apt-get install python3-dev libmysqlclient-dev
有人知道这个问题的解决方法吗?
【问题讨论】:
标签: python ubuntu python-3.6