summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalVisualStudioGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalVisualStudioGenerator.cxx')
-rw-r--r--Source/cmGlobalVisualStudioGenerator.cxx14
1 files changed, 8 insertions, 6 deletions
diff --git a/Source/cmGlobalVisualStudioGenerator.cxx b/Source/cmGlobalVisualStudioGenerator.cxx
index 93a597c..42492e6 100644
--- a/Source/cmGlobalVisualStudioGenerator.cxx
+++ b/Source/cmGlobalVisualStudioGenerator.cxx
@@ -129,9 +129,11 @@ cmGlobalVisualStudioGenerator
// Count the number of object files with each name. Note that
// windows file names are not case sensitive.
std::map<cmStdString, int> counts;
+ std::vector<cmSourceFile*> objectSources;
+ gt->GetObjectSources(objectSources);
for(std::vector<cmSourceFile*>::const_iterator
- si = gt->ObjectSources.begin();
- si != gt->ObjectSources.end(); ++si)
+ si = objectSources.begin();
+ si != objectSources.end(); ++si)
{
cmSourceFile* sf = *si;
std::string objectNameLower = cmSystemTools::LowerCase(
@@ -143,8 +145,8 @@ cmGlobalVisualStudioGenerator
// For all source files producing duplicate names we need unique
// object name computation.
for(std::vector<cmSourceFile*>::const_iterator
- si = gt->ObjectSources.begin();
- si != gt->ObjectSources.end(); ++si)
+ si = objectSources.begin();
+ si != objectSources.end(); ++si)
{
cmSourceFile* sf = *si;
std::string objectName =
@@ -152,10 +154,10 @@ cmGlobalVisualStudioGenerator
objectName += ".obj";
if(counts[cmSystemTools::LowerCase(objectName)] > 1)
{
- gt->ExplicitObjectName.insert(sf);
+ gt->AddExplicitObjectName(sf);
objectName = lg->GetObjectFileNameWithoutTarget(*sf, dir_max);
}
- gt->Objects[sf] = objectName;
+ gt->AddObject(sf, objectName);
}
std::string dir = gt->Makefile->GetCurrentOutputDirectory();