-
Notifications
You must be signed in to change notification settings - Fork 32
78 lines (67 loc) · 2.33 KB
/
build-windows.yml
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
name: Windows
on: push
env:
BUILD_TYPE: RelWithDebInfo
TARGET_FOLDER: Build/Release
DLSS_SDK_PATH: ${{ github.workspace }}\DLSS
jobs:
build-msvc:
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
dlss: [ON, OFF]
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Vulkan SDK
uses: humbletim/[email protected]
with:
version: 1.3.204.1
cache: true
- name: DLSS
uses: actions/checkout@v3
if: matrix.dlss == 'ON'
with:
repository: NVIDIA/DLSS
path: ${{ env.DLSS_SDK_PATH }}
- name: Shaders
run: |
cd Source/Shaders
python GenerateShaders.py
- name: CMake
run: cmake -B ${{github.workspace}}/BuildCMake/${{env.BUILD_FOLDER}} -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DRG_WITH_SURFACE_WIN32=ON -DRG_WITH_NVIDIA_DLSS=${{ matrix.dlss }}
- name: Build
run: cmake --build ${{github.workspace}}/BuildCMake/${{env.BUILD_FOLDER}} --config ${{env.BUILD_TYPE}}
- name: Prepare folder
run: |
mkdir final/bin
copy BuildCMake/RelWithDebInfo/RayTracedGL1.lib final/bin/RayTracedGL1.lib
copy BuildCMake/RelWithDebInfo/RayTracedGL1.pdb final/bin/RayTracedGL1.pdb
copy BuildCMake/RelWithDebInfo/RayTracedGL1.dll final/bin/RayTracedGL1.dll
mkdir final/include
mkdir final/include/RTGL1
copy Include/RTGL1/RTGL1.h final/include/RTGL1/RTGL1.h
mkdir final/ovrd
copy Tools/BlueNoise_LDR_RGBA_128.ktx2 final/ovrd/BlueNoise_LDR_RGBA_128.ktx2
copy Tools/CreateKTX2.py final/ovrd/CreateKTX2.py
mkdir final/ovrd/shaders
copy Build/shaders/*.spv final/ovrd/shaders
copy LICENSE final/LICENSE
echo "${{ github.sha }}" | Out-File -encoding ASCII final/VERSION
- name: Upload
uses: actions/upload-artifact@v3
if: matrix.dlss != 'ON'
with:
name: RayTracedGL1-Bundle
path: final/*
- name: Upload (DLSS)
uses: actions/upload-artifact@v3
if: matrix.dlss == 'ON'
with:
name: RayTracedGL1-Bundle-DLSS
path: final/*