【问题标题】:Cakephp : intl extension missingCakephp:缺少国际扩展名
【发布时间】:2019-12-02 16:59:45
【问题描述】:

我正在尝试在我的 Mac 中安装 CakePHP 3.8(macos high sierra 版本 10.13.6),但我从昨天开始就遇到了这个问题,告诉我你的系统中缺少扩展 intl

 User-iMac:TEST zakaria$ composer create-project --prefer-dist 
 cakephp/app my_app_name
 Installing cakephp/app (3.8.0)
 - Installing cakephp/app (3.8.0): Loading from cache
 Created project in my_app_name
 Loading composer repositories with package information
 Updating dependencies (including require-dev)
 Your requirements could not be resolved to an installable set of 
 packages.

 Problem 1
 - cakephp/cakephp 3.8.1 requires ext-intl * -> the requested PHP 
 extension intl is missing from your system.
 - cakephp/cakephp 3.8.0 requires ext-intl * -> the requested PHP 
 extension intl is missing from your system.
 - Installation request for cakephp/cakephp 3.8.* -> satisfiable 
by 
cakephp/cakephp[3.8.0, 3.8.1].

To enable extensions, verify that they are enabled in your .ini 
files:
 - /etc/php.ini
You can also run `php --ini` inside terminal to see which files 
are 
used by PHP in CLI mode.
User-iMac:TEST User$ 
  • 我试图在 php.ini 中取消注释 extension=php_intl.dll
  • 我尝试添加 extension=intl.so

还有很多解决方案,但似乎没有任何效果

【问题讨论】:

标签: cakephp-3.7


【解决方案1】:

不幸的是,在 Mac OS high sierra 上本地安装 PHP 7.1.24 时缺少 Intl 扩展。

从 php.net 下载 PHP 7.1,安装 XCode 命令行工具、ICU (http://site.icu-project.org/)、Autoconf,重新安装开发者工具头文件,最后使用 phpize 安装 Intl 扩展。

重要提示:您必须禁用 SIP。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2019-05-24
    • 2014-12-13
    • 2018-02-20
    • 2016-03-01
    • 1970-01-01
    • 1970-01-01
    • 2018-12-11
    相关资源
    最近更新 更多