diff options
author | Fred Baksik <frodak17@gmail.com> | 2019-01-05 16:01:22 (GMT) |
---|---|---|
committer | Fred Baksik <frodak17@gmail.com> | 2019-01-16 15:41:38 (GMT) |
commit | 14f3ba205989a422f1668073a325b057cece0b32 (patch) | |
tree | 16c0289473b6c09183b912777be626d76e9bd8c6 /Source/cmGlobalGhsMultiGenerator.cxx | |
parent | 702121c5f3eceeb6b74ede845f1e1297cf113c47 (diff) | |
download | CMake-14f3ba205989a422f1668073a325b057cece0b32.zip CMake-14f3ba205989a422f1668073a325b057cece0b32.tar.gz CMake-14f3ba205989a422f1668073a325b057cece0b32.tar.bz2 |
GHS: EXCLUDE_FROM_ALL updates
-- Excluded targets should be generated but not included in build ALL
-- Use the correct source list for this configuration when writing sources
Diffstat (limited to 'Source/cmGlobalGhsMultiGenerator.cxx')
-rw-r--r-- | Source/cmGlobalGhsMultiGenerator.cxx | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/Source/cmGlobalGhsMultiGenerator.cxx b/Source/cmGlobalGhsMultiGenerator.cxx index 452a610..f2f43e3 100644 --- a/Source/cmGlobalGhsMultiGenerator.cxx +++ b/Source/cmGlobalGhsMultiGenerator.cxx @@ -311,6 +311,10 @@ void cmGlobalGhsMultiGenerator::WriteSubProjects( dir += "/"; } } + + if (cmSystemTools::IsOn(target->GetProperty("EXCLUDE_FROM_ALL"))) { + fout << "{comment} "; + } fout << dir << projName << FILE_EXTENSION; fout << " " << projType << std::endl; } @@ -441,21 +445,6 @@ void cmGlobalGhsMultiGenerator::WriteHighLevelDirectives(std::ostream& fout) } } -bool cmGlobalGhsMultiGenerator::IsTgtForBuild(const cmGeneratorTarget* tgt) -{ - const std::string config = - tgt->Target->GetMakefile()->GetSafeDefinition("CMAKE_BUILD_TYPE"); - std::vector<cmSourceFile*> tgtSources; - tgt->GetSourceFiles(tgtSources, config); - bool tgtInBuild = true; - char const* excludeFromAll = tgt->GetProperty("EXCLUDE_FROM_ALL"); - if (NULL != excludeFromAll && '1' == excludeFromAll[0] && - '\0' == excludeFromAll[1]) { - tgtInBuild = false; - } - return !tgtSources.empty() && tgtInBuild; -} - std::string cmGlobalGhsMultiGenerator::trimQuotes(std::string const& str) { std::string result; |