[CMake] SCC bindings missing AUXPATH support?

Robert Dailey rcdailey at gmail.com
Mon Oct 31 20:20:20 EDT 2011


I forgot to explain why I made the change to begin with. Basically this all
comes down to Perforce binding support. SccAuxPath is used to specify the
Perforce connection string. Without this, each project opened will prompt
the user for the information via modal dialog. This gets very annoying...

Here is an example of how I have setup each of my projects:

set_target_properties(
"${project_name}" PROPERTIES
VS_SCC_AUXPATH
"P4SCC#${PERFORCE_SERVER}##${PERFORCE_USER}##${PERFORCE_WORKSPACE}"
VS_SCC_LOCALPATH "${CMAKE_SOURCE_DIR}"
VS_SCC_PROJECTNAME "Perforce Project"
VS_SCC_PROVIDER "MSSCCI:Perforce SCM"
)

All of the PERFORCE_ variables are cache variables, so that the user can
specify their credentials, server, and workspace. These are all formatted
into the connection string perforce expects.

The resulting XML in the VCPROJ looks like so:

SccProjectName="Perforce Project"
SccLocalPath="C:/Code/work/sandbox"
SccAuxPath="P4SCC#perforce.mycompany.com:3666##rdailey##rdailey-t510-sandbox
"
SccProvider="MSSCCI:Perforce SCM"

When I open the generated solution, all projects load perfectly with no
prompts and everything is binded to source control :)

---------
Robert Dailey


On Mon, Oct 31, 2011 at 7:06 PM, Robert Dailey <rcdailey at gmail.com> wrote:

> I fiddled around with TortoiseGit and managed to create the patch. It is
> attached.
>
> Please integrate this into your repository so it is included in version
> 2.8.7 :)
>
> ---------
> Robert Dailey
>
>
>
> On Mon, Oct 31, 2011 at 5:41 PM, Robert Dailey <rcdailey at gmail.com> wrote:
>
>> I have added source code support for this myself. I updated the following
>> files:
>>
>> cmLocalVisualStudio7Generator.cxx
>> cmLocalVisualStudio10TargetGenerator.cxx
>>
>> The existing SCC support code was already in these files, I just added
>> the SccAuxPath support to it.
>>
>> I'm not an expert at creating patch files outside of TortoiseSVN on
>> Windows, so could someone explain how to create a patch file for these on
>> Windows 7? Also how would you like me to deliver the code? I hope to see it
>> introduced in version 2.8.7
>>
>> Thanks.
>>
>> ---------
>> Robert Dailey
>>
>>
>>
>> On Mon, Oct 31, 2011 at 4:10 PM, Robert Dailey <rcdailey at gmail.com>wrote:
>>
>>> There are actually 4 SCC related key/value pairs used in VS2003 VCPROJ
>>> files:
>>>
>>> SccProjectName="SAK"
>>> SccAuxPath="SAK"
>>>  SccLocalPath="SAK"
>>> SccProvider="SAK"
>>>
>>> CMake supports these 3 via set_target_properties():
>>>
>>> VS_SCC_LOCALPATH
>>> VS_SCC_PROJECTNAME
>>> VS_SCC_PROVIDER
>>>
>>> Apparently one more is needed to support "SccAuxPath":
>>>
>>> VS_SCC_AUXPATH
>>>
>>> Can someone add support for this? Thanks.
>>>
>>> ---------
>>> Robert Dailey
>>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20111031/a4d3e192/attachment.htm>


More information about the CMake mailing list