checking for APR... no
configure: error: APR not found. Please read the documentation.
checking for pcre-config... false
configure: error: pcre-config for libpcre not found. PCRE is required and available from http://pcre.org/
如下图:
这是由于没有安装apr 及 apr-util 以及PCRE,因此需要下载安装,这里演示的是源码安装。
方法/步骤
-
下载apr-1.4.2.tar.gz并执行编译安装
# tar -zxvf apr-1.4.2.tar.gz
# cd apr-1.4.2
# ./configure
# make && make install
注意:在执行configure可能会出现
rm: cannot remove `libtoolT': No such file or directory错误信息。网上查阅了一下资料,提示编辑configure这个文件,将 $RM “$cfgfile” 那行注释掉 ,然后重新编译即可。
-
下载并编译安装apr-util-1.3.10
# tar -zxvf apr-util-1.3.10.tar.gz
# cd apr-util-1.3.10
# ./configure -with-apr=/usr/local/apr
# make && make install
-
pcre的编译安装
# tar -zxvf pcre-8.10.tar.gz
# cd pcre-8.10
# ./configure
# make && make install
END
注意事项
在make pcre的时候如果出现libtool: line 990: g++: command not found错误,则说明没有安装gcc+,装上gcc+就可以编译过去