On linux, you can run the configure script to make it into a CGI versus a lib.
I think the source for windows also allows that. I have no clue what compilation system the win source code uses (cygwin??). Anyway, somewhere in the config there should be a setting for CGI mode or CGI binary. Set that and it will compile an EXE.
If you download the IIS distrib, I think that contains a CGI (an exe program). I'm not 100% sure, but download it and see. Don't run the setup, just look through the files and if you spot a php.exe, copy that file along with all the DLLs and INIs to a system directory like C:\WINNT or WINNT\System32 (or Windows, if you aren't on nt/2k/xppro)
-sridhar