summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2009-02-02 19:36:53 (GMT)
committerBrad King <brad.king@kitware.com>2009-02-02 19:36:53 (GMT)
commit084e5a5e9e2886e2e4f7929e1d6f9fec87bdbc03 (patch)
tree37e54bea573516e6ec2f69567d16978df8371f47
parentfd40f274201e59ab9ee96f9f20d8923229e437dd (diff)
downloadCMake-084e5a5e9e2886e2e4f7929e1d6f9fec87bdbc03.zip
CMake-084e5a5e9e2886e2e4f7929e1d6f9fec87bdbc03.tar.gz
CMake-084e5a5e9e2886e2e4f7929e1d6f9fec87bdbc03.tar.bz2
BUG: Fix preprocess and assembly rule expansion
The recent change to avoid expanding rule variables in informational and 'cd' commands broke the logical order in generation of preprocess and assembly rules. This corrects the order.
-rw-r--r--Source/cmMakefileTargetGenerator.cxx24
1 files changed, 12 insertions, 12 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx
index 14f1a3d..4e71b2c 100644
--- a/Source/cmMakefileTargetGenerator.cxx
+++ b/Source/cmMakefileTargetGenerator.cxx
@@ -724,6 +724,12 @@ cmMakefileTargetGenerator
std::vector<std::string> preprocessCommands;
cmSystemTools::ExpandListArgument(preprocessRule, preprocessCommands);
+ std::string shellObjI =
+ this->Convert(objI.c_str(),
+ cmLocalGenerator::NONE,
+ cmLocalGenerator::SHELL).c_str();
+ vars.PreprocessedSource = shellObjI.c_str();
+
// Expand placeholders in the commands.
for(std::vector<std::string>::iterator i = preprocessCommands.begin();
i != preprocessCommands.end(); ++i)
@@ -738,12 +744,6 @@ cmMakefileTargetGenerator
commands.insert(commands.end(),
preprocessCommands.begin(),
preprocessCommands.end());
-
- std::string shellObjI =
- this->Convert(objI.c_str(),
- cmLocalGenerator::NONE,
- cmLocalGenerator::SHELL).c_str();
- vars.PreprocessedSource = shellObjI.c_str();
}
else
{
@@ -781,6 +781,12 @@ cmMakefileTargetGenerator
std::vector<std::string> assemblyCommands;
cmSystemTools::ExpandListArgument(assemblyRule, assemblyCommands);
+ std::string shellObjS =
+ this->Convert(objS.c_str(),
+ cmLocalGenerator::NONE,
+ cmLocalGenerator::SHELL).c_str();
+ vars.AssemblySource = shellObjS.c_str();
+
// Expand placeholders in the commands.
for(std::vector<std::string>::iterator i = assemblyCommands.begin();
i != assemblyCommands.end(); ++i)
@@ -795,12 +801,6 @@ cmMakefileTargetGenerator
commands.insert(commands.end(),
assemblyCommands.begin(),
assemblyCommands.end());
-
- std::string shellObjS =
- this->Convert(objS.c_str(),
- cmLocalGenerator::NONE,
- cmLocalGenerator::SHELL).c_str();
- vars.AssemblySource = shellObjS.c_str();
}
else
{