Export the debug API as functions instead of pointers.
A few other import fixes for Mingw.

6 files changed