homebrew - brew install php56-intl 装上了,但php并没有加载

WBOY
풀어 주다: 2016-06-06 20:20:34
원래의
1523명이 탐색했습니다.

系统 os x 10.11
用的是 brew 下的php56
brew 下的 nginx

下了一个项目,在安装过程中提示缺少,intl 和 apc扩展,就用下面的语句下载了,也装上了,但php还是没有加载,这怎么弄?
另外问下,apc 扩展怎么装,用 brew search php56 并没有 apc 扩展

<code>➜  brew reinstall php56-intl  --build-from-source
==> Reinstalling homebrew/php/php56-intl
==> Downloading https://php.net/get/php-5.6.17.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php56-intl-5.6.17
==> /usr/local/opt/php56/bin/phpize
==> ./configure --prefix=/usr/local/Cellar/php56-intl/5.6.17 --with-php-config=/us
==> make
==> Caveats
To finish installing intl for PHP 5.6:
  * /usr/local/etc/php/5.6/conf.d/ext-intl.ini was created,
    do not forget to remove it upon extension removal.
  * Validate installation via one of the following methods:
  *
  * Using PHP from a webserver:
  * - Restart your webserver.
  * - Write a PHP page that calls "phpinfo();"
  * - Load it in a browser and look for the info on the intl module.
  * - If you see it, you have been successful!
  *
  * Using PHP from the command line:
  * - Run "php -i" (command-line "phpinfo()")
  * - Look for the info on the intl module.
  * - If you see it, you have been successful!
==> Summary
?  /usr/local/Cellar/php56-intl/5.6.17: 3 files, 372.8K, built in 41 seconds</code>
로그인 후 복사
로그인 후 복사

回复内容:

系统 os x 10.11
用的是 brew 下的php56
brew 下的 nginx

下了一个项目,在安装过程中提示缺少,intl 和 apc扩展,就用下面的语句下载了,也装上了,但php还是没有加载,这怎么弄?
另外问下,apc 扩展怎么装,用 brew search php56 并没有 apc 扩展

<code>➜  brew reinstall php56-intl  --build-from-source
==> Reinstalling homebrew/php/php56-intl
==> Downloading https://php.net/get/php-5.6.17.tar.bz2/from/this/mirror
Already downloaded: /Library/Caches/Homebrew/php56-intl-5.6.17
==> /usr/local/opt/php56/bin/phpize
==> ./configure --prefix=/usr/local/Cellar/php56-intl/5.6.17 --with-php-config=/us
==> make
==> Caveats
To finish installing intl for PHP 5.6:
  * /usr/local/etc/php/5.6/conf.d/ext-intl.ini was created,
    do not forget to remove it upon extension removal.
  * Validate installation via one of the following methods:
  *
  * Using PHP from a webserver:
  * - Restart your webserver.
  * - Write a PHP page that calls "phpinfo();"
  * - Load it in a browser and look for the info on the intl module.
  * - If you see it, you have been successful!
  *
  * Using PHP from the command line:
  * - Run "php -i" (command-line "phpinfo()")
  * - Look for the info on the intl module.
  * - If you see it, you have been successful!
==> Summary
?  /usr/local/Cellar/php56-intl/5.6.17: 3 files, 372.8K, built in 41 seconds</code>
로그인 후 복사
로그인 후 복사

不太清楚你具体的环境配置是怎么样的。不过需要注意的有如下:
php的ISAPI有好几个,cli模式,apache模式等等,可能每个模式都对应一个php.ini,是不是在正确的ini文件中添加extension=/path/path/intl.so了?
apc如果brew没有提供,那就只能手动编译安装了,一般步骤是这样的:
到apc源码根目录,phpize-》configure-》make-》make install,到ini文件中添加extension=/path/apc.so

관련 라벨:
원천:php.cn
본 웹사이트의 성명
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.
인기 튜토리얼
더>
최신 다운로드
더>
웹 효과
웹사이트 소스 코드
웹사이트 자료
프론트엔드 템플릿