ENH: Use fixed header file type mapping for Xcode
This simplifies computation of the lastKnownFileType attribute for header files in Xcode projects. We now use a fixed mapping from header file extension to attribute value. The value is just a hint to the Xcode editor, so computing the target linker language is overkill.
This commit is contained in:
parent
2b5d97419f
commit
6ef56f7778
@ -633,17 +633,13 @@ cmGlobalXCodeGenerator::CreateXCodeFileReference(cmSourceFile* sf,
|
||||
{
|
||||
sourcecode += ".text.plist";
|
||||
}
|
||||
else if(ext == "h" || ext == "hxx" || ext == "hpp")
|
||||
else if(ext == "h")
|
||||
{
|
||||
const char* linkLanguage = cmtarget.GetLinkerLanguage();
|
||||
if(linkLanguage && (std::string(linkLanguage) == "CXX"))
|
||||
{
|
||||
sourcecode += ".cpp.h";
|
||||
}
|
||||
else
|
||||
{
|
||||
sourcecode += ".c.h";
|
||||
}
|
||||
sourcecode += ".c.h";
|
||||
}
|
||||
else if(ext == "hxx" || ext == "hpp" || ext == "txx")
|
||||
{
|
||||
sourcecode += ".cpp.h";
|
||||
}
|
||||
else if(lang && strcmp(lang, "CXX") == 0)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user