summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileTargetGenerator.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2013-11-10 10:22:44 (GMT)
committerStephen Kelly <steveire@gmail.com>2014-01-09 18:38:07 (GMT)
commit38de54cf6f3daae70792fae1bf26b97bccc78de4 (patch)
treeb8499bdf53aef7b2d98a9be50949e79566224b65 /Source/cmMakefileTargetGenerator.cxx
parentf579fe0d7a102df0c69c957d48e3e728333dffe1 (diff)
downloadCMake-38de54cf6f3daae70792fae1bf26b97bccc78de4.zip
CMake-38de54cf6f3daae70792fae1bf26b97bccc78de4.tar.gz
CMake-38de54cf6f3daae70792fae1bf26b97bccc78de4.tar.bz2
cmGeneratorTarget: Add methods to access source file groups.
These methods and others will be able to get a config parameter later to implement the INTERFACE_SOURCES feature.
Diffstat (limited to 'Source/cmMakefileTargetGenerator.cxx')
-rw-r--r--Source/cmMakefileTargetGenerator.cxx28
1 files changed, 19 insertions, 9 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx
index f82b808..25b2b4c 100644
--- a/Source/cmMakefileTargetGenerator.cxx
+++ b/Source/cmMakefileTargetGenerator.cxx
@@ -151,9 +151,11 @@ void cmMakefileTargetGenerator::WriteTargetBuildRules()
// First generate the object rule files. Save a list of all object
// files for this target.
+ std::vector<cmSourceFile*> customCommands;
+ this->GeneratorTarget->GetCustomCommands(customCommands);
for(std::vector<cmSourceFile*>::const_iterator
- si = this->GeneratorTarget->CustomCommands.begin();
- si != this->GeneratorTarget->CustomCommands.end(); ++si)
+ si = customCommands.begin();
+ si != customCommands.end(); ++si)
{
cmCustomCommand const* cc = (*si)->GetCustomCommand();
this->GenerateCustomRuleFile(*cc);
@@ -170,21 +172,28 @@ void cmMakefileTargetGenerator::WriteTargetBuildRules()
}
}
}
+ std::vector<cmSourceFile*> headerSources;
+ this->GeneratorTarget->GetHeaderSources(headerSources);
this->OSXBundleGenerator->GenerateMacOSXContentStatements(
- this->GeneratorTarget->HeaderSources,
+ headerSources,
this->MacOSXContentGenerator);
+ std::vector<cmSourceFile*> extraSources;
+ this->GeneratorTarget->GetExtraSources(extraSources);
this->OSXBundleGenerator->GenerateMacOSXContentStatements(
- this->GeneratorTarget->ExtraSources,
+ extraSources,
this->MacOSXContentGenerator);
+ std::vector<cmSourceFile*> externalObjects;
+ this->GeneratorTarget->GetExternalObjects(externalObjects);
for(std::vector<cmSourceFile*>::const_iterator
- si = this->GeneratorTarget->ExternalObjects.begin();
- si != this->GeneratorTarget->ExternalObjects.end(); ++si)
+ si = externalObjects.begin();
+ si != externalObjects.end(); ++si)
{
this->ExternalObjects.push_back((*si)->GetFullPath());
}
+ std::vector<cmSourceFile*> objectSources;
+ this->GeneratorTarget->GetObjectSources(objectSources);
for(std::vector<cmSourceFile*>::const_iterator
- si = this->GeneratorTarget->ObjectSources.begin();
- si != this->GeneratorTarget->ObjectSources.end(); ++si)
+ si = objectSources.begin(); si != objectSources.end(); ++si)
{
// Generate this object file's rule file.
this->WriteObjectRuleFiles(**si);
@@ -421,7 +430,8 @@ void cmMakefileTargetGenerator::WriteObjectRuleFiles(cmSourceFile& source)
}
// Get the full path name of the object file.
- std::string const& objectName = this->GeneratorTarget->Objects[&source];
+ std::string const& objectName = this->GeneratorTarget
+ ->GetObjectName(&source);
std::string obj = this->LocalGenerator->GetTargetDirectory(*this->Target);
obj += "/";
obj += objectName;