Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
116 changes: 116 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
name: Build

on:
push:
branches: [main]
paths:
- '**/*.cpp'
- '**/*.hpp'
- '**/*.h'
- '**/CMakeLists.txt'
- '**/*.cmake'
- '.github/workflows/build.yml'
pull_request:
paths:
- '**/*.cpp'
- '**/*.hpp'
- '**/*.h'
- '**/CMakeLists.txt'
- '**/*.cmake'
- '.github/workflows/build.yml'
workflow_dispatch:

concurrency:
group: ${{ github.event_name == 'pull_request' && format('build-pr-{0}', github.head_ref) || 'build-main' }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}

jobs:
linux:
name: Linux build
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v5

- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
build-essential cmake ninja-build \
libsndfile1-dev \
libgl1-mesa-dev libfuse2 \
libxkbcommon-dev '^libxcb.*-dev' libx11-xcb-dev \
libglu1-mesa-dev libxrender-dev libxi-dev libxkbfile-dev

- name: Install Qt 6.8
uses: jurplel/install-qt-action@v4
with:
version: "6.8.0"
host: linux
target: desktop
arch: linux_gcc_64
modules: ""
cache: true

- name: Configure
run: |
cmake -S . -B build -G Ninja \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH="${Qt6_DIR}"

- name: Build
run: cmake --build build --parallel

windows:
name: Windows build
if: false
runs-on: windows-2022
defaults:
run:
shell: pwsh
steps:
- uses: actions/checkout@v5

- name: Configure MSVC environment
uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64

- name: Install Qt 6.8
uses: jurplel/install-qt-action@v4
with:
version: "6.8.0"
host: windows
target: desktop
arch: win64_msvc2022_64
modules: ""
cache: true

- name: Configure
run: |
cmake -S . -B build -G Ninja `
-DCMAKE_BUILD_TYPE=Release `
-DCMAKE_PREFIX_PATH="$env:Qt6_DIR"

- name: Build
run: cmake --build build --parallel

macos:
name: macOS build
runs-on: macos-14
steps:
- uses: actions/checkout@v5

- name: Install dependencies
run: |
brew update
brew install cmake ninja libsndfile qt@6
brew link --force qt@6

- name: Configure
run: |
cmake -S . -B build -G Ninja \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH="$(brew --prefix qt@6)"

- name: Build
run: cmake --build build --parallel
Loading