diff --git a/build/llvm/LLVM.lua b/build/llvm/LLVM.lua index 9d7437c05..978fa0022 100644 --- a/build/llvm/LLVM.lua +++ b/build/llvm/LLVM.lua @@ -53,13 +53,15 @@ end function get_vs_version() local function map_msvc_to_vs_version(major, minor) - if major == "19" and minor >= "20" then return "vs2019" + if major == "22" then return "vs2022" + elseif major == "19" and minor >= "20" then return "vs2019" elseif major == "19" and minor >= "10" then return "vs2017" end end local function map_msbuild_to_vs_version(major, minor) - if major == "16" then return "vs2019" + if major == "17" then return "vs2022" + elseif major == "16" then return "vs2019" elseif major == "15" then return "vs2017" end end @@ -397,7 +399,9 @@ end function get_cmake_generator() local vsver = get_vs_version() - if vsver == "vs2019" then + if vsver == "vs2022" then + return "Visual Studio 17 2022", (target_architecture() == "x86") and "-A Win32" or nil + elseif vsver == "vs2019" then return "Visual Studio 16 2019", (target_architecture() == "x86") and "-A Win32" or nil elseif vsver == "vs2017" then return "Visual Studio 15 2017" .. (target_architecture() == "x64" and " Win64" or ""), nil