-
Notifications
You must be signed in to change notification settings - Fork 13
54 lines (45 loc) · 1.43 KB
/
build.yml
File metadata and controls
54 lines (45 loc) · 1.43 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
name: build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
paths-ignore:
- 'README.md'
jobs:
xmake:
strategy:
matrix:
os: [windows-2022]
build_type: [release, releasedbg]
runs-on: ${{ matrix.os }}
steps:
- name: Setup libstdc++-14
if: matrix.os == 'ubuntu-24.04'
run: |
sudo apt update
sudo apt install -y gcc-14 g++-14 libstdc++-14-dev
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-14 100
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-14 100
sudo update-alternatives --set gcc /usr/bin/gcc-14
sudo update-alternatives --set g++ /usr/bin/g++-14
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup xmake
uses: xmake-io/github-action-setup-xmake@v1
with:
actions-cache-folder: '.xmake-cache'
actions-cache-key: ${{ matrix.os }}
package-cache: true
package-cache-key: ${{ matrix.os }}-${{ matrix.build_type }}
# build-cache: true
# build-cache-key: ${{ matrix.os }}-${{ matrix.build_type }}
- name: Xmake configure
run: |
xmake f -c -vD --mode=${{ matrix.build_type }} -y
- name: Build
run: |
xmake build --verbose --diagnosis --all -y
- name: Run tests
run: |
xmake run -v blook-test