From 2d9bb3325f6b1155bc7848f1f666e79c37bfa253 Mon Sep 17 00:00:00 2001 From: Brad King Date: Thu, 16 Sep 2010 15:07:41 -0400 Subject: [PATCH] Evaluate rule variable for executables Previously this placeholder was evaluated only for libraries. Make it work for executables too. --- Source/cmMakefileExecutableTargetGenerator.cxx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Source/cmMakefileExecutableTargetGenerator.cxx b/Source/cmMakefileExecutableTargetGenerator.cxx index 93c981aa00..a5e319dd00 100644 --- a/Source/cmMakefileExecutableTargetGenerator.cxx +++ b/Source/cmMakefileExecutableTargetGenerator.cxx @@ -345,6 +345,13 @@ void cmMakefileExecutableTargetGenerator::WriteExecutableRule(bool relink) vars.CMTarget = this->Target; vars.Language = linkLanguage; vars.Objects = buildObjs.c_str(); + std::string objdir = cmake::GetCMakeFilesDirectoryPostSlash(); + objdir += this->Target->GetName(); + objdir += ".dir"; + objdir = this->Convert(objdir.c_str(), + cmLocalGenerator::START_OUTPUT, + cmLocalGenerator::SHELL); + vars.ObjectDir = objdir.c_str(); vars.Target = targetOutPathReal.c_str(); vars.TargetPDB = targetOutPathPDB.c_str();