CI-windows.yml: cleaned and sped up build_qt job
#23473
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions | |
| # Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners | |
| name: CI-windows | |
| on: | |
| push: | |
| branches: | |
| - 'main' | |
| - 'releases/**' | |
| - '2.*' | |
| tags: | |
| - '2.*' | |
| pull_request: | |
| permissions: | |
| contents: read | |
| defaults: | |
| run: | |
| shell: cmd | |
| jobs: | |
| build_qt: | |
| strategy: | |
| matrix: | |
| os: [windows-2022, windows-2025] | |
| qt_ver: [6.10.0] | |
| fail-fast: false | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: false | |
| - name: Set up Visual Studio environment | |
| uses: ilammy/msvc-dev-cmd@v1 | |
| with: | |
| arch: x64 | |
| - name: Install Qt ${{ matrix.qt_ver }} | |
| uses: jurplel/install-qt-action@v4 | |
| with: | |
| version: ${{ matrix.qt_ver }} | |
| modules: 'qtcharts' | |
| setup-python: 'false' | |
| cache: true | |
| - name: Run CMake | |
| run: | | |
| rem TODO: enable rules? | |
| cmake -S . -B build -Werror=dev --warn-uninitialized -DCMAKE_BUILD_TYPE=Debug -DCMAKE_COMPILE_WARNING_AS_ERROR=On -DBUILD_TESTING=Off -DBUILD_GUI=On -DWITH_QCHART=On -DBUILD_TRIAGE=On -DBUILD_ONLINE_HELP=On -DCMAKE_INSTALL_PREFIX=cppcheck-cmake-install -DCMAKE_COMPILE_WARNING_AS_ERROR=On || exit /b !errorlevel! | |
| - name: Build GUI release | |
| run: | | |
| cmake --build build --config Debug --target cppcheck-gui || exit /b !errorlevel! | |
| # TODO: is there a way to do this in CMake | |
| - name: Deploy GUI | |
| run: | | |
| windeployqt build\bin\Debug || exit /b !errorlevel! | |
| # TODO: run GUI tests | |
| - name: Run CMake install | |
| run: | | |
| rem TODO: the Qt DLLs are not being installed | |
| cmake --build build --config Debug --target install | |
| rem TODO: validate the installed files | |
| rem TODO: the structure does not match an actual Windows installation |