[PYTHON-CRYPTO] Problems compiling M2Crypto on 64 bit Linux ...

Bill boober95 at ROGERS.COM
Thu Jun 25 15:29:34 CEST 2009


I'm using m2crypto for pyXMPP.  I need to build from source against a specific 
version of openSLL but but I am having trouble compiling on a 64 bit system.

I am not having any problem on 32 bit systems, only on the 64 bit versions.

The system I am using is Ubuntu 9.04 AMD64, and I am building against the 
latest version of M2Crypto and openSSL, here is the error I am getting:

gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions 
build/temp.linux-x86_64-2.6/SWIG/_m2crypto_wrap.o -L/usr/local/ssl/lib 
-lssl -lcrypto -o build/lib.linux-x86_64-2.6/M2Crypto/__m2crypto.so
/usr/bin/ld: /usr/local/ssl/lib/libcrypto.a(rc4-x86_64.o): relocation 
R_X86_64_PC32 against symbol `OPENSSL_ia32cap_P' can not be used when 
making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
error: command 'gcc' failed with exit status 1

The -fPIC is a red herring as I made sure to build openSSL with that option.

The interesting thing is Ubuntu 9.04 AMD64 has m2crypto in its repositories, 
so it must be possible to build a 64 bit.

Any ideas or suggestions for what to do would be welcome.

Bill



More information about the python-crypto mailing list