qmake: added WinRT and WinPhone configuration switch
qmakespec for either WinRT or WinPhone have to specify QMAKE_PLATFORM with winrt and/or winphone. Change-Id: I87e0063881e6edd65de14adb006949247ce49904 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This commit is contained in:
parent
fee7420a73
commit
036cfadcc6
@ -620,8 +620,23 @@ void VCXProjectWriter::write(XmlOutput &xml, VCProject &tool)
|
||||
<< attrTag("Label", "Globals")
|
||||
<< tagValue("ProjectGuid", tool.ProjectGUID)
|
||||
<< tagValue("RootNamespace", tool.Name)
|
||||
<< tagValue("Keyword", tool.Keyword)
|
||||
<< closetag();
|
||||
<< tagValue("Keyword", tool.Keyword);
|
||||
|
||||
if (tool.SingleProjects.at(0).Configuration.WinRT) {
|
||||
xml << tagValue("MinimumVisualStudioVersion", "11.0");
|
||||
if (tool.SingleProjects.at(0).Configuration.WinPhone)
|
||||
xml << tagValue("WinMDAssembly", "true");
|
||||
else
|
||||
xml << tagValue("AppContainerApplication", "true");
|
||||
}
|
||||
|
||||
if (tool.SingleProjects.at(0).Configuration.WinPhone
|
||||
&& tool.SingleProjects.at(0).Configuration.ConfigurationType == typeApplication) {
|
||||
xml << tagValue("XapOutputs", "true");
|
||||
xml << tagValue("XapFilename", "$(RootNamespace)_$(Configuration)_$(Platform).xap");
|
||||
}
|
||||
|
||||
xml << closetag();
|
||||
|
||||
// config part.
|
||||
xml << import("Project", "$(VCTargetsPath)\\Microsoft.Cpp.Default.props");
|
||||
@ -792,6 +807,9 @@ void VCXProjectWriter::write(XmlOutput &xml, VCProject &tool)
|
||||
|
||||
xml << import("Project", "$(VCTargetsPath)\\Microsoft.Cpp.targets");
|
||||
|
||||
if (tool.SingleProjects.at(0).Configuration.WinPhone)
|
||||
xml << import("Project", "$(MSBuildExtensionsPath)\\Microsoft\\WindowsPhone\\v8.0\\Microsoft.Cpp.WindowsPhone.8.0.targets");
|
||||
|
||||
xml << tag("ImportGroup")
|
||||
<< attrTag("Label", "ExtensionTargets")
|
||||
<< closetag();
|
||||
|
@ -2102,6 +2102,8 @@ VCPreLinkEventTool::VCPreLinkEventTool()
|
||||
|
||||
VCConfiguration::VCConfiguration()
|
||||
: ATLMinimizesCRunTimeLibraryUsage(unset),
|
||||
WinRT(false),
|
||||
WinPhone(false),
|
||||
BuildBrowserInformation(unset),
|
||||
CharacterSet(charSetNotSet),
|
||||
ConfigurationType(typeApplication),
|
||||
|
@ -862,6 +862,7 @@ public:
|
||||
~VCConfiguration(){}
|
||||
|
||||
DotNET CompilerVersion;
|
||||
bool WinRT, WinPhone;
|
||||
|
||||
// Variables
|
||||
triState ATLMinimizesCRunTimeLibraryUsage;
|
||||
|
@ -968,6 +968,12 @@ void VcprojGenerator::initConfiguration()
|
||||
conf.PrimaryOutput.append(project->first("TARGET_VERSION_EXT").toQString());
|
||||
}
|
||||
|
||||
if (conf.CompilerVersion >= NET2012) {
|
||||
conf.WinRT = project->isActiveConfig("winrt");
|
||||
if (conf.WinRT)
|
||||
conf.WinPhone = project->isActiveConfig("winphone");
|
||||
}
|
||||
|
||||
conf.Name = project->values("BUILD_NAME").join(' ');
|
||||
if (conf.Name.isEmpty())
|
||||
conf.Name = isDebug ? "Debug" : "Release";
|
||||
|
Loading…
Reference in New Issue
Block a user