Compiling PHP 5?

software development

#1

I want to compile PHP5 with the latest version of GD (GIF support is back). But I dont know how do this considering I want to use CGI instead of Apache. Anyone have any instructions?