-
Notifications
You must be signed in to change notification settings - Fork 89
86 lines (82 loc) · 2.4 KB
/
main.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: CI
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build_linux:
name: Build on linux systems
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-20.04]
env:
build_dir: "build"
config: "Release"
CC: gcc-10
CXX: g++-10
APPIMAGE_EXTRACT_AND_RUN: 1# https://github.com/AppImage/AppImageKit/wiki/FUSE#docker
steps:
- name: Install dependencies
run: sudo apt-get update && sudo apt-get install -y cmake gcc-10 g++-10 libglu1-mesa-dev xorg-dev zenity zlib1g-dev
- uses: actions/checkout@v1
with:
submodules: recursive
- name: CMake
run: cmake . -B ${{ env.build_dir }} -DCMAKE_BUILD_TYPE=${{ env.config }} -DTEV_DEPLOY=1
- name: Build
working-directory: ${{ env.build_dir }}
run: cmake --build . --target all --verbose -j
- name: Package
working-directory: ${{ env.build_dir }}
run: cmake --build . --target package --verbose
- name: Upload AppImage
uses: actions/upload-artifact@v3
with:
name: Linux executable
path: ${{ env.build_dir }}/tev.appimage
build_macos:
name: Build on macOS
runs-on: macos-13
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: Build
run: scripts/create-dmg.sh
- name: Upload .dmg
uses: actions/upload-artifact@v3
with:
name: macOS installer
path: tev.dmg
build_windows:
name: Build on Windows
runs-on: windows-2022
env:
build_dir: "build"
config: "Release"
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: CMake
run: cmake . -B ${{ env.build_dir }} -DTEV_DEPLOY=1
- name: Build
working-directory: ${{ env.build_dir }}
run: cmake --build . --config ${{ env.config }} --target ALL_BUILD --verbose
- name: Create installer
working-directory: ${{ env.build_dir }}
run: cpack
- name: Upload executable
uses: actions/upload-artifact@v3
with:
name: Windows executable
path: ${{ env.build_dir }}/${{ env.config }}/tev.exe
- name: Upload installer
uses: actions/upload-artifact@v3
with:
name: Windows installer
path: ${{ env.build_dir }}/tev-installer.msi