You cannot do this explicitly only in cmake (ATM), but here is one way to hide several targets more efficiently: just put them in the same folder (in cmake) and then hide the folder (in visual studio).
Suppose you have cmake objects called Mm, Nn, and Pp that you want to hide in Visual Studio. You have to say cmake to allow "folders" and just set a property called FOLDER like that
set_property(GLOBAL PROPERTY USE_FOLDERS ON) set_target_properties(Mm Nn Pp PROPERTIES FOLDER nameOfTheFolder)
and then right-click on the nameOfTheFolder folder in the solution and hide it in the folder.
If you want to see the hidden folders again, right-click on the solution and then open the folders (this is at least the same as in Visual Studio 2010).
source share