contos 安装 pecl 或者pear自动匹配本地安装的php版本

  1. 下载安装 go-pear.phar
wget http://pear.php.net/go-pear.phar
  1. 用php运行这个文件
php go-pear.phar
  1. 安装操作提示选择安装
    选择本地php安装位置,1
    contos 安装 pecl 或者pear自动匹配本地安装的php版本

回车 - 下一步
contos 安装 pecl 或者pear自动匹配本地安装的php版本

回车 - 下一步
contos 安装 pecl 或者pear自动匹配本地安装的php版本

这里选 y 让他更改php.ini
contos 安装 pecl 或者pear自动匹配本地安装的php版本

然后就行了,试试 pecl -V peardev -V