Merge topic 'fix-12549-one-more-SCC-setting'

b0f0b3e VS: Add VS_SCC_AUXPATH target property (#12549)
This commit is contained in:
David Cole 2011-11-08 14:42:41 -05:00 committed by CMake Topic Stage
commit d8d4e801ac
4 changed files with 24 additions and 3 deletions

View File

@ -1811,11 +1811,18 @@ void cmLocalVisualStudio7Generator::WriteProjectSCC(std::ostream& fout,
const char* vsProjectname = target.GetProperty("VS_SCC_PROJECTNAME"); const char* vsProjectname = target.GetProperty("VS_SCC_PROJECTNAME");
const char* vsLocalpath = target.GetProperty("VS_SCC_LOCALPATH"); const char* vsLocalpath = target.GetProperty("VS_SCC_LOCALPATH");
const char* vsProvider = target.GetProperty("VS_SCC_PROVIDER"); const char* vsProvider = target.GetProperty("VS_SCC_PROVIDER");
if(vsProvider && vsLocalpath && vsProjectname) if(vsProvider && vsLocalpath && vsProjectname)
{ {
fout << "\tSccProjectName=\"" << vsProjectname << "\"\n" fout << "\tSccProjectName=\"" << vsProjectname << "\"\n"
<< "\tSccLocalPath=\"" << vsLocalpath << "\"\n" << "\tSccLocalPath=\"" << vsLocalpath << "\"\n"
<< "\tSccProvider=\"" << vsProvider << "\"\n"; << "\tSccProvider=\"" << vsProvider << "\"\n";
const char* vsAuxPath = target.GetProperty("VS_SCC_AUXPATH");
if(vsAuxPath)
{
fout << "\tSccAuxPath=\"" << vsAuxPath << "\"\n";
}
} }
} }

View File

@ -140,7 +140,8 @@ public:
"the target in an IDE like visual studio. VS_KEYWORD can be set " "the target in an IDE like visual studio. VS_KEYWORD can be set "
"to change the visual studio keyword, for example QT integration " "to change the visual studio keyword, for example QT integration "
"works better if this is set to Qt4VSv1.0.\n" "works better if this is set to Qt4VSv1.0.\n"
"VS_SCC_PROJECTNAME, VS_SCC_LOCALPATH, VS_SCC_PROVIDER can be set " "VS_SCC_PROJECTNAME, VS_SCC_LOCALPATH, VS_SCC_PROVIDER and "
"VS_SCC_AUXPATH can be set "
"to add support for source control bindings in a Visual Studio " "to add support for source control bindings in a Visual Studio "
"project file.\n" "project file.\n"
"VS_GLOBAL_<variable> can be set to add a Visual Studio " "VS_GLOBAL_<variable> can be set to add a Visual Studio "

View File

@ -1011,7 +1011,7 @@ void cmTarget::DefineProperties(cmake *cm)
"provider property."); "provider property.");
cm->DefineProperty cm->DefineProperty
("VS_SCC_LOCALPATH", cmProperty::TARGET, ("VS_SCC_LOCALPATH", cmProperty::TARGET,
"Visual Studio Source Code Control Provider.", "Visual Studio Source Code Control Local Path.",
"Can be set to change the visual studio source code control " "Can be set to change the visual studio source code control "
"local path property."); "local path property.");
cm->DefineProperty cm->DefineProperty
@ -1019,6 +1019,11 @@ void cmTarget::DefineProperties(cmake *cm)
"Visual Studio Source Code Control Project.", "Visual Studio Source Code Control Project.",
"Can be set to change the visual studio source code control " "Can be set to change the visual studio source code control "
"project name property."); "project name property.");
cm->DefineProperty
("VS_SCC_AUXPATH", cmProperty::TARGET,
"Visual Studio Source Code Control Aux Path.",
"Can be set to change the visual studio source code control "
"auxpath property.");
cm->DefineProperty cm->DefineProperty
("VS_GLOBAL_<variable>", cmProperty::TARGET, ("VS_GLOBAL_<variable>", cmProperty::TARGET,
"Visual Studio project-specific global variable.", "Visual Studio project-specific global variable.",

View File

@ -193,6 +193,14 @@ void cmVisualStudio10TargetGenerator::Generate()
this->WriteString("<SccProvider>", 2); this->WriteString("<SccProvider>", 2);
(*this->BuildFileStream) << cmVS10EscapeXML(vsProvider) << (*this->BuildFileStream) << cmVS10EscapeXML(vsProvider) <<
"</SccProvider>\n"; "</SccProvider>\n";
const char* vsAuxPath = this->Target->GetProperty("VS_SCC_AUXPATH");
if( vsAuxPath )
{
this->WriteString("<SccAuxPath>", 2);
(*this->BuildFileStream) << cmVS10EscapeXML(vsAuxPath) <<
"</SccAuxPath>\n";
}
} }
this->WriteString("<Keyword>Win32Proj</Keyword>\n", 2); this->WriteString("<Keyword>Win32Proj</Keyword>\n", 2);