centos4.X 安装python2.7.X SSL模块
来源:互联网 发布:知悉和悉知是什么意思 编辑:程序博客网 时间:2024/05/16 12:00
源代码方式安装Python2.7.9
Python build finished, but the necessary bits to build these modules were not found:_bsddb _tkinter bsddb185 dl imageop sunaudiodev To find the necessary bits, look in setup.py in detect_modules() for the module's name.Failed to build these modules:_ssl
查看编译日志:
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/download/Python-2.7.9/Include -I/root/download/Python-2.7.9 -c /root/download/Python-2.7.9/Modules/_ssl.c -o build/temp.linux-x86_64-2.7/root/download/Python-2.7.9/Modules/_ssl.o/root/download/Python-2.7.9/Modules/_ssl.c: In function `_get_peer_alt_names':/root/download/Python-2.7.9/Modules/_ssl.c:801: warning: passing arg 2 of `ASN1_item_d2i' from incompatible pointer type/root/download/Python-2.7.9/Modules/_ssl.c:806: warning: passing arg 2 of pointer to function from incompatible pointer type/root/download/Python-2.7.9/Modules/_ssl.c: In function `PySSL_cipher':/root/download/Python-2.7.9/Modules/_ssl.c:1358: warning: passing arg 1 of `SSL_CIPHER_get_name' discards qualifiers from pointer target type/root/download/Python-2.7.9/Modules/_ssl.c:1368: warning: passing arg 1 of `SSL_CIPHER_get_version' discards qualifiers from pointer target type/root/download/Python-2.7.9/Modules/_ssl.c:1378: warning: passing arg 1 of `SSL_CIPHER_get_bits' discards qualifiers from pointer target type/root/download/Python-2.7.9/Modules/_ssl.c: In function `cert_store_stats':/root/download/Python-2.7.9/Modules/_ssl.c:3084: warning: implicit declaration of function `X509_check_ca'/root/download/Python-2.7.9/Modules/_ssl.c: In function `init_ssl':/root/download/Python-2.7.9/Modules/_ssl.c:3970: error: `X509_V_FLAG_X509_STRICT' undeclared (first use in this function)/root/download/Python-2.7.9/Modules/_ssl.c:3970: error: (Each undeclared identifier is reported only once/root/download/Python-2.7.9/Modules/_ssl.c:3970: error: for each function it appears in.)
由于centos4.9中的openssl版本较低:
[root@localhost Python-2.7.9]# yum list installed | grep opensslopenssl.i686 0.9.7a-43.18.el4 installed openssl.x86_64 0.9.7a-43.18.el4 installed openssl-devel.i386 0.9.7a-43.18.el4 installed openssl-devel.x86_64 0.9.7a-43.18.el4 installed xmlsec1-openssl.x86_64 1.2.6-3.2 installed xmlsec1-openssl.i386 1.2.6-3.2 installed
手工编译一份较新的:openssl-0.9.8e.tar.gz
然后修改Python2.7.9/Module/Setup
SSL修改为手工安装的路径即可
# Socket module helper for SSL support; you must comment out the other# socket line above, and possibly edit the SSL variable:SSL=/usr/local/ssl_ssl _ssl.c \-DUSE_SSL -I$(SSL)/include -I$(SSL)/include/openssl \-L$(SSL)/lib -lssl -lcrypto
0 0
- centos4.X 安装python2.7.X SSL模块
- Python2.7.x安装requests模块
- python2.7.x安装BeasutifulSoup4模块
- 在centos4.x上安装oracle10g
- CentOS4.x系统上安装Oracle10g
- win764 + python2.7.x + opencv 安装
- centos 6.8 安装python2.7.x环境
- centos 6.8 安装python2.7.x环境
- python2.7.x windows下安装pip
- centos 下安装python2.7.x
- 在python2.7.X中怎么安装numpy scipymatplotlib pandas等模块
- 解决国内网络Python2.X 3.X PIP安装模块连接超时的问题
- Mac安装python2.x与python3.x
- Windows7x64平台安装Python2.x
- 在 Tomcat 4.x/5.x/6.x/7.x 中生成和安装 SSL 证书
- centos6.x 升级python2.7.x
- python2.x ~ python3.x
- python2.7.x使用pip安装第三方库lxml
- Sort List(四种算法)
- [C/C++]十-->二进制转换
- 图的遍历递归和非递归实现
- 栈
- effective C++ 第一章:让自己习惯C++
- centos4.X 安装python2.7.X SSL模块
- 字符编码详解
- 【算法】简单的桶排序算法
- thinking In Java ---07 复用类
- 收集 ios 常用的工具
- 获取SQL Server连接数与监视SQL Server连接状态的方法
- SpringMVC Ajax请求
- Thinkphp上传文件,保存时显示乱码
- Java异常详解