ci: resolve missing Windows ARM64 runtime DLLs and add pipeline inputs
The Windows ARM64 release package failed to launch on startup due to missing runtime DLLs (libdbus-1-3.dll, libmd4c.dll, zlib1.dll, libzstd.dll). This failure stemmed from several architectural and CI pipeline issues: 1. CMake unconditionally linked Qt6::DBus whenever available in the sysroot, introducing an unnecessary dependency on Qt6DBus.dll and libdbus-1-3.dll on Windows, even though D-Bus portal dialogs are only used on Linux. 2. The Docker build environment installed MSYS2 ARM64 Qt packages via an unchecked shell loop against a hardcoded package list. This missed crucial transitive runtime dependencies (such as md4c, zlib-ng-compat, libb2, and ICU) and failed silently when downloads or extractions broke. 3. Windows packaging lacked PE import verification, allowing broken packages with unresolved dynamic links to be produced and published without warning. To fix these issues and make image management more accessible: - Restrict Qt6::DBus detection and linking in CMakeLists.txt to Linux only, eliminating the D-Bus dependency from Windows builds. - Introduce scripts/download-mingw-arm64-qt.py to parse the MSYS2 clangarm64 database, resolve the complete transitive dependency graph, and verify essential runtime DLLs during the Docker image build. - Introduce scripts/verify-windows-dlls.py and integrate it into packaging/package-windows.sh to validate PE imports across the executable and bundled Qt plugins, failing packaging if any non-system DLL is missing. - Expose FORCE_REBUILD_IMAGE as a typed GitLab CI pipeline input (spec: inputs) to provide an interactive dropdown when triggering manual pipelines in the UI, and trigger container rebuilds when the download script changes. - Update AGENTS.md documentation to reflect the new dependency and packaging verification workflows.
This commit is contained in:
7 files changed
+467
-32
No files matched your search
+4
-2
@@ -19,7 +19,9 @@ find_package(Qt6 6.8 REQUIRED COMPONENTS
|
||||
Network
|
||||
)
|
||||
qt_standard_project_setup(REQUIRES 6.8)
|
||||
find_package(Qt6 OPTIONAL_COMPONENTS DBus)
|
||||
if(UNIX AND NOT APPLE)
|
||||
find_package(Qt6 OPTIONAL_COMPONENTS DBus)
|
||||
endif()
|
||||
|
||||
# Third-party libraries
|
||||
find_package(PkgConfig REQUIRED)
|
||||
@@ -180,7 +182,7 @@ target_link_libraries(asteria-qt PRIVATE
|
||||
${UCHARDET_LIB}
|
||||
)
|
||||
|
||||
if(Qt6DBus_FOUND)
|
||||
if(UNIX AND NOT APPLE AND Qt6DBus_FOUND)
|
||||
target_link_libraries(asteria-qt PRIVATE Qt6::DBus)
|
||||
target_compile_definitions(asteria-qt PRIVATE HAS_QT_DBUS)
|
||||
target_sources(asteria-qt PRIVATE
|
||||
|
||||
Reference in new issue
Block a user