4

when I try to import M2Crypto in python, I get following error:

I'm using Mac OS X, python 2.7

ImportError: dlopen(/Users/armita/.python-eggs/M2Crypto-0.22.3-py2.7-macosx-10.9-intel.egg-tmp/M2Crypto/__m2crypto.so, 2): Symbol not found: _X509_free
  Referenced from: /Users/armita/.python-eggs/M2Crypto-0.22.3-py2.7-macosx-10.9-intel.egg-tmp/M2Crypto/__m2crypto.so
  Expected in: flat namespace
 in /Users/armita/.python-eggs/M2Crypto-0.22.3-py2.7-macosx-10.9-intel.egg-tmp/M2Crypto/__m2crypto.so

what should I do?

Armita
  • 345
  • 1
  • 12

2 Answers2

0

You're missing libcrypto.

I've made a script based on tmiz's solution:

You can check it here.

After you install libssl and libcrypto you can reinstall M2Crypto.

0

this problem solved by installing M2Crypto version 21 or 23, 22 causes this problem.

Armita
  • 345
  • 1
  • 12