diff options
Diffstat (limited to 'Source/cmNinjaTargetGenerator.cxx')
-rw-r--r-- | Source/cmNinjaTargetGenerator.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/Source/cmNinjaTargetGenerator.cxx b/Source/cmNinjaTargetGenerator.cxx index b19b620..accdcf1 100644 --- a/Source/cmNinjaTargetGenerator.cxx +++ b/Source/cmNinjaTargetGenerator.cxx @@ -1398,6 +1398,19 @@ void cmNinjaTargetGenerator::WriteObjectBuildStatement( // Make sure ninja knows how to clean the generated header this->GetGlobalGenerator()->AddAdditionalCleanFile(ispcHeader, config); + auto ispcSuffixes = + detail::ComputeISPCObjectSuffixes(this->GeneratorTarget); + if (ispcSuffixes.size() > 1) { + auto ispcSideEfffectObjects = detail::ComputeISPCExtraObjects( + objectName, ispcDirectory, ispcSuffixes); + + for (auto sideEffect : ispcSideEfffectObjects) { + sideEffect = this->ConvertToNinjaPath(sideEffect); + objBuild.ImplicitOuts.emplace_back(sideEffect); + this->GetGlobalGenerator()->AddAdditionalCleanFile(sideEffect, config); + } + } + vars["ISPC_HEADER_FILE"] = this->GetLocalGenerator()->ConvertToOutputFormat( ispcHeader, cmOutputConverter::SHELL); |