Fix Qt5 build
Fix mingw build