Hi I've installed build tools from here: http://landinghub.visualstudio.com/visual-cpp-build-tools But CMake will automatically detect (and choose) Visual Studio 8 (installed here as well) instead.
Looking into the source: const std::string vsregBase = "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\"; std::vector<std::string> vsVerions; vsVerions.push_back("VisualStudio\\"); vsVerions.push_back("VCExpress\\"); vsVerions.push_back("WDExpress\\"); struct VSRegistryEntryName { const char* MSVersion; const char* GeneratorName; }; VSRegistryEntryName version[] = { /* clang-format needs this comment to break after the opening brace */ { "7.1", "Visual Studio 7 .NET 2003" }, { "8.0", "Visual Studio 8 2005" }, { "9.0", "Visual Studio 9 2008" }, { "10.0", "Visual Studio 10 2010" }, { "11.0", "Visual Studio 11 2012" }, { "12.0", "Visual Studio 12 2013" }, { "14.0", "Visual Studio 14 2015" }, { "15.0", "Visual Studio 15" }, { 0, 0 } }; for (int i = 0; version[i].MSVersion != 0; i++) { for (size_t b = 0; b < vsVerions.size(); b++) { std::string reg = vsregBase + vsVerions[b] + version[i].MSVersion; reg += ";InstallDir]"; cmSystemTools::ExpandRegistryValues(reg, cmSystemTools::KeyWOW64_32); if (!(reg == "/registry")) { installedCompiler = version[i].GeneratorName; break; } } } CMake will look for 'HKLM\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\14.0\InstallDir'. This key is not present indeed. When specified explicitly: cmake . -G "Visual Studio 14 2015" CMake will correctly detect the compiler and build without problems. These keys might be helpful when looking for Build Tools: [HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\14.0\Setup\VC] "ProductDir"="C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\" [HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\14.0\Setup\SSDT] "InstallDir"="C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\" "VersionNumber"="14.0.50616.0" Am I missing something or is this a bug which should be reported to issue tracker? Cheers, Eduard
-- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake