<div dir="ltr"><div class="gmail_extra">automatic selection</div><div class="gmail_extra">1) use a batch file and test things like %PROCESSOR_ARCHITECTURE% and generate a cmake -g "<appropriate environment>" </div><div class="gmail_extra">2) write a cmake script that does the test. and runs an appropraite cmake command specifying the generator</div><div class="gmail_extra"><br></div><div class="gmail_extra">instead of using msbuild, you can use 'cmake --build . --config Debug --target INSTALL -- /m:4 /v:m'  (for instance)  </div><div class="gmail_extra"><br></div><div class="gmail_extra">while I find it annoying that VS tests come from the registry, and therefore are always available, pre-empting that you have gcc in the path and not devenv... it has to default to something.</div></div>