aboutsummaryrefslogtreecommitdiff
path: root/tools/buildsteps
diff options
context:
space:
mode:
authorthexai <58434170+thexai@users.noreply.github.com>2020-07-27 21:07:38 +0200
committerthexai <58434170+thexai@users.noreply.github.com>2020-07-28 17:50:45 +0200
commitd3fc1bd106dab73477ff76edfd932686b0dc0fcd (patch)
treecbbbed454d7394590a316bc97f70da1973aa720c /tools/buildsteps
parentdb40b2ade4b6e13d6fead7004e819325e2ea0f0b (diff)
Updated build scripts for Visual Studio 2019 compatibility
Diffstat (limited to 'tools/buildsteps')
-rw-r--r--tools/buildsteps/windows/BuildSetup.bat2
-rw-r--r--tools/buildsteps/windows/arm-uwp/BuildSetup.bat3
-rw-r--r--tools/buildsteps/windows/vswhere.bat6
-rw-r--r--tools/buildsteps/windows/win32-uwp/BuildSetup.bat1
-rw-r--r--tools/buildsteps/windows/win32/BuildSetup.bat1
-rw-r--r--tools/buildsteps/windows/x64-uwp/BuildSetup.bat3
-rw-r--r--tools/buildsteps/windows/x64/BuildSetup.bat3
7 files changed, 13 insertions, 6 deletions
diff --git a/tools/buildsteps/windows/BuildSetup.bat b/tools/buildsteps/windows/BuildSetup.bat
index 0c4487c9e3..3b71d5935a 100644
--- a/tools/buildsteps/windows/BuildSetup.bat
+++ b/tools/buildsteps/windows/BuildSetup.bat
@@ -84,7 +84,7 @@ set WORKSPACE=%base_dir%\kodi-build.%TARGET_PLATFORM%
MKDIR %WORKSPACE%
PUSHD %WORKSPACE%
- cmake.exe -G "%cmakeGenerator%" %cmakeProps% %base_dir%
+ cmake.exe -G "%cmakeGenerator%" -A %cmakeArch% -T host=x64 %cmakeProps% %base_dir%
IF %errorlevel%==1 (
set DIETEXT="%APP_NAME%.EXE failed to build!"
goto DIE
diff --git a/tools/buildsteps/windows/arm-uwp/BuildSetup.bat b/tools/buildsteps/windows/arm-uwp/BuildSetup.bat
index 18b3ecf86c..8fd6e03de1 100644
--- a/tools/buildsteps/windows/arm-uwp/BuildSetup.bat
+++ b/tools/buildsteps/windows/arm-uwp/BuildSetup.bat
@@ -9,7 +9,8 @@ IF ERRORLEVEL 1 (
EXIT /B 1
)
-SET cmakeGenerator=Visual Studio %vsver% ARM
+SET cmakeGenerator=Visual Studio %vsver%
+SET cmakeArch=ARM
SET TARGET_ARCHITECTURE=arm
SET TARGET_PLATFORM=%TARGET_ARCHITECTURE%-uwp
SET cmakeProps=-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=%UCRTVersion%
diff --git a/tools/buildsteps/windows/vswhere.bat b/tools/buildsteps/windows/vswhere.bat
index 999afb4466..c33a30a4a7 100644
--- a/tools/buildsteps/windows/vswhere.bat
+++ b/tools/buildsteps/windows/vswhere.bat
@@ -47,7 +47,9 @@ SET vswhere="%builddeps%\%toolsdir%\tools\vswhere\vswhere.exe"
FOR /f "usebackq tokens=1* delims=" %%i in (`%vswhere% -latest -property installationPath`) do (
IF EXIST "%%i\VC\Auxiliary\Build\vcvarsall.bat" (
SET vcvars="%%i\VC\Auxiliary\Build\vcvarsall.bat"
- SET vsver=15
+ SET vsver=15 2017
+ ECHO %%i | findstr "2019" >NUL 2>NUL
+ IF NOT ERRORLEVEL 1 SET vsver=16 2019
)
)
@@ -57,7 +59,7 @@ IF %vcvars%==no (
IF NOT ERRORLEVEL 1 (
IF EXIST "%%i\VC\vcvarsall.bat" (
SET vcvars="%%i\VC\vcvarsall.bat"
- SET vsver=14
+ SET vsver=14 2015
)
)
)
diff --git a/tools/buildsteps/windows/win32-uwp/BuildSetup.bat b/tools/buildsteps/windows/win32-uwp/BuildSetup.bat
index 3aba2378f1..5ddf234b57 100644
--- a/tools/buildsteps/windows/win32-uwp/BuildSetup.bat
+++ b/tools/buildsteps/windows/win32-uwp/BuildSetup.bat
@@ -9,6 +9,7 @@ IF ERRORLEVEL 1 (
)
SET cmakeGenerator=Visual Studio %vsver%
+SET cmakeArch=Win32
SET TARGET_ARCHITECTURE=x86
SET TARGET_PLATFORM=win32-uwp
SET cmakeProps=-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=%UCRTVersion%
diff --git a/tools/buildsteps/windows/win32/BuildSetup.bat b/tools/buildsteps/windows/win32/BuildSetup.bat
index 70764985ba..0c10f4336c 100644
--- a/tools/buildsteps/windows/win32/BuildSetup.bat
+++ b/tools/buildsteps/windows/win32/BuildSetup.bat
@@ -10,6 +10,7 @@ IF ERRORLEVEL 1 (
)
SET cmakeGenerator=Visual Studio %vsver%
+SET cmakeArch=Win32
SET TARGET_ARCHITECTURE=x86
SET TARGET_PLATFORM=%TARGET_ARCHITECTURE%
diff --git a/tools/buildsteps/windows/x64-uwp/BuildSetup.bat b/tools/buildsteps/windows/x64-uwp/BuildSetup.bat
index 037c536b80..8144248dd0 100644
--- a/tools/buildsteps/windows/x64-uwp/BuildSetup.bat
+++ b/tools/buildsteps/windows/x64-uwp/BuildSetup.bat
@@ -8,7 +8,8 @@ IF ERRORLEVEL 1 (
EXIT /B 1
)
-SET cmakeGenerator=Visual Studio %vsver% Win64
+SET cmakeGenerator=Visual Studio %vsver%
+SET cmakeArch=x64
SET TARGET_ARCHITECTURE=x64
SET TARGET_PLATFORM=%TARGET_ARCHITECTURE%-uwp
SET cmakeProps=-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=%UCRTVersion%
diff --git a/tools/buildsteps/windows/x64/BuildSetup.bat b/tools/buildsteps/windows/x64/BuildSetup.bat
index 6434d3f0c0..09acf3faa1 100644
--- a/tools/buildsteps/windows/x64/BuildSetup.bat
+++ b/tools/buildsteps/windows/x64/BuildSetup.bat
@@ -8,7 +8,8 @@ IF ERRORLEVEL 1 (
EXIT /B 1
)
-SET cmakeGenerator=Visual Studio %vsver% Win64
+SET cmakeGenerator=Visual Studio %vsver%
+SET cmakeArch=x64
SET TARGET_ARCHITECTURE=x64
SET TARGET_PLATFORM=%TARGET_ARCHITECTURE%