通过phpize来安装imap这个扩展真是太闹心了,一个问题接着一个问题。下面是安装过程。。。php版本为5.6.4
[root@web2 imap]# ./configure
configure: error: utf8_mime2text() has new signature, but U8T_CANONICAL is missing. This should not happen. Check config.log for additional information.
#查了下,安装 libc-client-devel 包可以解决
[root@web2 imap]# yum install libc-client-devel
Downloading Packages:
ftp://10.0.0.1/yum/Packages/libc-client-2007e-11.el6.x86_64.rpm: [Errno 14] PYCURL ERROR 19 - "Given file does not exist"
Trying other mirror.
ftp://10.0.0.1/yum/Packages/libc-client-devel-2007e-11.el6.x86_64.rpm: [Errno 14] PYCURL ERROR 19 - "Given file does not exist"
Trying other mirror.
Error Downloading Packages:
libc-client-devel-2007e-11.el6.x86_64: failure: Packages/libc-client-devel-2007e-11.el6.x86_64.rpm from dvd: [Errno 256] No more mirrors to try.
libc-client-2007e-11.el6.x86_64: failure: Packages/libc-client-2007e-11.el6.x86_64.rpm from dvd: [Errno 256] No more mirrors to try.
#我做的本地源,安装其他软件都没问题,结果安装这个包报错。于是下载了这两个包libc-client-2007e-11.el6.x86_64.rpm、libc-client-devel-2007e-11.el6.x86_64.rpm,安装好了继续
[root@web2 imap]# ./configure #再次configure
configure: error: Cannot find imap library (libc-client.a). Please check your c-client installation. #报错
#解决办法,创建库文件软连接
[root@web2 imap]# ln -s /usr/lib64/libc-client.so /usr/lib/libc-client.so
[root@web2 imap]# ./configure #再次configure,还是报错,如下:
configure: error: This c-client library is built with Kerberos support.
Add --with-kerberos to your configure line. Check config.log for details.
[root@web2 imap]# ./configure --with-kerberos #那就加上这个参数再试一次
Add --with-imap-ssl to your configure line. Check config.log for details. #报错
[root@web2 imap]# ./configure --with-kerberos --with-imap-ssl #加上这两个参数再次configure,终于不报错了!