summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileTargetGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2012-05-07 19:24:16 (GMT)
committerBrad King <brad.king@kitware.com>2012-05-07 19:28:19 (GMT)
commit470f39cf4ea3da35716e6f4ea5bbdc17b5b0e814 (patch)
tree9075c975137ba6e59c15edb5a62b0687eca55af2 /Source/cmMakefileTargetGenerator.cxx
parentc5a67a7fec2dde8caba8044de3699331a89db020 (diff)
downloadCMake-470f39cf4ea3da35716e6f4ea5bbdc17b5b0e814.zip
CMake-470f39cf4ea3da35716e6f4ea5bbdc17b5b0e814.tar.gz
CMake-470f39cf4ea3da35716e6f4ea5bbdc17b5b0e814.tar.bz2
VS: Restore header files marked as OS X Framework content (#13196)
Header files listed in a target's PUBLIC_HEADER or similar properties are marked as OS X Framework content. Refactoring performed by commit 11d9b211 (Add cmGeneratorTarget to represent a target during generation, 2012-03-07) commit 45c2f932 (Simplify cmMakefileTargetGenerator using cmGeneratorTarget, 2012-03-07) commit 328c0f65 (Simplify cmVisualStudio10TargetGenerator source classification, 2012-03-19) and related commits accidentally removed such files from treatment as normal header files by the VS generator (generators other than Makefiles and Xcode). Move handling of such files out of cmGeneratorTarget and back to cmMakefileTargetGenerator. The central cmGeneratorTarget classification will always treat them as header or extra sources.
Diffstat (limited to 'Source/cmMakefileTargetGenerator.cxx')
-rw-r--r--Source/cmMakefileTargetGenerator.cxx26
1 files changed, 18 insertions, 8 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx
index a0e0481..408f287 100644
--- a/Source/cmMakefileTargetGenerator.cxx
+++ b/Source/cmMakefileTargetGenerator.cxx
@@ -153,14 +153,8 @@ void cmMakefileTargetGenerator::WriteTargetBuildRules()
}
}
}
- for(std::vector<cmSourceFile*>::const_iterator
- si = this->GeneratorTarget->OSXContent.begin();
- si != this->GeneratorTarget->OSXContent.end(); ++si)
- {
- cmTarget::SourceFileFlags tsFlags =
- this->Target->GetTargetSourceFileFlags(*si);
- this->WriteMacOSXContentRules(**si, tsFlags.MacFolder);
- }
+ this->WriteMacOSXContentRules(this->GeneratorTarget->HeaderSources);
+ this->WriteMacOSXContentRules(this->GeneratorTarget->ExtraSources);
for(std::vector<cmSourceFile*>::const_iterator
si = this->GeneratorTarget->ExternalObjects.begin();
si != this->GeneratorTarget->ExternalObjects.end(); ++si)
@@ -354,6 +348,22 @@ void cmMakefileTargetGenerator::WriteTargetLanguageFlags()
}
//----------------------------------------------------------------------------
+void cmMakefileTargetGenerator::WriteMacOSXContentRules(
+ std::vector<cmSourceFile*> const& sources)
+{
+ for(std::vector<cmSourceFile*>::const_iterator
+ si = sources.begin(); si != sources.end(); ++si)
+ {
+ cmTarget::SourceFileFlags tsFlags =
+ this->Target->GetTargetSourceFileFlags(*si);
+ if(tsFlags.Type != cmTarget::SourceFileTypeNormal)
+ {
+ this->WriteMacOSXContentRules(**si, tsFlags.MacFolder);
+ }
+ }
+}
+
+//----------------------------------------------------------------------------
void cmMakefileTargetGenerator::WriteMacOSXContentRules(cmSourceFile& source,
const char* pkgloc)
{