ubuntu 安裝apache

来源:互联网 发布:韩国代购的软件 编辑:程序博客网 时间:2024/05/22 05:17
需要准备的有:

1 httpd-2.4.16.tar.gz http://httpd.apache.org/download.cgi#apache24

 2 apr-1.5.2.tar.gz  http://apr.apache.org/download.cgi

 3 apr-util-1.5.4.tar http://apr.apache.org/download.cgi

4pcre-8.37.tar.gzhttp://www.pcre.org

5 g++ 环境


开始安装

1解压 1-4的文件 tar -zxvf xxxx.tar.gz

2g++ 环境安裝

1sudo apt-get update

2 sudo apt-get install g++

3 安装pcre-8.37.tar.gz

1到pcre-8.37的根目录

2 ./configure -prefix=/usr/local/pcre

3 make

4 make install

4 安裝apr-1.5.2

1到apr-1.5.2的跟目錄

2./configure --prefix=/usr/local/apr

3 make

4 make install

5安裝apr-util-1.5.4

1到apr-util-1.5.4的跟目錄

2./configure --prefix=/usr/local/apr-util --with-apr=/usr/local/apr

3 make

4 make install

6 安裝apache

1到httpd-2.4.16根目錄

2./configure --prefix=/usr/local/apache --with-pcre=/usr/local/pcre --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util -enable-dav -enable-so -enable-maintainer-mode -enable-rewrite

3 要把上面的 整個語句都写上 别偷懒

3make

4 make install


然后配置和启动