Fixes CMakeLists.txt for gcc/mingw