vs2022.lua 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. --
  2. -- vs2022.lua
  3. -- Extend the existing exporters with support for Visual Studio 2022.
  4. -- Copyright (c) Jason Perkins and the Premake project
  5. --
  6. local p = premake
  7. local vstudio = p.vstudio
  8. ---
  9. -- Define the Visual Studio 2019 export action.
  10. ---
  11. newaction {
  12. -- Metadata for the command line and help system
  13. trigger = "vs2022",
  14. shortname = "Visual Studio 2022",
  15. description = "Generate Visual Studio 2022 project files",
  16. -- Visual Studio always uses Windows path and naming conventions
  17. targetos = "windows",
  18. toolset = "msc-v143",
  19. -- The capabilities of this action
  20. valid_kinds = { "ConsoleApp", "WindowedApp", "StaticLib", "SharedLib", "Makefile", "None", "Utility", "SharedItems" },
  21. valid_languages = { "C", "C++", "C#", "F#" },
  22. valid_tools = {
  23. cc = { "msc", "clang" },
  24. dotnet = { "msnet" },
  25. },
  26. -- Workspace and project generation logic
  27. onWorkspace = function(wks)
  28. p.vstudio.vs2005.generateSolution(wks)
  29. end,
  30. onProject = function(prj)
  31. p.vstudio.vs2010.generateProject(prj)
  32. end,
  33. onRule = function(rule)
  34. p.vstudio.vs2010.generateRule(rule)
  35. end,
  36. onCleanWorkspace = function(wks)
  37. p.vstudio.cleanSolution(wks)
  38. end,
  39. onCleanProject = function(prj)
  40. p.vstudio.cleanProject(prj)
  41. end,
  42. onCleanTarget = function(prj)
  43. p.vstudio.cleanTarget(prj)
  44. end,
  45. pathVars = vstudio.vs2010.pathVars,
  46. -- This stuff is specific to the Visual Studio exporters
  47. vstudio = {
  48. solutionVersion = "12",
  49. versionName = "Version 17", --OpenMPT
  50. targetFramework = "4.7.2",
  51. toolsVersion = "15.0",
  52. userToolsVersion = "Current",
  53. filterToolsVersion = "4.0",
  54. }
  55. }