diff options
author | Stephen Kelly <steveire@gmail.com> | 2014-02-13 16:25:00 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2014-04-02 21:14:02 (GMT) |
commit | e6971df6ab647031ba9689c9afbbde78cc62e35f (patch) | |
tree | c9c67c6e3a1627d65cda8ee93373b97403c92106 /Source/cmLocalGenerator.cxx | |
parent | df753df94bb1e995372baabb0240585560c72ded (diff) | |
download | CMake-e6971df6ab647031ba9689c9afbbde78cc62e35f.zip CMake-e6971df6ab647031ba9689c9afbbde78cc62e35f.tar.gz CMake-e6971df6ab647031ba9689c9afbbde78cc62e35f.tar.bz2 |
cmTarget: Make the source files depend on the config.
Disallow the use of config-specific source files with
the Visual Studio and Xcode generators. They don't have
any way to represent the condition currently.
Use the same common-config API in cmQtAutoGenerators. While
it accepts config-specific files, it doesn't have to support
multiple configurations yet.
Loop over the configs in cmTargetTraceDependencies
and cmGlobalGenerator::WriteSummary and consume all source
files.
Loop over the configs in cmComputeTargetDepends and compute the
object library dependencies for each config.
Diffstat (limited to 'Source/cmLocalGenerator.cxx')
-rw-r--r-- | Source/cmLocalGenerator.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 61d2a80..e2f8375 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -662,7 +662,8 @@ void cmLocalGenerator::AddBuildTargetRule(const std::string& llang, std::vector<std::string> objVector; // Add all the sources outputs to the depends of the target std::vector<cmSourceFile*> classes; - target.GetSourceFiles(classes); + target.GetSourceFiles(classes, + this->Makefile->GetSafeDefinition("CMAKE_BUILD_TYPE")); for(std::vector<cmSourceFile*>::const_iterator i = classes.begin(); i != classes.end(); ++i) { @@ -1644,7 +1645,7 @@ void cmLocalGenerator::GetTargetFlags(std::string& linkLibs, !(this->Makefile->IsOn("CYGWIN") || this->Makefile->IsOn("MINGW"))) { std::vector<cmSourceFile*> sources; - target->GetSourceFiles(sources); + target->GetSourceFiles(sources, buildType); for(std::vector<cmSourceFile*>::const_iterator i = sources.begin(); i != sources.end(); ++i) { @@ -1692,7 +1693,7 @@ void cmLocalGenerator::GetTargetFlags(std::string& linkLibs, linkFlags += this->Makefile->GetSafeDefinition(build); linkFlags += " "; } - std::string linkLanguage = target->Target->GetLinkerLanguage(); + std::string linkLanguage = target->Target->GetLinkerLanguage(buildType); if(linkLanguage.empty()) { cmSystemTools::Error |