Apache:
./configure --with-pcre=/usr --enable-rewrite --enable-cgi --enable-modules=all --enable-so --prefix=/opt/apps/apache2 CFLAGS="-DBIG_SECURITY_HOLE"
PS: -DBIG_SECURITY_HOLE 允许以root用户运行apache
PHP5:
./configure --prefix=/data/apache2/php5 --with-apxs2=/data/apache2/bin/apxs --with-libdir=lib64 --enable-fastcgi --with-gd=/usr --with-jpeg-dir=/usr --with-png-dir=/usr --with-ttf --with-kerberos --with-zlib --enable-bcmath --with-bz2 --enable-calendar --with-curl --with-pcre-dir=/usr --enable-ftp --with-gettext --enable-mbstring --with-mysql '--with-mysqli --with-readline --enable-shmop --with-snmp --enable-soap --enable-sockets --enable-sysvshm --enable-sysvsem --enable-sysvmsg --with-xmlrpc --with-iconv --with-xsl --enable-zip --enable-zend-multibyte --with-freetype-dir=/usr
PS: 64位系统中使用 --with-libdir=lib64
LoadModule php5_module modules/libphp5.so
AddType application/x-httpd-php .php
php安装memcache支持
/data/apache2/php5/bin/phpize
./configure --with-php-config=/opt/apps/apache2/php5/bin/php-config --with-apxs=/opt/apps/apache2/bin/apxs --enable-memcache
fastcgi:
LoadModule fastcgi_module modules/mod_fastcgi.so
AddHandler fastcgi-script .do
ScriptAlias /fcgi/ /data/htdocs/oms/fcgi/