-
Notifications
You must be signed in to change notification settings - Fork 279
86 lines (75 loc) · 1.86 KB
/
msys2-cmake.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
79
80
81
82
83
84
85
86
name: Windows build (CMake + MSYS2)
on:
push:
branches:
- upload
paths-ignore:
- 'android/**'
- 'build-data/osx/**'
- 'doc/**'
- 'doxygen_doc/**'
- 'gfx/**'
- 'lang/**'
- 'tools/**'
- '!tools/format/**'
- 'utilities/**'
- 'scripts/**'
# We only care about the latest revision, so cancel previous instances.
concurrency:
group: msys2-cmake-build-${{ github.ref_name }}
cancel-in-progress: true
jobs:
build_catatclysm:
name: Build
runs-on: windows-2019
if: github.event.pull_request.draft == false
defaults:
run:
shell: msys2 {0}
steps:
- name: checkout repository
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Setup MSYS2
# Will by default install MINGW64
uses: msys2/setup-msys2@v2
with:
update: true
install: |
git
make
gettext
mingw-w64-x86_64-libmad
mingw-w64-x86_64-libwebp
mingw-w64-x86_64-pkg-config
mingw-w64-x86_64-SDL2
mingw-w64-x86_64-SDL2_image
mingw-w64-x86_64-SDL2_mixer
mingw-w64-x86_64-SDL2_ttf
mingw-w64-x86_64-toolchain
mingw-w64-x86_64-cmake
- name: Create build directory
run: mkdir build
- name: Configure
run: |
cd build
cmake.exe \
-DTILES=ON \
-DSOUND=ON \
-DLUA=ON \
-DTESTS=ON \
-DDYNAMIC_LINKING=ON \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DCMAKE_CXX_FLAGS="-w" \
-G "Ninja" \
..
- name: Build
run: |
cmake.exe --build build -j$((`nproc`+0))
- name: Compile translations
run: |
cmake.exe --build build --target translations_compile
- name: Run tests
run: |
./build/tests/cata_test-tiles.exe --rng-seed time