ENH: add some more properties for visual studio projects
This commit is contained in:
parent
9104097502
commit
49840778b9
|
@ -1321,7 +1321,7 @@ void cmLocalVisualStudio7Generator::OutputTargetRules(std::ostream& fout,
|
|||
void
|
||||
cmLocalVisualStudio7Generator::WriteProjectStart(std::ostream& fout,
|
||||
const char *libName,
|
||||
cmTarget &,
|
||||
cmTarget & target,
|
||||
std::vector<cmSourceGroup> &)
|
||||
{
|
||||
fout << "<?xml version=\"1.0\" encoding = \"Windows-1252\"?>\n"
|
||||
|
@ -1342,11 +1342,20 @@ cmLocalVisualStudio7Generator::WriteProjectStart(std::ostream& fout,
|
|||
fout << "\tVersion=\"7.00\"\n";
|
||||
}
|
||||
}
|
||||
|
||||
fout << "\tName=\"" << libName << "\"\n"
|
||||
const char* projLabel = target.GetProperty("PROJECT_LABEL");
|
||||
if(!projLabel)
|
||||
{
|
||||
projLabel = libName;
|
||||
}
|
||||
const char* keyword = target.GetProperty("VS_KEYWORD");
|
||||
if(!keyword)
|
||||
{
|
||||
keyword = "Win32Proj";
|
||||
}
|
||||
fout << "\tName=\"" << projLabel << "\"\n"
|
||||
<< "\tSccProjectName=\"\"\n"
|
||||
<< "\tSccLocalPath=\"\"\n"
|
||||
<< "\tKeyword=\"Win32Proj\">\n"
|
||||
<< "\tKeyword=\"" << keyword << "\">\n"
|
||||
<< "\t<Platforms>\n"
|
||||
<< "\t\t<Platform\n\t\t\tName=\"Win32\"/>\n"
|
||||
<< "\t</Platforms>\n";
|
||||
|
|
|
@ -78,7 +78,11 @@ public:
|
|||
"used in place of the target name when creating executables. "
|
||||
"If not set here then it is set to target_EXPORTS by default "
|
||||
"(with some substitutions if the target is not a valid C "
|
||||
"identifier). You can use any prop value pair you want and "
|
||||
"identifier). PROJECT_LABEL can be used to change the name of "
|
||||
"the target in an IDE like visual studio. VS_KEYWORD can be set "
|
||||
"to change the visual studio keyword, for example QT integration "
|
||||
"works better if this is set to Qt4VSv1.0. "
|
||||
"You can use any prop value pair you want and "
|
||||
"extract it later with the GET_TARGET_PROPERTY command.";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue