bug
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
#include "Python.h"
^~~~~~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Command "/home/python/.virtualenvs/py3_flask/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-icyoxyvz/mysqlclient/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-woj3ol_8/install-record.txt --single-version-externally-managed --compile --install-headers /home/python/.virtualenvs/py3_flask/include/site/python3.6/mysqlclient" failed with error code 1 in /tmp/pip-install-icyoxyvz/mysqlclient/
解决办法:
for scrapy with Python 3, you’ll need
sudo apt-get install python3 python-dev python3-dev \
build-essential libssl-dev libffi-dev \
libxml2-dev libxslt1-dev zlib1g-dev \
python-pip
with Python 2, you’ll need
sudo apt-get install python-dev \
build-essential libssl-dev libffi-dev \
libxml2-dev libxslt1-dev zlib1g-dev \
python-pip