As the only easy way to obtain the pre-released KeepassXC using Qt6 seems to be the appimage, I tried that.
Running it didnt work even after installing fuse (which is at version 2.x), so I just unpacked it (./KeePassXC-2.8.0-snapshot-x86_64.appimage --appimage-extract) and executed the “AppRun” executable.
After adding nix-ld and adding a bunch of libraries (painfully one after another, rebuilding every time) I had following:
programs.nix-ld = {
enable = true;
libraries = with pkgs; [
### KeepassXC Appimage
libusb1
libx11
libGL
harfbuzz
e2fsprogs # com_err.so
kdePackages.qtwayland # wayland platform plugin
];};
(also using info from here and here)
it had complained that the wayland platform was missing, I dont know how to fix that, as one of the reasons for Qt6 is getting rid of X11.
With debug options, this is the output:
Click to expand
QT_DEBUG_PLUGINS=1 QT_QPA_PLATFORM=wayland ./AppRun
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/lr92k9c8fa6yz350sp54sjl7nsxlfld4-konsole-26.04.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/qfbc7by7q9pfn8x4kdhwd0jjb5i8bq6c-qqc2-desktop-style-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/ra6pihkxrzkia3fh4ds5h44b8fckaiwy-sonnet-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/ypli6sz5gbgqhxbdjii1b0h13d2fk2sf-kio-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/9bwj64cl6i4q2qrgq96gw1h1lb2afjnd-kwindowsystem-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/qq70vkvpynhsl03x1kmjlx79n1jiiidz-kiconthemes-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/ljl397qakyrf2rbh6nc6akmqna0di2ix-ki18n-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/2brz1b87pwsa0ksnrn5ajln11ifjh2n1-qtmultimedia-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/vqlf2vdm5g5b6hada09773qs71rknnrz-qtquick3d-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/lwa1k7ni8d4ljj44mzzlagk4qnngrsr8-qtdeclarative-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/anjilsbn2zq0i36z0m67w2djvsvc7lzg-qtsvg-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqeglfs.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqeglfs.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqlinuxfb.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqlinuxfb.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqminimal.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqminimal.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqminimalegl.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqminimalegl.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqoffscreen.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqoffscreen.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqvkkhrdisplay.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqvkkhrdisplay.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqvnc.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqvnc.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqwayland.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqwayland.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqxcb.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqxcb.so'"
not a plugin
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/jdy21m56n8xffk2fc6z15761f1vbgl5m-dolphin-26.04.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/l1r4l6n5z7jxzzkbilvf1glm4fvwvwvj-kio-extras-26.04.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/6xx94hfry9il99abd9mkja79310f57jp-kactivitymanagerd-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/l3hgvdirgaq77m1mb9r76hfscz7y1660-kauth-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/dgk4had207ybr7jjc213p8lv982n6d9y-baloo-widgets-26.04.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/a388zn50fnrk7jd44xxm7dpmr5nh64qz-baloo-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/39nvk9fan639h6zcmpkkgk4bfsfc6xsm-kidletime-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/v89fw51d46j3lnxjvpmhddg0nzx9chrp-kfilemetadata-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/3wc6fkw8wmmq7ph37wsgl9pxisdbfjwp-plasma-workspace-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/d7lizlxnx6isjgn897vsby3rgfxmapyp-qtvirtualkeyboard-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/7cm8dxkg01v0fl46kvkdagsdjjvbk9b0-kwin-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/rbjgws2pxyk2abkblqlhp7a3hwzmh0ix-milou-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/drwbs49wb8n8i5i5n7a405vh922c9rwd-breeze-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/h4px4lpmjb1jv1wawickk61qi9h3ziwr-frameworkintegration-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/0kla4dgqr27w7ikmvh5vxlrc1fm342is-aurorae-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/7k43nxpll0yymx1b9s6iqh70dy3wynsj-ktexteditor-6.25.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/4yl2s5lfq2jc8swmyv00dp05l1gipyhh-kscreenlocker-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/apc2v3rsjxb1jcxpsx2mlq66lis8kygg-libplasma-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/bqxinzz43kxinbsz1vck49dapl2hnp83-libkscreen-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/4i812acv0gj4kchw85hvw0388bgjrlr8-layer-shell-qt-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/0hhrsvzf27rldm36sks04x3q0nh4np94-kglobalacceld-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/l6467aakn1dglqhvd10p97ac7iv4kqcg-qqc2-breeze-style-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/vks6zyxdfsgims8cf29qdskysh9mh5ki-plasma5support-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/pva7l5q61mmiq9ld4d4wfsngzd576klj-libksysguard-6.6.4/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/l1nqjg1yx6q6vx6zwsnd3ky0s7a0kfk8-qtwayland-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/rrincbwjdr4jlpvnnv0ksyz8322p997l-qtlocation-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/l3rjv27brkhz679gfzg2bgj69c45lkg6-qtpositioning-6.11.0/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqeglfs.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqeglfs.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqlinuxfb.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqlinuxfb.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqminimal.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqminimal.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqminimalegl.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqminimalegl.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqoffscreen.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqoffscreen.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqvkkhrdisplay.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqvkkhrdisplay.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqvnc.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqvnc.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqwayland.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqwayland.so'"
not a plugin
QFactoryLoader::QFactoryLoader() looking at "/nix/store/b5nagx4c8g6jbc8bc6bxqdg64sfnfwnv-system-path/lib/qt-6/plugins/platforms/libqxcb.so"
"Failed to extract plugin meta data from '/nix/store/1q8sx67miwfn3ws5k7mkmkcjbym4akkp-qtbase-6.11.0/lib/qt-6/plugins/platforms/libqxcb.so'"
not a plugin
QFactoryLoader::QFactoryLoader() checking directory path "/home/user/Apps/squashfs-root/usr/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-egl.so"
Found metadata in lib /home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-egl.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"wayland-egl"
]
},
"archreq": 0,
"className": "QWaylandEglPlatformIntegrationPlugin",
"debug": false,
"version": 331520
}
Got keys from plugin meta data ("wayland-egl")
QFactoryLoader::QFactoryLoader() looking at "/home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-generic.so"
Found metadata in lib /home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-generic.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"wayland"
]
},
"archreq": 0,
"className": "QWaylandIntegrationPlugin",
"debug": false,
"version": 331520
}
Got keys from plugin meta data ("wayland")
QFactoryLoader::QFactoryLoader() looking at "/home/user/Apps/squashfs-root/usr/plugins/platforms/libqxcb.so"
Found metadata in lib /home/user/Apps/squashfs-root/usr/plugins/platforms/libqxcb.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"xcb"
]
},
"archreq": 0,
"className": "QXcbIntegrationPlugin",
"debug": false,
"version": 331520
}
Got keys from plugin meta data ("xcb")
QFactoryLoader::QFactoryLoader() checking directory path "/home/user/Apps/squashfs-root/usr/bin/platforms" ...
Cannot load library /home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-generic.so: (libwayland-client.so.0: cannot open shared object file: No such file or directory)
QLibraryPrivate::loadPlugin failed on "/home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-generic.so" : "Cannot load library /home/user/Apps/squashfs-root/usr/plugins/platforms/libqwayland-generic.so: (libwayland-client.so.0: cannot open shared object file: No such file or directory)"
qt.qpa.plugin: Could not load the Qt platform plugin "wayland" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: wayland-egl, wayland, xcb.
fish: Job 1, 'QT_DEBUG_PLUGINS=1 QT_QPA_PLATF…' terminated by signal SIGABRT (Abort)