diff --git a/CHANGES.txt b/CHANGES.txt index 30fe4c30..78c95ea5 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -6,12 +6,13 @@ - Added Xbox 360 support to Visual Studio 2005/2008 - Added Mac OS X universal binary support - Added Playstation 3 support -- Bug 2564404: FatalWarnings has no effect with gmake target -- Bug 2550759: pchheader option has wrong type - Support links and libdirs for Visual Studio static libraries - Fail gracefully when list is assigned to string field - Changed GCC flags to -fno-exceptions and -fno-rtti - Improved performance of configuration building step +- Patch 2031626 Support for additional manifest files (Colin Graf) +- Bug 2564404: FatalWarnings has no effect with gmake target +- Bug 2550759: pchheader option has wrong type ----- diff --git a/src/actions/vstudio/vs200x_vcproj.lua b/src/actions/vstudio/vs200x_vcproj.lua index 73dba9e9..c69a5e29 100644 --- a/src/actions/vstudio/vs200x_vcproj.lua +++ b/src/actions/vstudio/vs200x_vcproj.lua @@ -281,6 +281,28 @@ end + +-- +-- Manifest block. +-- + + function premake.vs200x_vcproj_VCManifestTool(cfg) + -- locate all manifest files + local manifests = { } + for _, fname in ipairs(cfg.files) do + if path.getextension(fname) == ".manifest" then + table.insert(manifests, fname) + end + end + + _p('\t\t\t 0 then + _p('\t\t\t\tAdditionalManifestFiles="%s"', premake.esc(table.concat(manifests, ";"))) + end + _p('\t\t\t/>') + end + -- -- Write out a custom build steps block. @@ -308,6 +330,7 @@ VCCLCompilerTool_GCC = premake.vs200x_vcproj_VCCLCompilerTool_GCC, VCLinkerTool = premake.vs200x_vcproj_VCLinkerTool, VCLinkerTool_GCC = premake.vs200x_vcproj_VCLinkerTool_GCC, + VCManifestTool = premake.vs200x_vcproj_VCManifestTool, VCResourceCompilerTool = premake.vs200x_vcproj_VCResourceCompilerTool, } diff --git a/tests/test_vs200x_vcproj.lua b/tests/test_vs200x_vcproj.lua index ce48aae9..116ac83a 100644 --- a/tests/test_vs200x_vcproj.lua +++ b/tests/test_vs200x_vcproj.lua @@ -6,6 +6,7 @@ T.vs200x_vcproj = { } + -- -- Configure a solution for testing -- @@ -409,5 +410,31 @@ ]] end - +-- +-- Test manifest file handling. +-- + + function T.vs200x_vcproj.VCManifestTool_OnNoManifests() + files { "hello.c", "goodbye.c" } + prepare() + premake.vs200x_vcproj_VCManifestTool(premake.getconfig(prj, "Debug")) + test.capture [[ + + ]] + end + + + function T.vs200x_vcproj.VCManifestTool_OnNoManifests() + files { "hello.c", "project1.manifest", "goodbye.c", "project2.manifest" } + prepare() + premake.vs200x_vcproj_VCManifestTool(premake.getconfig(prj, "Debug")) + test.capture [[ + + ]] + end