mac上执行pecl search swoole安装swoole时提示:

No releases available for package "pecl.php.net/swoole"
install failed

解决方法是只需使用root权限即可:

sudo pecl search swoole

happy coding!