diff options
author | Brad King <brad.king@kitware.com> | 2015-09-21 13:25:29 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2015-09-21 13:25:29 (GMT) |
commit | dd8285c6880e08e4c6cbb0e2ca1a1684df3e11d1 (patch) | |
tree | 0c72135867161a3722857767c7d1d85f834acacb /Source | |
parent | 4f640afc1aa571a4a1a9083b62e3d2787db84bf3 (diff) | |
parent | 2514e4265c1914f53f9445f331ddb7183f0d9501 (diff) | |
download | CMake-dd8285c6880e08e4c6cbb0e2ca1a1684df3e11d1.zip CMake-dd8285c6880e08e4c6cbb0e2ca1a1684df3e11d1.tar.gz CMake-dd8285c6880e08e4c6cbb0e2ca1a1684df3e11d1.tar.bz2 |
Merge topic 'fix-compatibility-mode-LOCATION'
2514e426 CMP0026: Use compatibility codepath until configure is finished (#15748)
b98f7712 cmGlobalGenerator: Add API for the configure step being finished.
b5de2bd9 cmLocalGenerator: Simplify condition.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmGeneratorTarget.cxx | 12 | ||||
-rw-r--r-- | Source/cmGlobalGenerator.cxx | 5 | ||||
-rw-r--r-- | Source/cmGlobalGenerator.h | 3 | ||||
-rw-r--r-- | Source/cmLocalGenerator.cxx | 2 | ||||
-rw-r--r-- | Source/cmTarget.cxx | 4 |
5 files changed, 17 insertions, 9 deletions
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index fb5805b..555c437 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -2218,7 +2218,7 @@ cmGeneratorTarget::GetIncludeDirectories(const std::string& config, "INCLUDE_DIRECTORIES") != debugProperties.end(); - if (this->Makefile->IsConfigured()) + if (this->GlobalGenerator->GetConfigureDoneCMP0026()) { this->DebugIncludesDone = true; } @@ -2365,7 +2365,7 @@ void cmGeneratorTarget::GetCompileOptions(std::vector<std::string> &result, "COMPILE_OPTIONS") != debugProperties.end(); - if (this->Makefile->IsConfigured()) + if (this->GlobalGenerator->GetConfigureDoneCMP0026()) { this->DebugCompileOptionsDone = true; } @@ -2435,7 +2435,7 @@ void cmGeneratorTarget::GetCompileFeatures(std::vector<std::string> &result, "COMPILE_FEATURES") != debugProperties.end(); - if (this->Makefile->IsConfigured()) + if (this->GlobalGenerator->GetConfigureDoneCMP0026()) { this->DebugCompileFeaturesDone = true; } @@ -2503,7 +2503,7 @@ void cmGeneratorTarget::GetCompileDefinitions(std::vector<std::string> &list, "COMPILE_DEFINITIONS") != debugProperties.end(); - if (this->Makefile->IsConfigured()) + if (this->GlobalGenerator->GetConfigureDoneCMP0026()) { this->DebugCompileDefinitionsDone = true; } @@ -3937,7 +3937,7 @@ cmGeneratorTarget::ReportPropertyOrigin(const std::string &p, p) != debugProperties.end(); - if (this->Target->GetMakefile()->IsConfigured()) + if (this->GlobalGenerator->GetConfigureDoneCMP0026()) { this->DebugCompatiblePropertiesDone[p] = true; } @@ -4504,7 +4504,7 @@ void cmGeneratorTarget::GetLanguages(std::set<std::string>& languages, std::vector<cmGeneratorTarget*> objectLibraries; std::vector<cmSourceFile const*> externalObjects; - if (!this->Makefile->IsConfigured()) + if (!this->GlobalGenerator->GetConfigureDoneCMP0026()) { std::vector<cmTarget*> objectTargets; this->Target->GetObjectLibrariesCMP0026(objectTargets); diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index 33b04ac..7aa8bb6 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -72,6 +72,8 @@ cmGlobalGenerator::cmGlobalGenerator(cmake* cm) this->ExtraGenerator = 0; this->CurrentMakefile = 0; this->TryCompileOuterMakefile = 0; + + this->ConfigureDoneCMP0026 = false; } cmGlobalGenerator::~cmGlobalGenerator() @@ -1110,9 +1112,12 @@ void cmGlobalGenerator::Configure() this->CMakeInstance->GetHomeOutputDirectory()); // now do it + this->ConfigureDoneCMP0026 = false; dirMf->Configure(); dirMf->EnforceDirectoryLevelRules(); + this->ConfigureDoneCMP0026 = true; + // Put a copy of each global target in every directory. cmTargets globalTargets; this->CreateDefaultGlobalTargets(&globalTargets); diff --git a/Source/cmGlobalGenerator.h b/Source/cmGlobalGenerator.h index 9fc2d45..40f98dc 100644 --- a/Source/cmGlobalGenerator.h +++ b/Source/cmGlobalGenerator.h @@ -363,6 +363,8 @@ public: cmFileLockPool& GetFileLockPool() { return FileLockPool; } #endif + bool GetConfigureDoneCMP0026() const { return this->ConfigureDoneCMP0026; } + std::string MakeSilentFlag; protected: typedef std::vector<cmLocalGenerator*> GeneratorVector; @@ -520,6 +522,7 @@ protected: bool ForceUnixPaths; bool ToolSupportsColor; bool InstallTargetEnabled; + bool ConfigureDoneCMP0026; }; #endif diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 97a9f1e..4418ead 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -2850,7 +2850,7 @@ cmIML_INT_uint64_t cmLocalGenerator::GetBackwardsCompatibility() } } this->BackwardsCompatibility = CMake_VERSION_ENCODE(major, minor, patch); - this->BackwardsCompatibilityFinal = this->Makefile->IsConfigured(); + this->BackwardsCompatibilityFinal = true; } return this->BackwardsCompatibility; diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx index 2dfa19c..13e0d7e 100644 --- a/Source/cmTarget.cxx +++ b/Source/cmTarget.cxx @@ -636,7 +636,7 @@ void cmTarget::GetSourceFiles(std::vector<std::string> &files, { assert(this->GetType() != INTERFACE_LIBRARY); - if (!this->Makefile->IsConfigured()) + if (!this->GetMakefile()->GetGlobalGenerator()->GetConfigureDoneCMP0026()) { // At configure-time, this method can be called as part of getting the // LOCATION property or to export() a file to be include()d. However @@ -682,7 +682,7 @@ void cmTarget::GetSourceFiles(std::vector<std::string> &files, "SOURCES") != debugProperties.end(); - if (this->Makefile->IsConfigured()) + if (this->GetMakefile()->GetGlobalGenerator()->GetConfigureDoneCMP0026()) { this->DebugSourcesDone = true; } |