[windows] Fix build error with recent mingw-w64