diff options
Diffstat (limited to 'qmake/generators/win32/msbuild_objectmodel.cpp')
-rw-r--r-- | qmake/generators/win32/msbuild_objectmodel.cpp | 39 |
1 files changed, 37 insertions, 2 deletions
diff --git a/qmake/generators/win32/msbuild_objectmodel.cpp b/qmake/generators/win32/msbuild_objectmodel.cpp index 99cdd11..75fc910 100644 --- a/qmake/generators/win32/msbuild_objectmodel.cpp +++ b/qmake/generators/win32/msbuild_objectmodel.cpp @@ -2656,6 +2656,14 @@ bool VCXFilter::outputFileConfig(XmlOutput &xml, XmlOutput &xmlFilter, const QSt xml << tag("ClCompile") << attrTag("Include",Option::fixPathToLocalOS(filename)); + } else if(filename.endsWith(".res")) { + + xmlFilter << tag("CustomBuild") + << attrTag("Include",Option::fixPathToLocalOS(filename)) + << attrTagS("Filter", filtername); + + xml << tag("CustomBuild") + << attrTag("Include",Option::fixPathToLocalOS(filename)); } else { xmlFilter << tag("CustomBuild") @@ -2665,6 +2673,16 @@ bool VCXFilter::outputFileConfig(XmlOutput &xml, XmlOutput &xmlFilter, const QSt xml << tag("CustomBuild") << attrTag("Include",Option::fixPathToLocalOS(filename)); } + } else if(filtername == "Root Files") { + + if (filename.endsWith(".rc")) { + + xmlFilter << tag("ResourceCompile") + << attrTag("Include",Option::fixPathToLocalOS(filename)); + + xml << tag("ResourceCompile") + << attrTag("Include",Option::fixPathToLocalOS(filename)); + } } } @@ -2696,8 +2714,6 @@ bool VCXFilter::outputFileConfig(XmlOutput &xml, XmlOutput &xmlFilter, const QSt << attrTag("Condition", QString("'$(Configuration)|$(Platform)'=='%1'").arg((*Config).Name)) << valueTag(CompilerTool.PrecompiledHeader); } - - //xml << CompilerTool; } } @@ -3023,6 +3039,14 @@ void VCXProject::outputFileConfigs(XmlOutput &xml, xml << tag("ClCompile") << attrTag("Include",Option::fixPathToLocalOS(info.file)); + } else if(info.file.endsWith(".res")) { + + xmlFilter << tag("CustomBuild") + << attrTag("Include",Option::fixPathToLocalOS(info.file)) + << attrTagS("Filter", filtername); + + xml << tag("CustomBuild") + << attrTag("Include",Option::fixPathToLocalOS(info.file)); } else { xmlFilter << tag("CustomBuild") @@ -3033,6 +3057,16 @@ void VCXProject::outputFileConfigs(XmlOutput &xml, << attrTag("Include",Option::fixPathToLocalOS(info.file)); } + } else if(filtername == "Root Files") { + + if (info.file.endsWith(".rc")) { + + xmlFilter << tag("ResourceCompile") + << attrTag("Include",Option::fixPathToLocalOS(info.file)); + + xml << tag("ResourceCompile") + << attrTag("Include",Option::fixPathToLocalOS(info.file)); + } } else { xmlFilter << tag("None") @@ -3329,6 +3363,7 @@ XmlOutput &operator<<(XmlOutput &xml, VCXProject &tool) for (int x = 0; x < tool.ExtraCompilers.count(); ++x) { tool.outputFilter(xml, xmlFilter, tool.ExtraCompilers.at(x)); } + tool.outputFilter(xml, xmlFilter, "Root Files"); xml << import("Project", "$(VCTargetsPath)\\Microsoft.Cpp.targets"); |