Fix some mingw stuff