Use mingw-filesystem macros.