Merge pull request #1439 from withmorten/master
Disable XP deprecation warning for Visual Studio projects
This commit is contained in:
commit
09dbfca63f
@ -290,6 +290,42 @@ end
|
||||
end
|
||||
|
||||
|
||||
function suite.canSetXPDeprecationWarningToFalse_withV141XP()
|
||||
toolset "v141_xp"
|
||||
prepare()
|
||||
test.capture [[
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>MyProject</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Globals">
|
||||
<XPDeprecationWarning>false</XPDeprecationWarning>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Globals">
|
||||
<XPDeprecationWarning>false</XPDeprecationWarning>
|
||||
</PropertyGroup>
|
||||
]]
|
||||
end
|
||||
|
||||
|
||||
function suite.canSetXPDeprecationWarningToFalse_perConfig_withV141XP()
|
||||
filter "Release"
|
||||
toolset "v141_xp"
|
||||
prepare()
|
||||
test.capture [[
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>MyProject</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Globals">
|
||||
<XPDeprecationWarning>false</XPDeprecationWarning>
|
||||
</PropertyGroup>
|
||||
]]
|
||||
end
|
||||
|
||||
|
||||
function suite.windowsTargetPlatformVersion_latest_on2019()
|
||||
p.action.set("vs2019")
|
||||
systemversion "latest"
|
||||
|
@ -139,6 +139,7 @@
|
||||
m.elements.globalsCondition = function(prj, cfg)
|
||||
return {
|
||||
m.windowsTargetPlatformVersion,
|
||||
m.xpDeprecationWarning,
|
||||
}
|
||||
end
|
||||
|
||||
@ -2411,6 +2412,7 @@
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function m.projectGuid(prj)
|
||||
m.element("ProjectGuid", nil, "{%s}", prj.uuid)
|
||||
end
|
||||
@ -2622,6 +2624,13 @@
|
||||
end
|
||||
|
||||
|
||||
function m.xpDeprecationWarning(prj, cfg)
|
||||
if cfg.toolset == "msc-v141_xp" then
|
||||
m.element("XPDeprecationWarning", nil, "false")
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function m.preferredToolArchitecture(prj)
|
||||
if _ACTION >= "vs2013" then
|
||||
if prj.preferredtoolarchitecture == p.X86_64 then
|
||||
|
Reference in New Issue
Block a user