MantisBT - CMake
View Issue Details
0013788CMakeCMakepublic2012-12-12 15:072013-06-28 15:40
Shaun Williams 
Alex Neundorf 
normalfeaturealways
closedfixed 
CMake 2.8.10.2 
 
0013788: Hide Automoc Targets in Visual Studio projects
This is a feature request to hide the <target>_automoc projects in a folder in Visual Studio:
http://public.kitware.com/pipermail/cmake-developers/2012-June/004402.html [^]

It is also related to issue 0013688.

------------

The included patch adds in a new global property:

$ cmake --help-property AUTOMOC_FOLDER
cmake version 2.8.10.20121212

  AUTOMOC_FOLDER
       Name of FOLDER for *_automoc targets that are added automatically by
       CMake.

       If not set, CMake uses the FOLDER property of the parent target as a
       default value for this property. See also the documentation for the
       FOLDER target property and the AUTOMOC target property.

SET_PROPERTY(GLOBAL PROPERTY USE_FOLDERS ON)
SET_PROPERTY(GLOBAL PROPERTY AUTOMOC_FOLDER automoc)
No tags attached.
related to 0013688closed Alex Neundorf No way to specify target properties for AUTOMOC-generated targets 
patch automoc_folder.patch (1,840) 2012-12-12 15:07
https://public.kitware.com/Bug/file/4587/automoc_folder.patch
Issue History
2012-12-12 15:07Shaun WilliamsNew Issue
2012-12-12 15:07Shaun WilliamsFile Added: automoc_folder.patch
2012-12-12 15:45Alex NeundorfDescription Updatedbug_revision_view_page.php?rev_id=974#r974
2012-12-12 15:45Alex NeundorfSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=976#r976
2012-12-12 15:45Alex NeundorfAssigned To => Alex Neundorf
2012-12-12 15:45Alex NeundorfStatusnew => assigned
2012-12-12 15:45Alex NeundorfRelationship addedrelated to 0013688
2012-12-12 16:23Shaun WilliamsNote Added: 0031873
2013-01-30 03:43Marcel BeisterNote Added: 0032176
2013-04-10 14:32Alex NeundorfNote Added: 0032797
2013-04-10 16:23Shaun WilliamsNote Added: 0032802
2013-06-28 15:40Alex NeundorfNote Added: 0033403
2013-06-28 15:40Alex NeundorfStatusassigned => closed
2013-06-28 15:40Alex NeundorfResolutionopen => fixed

Notes
(0031873)
Shaun Williams   
2012-12-12 16:23   
The rationale is to allow the user to organize how the automoc projects are displayed in the Solution View. For our case, all projects are at the root level, and are sprinkled with the automoc projects that we would like to hide away in another folder.
(0032176)
Marcel Beister   
2013-01-30 03:43   
I would prefer a mixture of the solution proposed by Shaun Williams in this thread and the solution in 0013688. To inherit the folder properties from the source target is a good default behavior, but this does not allow the user to separate auto generated targets from real source targets. Is there any chance to get this in 2.8.11 or 2.8.11.1?
(0032797)
Alex Neundorf   
2013-04-10 14:32   
Can you please give 2.8.11 RC2 a try ?
Brad modified something the support for VS >= 7 so that pre-build events are used.
This should do what you need if I understand correctly.

http://www.kitware.com/blog/home/post/468 [^]

Please let me know whether it works for you or not.
(0032802)
Shaun Williams   
2013-04-10 16:23   
I tried the 2.8.11 RC2, and it didn't work. Pre-build events have no relation to creating an AUTOMOC folder in VS at configure time.

I uploaded a patch for this 4 months ago. It is attached to this issue.
(0033403)
Alex Neundorf   
2013-06-28 15:40   
Thanks for the patch.
I committed it, slightly modified, and merged it into next.
It should be in 2.8.12.