mac安装php xdebug

php php 517      收藏
mac安装php xdebug

本地php版本为 7.3.18 

xdebug 2.9.8版本是适合php7.3的,其他版本可以在 https://github.com/xdebug/xdebug/tags 中查找

安装步骤如下

wget http://xdebug.org/files/xdebug-2.9.8.tgz
tar -xvzf xdebug-2.9.8.tgz
cd xdebug-2.9.8
phpize
./configure
make

编译完成之后,把 xdebug.so 所在的路径配置到php.ini中

zend_extension = "/Users/myself/Downloads/xdebug/xdebug-2.9.8/modules/xdebug.so"

重启php即可