summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalGhsMultiGenerator.cxx
diff options
context:
space:
mode:
authorVitaly Stakhovsky <vvs31415@gitlab.org>2020-04-29 15:00:00 (GMT)
committerVitaly Stakhovsky <vvs31415@gitlab.org>2020-04-29 14:59:39 (GMT)
commit36aba01223cfb28ee574386cd91dbfccc4dc9359 (patch)
tree7acf2fc54b9ddf7a5372cb088eb80cde6764408d /Source/cmGlobalGhsMultiGenerator.cxx
parentd63c442a6bcec287afb32a88c80b68cb141f49f4 (diff)
downloadCMake-36aba01223cfb28ee574386cd91dbfccc4dc9359.zip
CMake-36aba01223cfb28ee574386cd91dbfccc4dc9359.tar.gz
CMake-36aba01223cfb28ee574386cd91dbfccc4dc9359.tar.bz2
cmGeneratorTarget::GetProperty: return cmProp
Diffstat (limited to 'Source/cmGlobalGhsMultiGenerator.cxx')
-rw-r--r--Source/cmGlobalGhsMultiGenerator.cxx11
1 files changed, 6 insertions, 5 deletions
diff --git a/Source/cmGlobalGhsMultiGenerator.cxx b/Source/cmGlobalGhsMultiGenerator.cxx
index 24559e6..651bfbd 100644
--- a/Source/cmGlobalGhsMultiGenerator.cxx
+++ b/Source/cmGlobalGhsMultiGenerator.cxx
@@ -376,8 +376,8 @@ void cmGlobalGhsMultiGenerator::WriteProjectLine(
std::ostream& fout, cmGeneratorTarget const* target, cmLocalGenerator* root,
std::string& rootBinaryDir)
{
- const char* projName = target->GetProperty("GENERATOR_FILE_NAME");
- const char* projType = target->GetProperty("GENERATOR_FILE_NAME_EXT");
+ cmProp projName = target->GetProperty("GENERATOR_FILE_NAME");
+ cmProp projType = target->GetProperty("GENERATOR_FILE_NAME_EXT");
if (projName && projType) {
cmLocalGenerator* lg = target->GetLocalGenerator();
std::string dir = lg->GetCurrentBinaryDirectory();
@@ -390,9 +390,9 @@ void cmGlobalGhsMultiGenerator::WriteProjectLine(
}
}
- std::string projFile = dir + projName + FILE_EXTENSION;
+ std::string projFile = dir + *projName + FILE_EXTENSION;
fout << projFile;
- fout << ' ' << projType << '\n';
+ fout << ' ' << *projType << '\n';
} else {
/* Should never happen */
std::string message =
@@ -469,7 +469,8 @@ void cmGlobalGhsMultiGenerator::WriteAllTarget(
if (t->GetType() == cmStateEnums::INTERFACE_LIBRARY) {
continue;
}
- if (!cmIsOn(t->GetProperty("EXCLUDE_FROM_ALL"))) {
+ cmProp p = t->GetProperty("EXCLUDE_FROM_ALL");
+ if (!(p && cmIsOn(*p))) {
defaultTargets.push_back(t);
}
}