Browse Source

Merge pull request #789 from realvictorprm/master

Added support for VS 2017 project generation
pull/790/head
João Matos 9 years ago committed by GitHub
parent
commit
9538be6d3e
  1. 11
      build/GenerateProjects.bat
  2. 7
      build/Helpers.lua
  3. 2
      build/scripts/LLVM.lua

11
build/GenerateProjects.bat

@ -8,12 +8,15 @@ echo [0] Clean
echo [1] Visual C++ 2012 echo [1] Visual C++ 2012
echo [2] Visual C++ 2013 echo [2] Visual C++ 2013
echo [3] Visual C++ 2015 echo [3] Visual C++ 2015
echo [4] GNU Make echo [4] Visual C++ 2017
echo [5] GNU Make
echo. echo.
:choice :choice
set /P C="Choice: " set /P C="Choice: "
if "%C%"=="4" goto gmake if "%C%"=="5" goto gmake
if "%C%"=="4" goto vs2017
if "%C%"=="3" goto vs2015 if "%C%"=="3" goto vs2015
if "%C%"=="2" goto vs2013 if "%C%"=="2" goto vs2013
if "%C%"=="1" goto vs2012 if "%C%"=="1" goto vs2012
@ -35,6 +38,10 @@ goto quit
"premake5" --file=premake5.lua vs2015 "premake5" --file=premake5.lua vs2015
goto quit goto quit
:vs2017
"premake5" --file=premake5.lua vs2017
goto quit
:gmake :gmake
"premake5" --file=premake5.lua gmake "premake5" --file=premake5.lua gmake
goto quit goto quit

7
build/Helpers.lua

@ -75,7 +75,12 @@ function SetupManagedProject()
configuration(c) configuration(c)
end end
if action == "vs2015" then if action == "vs2017" then
configuration "vs2017"
framework "4.6"
elseif action == "vs2015" then
configuration "vs2015" configuration "vs2015"
framework "4.6" framework "4.6"

2
build/scripts/LLVM.lua

@ -62,7 +62,7 @@ function get_toolset_configuration_name()
if not string.starts(vsver, "vs") then if not string.starts(vsver, "vs") then
local out = outputof("cl") local out = outputof("cl")
local ver, arch = string.match(out, '(%d+).%d+.%d+.?%d*%s+%w*%s+(%w+)') local ver, arch = string.match(out, '(%d+).%d+.%d+.?%d*%s+')
vsver = get_vs_version(ver) vsver = get_vs_version(ver)
end end

Loading…
Cancel
Save