Hi,
In order to compile apache from source with ssl and support for the php module, you can run the configure script like this:
Code:
./configure --enable-ssl --enable-so --prefix=/path/to/apache2
This way, you can later on install php as a ynamic module.
More details you can find
here
Regards