Phpize-PHP Tutorial

Source: Internet
Author: User
A deep understanding of phpize. When installing (fastcgi mode), there is often such a command: usrlocalwebserverphpbinphpize I. What is phpize? What is phpize? Official php instructions: when installing (fastcgi mode), there is often such a command:/usr/local/webserver/php/bin/phpize
I. What does phpize do?
What is phpize? Official php instructions:
Http://php.net/manual/en/install.pecl.phpize.php
Phpize is used to expand the php Extension Module. phpize can be used to establish a php plug-in module.
For example, if you want to add memcached, ImageMagick, and other extension modules to the compiled php, you can use phpize to perform the following steps.
II. how to use phpize?
After php compilation is complete, the php bin directory contains the phpize script file. Run the following phpize command before compiling the extension module you want to add;
For example, if you want to add the memcache extension module to php, do the following:
------------------------
Tar zxvf memcache-2.2.5.tgz
Cd memcache-2.2.5/
/Usr/local/webserver/php/bin/phpize
./Configure-with-php-config =/usr/local/webserver/php/bin/php-config
Make
Make install
------------------------
Note:./The path of the php-config file can be specified after configure.
In this way, the compilation is complete. you also need to add the extension value to the php. ini file.
Extension = "memcache. so"
---------------------------------------------------------
Note: Cannot find config. m4.
This error is a silly one. after decompression, you need to cd to the folder. otherwise, phpize will report an error.

The memcache extension library of PHP is dynamically compiled. an error occurs when/usr/localphp/bin/phpize is executed,
Cannot find autoconf. Please check your autoconf installation and the $ PHP_AUTOCONF environment variable is set correctly and then rerun this script.
Obviously, files are missing and need to be installed. I found some materials online.
# Wget http://ftp.gnu.org/gnu/m4/M4-1.4.9.tar.gz
# Tar-zvxf m4-1.4.9.tar.gz
# Cd m4-1.4.9/
#./Configure & make install
# Cd ../
# Wget http://ftp.gnu.org/gnu/autoconf/Autoconf-2.62.tar.gz
# Tar-zvxf autoconf-2.62.tar.gz
# Cd autoconf-2.62/
#./Configure & make install
Run the following command to install
#/Usr/local/php/bin/phpize
#. /Configure-prefix =/usr/local/memcached-with-libevent =/usr/local/libevent-with-php-config =/usr/local/php/bin/php- config
# Make & make install

When coding (fastcgi mode), there is often such a command:/usr/local/webserver/php/bin/phpize I. What is phpize? What is phpize? Official php instructions :...

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.