Skip to content

Fix: Qt install in for CMake workflow #21

Fix: Qt install in for CMake workflow

Fix: Qt install in for CMake workflow #21

Workflow file for this run

name: CMake and CTest
on:
push:
pull_request:
jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Qt # Generated with https://ddalcino.github.io/aqt-list-server/
uses: jurplel/install-qt-action@v3
with:
aqtversion: "==3.1.*"
host: "linux"
target: "desktop" # desktop libraries
tools: "tools_cmake" # Qt tools for cmake
- name: Install CMake
uses: jwlawson/actions-setup-cmake@v1
- name: Create build directory
run: mkdir build
- name: Test QT_ROOT_DIR
run: ls -la $QT_ROOT_DIR
# QT_ROOT_DIR set by install-qt-action
- name: Configure with CMake
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=$QT_ROOT_DIR
- name: Build
run: cmake --build build --target tests -- -j$(nproc)
- name: Run CTest
working-directory: build
run: ctest -V --output-on-failure