Python 3.7.3 ./configure --with-openssl 找不到 ssl.h

Python 3.7.3 ./configure --with-openssl could not find ssl.h

提问人:Reza Akraminejad 提问时间:5/22/2019 更新时间:11/2/2020 访问量:3161

问:

我已经下载了 Python 3.7.3 源代码,并希望使用 openssl 支持来制作和安装它。

从 ./configure --help 中发现新选项 --with-openssl 应指向安装 openssl-devel 的文件夹。

我在 make 命令之前和时为我的 Centos 安装了 openssl-devel.x86_64,我找到了 ssl.h,但是当带参数传递给 or 时,ls /usr/include/openssl |grep ssl./configure --with-openssl=/usr/include/openssl/./configure --with-openssl=/usr/include/openssl

它说检查 Oopenssl/ssl.h in /usr/include/openssl/... n

python-3.x 编译 openSSL

评论

12赞 Lorinczy Zsigmond 5/22/2019
只是--with-openssl=/usr
0赞 Reza Akraminejad 5/22/2019
@LorinczyZsigmond 谢谢伙计,它解决了我的问题,在这些让我感到困惑的情况下,有什么方法可以调试和跟踪此类配置脚本?
0赞 Lorinczy Zsigmond 5/22/2019
好吧,调用的文件是在 './configure 期间编写的,它通常包含有用的信息。compile.log
1赞 Reza Akraminejad 5/22/2019
@LorinczyZsigmond最后发现另一个错误:ModuleNotFoundError:没有名为“_ctypes”的模块
2赞 Lorinczy Zsigmond 5/22/2019
您可能需要安装 libffi:(以 root 身份)yum install -y libffi libffi-devel

答: 暂无答案