Merge pull request #9785 from stanley-cheung/php-update-doc

PHP: added README notes for RHEL 6/7 users
pull/9916/head^2
Stanley Cheung 8 years ago committed by GitHub
commit 7ef0cd668c
  1. 22
      src/php/README.md

@ -13,12 +13,24 @@ shared C library.
* `phpunit` (optional)
**Install PHP and PECL on Ubuntu/Debian:**
For PHP5:
```sh
$ sudo apt-get install php5 php5-dev php-pear
$ sudo apt-get install php5 php5-dev php-pear phpunit
```
OR
For PHP7:
```sh
$ sudo apt-get install php7.0 php7.0-dev php-pear phpunit
```
$ sudo apt-get install php7.0 php7.0-dev php-pear
**Install PHP and PECL on CentOS/RHEL 7:**
```sh
$ sudo rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
$ sudo rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
$ sudo yum install php56w php56w-devel php-pear phpunit gcc zlib-devel
```
**Install PECL on Mac:**
@ -52,6 +64,10 @@ This will compile and install the gRPC PHP extension into the standard PHP
extension directory. You should be able to run the [unit tests](#unit-tests),
with the PHP extension installed.
Note: For users on CentOS/RHEL 6, unfortunately this step won't work. Please
follow the instructions below to compile the extension from source.
**Update php.ini**
Add this line to your `php.ini` file, e.g. `/etc/php5/cli/php.ini`

Loading…
Cancel
Save