From a4a932238c871e78c25559f06a6bcb532837990f Mon Sep 17 00:00:00 2001 From: Mike Solar Date: Mon, 13 Jul 2026 15:54:55 +0800 Subject: [PATCH] fix(macOS): disable KDDockWidgets QtQuick frontend to resolve launch crash Oak only uses KDDockWidgets' QtWidgets frontend. Building the QtQuick frontend caused duplicate QML module registration when QtQuick.framework initialized, resulting in a SIGABRT in QQmlMetaType::qmlInsertModuleRegistration. - Set KDDockWidgets_FRONTENDS to qtwidgets in ext/CMakeLists.txt. - Remove the -qmldir flags from macOS CD deploy since QML plugins are no longer needed. --- .github/workflows/cd.yml | 5 +---- ext/CMakeLists.txt | 3 +++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index ee672ead1..f7e248ce8 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -130,10 +130,7 @@ jobs: - name: Deploy Qt dependencies run: | export PATH="$(brew --prefix qt@6)/bin:$PATH" - macdeployqt build/app/Oak.app \ - -qmldir=app \ - -qmldir=ext/KDDockWidgets/src/qtquick/views/qml \ - -verbose=2 + macdeployqt build/app/Oak.app # Re-sign after macdeployqt (it breaks signatures when modifying libs) codesign --force --deep --sign - build/app/Oak.app diff --git a/ext/CMakeLists.txt b/ext/CMakeLists.txt index 135d557c3..448a97685 100644 --- a/ext/CMakeLists.txt +++ b/ext/CMakeLists.txt @@ -18,4 +18,7 @@ add_subdirectory(core EXCLUDE_FROM_ALL) set(KDDockWidgets_STATIC ON CACHE INTERNAL "Force KDDockWidgets to build statically") set(KDDockWidgets_QT6 ${BUILD_QT6} CACHE INTERNAL "Conform KDDockWidgets' Qt 6 setting to ours") +# Oak only uses the QtWidgets frontend; building the QtQuick frontend causes +# duplicate QML module registration on macOS and pulls in unused dependencies. +set(KDDockWidgets_FRONTENDS "qtwidgets" CACHE INTERNAL "Only build the QtWidgets frontend for Oak") add_subdirectory(KDDockWidgets EXCLUDE_FROM_ALL)