我使用的是ubuntu 16.04和python 2.7.12。
当我试图用pip安装pycurl时,我看到下面的日志。
aaa@bbb:~/git/ccc$ sudo pip install pycurl
Downloading pycurl-7.43.0.tar.gz (182kB)
100% |████████████████████████████████| 184kB 515kB/s
Installing collected packages: pycurl
Running setup.py install for pycurl ... error
...
In file included from src/docstrings.c:4:0:
src/pycurl.h:173:30: fatal error: gnutls/gnutls.h: No such file or directory
compilation terminated.
如何使用上述日志安装pycurl?
pip install --compile --no-cache-dir --global-option="--with-gnutls" pycurl
- Lance