- yum install openssl-devel
- yum install openjdk-devel #java的开发环境
- wget http://apache.fayea.com//apr/apr-1.5.2.tar.gz
tar zxvf apr-1.5.2.tar.gz
cd apr-1.3.2
./configure
make
make install - wget http://apache.fayea.com//apr/apr-util-1.5.4.tar.gz
tar zxvf apr-util-1.3.2.tar.gz
cd apr-util-1.3.2
./configure --with-apr=/usr/local/apr
make
make install - cd /usr/local/tomcat-6.0.18/bin
tar zxvf tomcat-native.tar.gz
cd tomcat-native-1.1.14-src/jni/native
./configure --with-apr=/usr/local/apr --with-java-home=/usr/java/jdk1.6.0_11 #java-home为java开发环境的目录,openjdk一般安装在/usr/lib/jvm/这里
make
make install - vi /etc/profile #后面添加以下内容
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/apr/lib
source /etc/profile # 使profile生效
转载于:https://my.oschina.net/oyj/blog/532880