diff options
author | Brad King <brad.king@kitware.com> | 2014-07-29 17:32:22 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-07-29 19:06:26 (GMT) |
commit | 2df389115e7636756cd1f1d6c422651b4899522d (patch) | |
tree | cc279d84c21289418c4be763893de9d33311c78f /Source/cmVisualStudio10TargetGenerator.cxx | |
parent | 143b40051a71c2f53e487be69069f1932ccc25d1 (diff) | |
download | CMake-2df389115e7636756cd1f1d6c422651b4899522d.zip CMake-2df389115e7636756cd1f1d6c422651b4899522d.tar.gz CMake-2df389115e7636756cd1f1d6c422651b4899522d.tar.bz2 |
VS: Refactor handling of "extra" sources in VS >= 10
Create a WriteExtraSource method to handle writing of sources not
classified by cmGeneratorTarget for any particular purpose. This
will be useful to add special VS-specific handling for some sources.
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r-- | Source/cmVisualStudio10TargetGenerator.cxx | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx index ca6c41e..d50bdde 100644 --- a/Source/cmVisualStudio10TargetGenerator.cxx +++ b/Source/cmVisualStudio10TargetGenerator.cxx @@ -997,6 +997,11 @@ WriteGroupSources(const char* name, this->WriteString("</ItemGroup>\n", 1); } +void cmVisualStudio10TargetGenerator::WriteExtraSource(cmSourceFile const* sf) +{ + this->WriteSource("None", sf); +} + void cmVisualStudio10TargetGenerator::WriteSource( std::string const& tool, cmSourceFile const* sf, const char* end) { @@ -1157,7 +1162,11 @@ void cmVisualStudio10TargetGenerator::WriteAllSources() std::vector<cmSourceFile const*> extraSources; this->GeneratorTarget->GetExtraSources(extraSources, ""); - this->WriteSources("None", extraSources); + for(std::vector<cmSourceFile const*>::const_iterator + si = extraSources.begin(); si != extraSources.end(); ++si) + { + this->WriteExtraSource(*si); + } // Add object library contents as external objects. std::vector<std::string> objs; |