/usr/lib64/python2.4/distutils/dist.py:236: UserWarning: Unknown distribution option: 'zip_safe'
warnings.warn(msg)
running build_ext
building 'OpenSSL.SSL' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fPIC -I/usr/local/ssl/include -I/usr/include/python2.4 -c OpenSSL/ssl/connection.c -o build/temp.linux-x86_64-2.4/OpenSSL/ssl/connection.o
OpenSSL/ssl/connection.c: In function ‘ssl_Connection_set_context’:
OpenSSL/ssl/connection.c:289: warning: implicit declaration of function ‘SSL_set_SSL_CTX’
OpenSSL/ssl/connection.c: In function ‘ssl_Connection_get_servername’:
OpenSSL/ssl/connection.c:313: error: ‘TLSEXT_NAMETYPE_host_name’ undeclared (first use in this function)
OpenSSL/ssl/connection.c:313: error: (Each undeclared identifier is reported only once
OpenSSL/ssl/connection.c:313: error: for each function it appears in.)
OpenSSL/ssl/connection.c:320: warning: implicit declaration of function ‘SSL_get_servername’
OpenSSL/ssl/connection.c:320: warning: assignment makes pointer from integer without a cast
OpenSSL/ssl/connection.c: In function ‘ssl_Connection_set_tlsext_host_name’:
OpenSSL/ssl/connection.c:346: warning: implicit declaration of function ‘SSL_set_tlsext_host_name’
error: command 'gcc' failed with exit status 1

解决办法:

wget https://bugs.launchpad.net/pyopenssl/+bug/845445/+attachment/2666639/+files/pyOpenSSL-0.13.centos5.patch
# wget http://pypi.python.org/packages/source/p/pyOpenSSL/pyOpenSSL-0.13.tar.gz
# tar xf pyOpenSSL-0.13.tar.gz
# cd pyOpenSSL-0.13
[root@uyhd000461 pyOpenSSL-0.13]# grep "#define OPENSSL_VERSION_TEXT" /usr/include/openssl/opensslv.h
#define OPENSSL_VERSION_TEXT "OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008"
#define OPENSSL_VERSION_TEXT "OpenSSL 0.9.8e-rhel5 01 Jul 2008"
[root@uyhd000461 pyOpenSSL-0.13]# patch -p1 < pyOpenSSL-0.13.centos5.patch
patching file OpenSSL/ssl/connection.c
patching file OpenSSL/ssl/context.c

然后python setup.py install 就ok  

转自:http://www.gm100861.com/281.html

pyOpenSSL0.13安装失败的更多相关文章

  1. macOS 10.13 安装Virtualbox失败

    macOS 10.13 安装Virtualbox失败 Enviroment macOS: 10.13 High Sierra virtualBox: 5.1.28 Problem descriptio ...

  2. windows下Gulp入门详细教程 &&gulp安装失败的原因(红色)

    以下教程亲自实践可行: 另外添加一个Gulp自动编译.压缩.更新.测试的教程链接:https://markpop.github.io/2014/09/17/Gulp%E5%85%A5%E9%97%A8 ...

  3. 关于MySQL-python-1.2.3.tar.gz安装失败的解决方案

    关于MySQL-python-1.2.3.tar.gz安装失败的解决方案 RHEL6.4升级到python2.7.9,然后安装 MySQL-python-1.2.3.tar.gz, 报错.解决错误之后 ...

  4. [转]node-sass 安装失败的各种坑

    本文转自:https://blog.csdn.net/weixin_42406046/article/details/80604623?tdsourcetag=s_pctim_aiomsg 版权声明: ...

  5. TP5安装失败怎么办?

    安装TP5遇到这样的错误 TP5安装失败怎么办? [Mon Mar 13 06:24:58.011228 2017] [:error] [pid 10243] [client 192.168.28.1 ...

  6. Python系列之入门篇——python2.7.13安装

    Python2.7.13 安装 说明 以下所有操作都基于centos6.9 1. Issue zlib zlib-devel是安装setuptools依赖的模块,需要在安装python之前先安装这两个 ...

  7. mysql8.0.13安装、使用教程图解

    mysql8.0.13安装.使用教程图解 MySQL是最流行的关系型数据库管理系统之一,在 WEB 应用方面,MySQL是最好的 RDBMS (Relational Database Manageme ...

  8. node-sass 安装失败的各种坑

    开始的时候引入别人的一个项目 npm install npm run dev 启动项目 报错 > node build/dev-server.js Listening at http://loc ...

  9. node-sass 安装失败报错的原因及解决办法(整理)

    npm install 时偶尔遇到报错:没有安装python或node-sass 安装失败的问题,百度之后发现是被墙了,但根据百度的方法换了淘宝镜像和用了vpn都安装失败,最后发现原来是因为没有卸载之 ...

随机推荐

  1. js控制input type=checkbox 的勾选

    <script type="text/javascript">     $(function () {         //双击表格弹出窗口         //为jQ ...

  2. 【IOS笔记】Gesture Recognizers

    Gesture Recognizers Gesture recognizers convert low-level event handling code into higher-level acti ...

  3. 【转载】wireshark抓包

    两种过滤器 捕捉过滤器:用于决定将什么样的信息记录在捕捉结果中.需要在开始捕捉前设置显示过滤器:在捕捉结果中进行详细查找.他们可以在得到捕捉结果后随意修改 1.捕捉过滤器   语法实例: tcp ds ...

  4. egrep 查找IP

    1. egrep '([^0-9]|\<)(([0-1]?[0-9]{0,2}|([2]([0-4][0-9]|[5][0-5])))\.){3}([0-1]?[0-9]{0,2}|([2]([ ...

  5. link them together by means of pointers

    Computer Science An Overview _J. Glenn Brookshear _11th Edition An alternative to storing a heteroge ...

  6. delphi 最全日期格式_DateUtils时间单元说明

    DateUtils时间单元说明 CompareDate 函数 比较两个日期时间值日期部分的大小 CompareDateTime 函数 比较两个日期时间值的大小 CompareTime 函数 比较两个日 ...

  7. db link的查看创建与删除(转)

    1.查看dblink select owner,object_name from dba_objects where object_type='DATABASE LINK'; 或者 select * ...

  8. java JDK8 学习笔记——第17章 反射与类加载器

    第十七章 反射与类加载器 17.1 运用反射 反射:.class文档反映了类基本信息,从Class等API取得类信息的方式称为反射. 17.1.1 Class与.class文档 1.java.lang ...

  9. HashSet HashTable HashMap的区别

    (1)HashSet是set的一个实现类,hashMap是Map的一个实现类,同时hashMap是hashTable的替代品(为什么后面会讲到). (2)HashSet以对象作为元素,而HashMap ...

  10. SQLite.net发布后找不到"SQLite.Interop.dll"的问题

    http://system.data.sqlite.org/index.html/doc/trunk/www/downloads.wiki sqlite-netFx40-static-binary-b ...