diff options
author | Peter Kümmel <syntheticpp@gmx.net> | 2013-11-23 09:49:36 (GMT) |
---|---|---|
committer | Peter Kümmel <syntheticpp@gmx.net> | 2013-11-25 21:23:24 (GMT) |
commit | 7605e37aabae2678e5696a75e84aced2e84f9037 (patch) | |
tree | dced8cd0e0baf12da23f2e2221abca2483fba313 /Source/cmNinjaTargetGenerator.cxx | |
parent | da6b86f4f031b189768dc474721145a1b99f71ea (diff) | |
download | CMake-7605e37aabae2678e5696a75e84aced2e84f9037.zip CMake-7605e37aabae2678e5696a75e84aced2e84f9037.tar.gz CMake-7605e37aabae2678e5696a75e84aced2e84f9037.tar.bz2 |
Ninja: job pool support for compiling and linking
Could be tested by setting the environment
variable NINJA_STATUS=[%r]
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 b132db6..f40532c 100644 --- a/Source/cmNinjaTargetGenerator.cxx +++ b/Source/cmNinjaTargetGenerator.cxx @@ -572,6 +572,8 @@ cmNinjaTargetGenerator ConvertToNinjaPath(objectDir.c_str()).c_str(), cmLocalGenerator::SHELL); + this->addPoolNinjaVariable("JOB_POOL_COMPILE", this->GetTarget(), vars); + this->SetMsvcTargetPdbVariable(vars); if(this->Makefile->IsOn("CMAKE_EXPORT_COMPILE_COMMANDS")) @@ -725,3 +727,14 @@ cmNinjaTargetGenerator::MacOSXContentGeneratorType::operator()( // Add as a dependency of all target so that it gets called. this->Generator->GetGlobalGenerator()->AddDependencyToAll(output); } + +void cmNinjaTargetGenerator::addPoolNinjaVariable(const char* pool_property, + cmTarget* target, + cmNinjaVars& vars) +{ + const char* pool = target->GetProperty(pool_property); + if (pool) + { + vars["pool"] = pool; + } +} |