CMake support in Visual Studio – what’s new in 2017 15.2 update
Today’s preview release of Visual Studio 2017 15.2 update comes with several improvements and new features in CMake Tools for Visual Studio – recently updated to cover 15.2. We have upgraded the included version of CMake to 3.7.2 and enhanced the discoverability of features in the CMake menu. This update also includes bugfixes for community reported issues.
Please download the preview and try out the latest CMake features. If you are just getting started with CMake, follow the link to learn more about CMake support in Visual Studio. We are looking forward to your feedback.
CMake Tools Upgraded to CMake 3.7.2
We want to make Visual Studio the best way to work with CMake projects on Windows. To enhance compatibility with your projects, we have updated the internal version of CMake that the Visual Studio CMake tools use from version 3.6 to version 3.7.2.
CMake 3.7.2 brings many new features and improvements, which you can read about in CMake’s 3.7 release notes. On the IDE side, the update to CMake 3.7.2 gives Visual Studio more insight into your projects’ structure and allows Visual Studio to provide more accurate IntelliSense and builds.
A More Intuitive CMake Menu
The most visible change that many of you will notice in the update is the revamped CMake menu:
The revamped menu brings all the common operations to the forefront. At the top of the menu Build, Rebuild, Clean, and (if applicable) Test All apply globally to every CMake project detected in an open folder. The menu items below those allow finer control, such as building individual targets and managing the CMake cache. This menu should now be a one stop shop for all things CMake instead of having operations and entry points scattered around the IDE.
Bugfixes and Improvements
The 15.2 update includes many improvements and addresses several bugs, most of which were reported by the community. The following issues have been fixed in the latest release:
- Visual Studio fails to launch CMake targets because the output location cannot be found for some CMakeLists. Developer Community: 24375 24359
- CMake tools freeze or malfunction when the build output is a child of the opened folder. Developer Community: 12830 25412
- Running tests triggers installation stage. Developer Community: 19007
- Tests attempt to run even when build fails. Developer Community: 17949
- No way to pass arguments to tests via CMakeSettings.json. Developer Community: 17968
- CMake processing appears to be stalled and cannot be canceled for large or unsupported CMakeLists. Developer Community: 9879 13799 15384 24404 31401
- Visual Studio does not automatically restart cache generation after a failure upon re-opening a folder. Developer Community: 13185
- Visual Studio does not support CMake workspaces with long paths. Developer Community: 9222
- CMake cache generation fails if standard tools are not in toolbar. Developer Community: 37195
- CMake Tools for Visual Studio do not support “Rebuild All” Developer Community: 22318
- CMake output pane shows incomplete status during cache generation and IntelliSense configuration.
Send Us Feedback
To try out the latest and greatest CMake features and give us some early feedback, please download and install the latest Visual Studio 2017 Preview. As always, we welcome your feedback. Feel free to send any comments through e-mail at email@example.com, through Twitter @visualc, or Facebook at Microsoft Visual Cpp.
If you encounter other problems with Visual Studio 2017 please let us know via Report a Problem, which is available in both the installer and the IDE itself. For suggestions, let us know through UserVoice. We look forward to your feedback!