Fix Coverity warnings #2325
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
| name: CMake (Windows) | |
| on: [push, pull_request] | |
| env: | |
| BUILD_TYPE: RelWithDebInfo | |
| BUILD_NUMBER: ${{github.run_number}} | |
| CMAKE_BUILD_PARALLEL_LEVEL: 4 | |
| # Use libelectronic-id vcpkg manifest for dependencies | |
| VCPKG_MANIFEST_DIR: ./lib/libelectronic-id | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.arch == 'arm64' && 'windows-11-arm' || 'windows-2025' }} | |
| strategy: | |
| matrix: | |
| arch: [x64, arm64] | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| with: | |
| submodules: recursive | |
| persist-credentials: false | |
| - name: Cache vcpkg | |
| id: cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ${{ github.workspace }}/vcpkg_cache | |
| ~/.dotnet/tools | |
| ~/.wix | |
| key: vcpkg-${{ matrix.arch }}-${{ hashFiles(format('{0}/vcpkg.json', env.VCPKG_MANIFEST_DIR)) }} | |
| - name: Install Qt | |
| uses: jurplel/install-qt-action@v4 | |
| with: | |
| version: 6.10.1 | |
| arch: ${{ matrix.arch == 'arm64' && 'win64_msvc2022_arm64' || 'win64_msvc2022_64' }} | |
| cache: true | |
| - name: Setup MS Visual C++ dev env | |
| uses: ilammy/msvc-dev-cmd@v1 | |
| with: | |
| arch: ${{ matrix.arch }} | |
| - name: Install WiX | |
| if: steps.cache.outputs.cache-hit != 'true' | |
| run: | | |
| dotnet tool install --global wix --version 6.0.2 | |
| wix extension -g add WixToolset.UI.wixext/6.0.2 | |
| wix extension -g add WixToolset.Util.wixext/6.0.2 | |
| wix extension -g add WixToolset.BootstrapperApplications.wixext/6.0.2 | |
| - name: Configure | |
| env: | |
| VCPKG_BINARY_SOURCES: clear;files,${{ github.workspace }}/vcpkg_cache,readwrite | |
| run: | | |
| cmake "-GNinja" -S . -B build ` | |
| "-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake" ` | |
| "-DCMAKE_BUILD_TYPE=${env:BUILD_TYPE}" ` | |
| "-DVCPKG_MANIFEST_DIR=${{ env.VCPKG_MANIFEST_DIR }}" | |
| - name: Build | |
| run: | | |
| cmake --build build --config ${env:BUILD_TYPE} | |
| cmake --build build --config ${env:BUILD_TYPE} --target installer | |
| cmake --build build --config ${env:BUILD_TYPE} --target bundle | |
| - name: Test | |
| if: ${{ matrix.arch == 'x64' }} | |
| run: ctest -V -C ${env:BUILD_TYPE} --test-dir build | |
| - name: Upload artifacts | |
| uses: actions/upload-artifact@v5 | |
| with: | |
| name: web-eid-app-windows-build-${{matrix.arch}}-${{github.run_number}} | |
| path: | | |
| build/src/*/*.msi | |
| build/src/*/*.exe | |
| build/src/*/*.pdb | |
| build/lib/*/*.pdb |