diff options
Diffstat (limited to 'Source')
-rw-r--r-- | Source/CMakeVersion.cmake | 2 | ||||
-rw-r--r-- | Source/cmComputeTargetDepends.cxx | 2 | ||||
-rw-r--r-- | Source/cmCoreTryCompile.cxx | 16 | ||||
-rw-r--r-- | Source/cmProjectCommand.h | 8 |
4 files changed, 18 insertions, 10 deletions
diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake index 4ae8f3e..80d424e 100644 --- a/Source/CMakeVersion.cmake +++ b/Source/CMakeVersion.cmake @@ -2,5 +2,5 @@ set(CMake_VERSION_MAJOR 2) set(CMake_VERSION_MINOR 8) set(CMake_VERSION_PATCH 11) -set(CMake_VERSION_TWEAK 20130708) +set(CMake_VERSION_TWEAK 20130715) #set(CMake_VERSION_RC 1) diff --git a/Source/cmComputeTargetDepends.cxx b/Source/cmComputeTargetDepends.cxx index 8fd95b9..0829add 100644 --- a/Source/cmComputeTargetDepends.cxx +++ b/Source/cmComputeTargetDepends.cxx @@ -282,6 +282,8 @@ void cmComputeTargetDepends::AddInterfaceDepends(int depender_index, if(emitted.insert(*lib).second) { this->AddTargetDepend(depender_index, lib->c_str(), true); + this->AddInterfaceDepends(depender_index, lib->c_str(), + true, emitted); } } } diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx index 860417f..e312806 100644 --- a/Source/cmCoreTryCompile.cxx +++ b/Source/cmCoreTryCompile.cxx @@ -12,6 +12,7 @@ #include "cmCoreTryCompile.h" #include "cmake.h" #include "cmCacheManager.h" +#include "cmLocalGenerator.h" #include "cmGlobalGenerator.h" #include "cmExportTryCompileFileGenerator.h" #include <cmsys/Directory.hxx> @@ -214,8 +215,8 @@ int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv) } // Detect languages to enable. - cmGlobalGenerator* gg = - this->Makefile->GetCMakeInstance()->GetGlobalGenerator(); + cmLocalGenerator* lg = this->Makefile->GetLocalGenerator(); + cmGlobalGenerator* gg = lg->GetGlobalGenerator(); std::set<std::string> testLangs; for(std::vector<std::string>::iterator si = sources.begin(); si != sources.end(); ++si) @@ -295,13 +296,12 @@ int cmCoreTryCompile::TryCompileCode(std::vector<std::string> const& argv) for(std::set<std::string>::iterator li = testLangs.begin(); li != testLangs.end(); ++li) { - fprintf(fout, "SET(CMAKE_%s_FLAGS \"", li->c_str()); std::string langFlags = "CMAKE_" + *li + "_FLAGS"; - if(const char* flags = this->Makefile->GetDefinition(langFlags.c_str())) - { - fprintf(fout, " %s ", flags); - } - fprintf(fout, " ${COMPILE_DEFINITIONS}\")\n"); + const char* flags = this->Makefile->GetDefinition(langFlags.c_str()); + fprintf(fout, "SET(CMAKE_%s_FLAGS %s)\n", li->c_str(), + lg->EscapeForCMake(flags?flags:"").c_str()); + fprintf(fout, "SET(CMAKE_%s_FLAGS \"${CMAKE_%s_FLAGS}" + " ${COMPILE_DEFINITIONS}\")\n", li->c_str(), li->c_str()); } fprintf(fout, "INCLUDE_DIRECTORIES(${INCLUDE_DIRECTORIES})\n"); fprintf(fout, "SET(CMAKE_SUPPRESS_REGENERATION 1)\n"); diff --git a/Source/cmProjectCommand.h b/Source/cmProjectCommand.h index a53cb3f..9547c4c 100644 --- a/Source/cmProjectCommand.h +++ b/Source/cmProjectCommand.h @@ -71,7 +71,13 @@ public: "language \"NONE\" all checks for any language can be disabled. " "If a variable exists called CMAKE_PROJECT_<projectName>_INCLUDE, " "the file pointed to by that variable will be included as the last step " - "of the project command."; + "of the project command." + "\n" + "The top-level CMakeLists.txt file for a project must contain a " + "literal, direct call to the project() command; loading one through " + "the include() command is not sufficient. " + "If no such call exists CMake will implicitly add one to the top that " + "enables the default languages (C and CXX)."; } cmTypeMacro(cmProjectCommand, cmCommand); |