If you wish to get the latest PHP source tree, you can obtain it through anonymous CVS. You should be warned that the CVS version is a development version, and as such, is often unstable, and may not even compile properly. The advantage of using CVS, though, is that you can get the latest fixes and updates, without having to wait for the official releases.
You can find more information about CVS, and download clients for most major platforms, at CVShome.org.
Getting the PHP 4.0 CVS version to work is a bit more complicated than it is for PHP 3.0 for two main reasons - first, the engine, Zend, has been separated from the main language tree, and resides in a different CVS repository. And second, PHP 4.0 uses a much more advanced configuration system, that requires you to have not only autoconf installed, but also automake and libtool.
All of the necessary utilities (autoconf, automake. libtool, bison and flex) can be obtained from the GNU FTP site.
If after these warnings you're still interested in obtaining PHP from CVS, here's how.
cvs -z3 update -d -P checkout -P diff -u
cvs -d :pserver:cvsread@cvs.php.net:/repository login
cvs -d :pserver:cvsread@cvs.php.net:/repository co php4
cd php4
cvs -d :pserver:cvsread@cvs.zend.com:/repository login
cvs -d :pserver:cvsread@cvs.zend.com:/repository co Zend TSRM
Note:
Certain combinations of autoconf, automake and libtool may not work when used together.
See below for details.
There are also other things, like the XML source code for the documentation, available via anonymous CVS. See the web-based view of the CVS server to see what is available, and substitute the appropriate name for "php4" in step 3 (and ignore the later steps).
You can also mirror the PHP CVS repository using CVSup. See here for more details.
autoconf, automake and libtool information
There seem to be problems with libtool 1.4.2. It is suggested that you use libtool 1.4, along with the most current versions of autoconf and automake. You should also ensure that autoconf, automake and libtool are installed in the same directory.
The following combination are known to work.