forked from KhronosGroup/Vulkan-LoaderAndValidationLayers
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild_windows_targets.bat
81 lines (63 loc) · 2.47 KB
/
build_windows_targets.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
echo off
REM
REM This batch file builds both 32-bit and 64-bit versions of the loader.
REM It is assumed that the developer has run the update_external_sources.bat
REM file prior to running this.
REM
REM Determine the appropriate CMake strings for the current version of Visual Studio
echo Determining VS version
python .\determine_vs_version.py > vsversion.tmp
set /p VS_VERSION=< vsversion.tmp
echo Detected Visual Studio Version as %VS_VERSION%
REM Cleanup the file we used to collect the VS version output since it's no longer needed.
del /Q /F vsversion.tmp
rmdir /Q /S build
rmdir /Q /S build32
REM *******************************************
REM 64-bit LoaderAndTools build
REM *******************************************
mkdir build
pushd build
echo Generating 64-bit spirv-tools CMake files for Visual Studio %VS_VERSION%
cmake -G "Visual Studio %VS_VERSION% Win64" ..
echo Building 64-bit Debug LoaderAndTools
msbuild ALL_BUILD.vcxproj /p:Platform=x64 /p:Configuration=Debug /verbosity:quiet
REM Check for existence of one DLL, even though we should check for all results
if not exist .\loader\Debug\vulkan-1.dll (
echo.
echo LoaderAndTools 64-bit Debug build failed!
set errorCode=1
)
echo Building 64-bit Release LoaderAndTools
msbuild ALL_BUILD.vcxproj /p:Platform=x64 /p:Configuration=Release /verbosity:quiet
REM Check for existence of one DLL, even though we should check for all results
if not exist .\loader\Release\vulkan-1.dll (
echo.
echo LoaderAndTools 64-bit Release build failed!
set errorCode=1
)
popd
REM *******************************************
REM 32-bit LoaderAndTools build
REM *******************************************
mkdir build32
pushd build32
echo Generating 32-bit LoaderAndTools CMake files for Visual Studio %VS_VERSION%
cmake -G "Visual Studio %VS_VERSION%" ..
echo Building 32-bit Debug LoaderAndTools
msbuild ALL_BUILD.vcxproj /p:Platform=x86 /p:Configuration=Debug /verbosity:quiet
REM Check for existence of one DLL, even though we should check for all results
if not exist .\loader\Debug\vulkan-1.dll (
echo.
echo LoaderAndTools 32-bit Debug build failed!
set errorCode=1
)
echo Building 32-bit Release LoaderAndTools
msbuild ALL_BUILD.vcxproj /p:Platform=x86 /p:Configuration=Release /verbosity:quiet
REM Check for existence of one DLL, even though we should check for all results
if not exist .\loader\Release\vulkan-1.dll (
echo.
echo LoaderAndTools 32-bit Release build failed!
set errorCode=1
)
popd