MantisBT - CMake
View Issue Details
0010483CMakeCMakepublic2010-03-30 03:032010-09-09 23:59
Conrad 
 
normalmajoralways
closedfixed 
CMake-2-8 
CMake 2.8.3CMake 2.8.3 
0010483: Visual Studio 2010 *.vcxproj file parsing for INCLUDE_EXTERNAL_MSPROJECT: ProjectGUID now ProjectGuid
We use the INCLUDE_EXTERNAL_MSPROJECT for the third-party package Xerces. I used the latest VS 2010 release candidate to upgrade the third-party package's old VS 9 Xerces.vcproj files to VS 2010 Xerces.vcxproj files. The resulting Xerces.vcxproj file was not correctly imported into the CMake-generated 3rdParty.sln solution because its GUID was not successfully parsed. The same problem occurs with all five other packages that we import with INCLUDE_EXTERNAL_MSPROJECT as well, so it's not Xerces-specific.

Examining the VS 2010-generated Xerces.vcxproj files in a text editor, I saw that the XML was:
  <PropertyGroup Label="Globals">
    <ProjectGuid>{152CE948-F659-4206-A50A-1D2B9658EF96}</ProjectGuid>
  </PropertyGroup>

Note the GUID element name is "ProjectGuid" rather than the old "ProjectGUID".

I fixed this in the CMake source code by changing a single line in cmLocalVisualStudio10Generator.cxx from:
  if(strcmp("ProjectGUID", name) == 0)
to:
  // VS 2010 betas: "ProjectGUID". 2010-03-27 release candidate: "ProjectGuid"
  if(strcmp("ProjectGUID", name) == 0 || strcmp("ProjectGuid", name) == 0)

This fixes the problem in my version of the code.

I'm new to git and probably don't have commit access.
No tags attached.
Issue History
2010-03-30 03:03ConradNew Issue
2010-07-10 21:38ConradNote Added: 0021348
2010-07-13 09:17Bill HoffmanNote Added: 0021377
2010-07-13 09:17Bill HoffmanStatusnew => closed
2010-07-13 09:17Bill HoffmanResolutionopen => fixed
2010-09-09 23:59David ColeFixed in Version => CMake 2.8.3
2010-09-09 23:59David ColeTarget Version => CMake 2.8.3

Notes
(0021348)
Conrad   
2010-07-10 21:38   
Perhaps I was too verbose?

Concise version: INCLUDE_EXTERNAL_MSPROJECT is broken in VS 2010.

One-line fix: in cmLocalVisualStudio10Generator.cxx change:
  if(strcmp("ProjectGUID", name) == 0)
to:
  // VS 2010: "ProjectGUID" changed to "ProjectGuid"
  if(strcmp("ProjectGUID", name) == 0 || strcmp("ProjectGuid", name) == 0)
(0021377)
Bill Hoffman   
2010-07-13 09:17   
Thanks, this has been pushed to next. 4e7b24e..3cde195 next -> next