[英]Can't install pycurl with pip
Can't install pycurl with pip, win xp x32, python 2.7.无法使用 pip、win xp x32、python 2.7 安装 pycurl。
here is the log这是日志
pip install pycurl
Downloading/unpacking pycurl
Downloading pycurl-7.19.3.1.tar.gz (116Kb): 116Kb downloaded
Running setup.py egg_info for package pycurl
Please specify --curl-dir=/path/to/built/libcurl
Complete output from command python setup.py egg_info:
Please specify --curl-dir=/path/to/built/libcurl
----------------------------------------
Command python setup.py egg_info failed with error code 10 in C:\Documents and S
ettings\User\build\pycurl
Storing complete log in C:\Documents and Settings\User\Application Data\pip\pi
p.log
Following the steps one mentioned above, solved my problem.按照上面提到的步骤一,解决了我的问题。
sudo apt install libcurl4-gnutls-dev librtmp-dev
pip install pycurl
This is a problem indeed.这确实是个问题。 No need to update pip or easy install as it's often advised, well it won't hurt to update but you will still have the problem until you :无需像通常建议的那样更新 pip 或轻松安装,更新不会有什么坏处,但您仍然会遇到问题,直到您:
Worked the same in Linux在 Linux 中工作相同
I had the same problem.我有同样的问题。 I was able to install it with easy_install instead:我可以使用 easy_install 安装它:
easy_install pycurl
For easy_install, see setuptools .对于 easy_install,请参阅setuptools 。
Here are easy steps I did to get around this:以下是我为解决此问题所做的简单步骤:
Download the wheel of the version you want here: https://www.lfd.uci.edu/~gohlke/pythonlibs/在这里下载你想要的版本的轮子: https : //www.lfd.uci.edu/~gohlke/pythonlibs/
then you can pip install that like so:然后你可以像这样 pip install :
pip install C:\\sample\\sample_dir\\whl_file_downloaded pip 安装 C:\\sample\\sample_dir\\whl_file_downloaded
You should know be able to import in your python files你应该知道能够在你的 python 文件中导入
要遵循的步骤:
brew install openssl
PYCURL_SSL_LIBRARY=openssl LDFLAGS="-L/usr/local/opt/openssl/lib" CPPFLAGS="-I/usr/local/opt/openssl/include" pip install --no-cache-dir pycurl
使用 conda 安装 pycurl,conda 将安装所有依赖项,希望它有效
conda install -c anaconda pycurl
For Linux Please install the libcurl-devel
package and then try.对于 Linux 请安装libcurl-devel
package 然后尝试。 It will work.它会起作用。
So has said by Hai Vu you need to install cURL first. Hai Vu 说你需要先安装 cURL。 Here is the dowload page : http://curl.haxx.se/download.html I suggest you install it in your C:/ directory, or if you already installed it elsewhere copye the curl.exe file to your c:/这是下载页面: http : //curl.haxx.se/download.html我建议您将其安装在 C:/ 目录中,或者如果您已经在其他地方安装了它,请将 curl.exe 文件复制到您的 c:/
When done, you can try it by going to the cmd prompt :完成后,您可以通过转到 cmd 提示符来尝试:
cd c:/
curl "your-curl-request"
If it works then curl is correctly installed and you can install pycurl with pip.如果它有效,那么 curl 已正确安装,您可以使用 pip 安装 pycurl。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.