I compiled apache with
./configure -prefix=/usr/local/apache2 -enable-so ever since. But as I needed suexec, it got a bit more complicated.
This is a how-to to compile Apache2 with
suexec.
1. Go to the apache source directory, where you originally compiled apache. Change to
support/ directory in it:
cd /opt/httpd-2.2.3/support/
2. Edit the following lines in
suexec.h:
#define AP_HTTPD_USER "daemon" (the user that apache runs under)
#define AP_LOG_EXEC "/var/log/apache2/suexec.log" (logfile dir)
#define AP_DOC_ROOT "/usr/local/apache2/htdocs"
#define AP_USERDIR_SUFFIX "html"
3. Compile suexec:
make suexec
4. Copy and chmod suexec:
cp suexec /usr/local/sbin/
chmod 4755 /usr/local/sbin/suexec
6. Now, I compiled Apache again, now with suexec support:
cd /opt/httpd-2.2.3/
make clean
./configure -prefix=/usr/local/apache2 -enable-so --enable-suexec --with-suexec-bin=/usr/local/sbin/suexec
make
make install
7. I had to compile php again too, because it adds some module into apache2.
Source:
http://archiv.debianhowto.de/de/apache2-phpfcgi-sarge/apache2-phpfcgi_suexec_install.html (german)