-
Notifications
You must be signed in to change notification settings - Fork 3
81 lines (68 loc) · 2.33 KB
/
Copy pathcppcmake.yml
File metadata and controls
81 lines (68 loc) · 2.33 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
name: C/C++ CI
on:
workflow_dispatch:
push:
tags:
- v*.*
pull_request:
branches:
- master
env:
LSL_RELEASE_URL: 'https://github.com/sccn/liblsl/releases/download'
LSL_RELEASE_PREFIX: 'v'
LSL_RELEASE: '1.16.1'
LSL_RELEASE_SUFFIX: ''
defaults:
run:
shell: bash
jobs:
build:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
matrix:
config:
- { name: "windows-x64", os: "windows-latest", qt_arch: "win64_msvc2019_64", arch: "amd64" }
- { name: "macOS-latest", os: "macOS-latest" }
- { name: "ubuntu-20.04", os: "ubuntu-20.04"}
- { name: "ubuntu-22.04", os: "ubuntu-22.04"}
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Install liblsl (Ubuntu)
if: startsWith(matrix.config.os, 'ubuntu')
run: |
sudo apt install -y libpugixml-dev
curl -L ${LSL_RELEASE_URL}/${LSL_RELEASE_PREFIX}${LSL_RELEASE}/liblsl-${LSL_RELEASE}-$(lsb_release -sc)_amd64.deb -o liblsl.deb
sudo apt install ./liblsl.deb
- name: Download and extract liblsl (Windows)
if: startsWith(matrix.config.os, 'windows')
run: |
curl -L ${LSL_RELEASE_URL}/${LSL_RELEASE_PREFIX}${LSL_RELEASE}/liblsl-${LSL_RELEASE}-Win_${{ matrix.config.arch}}.zip -o liblsl.zip
7z x liblsl.zip -oLSL
- name: Install liblsl (macOS)
if: startsWith(matrix.config.os, 'macos')
run: brew install labstreaminglayer/tap/lsl
- name: Install Qt
uses: jurplel/install-qt-action@v3.0.0
with:
version: 5.15.2
arch: ${{ matrix.config.qt_arch }}
- name: Configure CMake
shell: bash
run: |
cmake -S . -B build -DLSL_INSTALL_ROOT=$PWD/LSL/ -DLSL_COMFY_DEFAULTS=ON -DCPACK_DEBIAN_PACKAGE_SHLIBDEPS=ON
- name: Make & Install
run: cmake --build build --config Release -j --target install
- name: Package
run: cmake --build build --config Release -j --target package
- name: Create Release
if: startsWith(github.ref, 'refs/tags/v')
uses: softprops/action-gh-release@v1
with:
# tag_name: ${{ github.ref }} # ${{ github.ref }} is default
name: Release ${{ github.ref }}
draft: false
prerelease: false
# body_path: CHANGELOG.txt
files: build/*.[dbz][ezi][b2p]