pycurl报错: ImportError: pycurl: libcurl link-time ssl backend (openssl) is different from compile-tim

Posted AmyZYX

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了pycurl报错: ImportError: pycurl: libcurl link-time ssl backend (openssl) is different from compile-tim相关的知识,希望对你有一定的参考价值。

报错:

ImportError: pycurl: libcurl link-time ssl backend (openssl) is different from compile-time ssl backend (none/other)

解决方法:

关键是匹配pycurl期望的SSL库

需要卸载原先的curl,重新安装curl-openssl并export相关配置。

brew uninstall curl
brew install curl-openssl

export PYCURL_SSL_LIBRARY=openssl
export PYCURL_CURL_CONFIG=/usr/local/opt/curl-openssl/bin/curl-config;export LDFLAGS=\'-L/usr/local/opt/openssl/lib -L/usr/local/opt/c-ares/lib -L/usr/local/opt/nghttp2/lib -L/usr/local/opt/libmetalink/lib -L/usr/local/opt/rtmpdump/lib -L/usr/local/opt/libssh2/lib -L/usr/local/opt/openldap/lib -L/usr/local/opt/brotli/lib\';export CPPFLAGS=-I/usr/local/opt/openssl/include;pip install pycurl --compile --no-cache-dir

pip install pycurl

以上是关于pycurl报错: ImportError: pycurl: libcurl link-time ssl backend (openssl) is different from compile-tim的主要内容,如果未能解决你的问题,请参考以下文章

弹性 beantalk 中的 celery worker 出错(使用 django 和 SQS)[ImportError:curl 客户端需要 pycurl 库。]

Django1.6 运行manage.py 报错解决办法(ImportError)

导入AppiumLibrary报错: ImportError: cannot import name 'InvalidArgumentException

ubuntu上跑python连接pg,报错 ImportError: No module named psycopg2

Py2neo.Graph()连接Neo4j报错:ImportError: cannot import name ‘clock‘ from ‘time‘ (unknown location)

virtualenv中解决报错:ImportError: No module named Cryptodome.PublicKey