-
Notifications
You must be signed in to change notification settings - Fork 13
83 lines (71 loc) · 2.3 KB
/
Copy pathbuild.yml
File metadata and controls
83 lines (71 loc) · 2.3 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
name: Build and Test
# run the workflow on push to master branch or pull request to master branch
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
strategy:
matrix:
os: [ windows-latest, ubuntu-latest, macos-latest ]
target_arch: [ x86_64, arm64 ]
exclude:
- os: windows-latest
target_arch: arm64
- os: ubuntu-latest
target_arch: arm64
include:
- os: macos-latest
target_arch: x86_64
runs-on: macos-15-intel
- os: macos-latest
target_arch: arm64
runs-on: macos-latest
runs-on: ${{ matrix.runs-on || matrix.os }}
steps:
- name: Check runner OS
run: echo "Runner OS is ${{ runner.os }}"
- name: Checkout code
uses: actions/checkout@v4
- name: Install NSIS on Windows
if: runner.os == 'Windows'
shell: powershell
run: |
choco install nsis -y --no-progress
- name: install GL and x11 for Linux
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install libgl1-mesa-dev libx11-dev libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev wayland-protocols libwayland-dev libwayland-bin
- name: Run install script on Windows
if: runner.os == 'Windows'
shell: cmd
run: |
install.cmake.bat
- name: Run install script on Linux
if: runner.os == 'Linux'
run: |
chmod +x ./install.cmake.sh
./install.cmake.sh
- name: Run install script on MacOS x86_64
if: runner.os == 'MacOS' && matrix.target_arch == 'x86_64'
run: |
chmod +x ./install.cmake.sh
./install.cmake.sh --force-x86
- name: Run install script on MacOS arm64
if: runner.os == 'MacOS' && matrix.target_arch == 'arm64'
run: |
chmod +x ./install.cmake.sh
./install.cmake.sh
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: "${{ matrix.os }}-${{ matrix.target_arch }}-packages"
path: |
build_cmake/*.deb
build_cmake/*.dmg
build_cmake/*.exe
build_cmake/*.zip
build_cmake/*.msi