MCPcopy Create free account
hub / github.com/Kitware/CMake / ComputeDeviceLinkCmd

Method ComputeDeviceLinkCmd

Source/cmNinjaNormalTargetGenerator.cxx:705–727  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

703}
704
705std::vector<std::string> cmNinjaNormalTargetGenerator::ComputeDeviceLinkCmd()
706{
707 cmList linkCmds;
708
709 // this target requires separable cuda compilation
710 // now build the correct command depending on if the target is
711 // an executable or a dynamic library.
712 switch (this->GetGeneratorTarget()->GetType()) {
713 case cmStateEnums::STATIC_LIBRARY:
714 case cmStateEnums::SHARED_LIBRARY:
715 case cmStateEnums::MODULE_LIBRARY: {
716 linkCmds.assign(
717 this->GetMakefile()->GetDefinition("CMAKE_CUDA_DEVICE_LINK_LIBRARY"));
718 } break;
719 case cmStateEnums::EXECUTABLE: {
720 linkCmds.assign(this->GetMakefile()->GetDefinition(
721 "CMAKE_CUDA_DEVICE_LINK_EXECUTABLE"));
722 } break;
723 default:
724 break;
725 }
726 return std::move(linkCmds.data());
727}
728
729std::vector<std::string> cmNinjaNormalTargetGenerator::ComputeLinkCmd(
730 std::string const& config)

Callers 1

Calls 7

moveFunction · 0.85
assignMethod · 0.80
GetTypeMethod · 0.45
GetGeneratorTargetMethod · 0.45
GetDefinitionMethod · 0.45
GetMakefileMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected