Consolidate Visual Studio extensions into the core action

This commit is contained in:
Jason Perkins 2014-12-08 17:42:00 -05:00
parent ceb3c83d67
commit 1bcd783031
21 changed files with 267 additions and 503 deletions

View File

@ -25,6 +25,7 @@
cs2005.elements.project = {
"xmlDeclaration",
"projectElement",
"commonProperties",
"projectProperties",
"configurations",
"applicationIcon",
@ -383,6 +384,13 @@
end
function cs2005.commonProperties(prj)
if _ACTION > "vs2010" then
_p(1,'<Import Project="$(MSBuildExtensionsPath)\\$(MSBuildToolsVersion)\\Microsoft.Common.props" Condition="Exists(\'$(MSBuildExtensionsPath)\\$(MSBuildToolsVersion)\\Microsoft.Common.props\')" />')
end
end
function cs2005.configurationCondition(cfg)
_x(2,'<Configuration Condition=" \'$(Configuration)\' == \'\' ">%s</Configuration>', cfg.buildcfg)
end

View File

@ -121,6 +121,7 @@
m.elements.globals = function(prj)
return {
m.projectGuid,
m.ignoreWarnDuplicateFilename,
m.keyword,
m.projectName,
}
@ -151,6 +152,7 @@
m.useOfAtl,
m.clrSupport,
m.characterSet,
m.platformToolset,
m.wholeProgramOptimization,
m.nmakeOutDirs,
}
@ -1124,6 +1126,18 @@
end
function m.ignoreWarnDuplicateFilename(prj)
-- VS 2013 warns on duplicate file names, even those files which are
-- contained in different, mututally exclusive configurations. See:
-- http://connect.microsoft.com/VisualStudio/feedback/details/797460/incorrect-warning-msb8027-reported-for-files-excluded-from-build
-- Premake already adds unique object names to conflicting file names, so
-- just go ahead and disable that warning.
if _ACTION > "vs2012" then
p.w('<IgnoreWarnCompileDuplicatedFilename>true</IgnoreWarnCompileDuplicatedFilename>')
end
end
function m.ignoreImportLibrary(cfg)
if cfg.kind == premake.SHAREDLIB and cfg.flags.NoImportLib then
_p(2,'<IgnoreImportLibrary>true</IgnoreImportLibrary>');
@ -1363,6 +1377,21 @@
end
function m.platformToolset(cfg)
local map = { vs2012 = "v110", vs2013 = "v120" }
local value = map[_ACTION]
if value then
-- should only be written if there is a C/C++ file in the config
for i = 1, #cfg.files do
if path.iscppfile(cfg.files[i]) then
_p(2,'<PlatformToolset>%s</PlatformToolset>', value)
return
end
end
end
end
function m.precompiledHeader(cfg, filecfg, condition)
if filecfg then
if cfg.pchsource == filecfg.abspath and not cfg.flags.NoPCH then

View File

@ -54,32 +54,3 @@
}
}
---
-- Add new elements to the configuration properties block of C++ projects.
---
p.override(vc2010.elements, "configurationProperties", function(base, cfg)
local calls = base(cfg)
table.insertafter(calls, vc2010.characterSet, vc2010.platformToolset)
return calls
end)
function vc2010.platformToolset(cfg)
if _ACTION > "vs2010" then
_p(2,'<PlatformToolset>v110</PlatformToolset>')
end
end
--
-- Add a common properties import statement to the top of C# projects.
--
table.insertafter(cs2005.elements.project, "projectElement", "commonProperties")
function cs2005.commonProperties(prj)
if _ACTION > "vs2010" then
_p(1,'<Import Project="$(MSBuildExtensionsPath)\\$(MSBuildToolsVersion)\\Microsoft.Common.props" Condition="Exists(\'$(MSBuildExtensionsPath)\\$(MSBuildToolsVersion)\\Microsoft.Common.props\')" />')
end
end

View File

@ -55,39 +55,3 @@
toolsVersion = "12.0",
}
}
---
-- VS 2013 warns on duplicate file names, even those files are contained in
-- different, mututally exclusive configurations. See:
-- http://connect.microsoft.com/VisualStudio/feedback/details/797460/incorrect-warning-msb8027-reported-for-files-excluded-from-build
--
-- Premake already adds unique object names to conflicting file names, so just
-- go ahead and disable that warning.
---
premake.override(vc2010.elements, "globals", function(base, prj)
local calls = base(prj)
table.insertafter(calls, vc2010.projectGuid, m.ignoreWarnDuplicateFilename)
return calls
end)
function m.ignoreWarnDuplicateFilename(prj)
if _ACTION > "vs2012" then
p.w('<IgnoreWarnCompileDuplicatedFilename>true</IgnoreWarnCompileDuplicatedFilename>')
end
end
---
-- Add new elements to the configuration properties block of C++ projects.
---
premake.override(vc2010, "platformToolset", function(base, cfg)
if _ACTION > "vs2012" then
_p(2,'<PlatformToolset>v120</PlatformToolset>')
else
base(cfg)
end
end)

View File

@ -58,6 +58,7 @@ return {
-- Visual Studio 2005-2010 C# projects
"actions/vstudio/cs2005/test_assembly_refs.lua",
"actions/vstudio/cs2005/test_build_events.lua",
"actions/vstudio/cs2005/test_common_props.lua",
"actions/vstudio/cs2005/test_compiler_props.lua",
"actions/vstudio/cs2005/test_debug_props.lua",
"actions/vstudio/cs2005/test_files.lua",
@ -67,6 +68,7 @@ return {
"actions/vstudio/cs2005/test_platform_groups.lua",
"actions/vstudio/cs2005/test_project_refs.lua",
"actions/vstudio/cs2005/projectsettings.lua",
"actions/vstudio/cs2005/test_targets.lua",
-- Visual Studio 2005-2010 solutions
"actions/vstudio/sln2005/test_dependencies.lua",
@ -117,21 +119,6 @@ return {
"actions/vstudio/vc2010/test_resource_compile.lua",
"actions/vstudio/vc2010/test_rule_vars.lua",
-- Visual Studio 2012
"actions/vs2012/test_csproj_common_props.lua",
"actions/vs2012/test_csproj_project_element.lua",
"actions/vs2012/test_csproj_project_props.lua",
"actions/vs2012/test_csproj_targets.lua",
"actions/vs2012/test_sln_header.lua",
"actions/vs2012/test_vcxproj_clcompile.lua",
"actions/vs2012/test_vcxproj_config_props.lua",
-- Visual Studio 2013
"actions/vs2013/test_csproj_project_element.lua",
"actions/vs2013/test_globals.lua",
"actions/vs2013/test_sln_header.lua",
"actions/vs2013/test_vcxproj_config_props.lua",
-- Makefile tests
"actions/make/test_make_escaping.lua",
"actions/make/test_make_tovar.lua",

View File

@ -1,28 +0,0 @@
--
-- tests/actions/vs2012/test_csproj_project_element.lua
-- Check generation of opening project element for VS2012 C# projects.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_csproj_project_element")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln, prj = test.createsolution()
end
function suite.allVersionsCorrect()
cs2005.projectElement(prj)
test.capture [[
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
]]
end

View File

@ -1,48 +0,0 @@
--
-- tests/actions/vs2012/test_csproj_project_props.lua
-- Check Visual Studio 2012 extensions to the project properties block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_csproj_project_props")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln = test.createsolution()
language "C#"
end
local function prepare()
prj = premake.solution.getproject(sln, 1)
cs2005.projectProperties(prj)
end
---
-- Visual Studio 2012 omits ProductVersion and SchemaVersion.
---
function suite.onDefaultProps()
prepare()
test.capture [[
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>MyProject</RootNamespace>
<AssemblyName>MyProject</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
]]
end

View File

@ -1,29 +0,0 @@
--
-- tests/actions/vs2012/test_sln_header.lua
-- Check VS2012 modifications to the solution header markup.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_sln_header")
local sln2005 = premake.vstudio.sln2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln = test.createsolution()
end
function suite.setsVersionsInHeader()
sln2005.header()
test.capture [[
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
]]
end

View File

@ -1,34 +0,0 @@
--
-- tests/actions/vs2012/test_vcxproj_clcompile.lua
-- Validate compiler settings in Visual Studio 2012 C/C++ projects.
-- Copyright (c) 2014 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_vcxproj_clcompile")
local vc2010 = premake.vstudio.vc2010
local project = premake.project
--
-- Setup
--
local sln, prj, cfg
function suite.setup()
_ACTION = "vs2012"
sln, prj = test.createsolution()
end
--
-- Verify the new instruction sets.
--
function suite.enhancedInstructionSet_onAVX()
vectorextensions "avx"
vc2010.enableEnhancedInstructionSet(test.getconfig(prj, "Debug"))
test.capture [[
<EnableEnhancedInstructionSet>AdvancedVectorExtensions</EnableEnhancedInstructionSet>
]]
end

View File

@ -1,43 +0,0 @@
---
-- tests/actions/vs2012/test_vcxproj_config_props.lua
-- Check the VC2012 extensions to the configuration properties block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
---
local suite = test.declare("vs2012_vcxproj_config_props")
local vc2010 = premake.vstudio.vc2010
local project = premake.project
---
-- Setup
---
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln, prj = test.createsolution()
end
local function prepare()
local cfg = test.getconfig(prj, "Debug")
vc2010.configurationProperties(cfg)
end
---
-- Visual Studio 2012 adds a new <PlatformToolset> element.
---
function suite.addsPlatformToolset()
prepare()
test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v110</PlatformToolset>
</PropertyGroup>
]]
end

View File

@ -1,28 +0,0 @@
--
-- tests/actions/vs2013/test_csproj_project_element.lua
-- Check generation of opening project element for VS2013 C# projects.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2013_csproj_project_element")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2013"
sln, prj = test.createsolution()
end
function suite.allVersionsCorrect()
cs2005.projectElement(prj)
test.capture [[
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
]]
end

View File

@ -1,42 +0,0 @@
--
-- tests/actions/vs2013/test_globals.lua
-- Validate generation of the Globals property group.
-- Copyright (c) 2014 Jason Perkins and the Premake project
--
local suite = test.declare("vstudio_vs2013_globals")
local vc2010 = premake.vstudio.vc2010
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2013"
sln = test.createsolution()
end
local function prepare()
prj = premake.solution.getproject(sln, 1)
vc2010.globals(prj)
end
--
-- Check the structure with the default project values.
--
function suite.structureIsCorrect_onDefaultValues()
prepare()
test.capture [[
<PropertyGroup Label="Globals">
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
<IgnoreWarnCompileDuplicatedFilename>true</IgnoreWarnCompileDuplicatedFilename>
<Keyword>Win32Proj</Keyword>
<RootNamespace>MyProject</RootNamespace>
</PropertyGroup>
]]
end

View File

@ -1,29 +0,0 @@
--
-- tests/actions/vs2013/test_sln_header.lua
-- Check VS2013 modifications to the solution header markup.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2013_sln_header")
local sln2005 = premake.vstudio.sln2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2013"
sln = test.createsolution()
end
function suite.setsVersionsInHeader()
sln2005.header()
test.capture [[
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
]]
end

View File

@ -1,43 +0,0 @@
---
-- tests/actions/vs2013/test_vcxproj_config_props.lua
-- Check the VC2013 extensions to the configuration properties block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
---
local suite = test.declare("vs2013_vcxproj_config_props")
local vc2010 = premake.vstudio.vc2010
local project = premake.project
---
-- Setup
---
local sln, prj
function suite.setup()
_ACTION = "vs2013"
sln, prj = test.createsolution()
end
local function prepare()
local cfg = test.getconfig(prj, "Debug")
vc2010.configurationProperties(cfg)
end
---
-- Visual Studio 2013 adds a new <PlatformToolset> element.
---
function suite.addsPlatformToolset()
prepare()
test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v120</PlatformToolset>
</PropertyGroup>
]]
end

View File

@ -1,11 +1,10 @@
--
-- tests/actions/vstudio/cs2005/projectelement.lua
-- Validate generation of <Project/> element in Visual Studio 2005+ .csproj
-- Copyright (c) 2009-2011 Jason Perkins and the Premake project
-- Copyright (c) 2009-2014 Jason Perkins and the Premake project
--
T.vstudio_cs2005_projectelement = { }
local suite = T.vstudio_cs2005_projectelement
local suite = test.declare("vstudio_cs2005_projectelement")
local cs2005 = premake.vstudio.cs2005
@ -29,7 +28,7 @@
-- Tests
--
function suite.On2005()
function suite.on2005()
_ACTION = "vs2005"
prepare()
test.capture [[
@ -37,7 +36,8 @@
]]
end
function suite.On2008()
function suite.on2008()
_ACTION = "vs2008"
prepare()
test.capture [[
@ -45,7 +45,8 @@
]]
end
function suite.On2010()
function suite.on2010()
_ACTION = "vs2010"
prepare()
test.capture [[
@ -53,3 +54,23 @@
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
]]
end
function suite.on2012()
_ACTION = "vs2012"
prepare()
test.capture [[
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
]]
end
function suite.on2013()
_ACTION = "vs2013"
prepare()
test.capture [[
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
]]
end

View File

@ -92,6 +92,25 @@
end
function suite.onVs2012()
_ACTION = "vs2012"
prepare()
test.capture [[
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>MyProject</RootNamespace>
<AssemblyName>MyProject</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
]]
end
--
-- Framework Tests
--

View File

@ -1,38 +1,38 @@
--
-- tests/actions/vs2012/test_csproj_common_props.lua
-- Check Visual Studio 2012 extensions to the project properties block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_csproj_common_props")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln = test.createsolution()
language "C#"
end
local function prepare()
prj = premake.solution.getproject(sln, 1)
cs2005.commonProperties(prj)
end
---
-- Visual Studio 2012 omits <ProductVersion> and <SchemaVersion>.
---
function suite.onDefaultCommonProps()
prepare()
test.capture [[
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
]]
end
--
-- tests/actions/vstudio/cs2005/test_common_props.lua
-- Check Visual Studio 2012 extensions to the project properties block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_csproj_common_props")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln = test.createsolution()
language "C#"
end
local function prepare()
prj = premake.solution.getproject(sln, 1)
cs2005.commonProperties(prj)
end
---
-- Visual Studio 2012 omits <ProductVersion> and <SchemaVersion>.
---
function suite.onDefaultCommonProps()
prepare()
test.capture [[
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
]]
end

View File

@ -1,45 +1,45 @@
--
-- tests/actions/vs2012/test_csproj_targets.lua
-- Check Visual Studio 2012 extensions to the targets block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_csproj_targets")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln = test.createsolution()
language "C#"
end
local function prepare()
prj = premake.solution.getproject(sln, 1)
cs2005.targets(prj)
end
---
-- Visual Studio 2012 changes the MS Build path slightly.
---
function suite.onDefaultCommonProps()
prepare()
test.capture [[
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
]]
end
--
-- tests/actions/vstudio/cs2005/test_targets.lua
-- Check Visual Studio 2012 extensions to the targets block.
-- Copyright (c) 2013 Jason Perkins and the Premake project
--
local suite = test.declare("vs2012_csproj_targets")
local cs2005 = premake.vstudio.cs2005
--
-- Setup
--
local sln, prj
function suite.setup()
_ACTION = "vs2012"
sln = test.createsolution()
language "C#"
end
local function prepare()
prj = premake.solution.getproject(sln, 1)
cs2005.targets(prj)
end
---
-- Visual Studio 2012 changes the MS Build path slightly.
---
function suite.on2012()
prepare()
test.capture [[
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
]]
end

View File

@ -1,24 +1,23 @@
--
-- tests/actions/vstudio/sln2005/test_header.lua
-- Validate generation of Visual Studio 2005+ solution header.
-- Copyright (c) 2009-2012 Jason Perkins and the Premake project
-- Copyright (c) 2009-2014 Jason Perkins and the Premake project
--
T.vstudio_sln2005_header = { }
local suite = T.vstudio_sln2005_header
local suite = test.declare("vstudio_sln2005_header")
local sln2005 = premake.vstudio.sln2005
--
-- Setup
-- Setup
--
local sln, prj
function suite.setup()
sln = test.createsolution()
end
local function prepare()
sln2005.header()
end
@ -28,7 +27,7 @@
-- Each supported action should output the corresponding version numbers.
--
function suite.On2005()
function suite.on2005()
_ACTION = "vs2005"
prepare()
test.capture [[
@ -38,7 +37,7 @@ Microsoft Visual Studio Solution File, Format Version 9.00
end
function suite.On2008()
function suite.on2008()
_ACTION = "vs2008"
prepare()
test.capture [[
@ -48,7 +47,7 @@ Microsoft Visual Studio Solution File, Format Version 10.00
end
function suite.On2010()
function suite.on2010()
_ACTION = "vs2010"
prepare()
test.capture [[
@ -56,3 +55,23 @@ Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
]]
end
function suite.on2012()
_ACTION = "vs2012"
prepare()
test.capture [[
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
]]
end
function suite.on2013()
_ACTION = "vs2013"
prepare()
test.capture [[
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
]]
end

View File

@ -16,6 +16,7 @@
local sln, prj
function suite.setup()
_ACTION = "vs2010"
sln, prj = test.createsolution()
end
@ -300,4 +301,53 @@
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
]]
end
end
---
-- Visual Studio 2012 adds a new <PlatformToolset> element.
---
function suite.addsPlatformToolset_onVS2012()
_ACTION = "vs2012"
files "hello.cpp"
prepare()
test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v110</PlatformToolset>
</PropertyGroup>
]]
end
function suite.addsPlatformToolset_onVS2013()
_ACTION = "vs2013"
files "hello.cpp"
prepare()
test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v120</PlatformToolset>
</PropertyGroup>
]]
end
function suite.excludesPlatformToolset_onNoRelevantSources()
_ACTION = "vs2012"
files "hello.x"
prepare()
test.capture [[
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
]]
end

View File

@ -157,3 +157,23 @@
</PropertyGroup>
]]
end
--
-- VS 2013 adds the <IgnoreWarnCompileDuplicatedFilename> to get rid
-- of spurious warnings when the same filename is present in different
-- configurations.
--
function suite.structureIsCorrect_on2013()
_ACTION = "vs2013"
prepare()
test.capture [[
<PropertyGroup Label="Globals">
<ProjectGuid>{42B5DBC6-AE1F-903D-F75D-41E363076E92}</ProjectGuid>
<IgnoreWarnCompileDuplicatedFilename>true</IgnoreWarnCompileDuplicatedFilename>
<Keyword>Win32Proj</Keyword>
<RootNamespace>MyProject</RootNamespace>
</PropertyGroup>
]]
end