Commit bcaecf6b authored by Brad King's avatar Brad King

Teach check for single-language targets to consider all configurations

parent 324988a6
......@@ -6356,8 +6356,7 @@ bool cmGeneratorTarget::IsCSharpOnly() const
this->GetType() != cmStateEnums::EXECUTABLE) {
return false;
}
std::set<std::string> languages;
this->GetLanguages(languages, "");
std::set<std::string> languages = this->GetAllConfigCompileLanguages();
// Consider an explicit linker language property, but *not* the
// computed linker language that may depend on linked targets.
const char* linkLang = this->GetProperty("LINKER_LANGUAGE");
......
......@@ -810,8 +810,7 @@ bool cmGlobalVisualStudioGenerator::TargetIsFortranOnly(
// If there's only one source language, Fortran has to be used
// in order for the sources to compile.
std::set<std::string> languages;
gt->GetLanguages(languages, "");
std::set<std::string> languages = gt->GetAllConfigCompileLanguages();
// Consider an explicit linker language property, but *not* the
// computed linker language that may depend on linked targets.
// This allows the project to control the language choice in
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment