diff options
Diffstat (limited to 'Source/cmMakefileTargetGenerator.cxx')
-rw-r--r-- | Source/cmMakefileTargetGenerator.cxx | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx index 6b290ab..9dcd8f1 100644 --- a/Source/cmMakefileTargetGenerator.cxx +++ b/Source/cmMakefileTargetGenerator.cxx @@ -849,7 +849,7 @@ cmMakefileTargetGenerator p_depends.push_back(relativeObj); this->LocalGenerator->WriteMakeRule(*this->BuildFileStream, 0, temp.c_str(), p_depends, no_commands, - true); + false); } //---------------------------------------------------------------------------- @@ -1527,6 +1527,12 @@ void cmMakefileTargetGenerator this->LocalGenerator->AppendRuleDepend(depends, this->BuildFileNameFull.c_str()); + // Add a dependency on the link definitions file, if any. + if(!this->ModuleDefinitionFile.empty()) + { + depends.push_back(this->ModuleDefinitionFile); + } + // Add dependencies on the external object files. for(std::vector<std::string>::const_iterator obj = this->ExternalObjects.begin(); @@ -1723,8 +1729,6 @@ const char* cmMakefileTargetGenerator::GetFortranModuleDirectory() this->Target->GetProperty("Fortran_MODULE_DIRECTORY"); const char* moddir_flag = this->Makefile->GetDefinition("CMAKE_Fortran_MODDIR_FLAG"); - const char* moddir_default = - this->Makefile->GetDefinition("CMAKE_Fortran_MODDIR_DEFAULT"); if(target_mod_dir && moddir_flag) { // Compute the full path to the module directory. @@ -1745,10 +1749,6 @@ const char* cmMakefileTargetGenerator::GetFortranModuleDirectory() // Make sure the module output directory exists. cmSystemTools::MakeDirectory(this->FortranModuleDirectory.c_str()); } - else if(moddir_default && moddir_flag) - { - this->FortranModuleDirectory = moddir_default; - } this->FortranModuleDirectoryComputed = true; } @@ -1774,7 +1774,12 @@ void cmMakefileTargetGenerator::AddFortranFlags(std::string& flags) } // Add a module output directory flag if necessary. - if(const char* mod_dir = this->GetFortranModuleDirectory()) + const char* mod_dir = this->GetFortranModuleDirectory(); + if(!mod_dir) + { + mod_dir = this->Makefile->GetDefinition("CMAKE_Fortran_MODDIR_DEFAULT"); + } + if(mod_dir) { const char* moddir_flag = this->Makefile->GetRequiredDefinition("CMAKE_Fortran_MODDIR_FLAG"); |