Fix windows build

When building for Windows (using MingW on Linux), the build fails for two reasons:

* First, the debug macro was incorrect; DEBUG_FMT() allows printf-style but DEBUG() does not.  Compiler complained and refused to build.
* Second, the UUID value was "undefined" to the linker, and refusing to generate a DLL as a result. Once the correct UUID headers were included from the Windows APIs, the build succeeded and the DLL was created.

These commits allow the mingw-compiled Windows build to work again.
http://msdn.microsoft.com/en-us/library/windows/hardware/ff545978%28v=vs.85%29.aspx