diff options
author | Brad King <brad.king@kitware.com> | 2014-03-17 14:00:43 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2014-03-17 14:00:43 (GMT) |
commit | b16f26f5f9cd033e24bbf398faf32369d7305bd7 (patch) | |
tree | 8502bd90002024b356d85ce8d3920c0fd65db118 /Source/cmGlobalXCodeGenerator.cxx | |
parent | 41b82db6855a26d01e1000b59da1792b954b326a (diff) | |
parent | 6c9dd0ec7b1e000b0bedd567fa52074671d639c9 (diff) | |
download | CMake-b16f26f5f9cd033e24bbf398faf32369d7305bd7.zip CMake-b16f26f5f9cd033e24bbf398faf32369d7305bd7.tar.gz CMake-b16f26f5f9cd033e24bbf398faf32369d7305bd7.tar.bz2 |
Merge topic 'target-objects-refactor'
6c9dd0ec cmGlobalGenerator: Make ComputeTargetObjects non-virtual
c481fadc cmGeneratorTarget: Don't store ObjectSources for object libraries.
f6da0440 cmLocalGenerator: Add ComputeObjectFilenames interface.
9ad804ac cmGeneratorTarget: Constify cmSourceFile* in containers.
c725bb3c Constify some APIs in generators.
dcfcd23e cmGeneratorTarget: Make GetSourceDepends const.
04cf50ff cmOSXBundleGenerator: Make MacOSXContentGeneratorType arg const.
6132d979 cmGeneratorTarget: Constify the AddExplicitObjectName API.
bc512211 cmGeneratorTarget: Constify the AddObject API.
cd43433d cmGlobalGenerator: Extract a ComputeTargetObjectDirectory interface.
d5b2e33b Makefiles: Compute local object files on demand.
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r-- | Source/cmGlobalXCodeGenerator.cxx | 33 |
1 files changed, 3 insertions, 30 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx index 36196a2..d4eb85b 100644 --- a/Source/cmGlobalXCodeGenerator.cxx +++ b/Source/cmGlobalXCodeGenerator.cxx @@ -3934,37 +3934,10 @@ bool cmGlobalXCodeGenerator::IsMultiConfig() return true; } - //---------------------------------------------------------------------------- -void -cmGlobalXCodeGenerator -::ComputeTargetObjects(cmGeneratorTarget* gt) const +//---------------------------------------------------------------------------- +void cmGlobalXCodeGenerator +::ComputeTargetObjectDirectory(cmGeneratorTarget* gt) const { - // Count the number of object files with each name. Warn about duplicate - // names since Xcode names them uniquely automatically with a numeric suffix - // to avoid exact duplicate file names. Note that Mac file names are not - // typically case sensitive, hence the LowerCase. - std::map<std::string, int> counts; - std::vector<cmSourceFile*> objectSources; - gt->GetObjectSources(objectSources); - for(std::vector<cmSourceFile*>::const_iterator - si = objectSources.begin(); - si != objectSources.end(); ++si) - { - cmSourceFile* sf = *si; - std::string objectName = - cmSystemTools::GetFilenameWithoutLastExtension(sf->GetFullPath()); - objectName += ".o"; - - std::string objectNameLower = cmSystemTools::LowerCase(objectName); - counts[objectNameLower] += 1; - if (2 == counts[objectNameLower]) - { - // TODO: emit warning about duplicate name? - } - - gt->AddObject(sf, objectName); - } - const char* configName = this->GetCMakeCFGIntDir(); std::string dir = this->GetObjectsNormalDirectory( "$(PROJECT_NAME)", configName, gt->Target); |