summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2014-03-22 02:27:59 (GMT)
committerBen Boeckel <ben.boeckel@kitware.com>2014-07-08 14:13:51 (GMT)
commit6208c285c8ae43d566474f488a00967b74ee4389 (patch)
treef5ababa9b946a86b9ec3f1a34a44746b003ab3c5 /Source/cmMakefile.cxx
parentdc2e26df01eb4230a69c43a05b867fce330f57a4 (diff)
downloadCMake-6208c285c8ae43d566474f488a00967b74ee4389.zip
CMake-6208c285c8ae43d566474f488a00967b74ee4389.tar.gz
CMake-6208c285c8ae43d566474f488a00967b74ee4389.tar.bz2
cmMakefile: Defer dependency calculations
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 452d3f6..2218e2f 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -1056,16 +1056,16 @@ cmMakefile::AddCustomCommandToOutput(const std::vector<std::string>& outputs,
}
}
- // Construct a complete list of dependencies.
- std::vector<std::string> depends2(depends);
- if(!main_dependency.empty())
- {
- depends2.push_back(main_dependency);
- }
-
// Attach the custom command to the file.
if(file)
{
+ // Construct a complete list of dependencies.
+ std::vector<std::string> depends2(depends);
+ if(!main_dependency.empty())
+ {
+ depends2.push_back(main_dependency);
+ }
+
cmCustomCommand* cc =
new cmCustomCommand(this, outputs, depends2, commandLines,
comment, workingDir);