mac os x 10.11 php7,mac osx 10.11.2安装PHP7提示“configure: error: libcrypto not found!”

刚升级到了最新的系统OS X 10.11.2,在安装PHP7时

./configure --prefix=/usr/local/php7 --with-config-file-path=/usr/local/php7/etc --enable-fpm --with-fpm-user=www --with-fpm-group=www --with-mysqli --with-pdo-mysql --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --enable-mbregex --enable-mbstring --with-mcrypt --enable-ftp --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --disable-fileinfo --enable-maintainer-zts

时,提示错误:

checking for xml2-config path... /usr/bin/xml2-config

checking whether libxml build works... yes

checking for OpenSSL support... yes

checking for Kerberos support... no

checking whether to use system default cipher list instead of hardcoded value... no

checking for RAND_egd... no

checking for pkg-config... no

checking for OpenSSL version... >= 0.9.8

checking for CRYPTO_free in -lcrypto... no

configure: error: libcrypto not found!

百度了一下,这个和openssl有关系 ,目前openssl已经安装过了,版本为0.9.8,此错误好像是openssl-devel开发包里的内容,但用brew install 安装好像并没有找到此包,不知应该如何解决。。。

已经解决,重新用brew install openssl安装了一次openssl,然后指定了openssl的路径。

--with-openssl=/usr/local/opt/openssl

原来试了不行,来回折腾了下,竟然又可以了。

诶,你

--with-openssl

是需要指定openssl的位置的,看你

brew

的位置

直接用brew install php70不行吗?

重新安装openssl的时候,提示这个

A CA file has been bootstrapped using certificates from the system

keychain. To add additional certificates, place .pem files in

/usr/local/etc/openssl/certs

and run

/usr/local/opt/openssl/bin/c_rehash

This formula is keg-only, which means it was not symlinked into /usr/local.

Apple has deprecated use of OpenSSL in favor of its own TLS and crypto libraries

Generally there are no consequences of this for you. If you build your

own software and it requires this formula, you'll need to add to your

build variables:

LDFLAGS:  -L/usr/local/opt/openssl/lib

CPPFLAGS: -I/usr/local/opt/openssl/include

感觉着应该是这个问题的.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值