安装apache on Unix

./configure --prefix=/home/julio/apache/httpd-2.4.2/srclib/apr
make
make install


./configure --prefix=/home/julio/apache/httpd-2.4.2/srclib/apr-util/ --with-apr=/home/julio/apache/httpd-2.4.2/srclib/apr
make
make install


./configure --prefix=/home/julio/apache/pcre-8.31/
make 
make install


./configure --prefix=/home/julio/apache/httpd-2.4.2/ --with-apr=/home/julio/apache/httpd-2.4.2/srclib/apr/ --with-included-apr --with-apr-util=/home/julio/apache/httpd-2.4.2/srclib/apr-util --with-pcre=/home/julio/apache/pcre-8.31 --enable-file-cache --enable-cache --enable-disk-cache --enable-mem-cache --enable-deflate --enable-expires --enable-headers --enable-usertrack --enable-cgi --enable-vhost-alias --enable-rewrite --enable-so --enable-ssl 
make 

make install


IMPORTANT: don't forget to change the default port from 80 to something else e.g. 8080, this is especially important for non-root user. (How to? open httpd.conf -> search "Listen 80" -> change it to "Listen 8080".

Deleting # and changing SREVERNAME accordingly.


Stop service 

apachectl -k stop


Restart service

apachectl -k restart

你可能感兴趣的:(安装apache on Unix)