-
Notifications
You must be signed in to change notification settings - Fork 226
65 lines (52 loc) · 1.65 KB
/
linux.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
name: Build linux
on:
pull_request:
push:
branches:
- master
jobs:
build:
strategy:
matrix:
os: [ubuntu-22.04]
arch: [x64]
mode: [debug]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- uses: actions/checkout@v2
- name: Checkout submodules
run: |
git submodule sync --recursive
git submodule update --init --force --recursive --depth=1
# Install dependencies
- name: Update apt repositories
run: sudo apt-get update
- name: Install GCC12
shell: bash
run: |
sudo apt update
sudo apt install gcc-12 g++-12
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 110 --slave /usr/bin/g++ g++ /usr/bin/g++-12 --slave /usr/bin/gcov gcov /usr/bin/gcov-12
# Install xmake
- name: Setup xmake
uses: xmake-io/github-action-setup-xmake@v1
with:
xmake-version: '2.8.5'
# Update xmake repository (in order to have the file that will be cached)
- name: Update xmake repository
run: xmake repo --update
# Setup compilation mode and install project dependencies
- name: Configure xmake and install dependencies
run: xmake config --arch=${{ matrix.arch }} --mode=${{ matrix.mode }} --yes
# Build the game
- name: Build
run: xmake
# Create install
#- name: Install
# run: xmake install -o packaged
# Upload artifacts
#- uses: actions/upload-artifact@v2
# with:
# name: ${{ matrix.os }}-${{ matrix.arch }}-${{ matrix.mode }}
# path: packaged/bin/**