升级mac中的系统之后,给PHP安装扩展常出现问题
(1)在装mcrypt插件时报错,提示:mcrypt fatal error: ‘php.h‘ file not found,
然后又仔细操作了一次在输完phpize回车时就已经开始出错了,出错信息如下:
grep: /usr/include/php/main/php.h: No such file or directory
grep: /usr/include/php/Zend/zend_modules.h: No such file or directory
grep: /usr/include/php/Zend/zend_extensions.h: No such file or directory
Configuring for:
PHP Api Version:
Zend Module Api No:
Zend Extension Api No:
解决办法:
sudo ln -s /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include /usr/include
(2)执行./confiure是报错
xcrun: error: active developer path ("/Applications/Xcode.app/Contents/Developer") does not exist, use xcode-select to change
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。