2017-01-23 5 views
0

installieren, wenn ich die Kryptographie zu installieren, da einige Fehler haben, für die Plattform:Kann nicht openssl-devel für Python 2.7.11

[[email protected] ~]# python -V 
Python 2.7.11 
[[email protected] ~]# rpm -qa openssl 
openssl-1.0.0-20.el6.x86_64 
[[email protected] ~]# rpm -qa openssl-devel 
openssl-devel-1.0.0-20.el6.x86_64 
[[email protected] ~]# rpm -qa python-devel 
python-devel-2.6.6-29.el6.x86_64 
[[email protected] ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 6.2 (Santiago) 

die Fehler folgt:

already up-to-date 
building '_openssl' extension 
gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/usr/local/python/include/python2.7 -c build/temp.linux-x86_64-2.7/_openssl.c -o build/temp.linux-x86_64-2.7/build/temp.linux-x86_64-2.7/_openssl.o 
build/temp.linux-x86_64-2.7/_openssl.c:2078: warning: function declaration isn?. a prototype 
build/temp.linux-x86_64-2.7/_openssl.c:2079: warning: function declaration isn?. a prototype 
build/temp.linux-x86_64-2.7/_openssl.c:2080: warning: function declaration isn?. a prototype 
build/temp.linux-x86_64-2.7/_openssl.c:2105: warning: function declaration isn?. a prototype 
build/temp.linux-x86_64-2.7/_openssl.c:2163: warning: function declaration isn?. a prototype 
build/temp.linux-x86_64-2.7/_openssl.c: In function ?.cffi_const_CMS_DEBUG_DECRYPT?. 
build/temp.linux-x86_64-2.7/_openssl.c:8193: error: ?.MS_DEBUG_DECRYPT?.undeclared (first use in this function) 
build/temp.linux-x86_64-2.7/_openssl.c:8193: error: (Each undeclared identifier is reported only once 
build/temp.linux-x86_64-2.7/_openssl.c:8193: error: for each function it appears in.) 
error: command 'gcc' failed with exit status 1 

Antwort

0

Ich benutzte die folgenden Schritte und es funktionierte für mich in meiner virtuellen Umgebung. Zuerst habe ich Python Development Header und Libevent Header installiert.

sudo apt-get install python-dev 

sudo apt-get install libevent-dev 

dann, habe ich Dokumentation https://cryptography.io/en/latest/installation/#building-cryptography-on-linux

+0

sudo yum install gcc libffi-devel python-devel openssl-devel, ja, ich tue dies, aber dies nicht lösen können ,, das ist openssh Problem? aber ich habe das Paket installiert – Kel

Verwandte Themen