View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0010638CMakeCMakepublic2010-04-29 02:002011-06-17 18:10
ReporterAlexander 
Assigned ToDavid Cole 
PrioritynormalSeverityfeatureReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product VersionCMake-2-8 
Target VersionCMake 2.8.5Fixed in VersionCMake 2.8.5 
Summary0010638: Enable code analysis in Visual Studio 9 (2008)
DescriptionThere is no way to enable code analysis for C/C++ on Visual Studio 2008 build. Microsoft document "/analize" flag on cl.exe, but it dosn't work.
Microsoft use "EnablePREfast" boolean attribute on VisualStudioProject/Configurations/Configuration/Tool[@Name='VCCLCompilerTool'] in .vcproj
When I add two flags to cmVS8ExtraFlagTable (), the problem was solved and cmake command:
set( CMAKE_C_FLAGS "-analize" )
turned code analysis ON, and command
set( CMAKE_C_FLAGS "-analize-" )
turned code analysis OFF.

When cmake project dosn't contain nether "-analize" nor "-analize-" flags vcproj dosn't contain EnablePREfast attribute.
Additional Informationstatic cmVS7FlagTable cmVS8ExtraFlagTable[] =
...
  {"EnablePREfast", "analize", "enable code analysis for c/c++ on build",
     "TRUE", 0},
  {"EnablePREfast", "analize-", "disable code analysis for c/c++ on build",
     "FALSE", 0},
...
TagsNo tags attached.
Attached Files

 Relationships

  Notes
(0025200)
David Cole (manager)
2011-02-01 13:57

Fix pushed to 'next'
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=15e422249eab4d920ffeb3de08057d35f3bc6387 [^]
(0026715)
David Cole (manager)
2011-06-06 18:25

Closing resolved issues that have not been updated in more than 3 months.

 Issue History
Date Modified Username Field Change
2010-04-29 02:00 Alexander New Issue
2011-01-17 15:39 David Cole Assigned To => David Cole
2011-01-17 15:39 David Cole Status new => assigned
2011-02-01 13:57 David Cole Note Added: 0025200
2011-02-01 13:57 David Cole Status assigned => resolved
2011-02-01 13:57 David Cole Resolution open => fixed
2011-02-16 11:42 David Cole Target Version => CMake 2.8.5
2011-06-06 18:25 David Cole Status resolved => closed
2011-06-06 18:25 David Cole Note Added: 0026715
2011-06-17 18:10 David Cole Fixed in Version => CMake 2.8.5


Copyright © 2000 - 2018 MantisBT Team