diff --git a/src/actions/vstudio/vs2005_solution.lua b/src/actions/vstudio/vs2005_solution.lua index 5f5f8957..4b6da58a 100644 --- a/src/actions/vstudio/vs2005_solution.lua +++ b/src/actions/vstudio/vs2005_solution.lua @@ -67,9 +67,6 @@ -- function sln2005.projectdependencies_ng(prj) - -- VS2010 C# gets dependencies right from the projects; doesn't need rules here - if _ACTION > "vs2008" and prj.language == "C#" then return end - local deps = project.getdependencies(prj) if #deps > 0 then _p(1,'ProjectSection(ProjectDependencies) = postProject') @@ -183,9 +180,6 @@ -- function sln2005.projectdependencies(prj) - -- VS2010 C# gets dependencies right from the projects; doesn't need rules here - if _ACTION > "vs2008" and prj.language == "C#" then return end - local deps = premake.getdependencies(prj) if #deps > 0 then _p('\tProjectSection(ProjectDependencies) = postProject') diff --git a/src/actions/vstudio/vs2010_vcxproj.lua b/src/actions/vstudio/vs2010_vcxproj.lua index 2a0164a9..5ff6979b 100644 --- a/src/actions/vstudio/vs2010_vcxproj.lua +++ b/src/actions/vstudio/vs2010_vcxproj.lua @@ -169,6 +169,10 @@ local outdir = path.translate(target.directory) _x(2,'%s\\', outdir) + if cfg.system == premake.XBOX360 then + _x(2,'$(OutDir)%s', target.name) + end + local objdir = path.translate(config.getuniqueobjdir(cfg)) _x(2,'%s\\', objdir) diff --git a/src/project/config.lua b/src/project/config.lua index 8752eed8..a9ef3002 100755 --- a/src/project/config.lua +++ b/src/project/config.lua @@ -47,7 +47,7 @@ extension = ".lib" end - elseif cfg.system == premake.WINDOWS then + elseif cfg.system == premake.WINDOWS or cfg.system == premake.XBOX360 then if kind == premake.CONSOLEAPP or kind == premake.WINDOWEDAPP then extension = ".exe" elseif kind == premake.SHAREDLIB then diff --git a/tests/actions/vstudio/sln2005/test_dependencies.lua b/tests/actions/vstudio/sln2005/test_dependencies.lua index be614170..aebf15a5 100755 --- a/tests/actions/vstudio/sln2005/test_dependencies.lua +++ b/tests/actions/vstudio/sln2005/test_dependencies.lua @@ -59,12 +59,17 @@ -- --- Visual Studio 2010 C# projects lists dependencies in the project, rather --- than the solution. Make sure nothing gets written in that case. +-- Most C# references should go into the project rather than the solution, +-- but until I know the conditions, put everything here to be safe. -- function suite.nothingOutput_onVs2010() _ACTION = "vs2010" prepare("C#") - test.isemptycapture() + test.capture [[ + ProjectSection(ProjectDependencies) = postProject + {AE61726D-187C-E440-BD07-2556188A6565} = {AE61726D-187C-E440-BD07-2556188A6565} + EndProjectSection + ]] end + diff --git a/tests/actions/vstudio/vc2010/test_output_props.lua b/tests/actions/vstudio/vc2010/test_output_props.lua index 36bb9a35..ac676556 100755 --- a/tests/actions/vstudio/vc2010/test_output_props.lua +++ b/tests/actions/vstudio/vc2010/test_output_props.lua @@ -45,6 +45,26 @@ end +-- +-- Xbox360 adds an extra element to the block. +-- + + function suite.structureIsCorrect_onXbox360() + system "Xbox360" + prepare() + test.capture [[ + + true + .\ + $(OutDir)MyProject.exe + obj\Debug\ + MyProject + .exe + + ]] + end + + -- -- Static libraries should omit the link incremental element entirely. -- diff --git a/tests/config/test_targetinfo.lua b/tests/config/test_targetinfo.lua index f2ebb2e1..c5d585d1 100755 --- a/tests/config/test_targetinfo.lua +++ b/tests/config/test_targetinfo.lua @@ -219,6 +219,18 @@ end +-- +-- Name should use ".exe" for Xbox360 executables. +-- + + function suite.nameUsesExe_onWindowsConsoleApp() + kind "ConsoleApp" + system "Xbox360" + i = prepare() + test.isequal("MyProject.exe", i.name) + end + + -- -- Name should use a prefix if set. --