centos6.3+php5.3.23 do not recompile php add IMAP Extension Module

Source: Internet
Author: User
Tags imap ini zend

Locate the previously installed package, or download the unpacked installation package again:
1. Enter the source code installation package

The code is as follows Copy Code

[Root@hexu.org ~]$ Cd/data/softs/php_packet/php-5.3.23/ext/imap

2. Installing IMAP dependencies

The code is as follows Copy Code

[root@hexu.org imap]$ Yum install-y libc-client-devel
[Root@hexu.org imap]$ ln-s/usr/lib64/libc-client.so/usr/lib/libc-client.so

3. To install

The code is as follows Copy Code

[Root@hexu.org imap]$/usr/local/php/bin/phpize
[root@hexu.org imap]$./configure--with-php-config=/usr/local/php/bin/php-config--with-imap--with-imap-ssl-- With-kerberos
[root@hexu.org imap]$ make && make install

4. Final adjustment php.ini

The code is as follows Copy Code

[Root@hexu.org imap]$ Vi/usr/local/php/lib/php.ini
# #vi php.ini add following config
[IMAP]
Extension = imap.so

5. Check if the installation is successful

The code is as follows Copy Code

[Root@hexu.org imap]# Php-v
PHP 5.3.23 (CLI) (built:apr 7 2013 23:20:21)
Copyright (c) 1997-2013 the PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2013 Zend Technologies
[Root@hexu.org imap]# php-m | grep IMAP
IMAP # # See here, instructions for successfully installing the

In order to install in the above should not have an error, if found to be prompted to find the appropriate dependent package installation, the following example installation process encountered 2 error.
1. No installation libc-client-devel caused by the first step above installation can be, Error info:

The code is as follows Copy Code

Checking for Utf8_mime2text signature ... new
Checking for u8t_decompose ...
Configure:error:utf8_mime2text () has new signature, but U8t_canonical is missing. This should is not happen. Check Config.log For additional information.

2. Cannot find LIBC-CLIENT.A library, need to manually add File link, errof info:

The code is as follows Copy Code

Checking for crypt In-lcrypt ... yes
Configure:error:Cannot Find IMAP library (LIBC-CLIENT.A). Please check your c-client installation.

Workaround:

The code is as follows Copy Code

[root@hexu.org]$ ln-s/usr/lib64/libc-client.so/usr/lib/libc-client.so


If the cannot find IMAP library (LIBC-CLIENT.A) appears.

We just have to execute

  code is as follows copy code

# yum Install libc-client-devel.x86_64
# ln-s/usr/lib64/libc-client.so/usr/lib/libc-client.so

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.