PHP tips for installing extensions by using the Pecl method

Source: Internet
Author: User
Tags pear
The following small series for you to share a PHP through the pecl way to install the extension of the example, with a good reference value, I hope to be helpful to everyone. Let's take a look at it with a little knitting.

1, install the PECL and create shortcut keys (if the installation of PHP with can ignore this step installation steps)

# cd/usr/local/php/bin/  //Can see if it has pecl # wget Http://pear.php.net/go-pear.phar-O go-pear.php # php go-pear.php # ln -s/usr/local/php/bin/pecl/usr/bin/pecl

2, whether the query has been included in the extension

# PECL Search Swoole  //swoole to query the extension (take the swoole extension as an example)//query result: Retrieving data ... 0%. Matched packages, Channel Pecl.php.net: ======================================= package stable/(Latest) Local Swoole 1.9.23 (Stable) Event-driven asynchronous and concurrent networking engine with high performance for PHP. Swoole_serialize 0.1.1 (Beta) the fastest and smallest serialize fucntion bound for PHP7

3. Installation Configuration extension

# pecl Install swoole//Output Result: Build process completed successfully installing '/usr/lib64/php/modules/swoole.so ' Install O k:channel://pecl.php.net/swoole-1.9.23 configuration Option "Php_ini" is not set to php.ini location should add "Exte Nsion=swoole.so "to php.ini  # configure php.ini reference swoole.so and then restart PHP

Note: compared to phpize mode installation, PECL mode installation is more convenient, can save manually added to the php.ini link

The above PHP through the pecl way to install the extension of the example is small part of the share to everyone's content, I hope to give you a reference, but also hope that we support PHP Chinese network.

Articles you may be interested in:

PHP tips for mb_strstr basic PHP Learning Notes

PHP deletes an array of elements specified in the subscript method PHP instance

PHP technique for parsing XML and generating SQL statements

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.