Mac OS下为PHP 8通过pecl安装xdebug出现mkdir报错如何解决?
执行
phpunit --coverage报错与Xdebug安装失败问题说明 - 计划执行操作:为项目运行
phpunit --coverage命令生成代码覆盖率 - 首次执行返回报错:
PHPUnit 9.5.0 by Sebastian Bergmann and contributors. Warning: No code coverage driver available
- 排查动作:执行
php -v校验当前PHP环境配置,确认是否安装Xdebug扩展,输出结果如下:
PHP 8.0.0 (cli) (built: Nov 30 2020 13:51:52) ( NTS ) Copyright (c) The PHP Group Zend Engine v4.0.0-dev, Copyright (c) Zend Technologies with Zend OPcache v8.0.0, Copyright (c), by Zend Technologies
- 排查结论:当前环境未安装Xdebug,因此通过Homebrew执行
pecl install xdebug命令安装扩展 - 安装流程末尾返回报错:
........ Build process completed successfully Installing '/usr/local/Cellar/php/8.0.0_1/pecl/20200930/xdebug.so' Warning: mkdir(): File exists in System.php on line 294 Warning: mkdir(): File exists in /usr/local/Cellar/php/8.0.0_1/share/php/pear/System.php on line 294 ERROR: failed to mkdir /usr/local/Cellar/php/8.0.0_1/pecl/20200930
内容的提问来源于stack exchange,提问作者user14577547
相关产品推荐
相关产品推荐

