SUMMARY See the pipeline run for a complete log: https://invent.kde.org/frameworks/kconfig/-/jobs/484432
The error reported is: QWARN : KConfigTest::initTestCase() kf.config.core: KConfigGroup::writeEntry was passed GUI type ' QColor ' but KConfigGui isn't linked! If it is linked to your program, this is a platform bug. Please inform the KDE developers QWARN : KConfigTest::initTestCase() kf.config.core: KConfigGroup::writeEntry was passed GUI type ' QColor ' but KConfigGui isn't linked! If it is linked to your program, this is a platform bug. Please inform the KDE developers QWARN : KConfigTest::initTestCase() kf.config.core: KConfigGroup::writeEntry was passed GUI type ' QFont ' but KConfigGui isn't linked! If it is linked to your program, this is a platform bug. Please inform the KDE developers PASS : KConfigTest::initTestCase() QWARN : KConfigTest::testComplex() kf.config.core: KConfigGroup::readEntry was passed GUI type ' QColor ' but KConfigGui isn't linked! If it is linked to your program, this is a platform bug. Please inform the KDE developers QWARN : KConfigTest::testComplex() kf.config.core: unhandled type QColor FAIL! : KConfigTest::testComplex() Compared values are not the same Actual (QVariant(sc3.readEntry("colorEntry1", QColor(Qt::black))).toString()): "#000000" Expected (QVariant(s_color_entry1).toString()) : "#4682b4" Loc: [/builds/frameworks/kconfig/autotests/kconfigguitest.cpp(80)] The important bits are: kf.config.core: KConfigGroup::writeEntry was passed GUI type ' QColor '/'QFont' kf.config.core: unhandled type QColor/QFont
This is due to `initKConfigGroupGui()` in kconfiggroupgui.cpp not being called when building statically, forcing that by manually calling it from the test fixes it.
I'm not finding a way to do this without explicit API, not even with just one compiler, let alone portable.
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/kconfig/-/merge_requests/145
Git commit d6173cee8d62b241672d98abe9dd6515d2049336 by Alexander Lohnau. Committed on 17/10/2022 at 16:02. Pushed by alex into branch 'master'. Fix KConfigGui initialization in case of static builds This way we ensure that the symbols land in the actual executable and thus we call the KConfigGui method. M +8 -0 src/gui/CMakeLists.txt M +2 -1 src/gui/kconfiggroupgui.cpp A +6 -0 src/gui/kconfigguistaticinitializer.cpp [License: LGPL(3+eV) LGPL(v3.0) LGPL(v2.1)] https://invent.kde.org/frameworks/kconfig/commit/d6173cee8d62b241672d98abe9dd6515d2049336