有一匹母马。我正在尝试安装最新的 PHP mongo DB 驱动程序。我到处寻找并尝试了所有建议但它不会通过这个错误:
In file included from /private/tmp/pear/install/mongodb/src/contrib/php-ssl.c:31:
/private/tmp/pear/install/mongodb/src/contrib/php-ssl.h:33:10: fatal error: 'openssl/evp.h' file not found
include <openssl/evp.h>
^
1 error generated.
make: *** [src/contrib/php-ssl.lo] Error 1
ERROR: `make' failed
我的系统/设置:
OS X El Capitain v 10.11.6
PHP 7.1.0
Apache
我正在使用这个命令来安装它:sudo pecl install mongodb
我试过了:
$ brew install openssl
$ brew link openssl --force
但这不再有效......并且任何最新的解决方法都不起作用
我什至尝试过“无根”但无济于事。
最佳答案
This solution为我工作。如果您还没有 openssl,请先运行 brew install openssl
。
然后运行:
$ cd /usr/local/include
$ ln -s ../opt/openssl/include/openssl .
关于php - 'openssl/evp.h' 文件未找到 OS x Mongodb,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40392021/