diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-05-16 05:18:39 +0200 |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-05-16 05:20:12 +0200 |
commit | e9b134b95ddc832979b2cf78aff68643139e5006 (patch) | |
tree | 5c594fa6e30f8c1e094214c8c73da7386a657d6c | |
parent | 24613d8b45b4f76e9227e9dec4dcd19ae9cfdfb5 (diff) | |
download | cmake-e9b134b95ddc832979b2cf78aff68643139e5006.tar.gz |
cmGlobalUnixMakefileGenerator3: Host the include directive.
There is no sense in copying this to each cmLocalGenerator.
-rw-r--r-- | Source/cmGlobalBorlandMakefileGenerator.cxx | 2 | ||||
-rw-r--r-- | Source/cmGlobalUnixMakefileGenerator3.cxx | 2 | ||||
-rw-r--r-- | Source/cmGlobalUnixMakefileGenerator3.h | 2 | ||||
-rw-r--r-- | Source/cmGlobalWatcomWMakeGenerator.cxx | 2 | ||||
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator3.cxx | 1 | ||||
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator3.h | 8 | ||||
-rw-r--r-- | Source/cmMakefileTargetGenerator.cxx | 6 | ||||
-rw-r--r-- | Source/cmMakefileUtilityTargetGenerator.cxx | 2 |
8 files changed, 10 insertions, 15 deletions
diff --git a/Source/cmGlobalBorlandMakefileGenerator.cxx b/Source/cmGlobalBorlandMakefileGenerator.cxx index d19105662c..ab878fe530 100644 --- a/Source/cmGlobalBorlandMakefileGenerator.cxx +++ b/Source/cmGlobalBorlandMakefileGenerator.cxx @@ -22,6 +22,7 @@ cmGlobalBorlandMakefileGenerator::cmGlobalBorlandMakefileGenerator() this->ToolSupportsColor = true; this->UseLinkScript = false; this->WindowsShell = true; + this->IncludeDirective = "!include"; } @@ -43,7 +44,6 @@ cmLocalGenerator *cmGlobalBorlandMakefileGenerator::CreateLocalGenerator( { cmLocalUnixMakefileGenerator3* lg = new cmLocalUnixMakefileGenerator3(this, parent); - lg->SetIncludeDirective("!include"); lg->SetDefineWindowsNULL(true); lg->SetMakefileVariableSize(32); lg->SetPassMakeflags(true); diff --git a/Source/cmGlobalUnixMakefileGenerator3.cxx b/Source/cmGlobalUnixMakefileGenerator3.cxx index 181f4c0af8..32523de55f 100644 --- a/Source/cmGlobalUnixMakefileGenerator3.cxx +++ b/Source/cmGlobalUnixMakefileGenerator3.cxx @@ -33,6 +33,8 @@ cmGlobalUnixMakefileGenerator3::cmGlobalUnixMakefileGenerator3() this->UseLinkScript = true; #endif this->CommandDatabase = NULL; + + this->IncludeDirective = "include"; } void cmGlobalUnixMakefileGenerator3 diff --git a/Source/cmGlobalUnixMakefileGenerator3.h b/Source/cmGlobalUnixMakefileGenerator3.h index 165a3c8b27..950a4469b5 100644 --- a/Source/cmGlobalUnixMakefileGenerator3.h +++ b/Source/cmGlobalUnixMakefileGenerator3.h @@ -132,6 +132,8 @@ public: virtual bool AllowDeleteOnError() const { return true; } virtual void ComputeTargetObjectDirectory(cmGeneratorTarget* gt) const; + + std::string IncludeDirective; protected: void WriteMainMakefile2(); void WriteMainCMakefile(); diff --git a/Source/cmGlobalWatcomWMakeGenerator.cxx b/Source/cmGlobalWatcomWMakeGenerator.cxx index 181178f887..fcc754a8d4 100644 --- a/Source/cmGlobalWatcomWMakeGenerator.cxx +++ b/Source/cmGlobalWatcomWMakeGenerator.cxx @@ -26,6 +26,7 @@ cmGlobalWatcomWMakeGenerator::cmGlobalWatcomWMakeGenerator() this->WindowsShell = true; #endif this->WatcomWMake = true; + this->IncludeDirective = "!include"; } void cmGlobalWatcomWMakeGenerator @@ -55,7 +56,6 @@ cmGlobalWatcomWMakeGenerator::CreateLocalGenerator(cmLocalGenerator* parent) lg->SetIgnoreLibPrefix(true); lg->SetPassMakeflags(false); lg->SetUnixCD(false); - lg->SetIncludeDirective("!include"); return lg; } diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx index f11c79edcf..3db04339d4 100644 --- a/Source/cmLocalUnixMakefileGenerator3.cxx +++ b/Source/cmLocalUnixMakefileGenerator3.cxx @@ -83,7 +83,6 @@ cmLocalUnixMakefileGenerator3:: cmLocalUnixMakefileGenerator3(cmGlobalGenerator* gg, cmLocalGenerator* parent) : cmLocalGenerator(gg, parent) { - this->IncludeDirective = "include"; this->MakefileVariableSize = 0; this->IgnoreLibPrefix = false; this->PassMakeflags = false; diff --git a/Source/cmLocalUnixMakefileGenerator3.h b/Source/cmLocalUnixMakefileGenerator3.h index 4836867275..492f5d3f4e 100644 --- a/Source/cmLocalUnixMakefileGenerator3.h +++ b/Source/cmLocalUnixMakefileGenerator3.h @@ -94,13 +94,6 @@ public: void SetUnixCD(bool v) {this->UnixCD = v;} /** - * Set the string used to include one makefile into another default - * is include. - */ - void SetIncludeDirective(const std::string& s) - { this->IncludeDirective = s; } - - /** * Set max makefile variable size, default is 0 which means unlimited. */ void SetMakefileVariableSize(int s) { this->MakefileVariableSize = s; } @@ -302,7 +295,6 @@ private: //========================================================================== // Configuration settings. int MakefileVariableSize; - std::string IncludeDirective; std::string MakeSilentFlag; std::string ConfigurationName; bool DefineWindowsNULL; diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx index 2ee23d18a4..9afe09c6e0 100644 --- a/Source/cmMakefileTargetGenerator.cxx +++ b/Source/cmMakefileTargetGenerator.cxx @@ -226,7 +226,7 @@ void cmMakefileTargetGenerator::WriteCommonCodeRules() dependFileNameFull += "/depend.make"; *this->BuildFileStream << "# Include any dependencies generated for this target.\n" - << this->LocalGenerator->IncludeDirective << " " << root + << this->GlobalGenerator->IncludeDirective << " " << root << this->Convert(dependFileNameFull, cmLocalGenerator::HOME_OUTPUT, cmLocalGenerator::MAKERULE) @@ -237,7 +237,7 @@ void cmMakefileTargetGenerator::WriteCommonCodeRules() // Include the progress variables for the target. *this->BuildFileStream << "# Include the progress variables for this target.\n" - << this->LocalGenerator->IncludeDirective << " " << root + << this->GlobalGenerator->IncludeDirective << " " << root << this->Convert(this->ProgressFileNameFull, cmLocalGenerator::HOME_OUTPUT, cmLocalGenerator::MAKERULE) @@ -270,7 +270,7 @@ void cmMakefileTargetGenerator::WriteCommonCodeRules() // Include the flags for the target. *this->BuildFileStream << "# Include the compile flags for this target's objects.\n" - << this->LocalGenerator->IncludeDirective << " " << root + << this->GlobalGenerator->IncludeDirective << " " << root << this->Convert(this->FlagFileNameFull, cmLocalGenerator::HOME_OUTPUT, cmLocalGenerator::MAKERULE) diff --git a/Source/cmMakefileUtilityTargetGenerator.cxx b/Source/cmMakefileUtilityTargetGenerator.cxx index 617214fe47..25d929ccea 100644 --- a/Source/cmMakefileUtilityTargetGenerator.cxx +++ b/Source/cmMakefileUtilityTargetGenerator.cxx @@ -51,7 +51,7 @@ void cmMakefileUtilityTargetGenerator::WriteRuleFiles() // Include the progress variables for the target. *this->BuildFileStream << "# Include the progress variables for this target.\n" - << this->LocalGenerator->IncludeDirective << " " << root + << this->GlobalGenerator->IncludeDirective << " " << root << this->Convert(this->ProgressFileNameFull, cmLocalGenerator::HOME_OUTPUT, cmLocalGenerator::MAKERULE) |