Add a terrible mingw build script.

Should sort out the build system at some point.
Silence some WinSock warnings.

Bad bad bad.