我在升级 MAMP 的 xdebug 时遇到问题。我运行的是 2.2.0 版本,遇到了一个已知问题:PhpStorm 和 Xdebug 在 Symfony2 控制器中没有中断 https://stackoverflow.com/questions/20389916/phpstorm-and-xdebug-not-breaking-in-symfony2-controller
我尝试按照以下说明升级到版本 2.2.3http://xdebug.org/wizard.php http://xdebug.org/wizard.php
下载并解压 xdebug tar 后我运行/Applications/MAMP/bin/php/php5.4.4/bin/phpize
这是输出:
Configuring for:
PHP Api Version: 20100412
Zend Module Api No: 20100525
Zend Extension Api No: 220100525
然后我将modules/xdebug.so文件复制到mamp php5.4.4扩展目录中:`/Applications/MAMP/bin/php/php5.4.4/lib/php/extensions/no-debug-non-zts-20100525/xdebug 。
如果我跑/Applications/MAMP/bin/php/php5.4.4/bin/php -v
我得到以下信息:
Xdebug requires Zend Engine API version 220090626.
The Zend Engine API version 220100525 which is installed, is newer.
Contact Derick Rethans at http://xdebug.org/docs/faq#api for a later version of Xdebug.
PHP 5.4.4 (cli) (built: Jul 4 2012 17:28:56)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies
我已经重新启动了 MAMP 和 Apache 并尝试使用以下命令加载页面phpinfo()
我没有看到 Xdebug 列出。如果我将旧的 xdebug.so 文件移回原位,错误将被删除并且phpinfo()
显示 xdebug 已启用