<div dir="ltr"><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">Hi,</div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">

 </div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">I am using cmake (3.0.0) to setup environment for my compiling on Windows and require mingw-w64 compiler. I pretty much followed your instruction with Method 2 here:</div>

<div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px"><a href="http://www.cmake.org/Wiki/CMake_FAQ#How_do_I_use_a_different_compiler.3F" target="_blank" style="font-family:arial,sans-serif;line-height:normal">http://www.cmake.org/Wiki/CMake_FAQ#How_do_I_use_a_different_compiler.3F</a><br>

</div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px"><br></div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">

But cmake output always showed that it is <span style="line-height:normal;color:rgb(34,34,34);font-family:arial,sans-serif">building for Visual Studio 12 2013 and the c </span><span class="" style="line-height:normal;color:rgb(34,34,34);background-color:rgb(255,255,204);font-family:arial,sans-serif">compiler</span><span style="line-height:normal;color:rgb(34,34,34);font-family:arial,sans-serif"> identification is MSVC 18.0.21005.1 not the mingw-w64 compiler I want.</span></div>

<div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px"><span style="line-height:normal;color:rgb(34,34,34);font-family:arial,sans-serif"><br></span></div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">

<span style="color:rgb(34,34,34);font-family:arial,sans-serif;line-height:normal">I usually deleted all files under the build subdir to remove cached stuff before start over.</span><span style="line-height:normal;color:rgb(34,34,34);font-family:arial,sans-serif"><br>

</span></div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;line-height:normal"><br></span></div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">

<div dir="ltr" style="color:rgb(34,34,34);font-family:arial,sans-serif;line-height:normal">However the cmake gui version is much better which allows to delete the cached stuff and then I can specify the generator for the making, say MinGW. I was able to specify the right <span class="" style="background-color:rgb(255,255,204)">compiler</span>. </div>

<div dir="ltr" style="color:rgb(34,34,34);font-family:arial,sans-serif;line-height:normal"><br></div><div style="color:rgb(34,34,34);font-family:arial,sans-serif;line-height:normal">So why only cmake gui version works for me, not the cmake command? </div>

<div class="" style="color:rgb(34,34,34);font-family:arial,sans-serif;line-height:normal"></div></div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px"><br></div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">

Thanks in advance.</div><div style="color:rgb(0,0,0);font-family:'Helvetica Neue',Helvetica,sans-serif;line-height:22px">Jici</div></div>