加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 站长学院 > PHP教程 > 正文

山狮php梨和pecl

发布时间:2020-12-13 17:27:35 所属栏目:PHP教程 来源:网络整理
导读:我已经升级到Mountain Lion,并安装了php5.4,它花了一点调整 Mountain Lion change php location 我的下一个问题是如果我运行pear -v或pecl -v这些返回 Could not open input file: /usr/lib/php/pear/pearcmd.phpCould not open input file: /usr/lib/php/pe
我已经升级到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

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读