How to install php7.0-intl extension for PHP7.0

Here’s what I’m trying to do:

version: 2

      - image: circleci/php:7.0-browsers

      - checkout

      - run: sudo apt-get install php7.0-intl

The result is:

E: Unable to locate package php7.0-intl
E: Couldn't find any package by regex 'php7.0-intl'

What should I do in order to install php7.0-intl?

Any help from CircleCI support?

- run:
    shell: sudo bash -eo pipefail
    command: |
      apt install icu-devtools libicu-dev 
      echo | pecl install intl

However it errors out saying php_smart_str.h is missing, which is a PHP5 thing.

Pecl only specifies 5.x versions

This article may be helpful to you

We’re just extending the official PHP images and not adding any extensions ourselves.

Thanks a lot @rohara!

This configuration works perfectly for me:

version: 2

    machine: true

      - checkout

      - run: echo 'deb jessie all' | sudo tee -a /etc/apt/sources.list
      - run: echo 'deb-src jessie all' | sudo tee -a /etc/apt/sources.list
      - run: cat /etc/apt/sources.list

      - run: cd /tmp
      - run: wget
      - run: sudo apt-key add dotdeb.gpg
      - run: sudo apt-get update

      - run: sudo apt-get install php7.0 php7.0-intl
1 Like