[cmake-developers] [CMake 0013016]: [patch] CMake does not support setting "CompileAsManaged" attribute for Visual Studio managed C++ files.

Mantis Bug Tracker mantis at public.kitware.com
Mon Mar 5 18:32:00 EST 2012


The following issue has been SUBMITTED. 
====================================================================== 
http://public.kitware.com/Bug/view.php?id=13016 
====================================================================== 
Reported By:                chris.haverkate
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   13016
Category:                   CMake
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2012-03-05 18:32 EST
Last Modified:              2012-03-05 18:32 EST
====================================================================== 
Summary:                    [patch] CMake does not support setting
"CompileAsManaged" attribute for Visual Studio managed C++ files.
Description: 
CMake does not support setting "CompileAsManaged" attribute for Visual Studio
managed C++ files with the Visual Studio 10 generator.

This is not a very "cross-platform" feature (unless Mono supports managed C++?)
but it is necessary for Intellisense for managed code.

Steps to Reproduce: 
Create a shared library project with managed C++ files with the Visual Studio 10
generator, and observe the apparent inability to specify whether a file needs to
be compiled as managed C++ in the generated project XML file.

Additional Information: 
The attached patch adds support for the VS_COMPILE_AS_MANAGED file property:

set_source_files_properties(file.cpp PROPERTIES VS_COMPILE_AS_MANAGED false)

I tried to copy the coding style but might not have it quite right, there wasn't
much guidance on the wiki. If there is a better way to introduce these changes,
I'm happy to resubmit.
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2012-03-05 18:32 chris.haverkateNew Issue                                    
2012-03-05 18:32 chris.haverkateFile Added:
VisualStudio10GeneratorAddingCompileAsManagedForSourceFileProperties.patch      
             
======================================================================




More information about the cmake-developers mailing list