On a Windows machine, you'll first need Visual Studio (the free version is fine). Once that's complete:
- Open a command prompt
- Find
vcvarsall.bat
in your VS installation path, thencall
it withx64
as it's argument. It will look something like:call "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\vcvarsall.bat" x64
- Run
cl main.c -nologo -Zi -link user32.lib
That should compile and generate main.exe
.