Troubleshoot Mac installation M2crypto prompt Unable to find OpenSSL header file issues

Source: Internet
Author: User

That's probably the problem.

running build running build_py running build_ext building‘M2Crypto.__m2crypto‘ extension swigging SWIG/_m2crypto.i to SWIG/_m2crypto_wrap.c swig -python -I/usr/include/python2.7-I/usr/include -includeall -modern -builtin -outdir build/lib.linux-i686-2.7/M2Crypto -o SWIG/_m2crypto_wrap.c SWIG/_m2crypto.i SWIG/_evp.i:12:Error:Unable to find‘openssl/opensslconf.h‘SWIG/_ec.i:7:Error:Unable to find‘openssl/opensslconf.h‘error: command ‘swig‘ failed with exit status 1?

Since OS X is not even/usr/include after the upgrade, use the command

? xcode-select--install?

Install the Xcode command-line tool and/usr/include will come back several times.

But there's no OpenSSL in there.

When installing OpenSSL in addition, you will find that there is no head file ln to/usr/include, no eggs,/usr/include or a system directory that cannot be changed.

But do we notice the installation? M2crypto when the error is prompted SWIG statement there is a problem, so you can modify the Swig address path, as follows, duly:

sudo env ldflags= "-l$ (Brew--prefix OpenSSL)/lib" \

Cflags= "-i$ (Brew--prefix OpenSSL)/include" \

Swig_features= "-cpperraswarn-includeall-i$ (Brew--prefix OpenSSL)/include" \

Pip Install M2crypto

Pro-Test success

Troubleshoot Mac installation M2crypto prompt Unable to find OpenSSL header file issues

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.