【问题标题】:Fatal error C1083: Cannot open include file: 'openssl/opensslv.h'致命错误 C1083:无法打开包含文件:“openssl/opensslv.h”
【发布时间】:2016-10-23 09:47:33
【问题描述】:

我正在尝试安装 Scrapy,但在安装过程中出现此错误:build\temp.win-amd64-2.7\Release_openssl.c(429):致命错误 C1083:无法打开包含文件:'openssl/opensslv.h ': 没有这样的文件或目录

我检查了文件“opensslv.h”在此处“C:\OpenSSL-Win64\include\openssl”。而且我还在路径系统变量中包含了这个“C:\OpenSSL-Win64\include”。

坚持了几个小时,有人可以帮忙吗?谢谢。

“cryptography-1.5.2”包也发现了同样的问题

【问题讨论】:

    标签: python openssl cryptography scrapy


    【解决方案1】:

    设置这两个环境值为我修复了它,之后pip install cryptography 起作用了:

    set LIB=C:\OpenSSL-win64\lib;%LIB%
    set INCLUDE=C:\OpenSSL-win64\include;%INCLUDE%
    

    更多信息请参见here

    【讨论】:

    • 就我而言,由于错误 No job,我无法使用 set 添加这些环境变量。但我在Control Panel\System and Security\System\Advanced system settings\Environment Variables...Windows 10 中直观地添加了它们,然后单击System variables 下的New 按钮。这样做之后,问题就解决了
    【解决方案2】:

    将“openssl”文件夹从 C:\OpenSSL-Win32\include\ 复制到 C:\Pyhton27\include\

    并将所有库从 C:\OpenSSL-win32\lib 复制到 C:\Python27\Libs\

    【讨论】:

    • 仍然无法安装。我需要安装 django 频道。
    猜你喜欢
    • 2011-02-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多