diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8e4d47f0e..2ea283cc1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -404,10 +404,6 @@ jobs: - { toolchain: llvm, qt: '6.4.3' } - { toolchain: llvm, qt: '6.5.3' } - { toolchain: llvm, qt: '6.6.3' } - # \todo Temporarily exclude LLVM builds for Qt 6.7 and 6.8: https://github.com/miurahr/aqtinstall/issues/825 - - { toolchain: llvm, qt: '6.7.3' } - - { toolchain: llvm, qt: '6.8.1' } - - { toolchain: llvm, qt: '6.9.0' } include: # Map the aqtinstall (aqt) architectures. - { qt: '5.9.9', toolchain: mingw, arch: x86, aqtArch: win32_mingw53 } @@ -459,15 +455,15 @@ jobs: - { qt: '6.6.3', toolchain: mingw, arch: x86-64, aqtArch: win64_mingw } - { qt: '6.6.3', toolchain: msvc, arch: arm64, aqtArch: win64_msvc2019_arm64 } - { qt: '6.6.3', toolchain: msvc, arch: x86-64, aqtArch: win64_msvc2019_64 } - # { qt: '6.7.3', toolchain: llvm, arch: x86-64, aqtArch: win64_llvm_mingw } \todo See temp exclusion above. + - { qt: '6.7.3', toolchain: llvm, arch: x86-64, aqtArch: win64_llvm_mingw } - { qt: '6.7.3', toolchain: mingw, arch: x86-64, aqtArch: win64_mingw } - { qt: '6.7.3', toolchain: msvc, arch: arm64, aqtArch: win64_msvc2019_arm64 } - { qt: '6.7.3', toolchain: msvc, arch: x86-64, aqtArch: win64_msvc2019_64 } - # { qt: '6.8.1', toolchain: llvm, arch: x86-64, aqtArch: win64_llvm_mingw } \todo See temp exclusion above. + - { qt: '6.8.1', toolchain: llvm, arch: x86-64, aqtArch: win64_llvm_mingw } - { qt: '6.8.1', toolchain: mingw, arch: x86-64, aqtArch: win64_mingw } - { qt: '6.8.1', toolchain: msvc, arch: arm64, aqtArch: win64_msvc2022_arm64_cross_compiled } - { qt: '6.8.1', toolchain: msvc, arch: x86-64, aqtArch: win64_msvc2022_64 } - # { qt: '6.9.0', toolchain: llvm, arch: x86-64, aqtArch: win64_llvm_mingw } \todo See temp exclusion above. + - { qt: '6.9.0', toolchain: llvm, arch: x86-64, aqtArch: win64_llvm_mingw } - { qt: '6.9.0', toolchain: mingw, arch: x86-64, aqtArch: win64_mingw } - { qt: '6.9.0', toolchain: msvc, arch: arm64, aqtArch: win64_msvc2022_arm64_cross_compiled } - { qt: '6.9.0', toolchain: msvc, arch: x86-64, aqtArch: win64_msvc2022_64 } @@ -476,7 +472,7 @@ jobs: - { toolchain: msvc, arch: x86, msvcArch: amd64_x86 } - { toolchain: msvc, arch: x86-64, msvcArch: amd64 } # Define the generator and dll names per toolchain. - # { toolchain: 'llvm', generator: 'MinGW Makefiles', dll: libQtPokit.dll } \todo See temp exclusion above. + - { toolchain: 'llvm', generator: 'MinGW Makefiles', dll: libQtPokit.dll } - { toolchain: 'mingw', generator: 'MinGW Makefiles', dll: libQtPokit.dll } - { toolchain: 'msvc', generator: 'NMake Makefiles', dll: QtPokit.dll } # Use Qt-provided 64-bit MinGW for recent Qt's (defaulting to GitHub's 12.2.0 version for older Qt versions). @@ -485,8 +481,11 @@ jobs: - { toolchain: 'mingw', arch: x86-64, qt: '6.4.3', aqtTools: 'tools_mingw1310' } - { toolchain: 'mingw', arch: x86-64, qt: '6.5.3', aqtTools: 'tools_mingw1310' } - { toolchain: 'mingw', arch: x86-64, qt: '6.6.3', aqtTools: 'tools_mingw1310' } + - { toolchain: 'llvm', arch: x86-64, qt: '6.7.3', aqtTools: 'tools_llvm_mingw1706' } - { toolchain: 'mingw', arch: x86-64, qt: '6.7.3', aqtTools: 'tools_mingw1310' } + - { toolchain: 'llvm', arch: x86-64, qt: '6.8.1', aqtTools: 'tools_llvm_mingw1706' } - { toolchain: 'mingw', arch: x86-64, qt: '6.8.1', aqtTools: 'tools_mingw1310' } + - { toolchain: 'llvm', arch: x86-64, qt: '6.9.0', aqtTools: 'tools_llvm_mingw1706' } - { toolchain: 'mingw', arch: x86-64, qt: '6.9.0', aqtTools: 'tools_mingw1310' } steps: - name: Configure path @@ -602,6 +601,11 @@ jobs: copy /v /b src\lib\${{ matrix.dll }} /b test\unit\cli copy /v /b src\lib\${{ matrix.dll }} /b test\unit\lib working-directory: ${{ runner.temp }}/release + # \todo Remove this step when https://github.com/llvm/llvm-project/issues/110975 is resolved. + - name: Test StatusService for LLVM debugging + if: matrix.toolchain == 'llvm' + shell: bash + run: /d/a/_temp/coverage/test/unit/lib/testStatusService.exe -o output,txt || :; cat output - name: Test w/ coverage # We can't execute arm64 binaries on an x86-64 host. if: matrix.arch != 'arm64' && matrix.toolchain != 'msvc' run: ctest --output-on-failure --test-dir "%RUNNER_TEMP%/coverage" --verbose @@ -609,7 +613,7 @@ jobs: if: matrix.arch != 'arm64' run: ctest --output-on-failure --test-dir "%RUNNER_TEMP%/release" --verbose - name: Collate test coverage - if: matrix.toolchain != 'msvc' + if: matrix.toolchain != 'msvc' && matrix.toolchain != 'llvm' run: cmake --build "%RUNNER_TEMP%/coverage" --target coverage --verbose - name: Upload test results if: matrix.arch != 'arm64' && ( matrix.toolchain != 'msvc' || fromJSON(steps.post-build.outputs.tap) ) diff --git a/src/cli/CMakeLists.txt b/src/cli/CMakeLists.txt index 72b6e8c1b..9a6611aa6 100644 --- a/src/cli/CMakeLists.txt +++ b/src/cli/CMakeLists.txt @@ -108,16 +108,26 @@ endif() find_program(WINDEPLOYQT NAMES windeployqt windeployqt.exe) if (WINDEPLOYQT) message(STATUS "Found windeployqt: ${WINDEPLOYQT}") + if (CMAKE_CXX_COMPILER_ID MATCHES "Clang$") + message( + NOTICE + "${CMAKE_CXX_COMPILER_ID} compiler runtime not supported by windeployqt, " + "so compiler runtime will not be included in portable builds.") + set(DOKIT_INCLUDE_COMPILER_RUNTIME false) + else() + set(DOKIT_INCLUDE_COMPILER_RUNTIME true) + endif() file(MAKE_DIRECTORY ${PROJECT_BINARY_DIR}/portable) add_custom_target( cli-portable COMMAND ${CMAKE_COMMAND} -E copy "$" "${PROJECT_BINARY_DIR}/portable" COMMAND ${CMAKE_COMMAND} -E copy "$" "${PROJECT_BINARY_DIR}/portable" - COMMAND ${WINDEPLOYQT} --compiler-runtime --release --verbose 2 + COMMAND ${WINDEPLOYQT} "$<$:--compiler-runtime>" --release --verbose 2 "$" "$" COMMENT "Bundling portable version" DEPENDS cli QtPokit + COMMAND_EXPAND_LISTS VERBATIM WORKING_DIRECTORY ${PROJECT_BINARY_DIR}/portable) endif() diff --git a/test/unit/lib/teststatusservice.cpp b/test/unit/lib/teststatusservice.cpp index ea47a5280..802320787 100644 --- a/test/unit/lib/teststatusservice.cpp +++ b/test/unit/lib/teststatusservice.cpp @@ -605,6 +605,13 @@ void TestStatusService::serviceDiscovered() // Pokit Meter's Status service UUId will be assigned. service.d_func()->serviceDiscovered(StatusService::ServiceUuids::pokitMeter); + #if defined(Q_OS_WIN) && defined(Q_CC_CLANG) + qInfo() << "service.d_func()->serviceUuid" << service.d_func()->serviceUuid; + qInfo() << "StatusService::ServiceUuids::pokitMeter" << StatusService::ServiceUuids::pokitMeter; + qInfo() << "\\todo Once llvm-mingw is updated such that the above two match, then remove the following QSKIP()"; + qInfo() << "\\todo See https://github.com/llvm/llvm-project/issues/110975"; + QSKIP("LLVM has known 'const static inline variable initialisation' bug on Windows #110975"); + #endif QCOMPARE(service.d_func()->serviceUuid, StatusService::ServiceUuids::pokitMeter); // Pokit Pro's Status service UUId will be assigned.