-
Notifications
You must be signed in to change notification settings - Fork 97
142 lines (118 loc) · 4.97 KB
/
Copy pathbuild-windows.yml
File metadata and controls
142 lines (118 loc) · 4.97 KB
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
name: Win32/UWP build
on: [push, pull_request]
jobs:
precheks:
name: Win10 -> Pre-checks
runs-on: windows-2025
steps:
- name: Clone DiligentCore
uses: actions/checkout@v6
with:
repository: DiligentGraphics/DiligentCore
path: DiligentCore
- name: Clone DiligentTools
uses: actions/checkout@v6
with:
path: DiligentTools
- name: Format validation
shell: cmd
working-directory: ${{github.workspace}}/DiligentTools/BuildTools/FormatValidation
run: validate_format_win.bat
build:
needs: precheks
runs-on: windows-2025
strategy:
fail-fast: false
matrix:
name: ["Win10"]
toolset: ["Win32", "x64"]
build_type: ["Debug", "Release"]
cmake_generator: ["Visual Studio 18 2026"]
cmake_args: ["-DDILIGENT_BUILD_TOOLS_TESTS=ON -DDILIGENT_BUILD_TOOLS_INCLUDE_TEST=ON -DZLIB_BUILD_MINIZIP=ON -DDILIGENT_NO_WEBGPU=OFF"]
platform: ["Win32"]
include:
- name: "Win10-Dev"
platform: "Win32"
toolset: "x64"
build_type: "RelWithDebInfo"
cmake_generator: "Visual Studio 18 2026"
cmake_args: "-DDILIGENT_BUILD_TOOLS_TESTS=ON -DDILIGENT_DEVELOPMENT=ON"
- name: "Win10-Ninja"
platform: "Win32"
toolset: "x64"
build_type: "Debug"
cmake_generator: "Ninja"
cmake_args: "-DDILIGENT_BUILD_TOOLS_TESTS=ON"
- name: "MinGW"
platform: "Win32"
toolset: "x64"
build_type: "Release" # Debug build is unbelievably slow
cmake_generator: "MinGW Makefiles"
cmake_args: "-DDILIGENT_BUILD_TOOLS_TESTS=ON"
- name: "UWP"
platform: "UWP"
toolset: "x64"
build_type: "Debug"
cmake_generator: "Visual Studio 18 2026"
cmake_args: "-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0"
- name: "UWP"
platform: "UWP"
toolset: "x64"
build_type: "Release"
cmake_generator: "Visual Studio 18 2026"
cmake_args: "-DCMAKE_SYSTEM_NAME=WindowsStore -DCMAKE_SYSTEM_VERSION=10.0"
name: Win10 -> ${{ matrix.name }}-${{ matrix.toolset }}, ${{ matrix.build_type }}
steps:
- name: Checkout
uses: DiligentGraphics/github-action/checkout@v27
- name: Set up build environment
if: success()
uses: DiligentGraphics/github-action/setup-build-env@v27
with:
platform: ${{ matrix.platform }}
cmake-generator: ${{ matrix.cmake_generator }}
ninja-vs-arch: ${{ matrix.toolset }}
- name: Configure CMake
if: success()
uses: DiligentGraphics/github-action/configure-cmake@v27
with:
generator: ${{ matrix.cmake_generator }}
vs-arch: ${{ matrix.toolset }}
build-type: ${{ matrix.build_type }}
cmake-args: ${{ matrix.cmake_args }}
- name: Build
id: build
if: success()
uses: DiligentGraphics/github-action/build@v27
with:
target: install
- name: DiligentToolsTest
if: ${{ success() && matrix.name != 'UWP'}}
uses: DiligentGraphics/github-action/run-tools-tests@v27
- name: DiligentToolsGPUTest D3D11
# NB: it is essential to include failure() to override the default status check of success()
# that is automatically applied to if conditions that don't contain a status check function.
if: ${{ (success() || failure() && steps.build.outcome == 'success') && (matrix.name == 'Win10' || matrix.name == 'Win8.1') }}
uses: DiligentGraphics/github-action/run-tools-gpu-tests@v27
with:
mode: d3d11_sw
- name: DiligentToolsGPUTest D3D12
if: ${{ (success() || failure() && steps.build.outcome == 'success') && matrix.name == 'Win10' }}
uses: DiligentGraphics/github-action/run-tools-gpu-tests@v27
with:
mode: d3d12_sw
- name: DiligentToolsGPUTest WebGPU
if: ${{ (success() || failure() && steps.build.outcome == 'success') && matrix.name == 'Win10' }}
uses: DiligentGraphics/github-action/run-tools-gpu-tests@v27
with:
mode: wgpu
- name: HLSL2GLSLConverterTest
if: ${{ (success() || failure() && steps.build.outcome == 'success') && matrix.name != 'UWP'}}
uses: DiligentGraphics/github-action/run-hlsl2glsl-converter-test@v27
- name: Upload artifact
uses: actions/upload-artifact@v7
if: ${{ success() && matrix.build_type != 'Debug' && matrix.name == 'Win10' }}
with:
name: DiligentTools-${{ matrix.name }}-${{ matrix.toolset }}-${{ matrix.build_type }}
path: ${{env.DILIGENT_INSTALL_DIR}}/bin/DiligentTools
retention-days: 90