-
Notifications
You must be signed in to change notification settings - Fork 2
41 lines (32 loc) · 1.05 KB
/
cmake.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
name: CMake
on: [push, pull_request]
env:
BUILD_TYPE: Release
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v2
with:
submodules: recursive
- name: Prepare (ubuntu)
run: |
sudo apt-get update
sudo apt-get install -y gcc-10 g++-10
sudo apt-get install -y libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev
if: matrix.os == 'ubuntu-latest'
- name: Configure (ubuntu)
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_VERBOSE_MAKEFILE=ON
env:
CC: gcc-10
CXX: g++-10
if: matrix.os == 'ubuntu-latest'
- name: Configure (windows)
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_VERBOSE_MAKEFILE=ON
if: matrix.os == 'windows-latest'
- name: Build
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}