python - 无法easy_install ssl模块

标签 python ssl easy-install

执行 easy_install ssl 时出现以下错误:

C:\Windows\system32>easy_install ssl
Searching for ssl
Reading http://pypi.python.org/simple/ssl/
Reading http://docs.python.org/dev/library/ssl.html
Best match: ssl 1.15
Downloading http://pypi.python.org/packages/source/s/ssl/ssl-1.15.tar.gz#md5=81ea8a1175e437b4c769ae65b3290e0c
Processing ssl-1.15.tar.gz
Running ssl-1.15\setup.py -q bdist_egg --dist-dir c:\users\fipethor\appdata\local\temp\easy_install-v2d68a\ssl-1.15\egg-dist-tmp-klfhbm

error: Setup script exited with error: Python was built with Visual Studio 2003;
extensions must be built with a compiler than can generate compatible binaries.
Visual Studio 2003 was not found on this system. If you have Cygwin installed,
you can try compiling with MingW32, by passing "-c mingw32" to setup.py.

最佳答案

  1. 访问:http://sourceforge.net/project/showfiles.php?group_id=2435

  2. 下载并运行:自动化 MinGW 安装程序(确保检查基础、g++ 和 Make)

  3. 更新您的 PATH:将 C:\mingw\bin 目录添加到系统 PATH

  4. 创建(或编辑):C:\Python25\Lib\distutils\distutils.cfg 并添加以下两行:

    [构建]

    编译器=mingw32

在这里找到:

http://old.nabble.com/Installing-PyXML-problems-td12405796.html

关于python - 无法easy_install ssl模块,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6816935/

相关文章:

python - pygame 函数似乎被忽略

iOS Thrift SSL 连接

ssl - 为 SSH 生成 SSL key 对时,您可以使用的最大位数 (-b) 是多少?

python - 如何在 Python 3.1 中安装 argparse?

python - 从 git 安装 Python 包 pathos

python - 将 rpy2 与 numpy.testing 一起使用时出现 ImportError

python - 导入 pymorphy2 时出现异常

python - 如何重新安装 lxml?

Python倒计时小游戏需要指导

ssl - 与二进制模式的 Spark Thrift 服务器的通信是否安全传输?