Building PHP on Windows 7 with Visual Studio 2010 installed...- this differs slightly from the stepbystepbuild info and it worked for me :)

0. make a directory and unpack both of these into it: php-5.4.23-src.zip (should have a win32 directory in it) php-sdk-binary-tools-20110915 1. Run Visual Studio 2010 command prompt2. CD to your php source root directory3. set mc="C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\mc" - or wherever it is on your machine4. vcvars325. set path=your_php_source_directory\bin;%PATH%6. buildconf7. configure --help this gets you a list of all the options, then... (e.g.)8. configure --disable-all --enable-cgi --with-sqlite39. nmake10. results should be in Release_TS in this example, all we need is php-cgi.exe and php5ts.dll

To build everything in the distribution, pass --enable-snapshot-build to configure.js. In addition, you may like to use "snap" as the nmake target. If you intend to build the PHP Windows Installer, WiX source files can be obtained from http://svn.php.net/repository/php/win-installer/.

If you are getting the following error message:Input Error: There is no script engine for file extension ".js"with Visual Studio 2005 Command Prompt or similar, try to add "/e:jscript" to the command line.