Problems with lib-icu dependency when installing Symfony 2.3.x via Composer

后端 未结 6 541
轻奢々
轻奢々 2020-12-04 08:48

I\'ve had no problems installing Symfony 2.2.x using Composer, I\'ve always just copied the stable version at http://symfony.com/download.

composer create-pr         


        
6条回答
  •  自闭症患者
    2020-12-04 09:14

    A better solution is to fix your composer.json to the version required by the production server. First, determine the ICU version on the server: 1 2

    $ php -i | grep ICU
    ICU version => 4.2.1
    

    Then fix the Icu component in your composer.json file to a matching version:

    "require: {
        "symfony/icu": "1.1.*"
    }
    

    Set the version to "1.0." if the server does not have the intl extension installed; "1.1." if the server is compiled with ICU 4.2 or lower.

    Finally, run

    php composer.phar update symfony/icu
    

    on your development machine, test extensively and deploy again. The installation of the dependencies will now succeed.

提交回复
热议问题