Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Having problem installing intl #78

Open
ksowa opened this issue Nov 23, 2017 · 2 comments
Open

Having problem installing intl #78

ksowa opened this issue Nov 23, 2017 · 2 comments

Comments

@ksowa
Copy link

ksowa commented Nov 23, 2017

Hi,
as I'm working on international project, I'm taking the advantage of the intl PHP extension. Symfony also recommends to install it.

I tried many different options, but couldn't get it installed.

First of all I had to install libicu-dev package:
docker-compose exec php apt install libicu-dev

Then I tried to do similar thing for intl:
docker-compose exec php apt install php7.1-intl
but the error says the package could not be found.

I even added ppa:ondrej/php repository, but it says:

W: Failed to fetch http://ppa.launchpad.net/ondrej/php/ubuntu/dists/jessie/main/binary-amd64/Packages  404  Not Found
W: Failed to fetch http://ppa.launchpad.net/ondrej/php5-5.6/ubuntu/dists/jessie/main/binary-amd64/Packages  403  Forbidden

I also tried to install that by PECL:
docker-compose exec php pecl install intl
but it throws the following error:

compilation terminated.
Makefile:194: recipe for target 'php_intl.lo' failed
make: *** [php_intl.lo] Error 1
ERROR: `make' failed

Do you have any idea of how to make this working?

@maxpou
Copy link
Owner

maxpou commented Nov 24, 2017

Hi,

I think you should run docker-php-ext-install command in your PHP container.
https://github.com/maxpou/docker-symfony/blob/master/php7-fpm/Dockerfile#L22
Then update Dockerfile.

@ksowa
Copy link
Author

ksowa commented Nov 24, 2017

Thanks @maxpou , it worked. I tried this solution at a very beginning, but it didn't work without the libicu-dev package. After installing it, I was trying other approaches and forgot about the easiest path.

I've created pull request for this - https://github.com/maxpou/docker-symfony/pull/79/files

I think it's worth merging it, as Symfony recommends intl extension, anyway.

The other thing I was struggling with, but less important, is this message printed by bin/symfony_requirements:

 * intl ICU version installed on your system is outdated (52.1) and
   does not match the ICU data bundled with Symfony (60.1)
   > To get the latest internationalization data upgrade the ICU
   > system package and the intl PHP extension.

I was trying to update the ICU package, but with no success. Do you think it would be doable?

Thanks for your great work on the integration. It's really useful!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants