An unforseen need required us either to put a six years old PHP 5.1 application back online for a few weeks in our Intranet. Between rewriting or adapt a significant portion of the code to make it work on 5.3+ or getting back a system with a running 5.1 PHP with its Oracle dependencies, business and team constrainsts usually give little choice:
Compilation for a temporary site seemed to be the solution with the lowest duration and risks, however I had to adjust PHP 5.1 a bit to make it work with our recent Centos systems. This post details what I had to modify.