Merge topic 'vs-osx-framework-headers'
470f39c
VS: Restore header files marked as OS X Framework content (#13196)
This commit is contained in:
commit
e7e9f242db
|
@ -39,17 +39,10 @@ void cmGeneratorTarget::ClassifySources()
|
||||||
{
|
{
|
||||||
cmSourceFile* sf = *si;
|
cmSourceFile* sf = *si;
|
||||||
std::string ext = cmSystemTools::LowerCase(sf->GetExtension());
|
std::string ext = cmSystemTools::LowerCase(sf->GetExtension());
|
||||||
cmTarget::SourceFileFlags tsFlags =
|
|
||||||
this->Target->GetTargetSourceFileFlags(sf);
|
|
||||||
if(sf->GetCustomCommand())
|
if(sf->GetCustomCommand())
|
||||||
{
|
{
|
||||||
this->CustomCommands.push_back(sf);
|
this->CustomCommands.push_back(sf);
|
||||||
}
|
}
|
||||||
else if(tsFlags.Type != cmTarget::SourceFileTypeNormal)
|
|
||||||
{
|
|
||||||
this->OSXContent.push_back(sf);
|
|
||||||
if(isObjLib) { badObjLib.push_back(sf); }
|
|
||||||
}
|
|
||||||
else if(sf->GetPropertyAsBool("HEADER_FILE_ONLY"))
|
else if(sf->GetPropertyAsBool("HEADER_FILE_ONLY"))
|
||||||
{
|
{
|
||||||
this->HeaderSources.push_back(sf);
|
this->HeaderSources.push_back(sf);
|
||||||
|
|
|
@ -37,7 +37,6 @@ public:
|
||||||
std::vector<cmSourceFile*> HeaderSources;
|
std::vector<cmSourceFile*> HeaderSources;
|
||||||
std::vector<cmSourceFile*> ObjectSources;
|
std::vector<cmSourceFile*> ObjectSources;
|
||||||
std::vector<cmSourceFile*> ExternalObjects;
|
std::vector<cmSourceFile*> ExternalObjects;
|
||||||
std::vector<cmSourceFile*> OSXContent;
|
|
||||||
std::vector<cmSourceFile*> IDLSources;
|
std::vector<cmSourceFile*> IDLSources;
|
||||||
std::string ModuleDefinitionFile;
|
std::string ModuleDefinitionFile;
|
||||||
|
|
||||||
|
|
|
@ -153,14 +153,8 @@ void cmMakefileTargetGenerator::WriteTargetBuildRules()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for(std::vector<cmSourceFile*>::const_iterator
|
this->WriteMacOSXContentRules(this->GeneratorTarget->HeaderSources);
|
||||||
si = this->GeneratorTarget->OSXContent.begin();
|
this->WriteMacOSXContentRules(this->GeneratorTarget->ExtraSources);
|
||||||
si != this->GeneratorTarget->OSXContent.end(); ++si)
|
|
||||||
{
|
|
||||||
cmTarget::SourceFileFlags tsFlags =
|
|
||||||
this->Target->GetTargetSourceFileFlags(*si);
|
|
||||||
this->WriteMacOSXContentRules(**si, tsFlags.MacFolder);
|
|
||||||
}
|
|
||||||
for(std::vector<cmSourceFile*>::const_iterator
|
for(std::vector<cmSourceFile*>::const_iterator
|
||||||
si = this->GeneratorTarget->ExternalObjects.begin();
|
si = this->GeneratorTarget->ExternalObjects.begin();
|
||||||
si != this->GeneratorTarget->ExternalObjects.end(); ++si)
|
si != this->GeneratorTarget->ExternalObjects.end(); ++si)
|
||||||
|
@ -353,6 +347,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,
|
void cmMakefileTargetGenerator::WriteMacOSXContentRules(cmSourceFile& source,
|
||||||
const char* pkgloc)
|
const char* pkgloc)
|
||||||
|
|
|
@ -73,6 +73,7 @@ protected:
|
||||||
void WriteTargetDependRules();
|
void WriteTargetDependRules();
|
||||||
|
|
||||||
// write rules for Mac OS X Application Bundle content.
|
// write rules for Mac OS X Application Bundle content.
|
||||||
|
void WriteMacOSXContentRules(std::vector<cmSourceFile*> const& sources);
|
||||||
void WriteMacOSXContentRules(cmSourceFile& source, const char* pkgloc);
|
void WriteMacOSXContentRules(cmSourceFile& source, const char* pkgloc);
|
||||||
|
|
||||||
// write the rules for an object
|
// write the rules for an object
|
||||||
|
|
|
@ -396,7 +396,6 @@ cmNinjaTargetGenerator
|
||||||
cmCustomCommand const* cc = (*si)->GetCustomCommand();
|
cmCustomCommand const* cc = (*si)->GetCustomCommand();
|
||||||
this->GetLocalGenerator()->AddCustomCommandTarget(cc, this->GetTarget());
|
this->GetLocalGenerator()->AddCustomCommandTarget(cc, this->GetTarget());
|
||||||
}
|
}
|
||||||
// TODO: this->GeneratorTarget->OSXContent
|
|
||||||
for(std::vector<cmSourceFile*>::const_iterator
|
for(std::vector<cmSourceFile*>::const_iterator
|
||||||
si = this->GeneratorTarget->ExternalObjects.begin();
|
si = this->GeneratorTarget->ExternalObjects.begin();
|
||||||
si != this->GeneratorTarget->ExternalObjects.end(); ++si)
|
si != this->GeneratorTarget->ExternalObjects.end(); ++si)
|
||||||
|
|
Loading…
Reference in New Issue