From 247a132422bd3f1c97f5fcf8457d5a105ab65687 Mon Sep 17 00:00:00 2001 From: David Cole Date: Wed, 14 Mar 2012 17:36:31 -0400 Subject: [PATCH] Allow txt files as ExtraSources in object library targets Necessary for the Xcode generator, in which the CMakeLists.txt files are added as sources merely for convenient access, without any associated custom command. --- Source/cmGeneratorTarget.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index 369eb5cf2..b5fcae267 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -74,7 +74,10 @@ void cmGeneratorTarget::ClassifySources() else { this->ExtraSources.push_back(sf); - if(isObjLib) { badObjLib.push_back(sf); } + if(isObjLib && cmSystemTools::LowerCase(sf->GetExtension()) != "txt") + { + badObjLib.push_back(sf); + } } }