python - 使用 SSL 支持编译 Python 时出错

标签 python ssl build

我正在尝试在 Centos6 上编译 Python 2.7.3。几乎一切正常,除了我真正需要的东西 ^^。

当我输入 make 时,出现错误:

building '_ssl' extension
gcc -pthread -fPIC -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I. -IInclude -I./Include -I/usr/local/include -I/root/Python-2.7.3/Include -I/root/Python-2.7.3 -c /root/Python-2.7.3/Modules/_ssl.c -o build/temp.linux-i686-2.7/root/Python-2.7.3/Modules/_ssl.o
gcc -pthread -shared build/temp.linux-i686-2.7/root/Python-2.7.3/Modules/_ssl.o -L/usr/local/lib -lssl -lcrypto -o build/lib.linux-i686-2.7/_ssl.so
*** WARNING: renaming "_ssl" since importing it failed: build/lib.linux-i686-2.7/_ssl.so: undefined symbol: krb5_auth_con_getrcache

最后,我收到一条消息,指出模块 _ssl 的构建失败(类似于这样)。

你遇到过这样的问题吗?我已经安装了 OpenSSL (0.9.8e fips) 和 OpenSSL-dev。

最佳答案

确保 openssl-dev(lib 和 include)的正确路径在您的 Makefile 中

关于python - 使用 SSL 支持编译 Python 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13442779/

相关文章:

python - 为什么这个tensorflow.keras代码需要大量内存?

python - 检查字符串是否是名称的可能缩写

python postgres游标时间戳问题

Qt 错误在几台计算机上创建 SSL 上下文

android - Qt5.1-安卓: Qt version for mips missing in QtCreator

python - L1-范数最小化

ssl - 我如何将端口 123 上的 url www.test.com 指向默认网站下的子站点?

facebook - 新的 SSL 证书将于 10 月 1 日到位

tfs - 仅当 TFS 中的程序集版本发生更改时,如何增加它们?

android - native 库没有从 golang 条件实现加载到 apex_defaults?