山狮php梨和pecl

我已经升级到Mountain Lion,并安装了PHP5.4,它花了一点调整 Mountain Lion change php location

我的下一个问题是如果我运行pear -v或pecl -v这些返回

Could not open input file: /usr/lib/PHP/pear/pearcmd.PHP

Could not open input file: /usr/lib/PHP/pear/peclcmd.PHP

我需要更改pear和pecl来指向我的新PHP,它安装在/usr/local / PHP5 / bin /

如果是这样做,我将如何丢失以前安装的所有扩展,如PHPunit?

谢谢

我通过再次安装梨来分类.下载之后,然后运行梨梨
sudo PHP -d detect_unicode=0 go-pear.phar

在安装中有可以更改梨正在使用的目录.它们已经被设置到我的新PHP的正确位置,例如/usr/local / PHP5 / bin

然后我必须将该路径添加到我的bash_profile中,以便pear命令被识别.

export PATH=$PATH:/usr/local/PHP5/bin

为了让pecl再次工作,我从/usr/bin中删除了pecl,然后符号链接到/usr/local / PHP5 / bin中的pecl

sudo ln -s /usr/local/PHP5/bin/pecl /usr/bin/pecl

我试图安装的第一个包是APC,我收到错误

Cannot find autoconf. Please check your autoconf installation and the
$PHP_AUTOCONF environment variable. Then,rerun this script.

ERROR: `PHPize' Failed

这是按照phpize won’t work on Mac OS X Lion中的使用自制软件解决方案的说明排序的

更新:我安装PHPUnit罚款,然后运行PHPunit –version

这给了一个错误

PHP Warning:  require(/usr/lib/PHP/pear/PHPUnit/Autoload.PHP): Failed to open stream: No such file or directory in /usr/bin/PHPunit on line 43

运行哪个PHPunit返回/usr/bin/PHPunit

解决了更多的符号

sudo ln -s /usr/local/PHP5/bin/PHPunit PHPunit

相关文章

统一支付是JSAPI/NATIVE/APP各种支付场景下生成支付订单,返...
统一支付是JSAPI/NATIVE/APP各种支付场景下生成支付订单,返...
前言 之前做了微信登录,所以总结一下微信授权登录并获取用户...
FastAdmin是我第一个接触的后台管理系统框架。FastAdmin是一...
之前公司需要一个内部的通讯软件,就叫我做一个。通讯软件嘛...
统一支付是JSAPI/NATIVE/APP各种支付场景下生成支付订单,返...