diff options
author | Brad King <brad.king@kitware.com> | 2017-06-12 14:17:53 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2017-06-12 14:20:58 (GMT) |
commit | 99153a9eb6c3e997dfb07dcf9ea01836f2c384d1 (patch) | |
tree | 202170e74ef8ee9c162c57ce4a00ef7bdcc28103 /Source | |
parent | 22b412c32574986720198445172e8a460429eba1 (diff) | |
parent | 414438b2fb5a43c447273b425b59cd982818457b (diff) | |
download | CMake-99153a9eb6c3e997dfb07dcf9ea01836f2c384d1.zip CMake-99153a9eb6c3e997dfb07dcf9ea01836f2c384d1.tar.gz CMake-99153a9eb6c3e997dfb07dcf9ea01836f2c384d1.tar.bz2 |
Merge topic 'cuda-compiler-launcher'
414438b2 CUDA: Add option to run the compiler through launcher tools
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !949
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmMakefileTargetGenerator.cxx | 3 | ||||
-rw-r--r-- | Source/cmNinjaTargetGenerator.cxx | 3 | ||||
-rw-r--r-- | Source/cmTarget.cxx | 1 |
3 files changed, 5 insertions, 2 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx index a4511b6..7938683 100644 --- a/Source/cmMakefileTargetGenerator.cxx +++ b/Source/cmMakefileTargetGenerator.cxx @@ -657,7 +657,8 @@ void cmMakefileTargetGenerator::WriteObjectBuildFile( } // Maybe insert a compiler launcher like ccache or distcc - if (!compileCommands.empty() && (lang == "C" || lang == "CXX")) { + if (!compileCommands.empty() && + (lang == "C" || lang == "CXX" || lang == "CUDA")) { std::string const clauncher_prop = lang + "_COMPILER_LAUNCHER"; const char* clauncher = this->GeneratorTarget->GetProperty(clauncher_prop); diff --git a/Source/cmNinjaTargetGenerator.cxx b/Source/cmNinjaTargetGenerator.cxx index 2f4cccb..7c57ef0 100644 --- a/Source/cmNinjaTargetGenerator.cxx +++ b/Source/cmNinjaTargetGenerator.cxx @@ -648,7 +648,8 @@ void cmNinjaTargetGenerator::WriteCompileRule(const std::string& lang) } // Maybe insert a compiler launcher like ccache or distcc - if (!compileCmds.empty() && (lang == "C" || lang == "CXX")) { + if (!compileCmds.empty() && + (lang == "C" || lang == "CXX" || lang == "CUDA")) { std::string const clauncher_prop = lang + "_COMPILER_LAUNCHER"; const char* clauncher = this->GeneratorTarget->GetProperty(clauncher_prop); if (clauncher && *clauncher) { diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index c95a3ca..c1b6f97 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -276,6 +276,7 @@ cmTarget::cmTarget(std::string const& name, cmStateEnums::TargetType type, this->SetPropertyDefault("CUDA_STANDARD", CM_NULLPTR); this->SetPropertyDefault("CUDA_STANDARD_REQUIRED", CM_NULLPTR); this->SetPropertyDefault("CUDA_EXTENSIONS", CM_NULLPTR); + this->SetPropertyDefault("CUDA_COMPILER_LAUNCHER", CM_NULLPTR); this->SetPropertyDefault("LINK_SEARCH_START_STATIC", CM_NULLPTR); this->SetPropertyDefault("LINK_SEARCH_END_STATIC", CM_NULLPTR); } |