cmake: Fix mingw build