Using a common shared lib for multiple SAPIs?

From: Date: Tue, 18 Nov 2014 20:22:21 +0000
Subject: Using a common shared lib for multiple SAPIs?
Groups: php.internals 
Request: Send a blank email to internals+get-78955@lists.php.net to get a copy of this message
Hi there, the default build process of PHP on Unix/Linux links together all code needed for any SAPI that one builds (excluding dynamically loadable extensions). This often leads to relatively big SAPI shared object files. But most of this code is exactly the same for all SAPIs. That adds considerable to the package size if one ships e.g. CLI, CGI, mod_php and FPM. One could instead use one common shared library which conatins most of the code and only small additional SAPI shared object files with the SAPI specifics. I twisted the existing build process to achieve this building of a common lib plus one shared object per SAPI and it seems to work well. Is there any interest in adopting the existing build process to this? I can provide details how I do it currently. I use it for 5.5 and 5.6, but I expect it to work similarly for master which would probably be the target for the change. Thanks for any feedback, Rainer

« previous php.internals (#78955) next »