diff options
author | Brad King <brad.king@kitware.com> | 2010-10-05 19:28:45 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2010-10-05 19:28:45 (GMT) |
commit | 46bc165c36f166923dab2a829989a697221b69e5 (patch) | |
tree | 1912ede401c50c426d5605c3f4b7c81e92d0bb3f | |
parent | 111f81c930dd2ba5db7d83670bba814c12dc3c95 (diff) | |
parent | 3d68dd230d84a1faac9b4d6750ec36cba3c6f8a2 (diff) | |
download | CMake-46bc165c36f166923dab2a829989a697221b69e5.zip CMake-46bc165c36f166923dab2a829989a697221b69e5.tar.gz CMake-46bc165c36f166923dab2a829989a697221b69e5.tar.bz2 |
Merge topic 'fix_custom_commands_with_intdir_vs10'
3d68dd2 Fix for bug #11274, VS10 custom commands that create files in INTDIR fix.
-rw-r--r-- | Source/cmMakefile.cxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index c64053a..ef15113 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -894,6 +894,14 @@ cmMakefile::AddCustomCommandToOutput(const std::vector<std::string>& outputs, // Construct a rule file associated with the first output produced. std::string outName = outputs[0]; outName += ".rule"; + const char* dir = + this->LocalGenerator->GetGlobalGenerator()-> + GetCMakeCFGInitDirectory(); + if(dir && dir[0] == '$') + { + cmSystemTools::ReplaceString(outName, dir, + cmake::GetCMakeFilesDirectory()); + } // Check if the rule file already exists. file = this->GetSource(outName.c_str()); if(file && file->GetCustomCommand() && !replace) |