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
|
name: build
on: [push, pull_request]
jobs:
build:
strategy:
matrix:
config:
- { os: macos-latest, cxx: "clang++" }
- { os: ubuntu-latest, cxx: "g++" }
- { os: windows-latest, cxx: "cl" }
runs-on: ${{ matrix.config.os }}
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Cache Qt
id: cache-qt
uses: actions/cache@v1.2.0
with:
path: ../Qt
key: ${{ runner.os }}-QtCache
- name: Install Qt
uses: jurplel/install-qt-action@v2.12.1
with:
cached: ${{ steps.cache-qt.outputs.cache-hit }}
- name: Build with CMake in ${{ matrix.config.os }} / ${{ matrix.config.cxx }}
env:
CXX: ${{ matrix.config.cxx }}
run: |
cmake -B cmake_build
cmake --build cmake_build -j2
- name: Build with QMake in ${{ matrix.config.os }} / ${{ matrix.config.cxx }}
if: matrix.config.os != 'windows-latest'
env:
CXX: ${{ matrix.config.cxx }}
run: |
qmake
make -j2
|