Home > Backend Development > PHP Tutorial > How to solve the problem of two missing php extensions during magento2 installation: ext-intl and ext-xsl

How to solve the problem of two missing php extensions during magento2 installation: ext-intl and ext-xsl

WBOY
Release: 2016-07-29 09:09:10
Original
4695 people have browsed it
How to solve the problem of two missing php extensions during magento2 installation: ext-intl and ext-xsl
问题现象:
[root@localhost magento2]# pwd
/home/wwwroot/default/magento2
[root@localhost magento2]# composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to 
update them.
Your requirements could not be resolved to an installable set of packages.
  Problem 1
    - The requested PHP extension ext-intl * is missing from your system. Install or enable PHP's intl extension.
  Problem 2
    - The requested PHP extension ext-xsl * is missing from your system. Install or enable PHP's xsl extension.
解决问题:
进入cd /home/freeman/tools/lnmp1.2-full/src/php-5.6.9/ext/intl/
执行$phpize && ./configure --with-php-c/local/php/bin/php-config && make && make install
在这个configure的过程中会出现错误,安装相应的lib就行。
$yum install libicu-devel -y
$yum install libxslt-devel -y
cd /home/freeman/tools/lnmp1.2-full/src/php-5.6.9/ext/xsl/
$phpize && ./configure --with-php-c/local/php/bin/php-config && make && make install
修改php.ini
$vi /usr/local/php/etc/php.ini
增加:
extension=xsl.so
extension=intl.so
然后重启php服务/etc/init.d/php-fpm restart
再回到/home/wwwroot/magento2下面执行
$composer install
[root@localhost magento2]# composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
  - Installing magento/magento-composer-installer (0.1.5)
    Downloading: 100%         
  - Installing braintree/braintree_php (2.39.0)
    Downloading: 100%         
这样就成功了。

以上就介绍了How to solve the problem of two missing php extensions during magento2 installation: ext-intl and ext-xsl,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template