From f4e02c46fc2b07836f6e35b92681f043f26f2361 Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Mon, 3 Feb 2020 15:31:15 -0500 Subject: cmGlobalNinjaGenerator: run ninja tools in the build directory Fixes: #20303 --- Source/cmGlobalNinjaGenerator.cxx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Source/cmGlobalNinjaGenerator.cxx b/Source/cmGlobalNinjaGenerator.cxx index fd67f12..f7694ff 100644 --- a/Source/cmGlobalNinjaGenerator.cxx +++ b/Source/cmGlobalNinjaGenerator.cxx @@ -547,6 +547,8 @@ void cmGlobalNinjaGenerator::CleanMetaData() auto run_ninja_tool = [this](std::vector const& args) { std::vector command; command.push_back(this->NinjaCommand); + command.emplace_back("-C"); + command.emplace_back(this->GetCMakeInstance()->GetHomeOutputDirectory()); command.emplace_back("-t"); for (auto const& arg : args) { command.emplace_back(arg); -- cgit v0.12