First, Introduction
PECL (the PHP Extension Community library) is a PHP extension repository that provides hosting and download services for all PHP extensions.
The PECL extension can be downloaded and installed using the PEAR (PHP Extension and application Repository) Package Manager installation Management method.
Second, installation
The official provides the PEAR in each platform installation way, directly looks the official document the request enters "the portal", the MacOS platform official installation translation follows.
1. Download PEAR
You can download it using the Curl command:
$ curl -O https://pear.php.net/go-pear.phar
2. Installing PEAR
To install using sudo licensing:
$ sudo php -d detect_unicode=0 go-pear.phar
The installation process requires a simple configuration, as follows:
Below is a suggested the file layout for your new PEAR installation. Tochange individual locations, type the number in front of thedirectory. Type ' All ' to change all of them or simply press Enter toaccept these locations. 1. Installation Base ($prefix):/usr 2. Temporary directory for processing:/tmp/pear/install 3. Temporary directory for downloads:/tmp/pear/install 4. Binaries directory:/usr/bin 5. PHP Code directory ($php _dir):/usr/share/pear 6. Documentation Directory:/usr/docs 7. Data directory:/usr/data 8. user-modifiable Configuration Files directory:/usr/cfg 9. Public Web Files directory:/USR/WWW10. System Manual pages Directory:/usr/man11. Tests directory:/USR/TESTS12. Name of configuration file:/private/etc/pear.conf1-12, ' all ' or EnterTo Continue:1
Enter 1 To change the installation root directory to/usr/local/pear;
Enter 4 to install the command into the/usr/local/bin directory;
Other options default, all the way to the return.
3. Check if the installation is successful
The installation succeeds if the following results appear:
$ pear versionPEAR Version: 1.10.5PHP Version: 7.1.7Zend Engine Version: 3.1.0
Third, related connection
PECL Official Address: http://pecl.php.net/
PEAR Official Address: http://pear.php.net/
This article started in Mayanlong personal blog, Welcome to share, reproduced please indicate the source.
Mayanlong Personal Blog: http://www.mayanlong.com
Mayanlong personal Weibo: Http://weibo.com/imayanlong
Mayanlong GitHub Home: Https://github.com/yanlongma
Install PECL on MacOS