推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
itlynn
V2EX  ›  Python

求助下 Ubuntu 15.10(64 位)下安装 pyspider 下的问题

  •  
  •   itlynn · May 18, 2016 · 3787 views
    This topic created in 3661 days ago, the information mentioned may be changed or developed.

    环境: Ubuntu 15.10(64 位) pip install pyspider 出现如下错误(部分):

    Using curl-config (libcurl 7.43.0)
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-2.7
    creating build/lib.linux-x86_64-2.7/curl
    copying python/curl/__init__.py -> build/lib.linux-x86_64-2.7/curl
    running build_ext
    building 'pycurl' extension
    creating build/temp.linux-x86_64-2.7
    creating build/temp.linux-x86_64-2.7/src
    x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -DPYCURL_VERSION="7.43.0" -DHAVE_CURL_OPENSSL=1 -DHAVE_CURL_SSL=1 -I/usr/include/python2.7 -c src/docstrings.c -o build/temp.linux-x86_64-2.7/src/docstrings.o
    In file included from src/docstrings.c:4:0:
    src/pycurl.h:170:31: fatal error: openssl/crypto.h: No such file or directory
    compilation terminated.
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
    

    Command "/usr/bin/python -u -c "import setuptools, tokenize;file='/tmp/pip-build-TXbOqA/pycurl/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/pip-HNEDNr-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-TXbOqA/pycurl/

    python-dev 已安装。 求助下万能的 V 友,谢谢!

    3 replies    2016-05-18 10:28:55 +08:00
    ayaseangle
        2
    ayaseangle  
       May 18, 2016
    fatal error: openssl/crypto.h: No such file or directory

    大概 openssl-dev 之类的缺失。。。。

    这么明显的错误信息还要问?


    话说有时候就算遇到笔记陌生的错误信息,扔到 google 里多数都能找到解决方案。。。
    itlynn
        3
    itlynn  
    OP
       May 18, 2016
    感谢,已解决!
    sudo apt install libpq-dev python-dev libxml2-dev libxslt1-dev libldap2-dev libsasl2-dev
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5648 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 06:14 · PVG 14:14 · LAX 23:14 · JFK 02:14
    ♥ Do have faith in what you're doing.