From 1c489923d54592dfdd0a9421f585bb45ccf9aa44 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 28 Mar 2012 08:41:48 -0400 Subject: Always compile sources with known language Refactoring by commit 11d9b211 (Add cmGeneratorTarget to represent a target during generation, 2012-03-07) and commit 45c2f932 (Simplify cmMakefileTargetGenerator using cmGeneratorTarget, 2012-03-07) preserved behavior introduced by commit 7740ccd1 (some cleanup of the makefile generator, 2006-02-14) that favored the IgnoreFile extension test over the availability of a known compilation language associated with a source file. If a source is not marked as HEADER_FILE_ONLY and has a known language extension or an explicit LANGUAGE property it should be treated as that language. The LANGUAGE source file property documentation says so. --- Source/cmGeneratorTarget.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index 7979928..3f43465 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -58,6 +58,10 @@ void cmGeneratorTarget::ClassifySources() this->ExternalObjects.push_back(sf); if(isObjLib) { badObjLib.push_back(sf); } } + else if(sf->GetLanguage()) + { + this->ObjectSources.push_back(sf); + } else if(ext == "def") { this->ModuleDefinitionFile = sf->GetFullPath(); @@ -75,10 +79,6 @@ void cmGeneratorTarget::ClassifySources() // No message or diagnosis should be given. this->ExtraSources.push_back(sf); } - else if(sf->GetLanguage()) - { - this->ObjectSources.push_back(sf); - } else { this->ExtraSources.push_back(sf); -- cgit v0.12