Linux 安装 httpd2.4.16
假设:
apr安装在: /opt/httpd/apr
apr-util安装在 /opt/httpd/apr-suite/apr-util
apr-iconv安装在/opt/httpd/apr-suite/apr-iconv
apache http server(httpd)安装在 /opt/httpd/httpd
1, 下载各个应用
wget http://mirrors.cnnic.cn/apache//httpd/httpd-2.4.16.tar.gz
wget http://archive.apache.org/dist/apr/apr-iconv-1.2.1.tar.gz
wget http://archive.apache.org/dist/apr/apr-util-1.5.4.tar.gz
wget http://archive.apache.org/dist/apr/apr-1.5.2.tar.gz
2,解压各个压缩包,示例:
tar -zxvf apr-1.5.2.tar.gz
3,设置安装路径并安装(各个命令在执行前,需要进入到安装程序解压后的目录中再执行./configure)
./configure --prefix=/opt/httpd/apr && make && make install
./configure --prefix=/opt/httpd/apr-suite/apr-util --with-apr=/opt/httpd/apr/bin/apr-1-config && make && make install
./configure --prefix=/opt/httpd/apr-suite/apr-iconv --with-apr=/opt/httpd/apr && make && make install
./configure --prefix=/opt/httpd/httpd --enable-mods-shared=all --enable-proxy --enable-proxy-connect --enable-proxy-ftp --enable-proxy-http --enable-proxy-ajp --enable-proxy-balancer --enable-rewrite --enable-status --with-apr=/opt/httpd/apr --with-apr-util=/opt/httpd/apr-suite/apr-util