Trying to run KDE 6 Plasma with Wayland....

Thanks. It does make difference. Instead I see a big difference when I change the value of "QT_QPA_PLATFORM".
Actually I have :

Code:
export QT_QPA_PLATFORM=minimal

but I read that it can assume different values. At the moment I don't know what they are. Can you tell me all the values that I can use ? I will try them one by one. Thanks.
 
I've looked for what caused this error for months :

Istantanea_2024-07-23_17-28-00.png


and finally I got it. It is :

export QT_QPA_PLATFORM=xcb
 
export QT_QPA_PLATFORM=vnc

is interesting :

Istantanea_2024-07-23_17-35-43.png


It says "the bound address is already in use" because I'm using a vm like this :

Code:
/usr/sbin/./bhyve-win -S -c sockets=1,cores=12,threads=1 -m 12G -w -H -A \
-s 0,hostbridge \
-s 1,ahci-hd,/mnt/$vmdisk4'p2'/bhyve/img/FreeBSD/FreeBSD-141.img,bootindex=1 \
-s 8:0,passthru,2/0/0 \
-s 8:1,passthru,2/0/1 \
-s 8:2,passthru,2/0/2 \
-s 8:3,passthru,2/0/3 \
-s 11,hda,play=/dev/dsp,rec=/dev/dsp \
-s 13,virtio-net,tap14 \
-s 14,virtio-9p,sharename=/ \
-s 29,fbuf,tcp=0.0.0.0:5914,w=1600,h=950,wait \
-s 30,xhci,tablet \
-s 31,lpc \
-l bootrom,/usr/local/share/uefi-firmware/BHYVE_UEFI_CODE.fd \
vm0:14 < /dev/null & sleep 2 && vncviewer 0:14

but the busy port is not 5900,but 5914...
 
  1. seatd - Service is enabled

Plasma cannot use seatd without https://github.com/CTSRD-CHERI/cheribsd-ports/commit/02e468a397ad

Plasma requires ConsoleKit2 session, so prepend ck-launch-session,like :

https://cgit.freebsd.org/ports/tree/x11/plasma5-plasma-workspace/files/startplasma-wayland.sh

Anyway,I'm trying with :

Code:
export LIBSEAT_BACKEND=consolekit2

  • sddm - Wayland session is visible but doesn't start. X11 is visible and KDE6 starts.

please disable sddm,it causes problems.
 
14.1 xdg runtime dir location

Code:
/var/run/xdg/username

where username is your username
you dont need to set export the XDG_RUNTIME_DIR

its automatically set to your username with the correct permissions and exported

if you comment out export XDG_RUNTIME_DIR
and reboot the vm and run

Code:
printenv

you will see its exported

Code:
XDG_RUNTIME_DIR=/var/run/xdg/djwilcox
 
like this ?

Code:
#!/bin/sh

#export QT_DEBUG_PLUGINS=1
#export WAYLAND_DEBUG=1

export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"
#export XDG_RUNTIME_DIR=/var/run/user/"$(id -u)"

export QT_WAYLAND_SHELL_INTEGRATION=xdg-shell
export XDG_SESSION_TYPE=xdg-shell

export QT_QPA_PLATFORMTHEME=qt6ct

export __GLX_VENDOR_LIBRARY_NAME=nvidia
export CLUTTER_BACKEND=wayland
export SDL_VIDEODRIVER=wayland
export LIBGL_DRI3_ENABLE=1
export XKB_DEFAULT_RULES=evdev

export QT_QPA_PLATFORM=minimal

#export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
#export BEMENU_BACKEND=wayland
#export WLR_DRM_NO_ATOMIC=1
#export XCURSOR_THEME=whiteglass

export WLR_NO_HARDWARE_CURSORS=1
export LIBSEAT_BACKEND=consolekit2

#mkdir -p /var/run/user/"$(id -u)"
#chown -R "${USER}":wheel /var/run/user/"$(id -u)"
#chmod 700 /var/run/user/"$(id -u)"

dbus-launch --sh-syntax --exit-with-session startplasma-wayland 2> startplasma.log

#ck-launch-session dbus-run-session startplasma-wayland 2> startplasma.log

#ck-launch-session dbus-run-session wayfire

it does not seem better to me :

Code:
org.kde.startup: not a reply org.freedesktop.locale1 QDBusMessage(type=Error, service="", error name="org.freedesktop.DBus.Error.ServiceUnknown", error message="The name org.freedesktop.locale1 was not provided by any .service files", signature="s", contents=("The name org.freedesktop.locale1 was not provided by any .service files") )
Initializing  "/usr/local/lib/qt6/plugins/plasma/kcms/systemsettings/kcm_fonts.so"
kf.kirigami.platform: Failed to find a Kirigami platform plugin for style ""
No backend specified, automatically choosing drm
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
No backend specified, automatically choosing drm
kwin_core: Could not determine the active graphical session
kwin_wayland_drm: failed to open drm device at "/dev/dri/card0"
kwin_wayland_drm: No suitable DRM devices have been found
org.kde.startup: "kdeinit5_shutdown" QList() exited with code 255
Initializing  "/usr/local/lib/qt6/plugins/plasma/kcms/systemsettings/kcm_style.so"
startplasma-wayland: Shutting down...
startplasmacompositor: Shutting down...
startplasmacompositor: Done.
/usr/local/bin/xrdb: Connection refused
/usr/local/bin/xrdb: Can't open display ':0'
/usr/local/bin/xsetroot:  unable to open display ':0'
Initializing  "/usr/local/lib/qt6/plugins/plasma/kcms/systemsettings/kcm_mouse.so"
kcm_mouse: Not able to select appropriate backend.

I think we need : dbus-run-session.
 
with dbus-run-session :

Code:
org.kde.startup: not a reply org.freedesktop.locale1 QDBusMessage(type=Error, service="", error name="org.freedesktop.DBus.Error.ServiceUnknown", error message="The name org.freedesktop.locale1 was not provided by any .service files", signature="s", contents=("The name org.freedesktop.locale1 was not provided by any .service files") )
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.kde.KSplash' requested by ':1.0' (uid=1001 pid=1847 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.kde.KSplash'
Initializing  "/usr/local/lib/qt6/plugins/plasma/kcms/systemsettings/kcm_fonts.so"
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.freedesktop.portal.Desktop' requested by ':1.5' (uid=1001 pid=1852 comm="")
kf.kirigami.platform: Failed to find a Kirigami platform plugin for style ""
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.freedesktop.portal.Documents' requested by ':1.6' (uid=1001 pid=1860 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.freedesktop.impl.portal.PermissionStore' requested by ':1.7' (uid=1001 pid=1862 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.freedesktop.impl.portal.PermissionStore'
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.freedesktop.portal.Documents'
fuse: unknown option(s): `-o auto_unmount'
error: fuse init failed: Can't create fuse session

(/usr/local/libexec/xdg-desktop-portal:1860): xdg-desktop-portal-WARNING **: 19:06:24.967: Failed to load RealtimeKit property: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.RealtimeKit1 was not provided by any .service files

(/usr/local/libexec/xdg-desktop-portal:1860): xdg-desktop-portal-WARNING **: 19:06:24.967: Failed to load RealtimeKit property: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.RealtimeKit1 was not provided by any .service files

(/usr/local/libexec/xdg-desktop-portal:1860): xdg-desktop-portal-WARNING **: 19:06:24.968: Failed to load RealtimeKit property: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.RealtimeKit1 was not provided by any .service files
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.freedesktop.impl.portal.desktop.kde' requested by ':1.6' (uid=1001 pid=1860 comm="")
No backend specified, automatically choosing drm
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.freedesktop.impl.portal.desktop.kde'
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.gtk.vfs.Daemon' requested by ':1.6' (uid=1001 pid=1860 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.gtk.vfs.Daemon'
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.gtk.vfs.UDisks2VolumeMonitor' requested by ':1.6' (uid=1001 pid=1860 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.gtk.vfs.UDisks2VolumeMonitor'
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.gtk.vfs.MTPVolumeMonitor' requested by ':1.6' (uid=1001 pid=1860 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.gtk.vfs.MTPVolumeMonitor'
dbus-daemon[1846]: [session uid=1001 pid=1846] Activating service name='org.gtk.vfs.GPhoto2VolumeMonitor' requested by ':1.6' (uid=1001 pid=1860 comm="")
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.gtk.vfs.GPhoto2VolumeMonitor'

(/usr/local/libexec/xdg-desktop-portal:1860): xdg-desktop-portal-WARNING **: 19:06:25.071: Failed connect to PipeWire: Couldn't connect to PipeWire

(/usr/local/libexec/xdg-desktop-portal:1860): xdg-desktop-portal-WARNING **: 19:06:25.076: Choosing kwallet.portal for org.freedesktop.impl.portal.Secret via the deprecated UseIn key

(/usr/local/libexec/xdg-desktop-portal:1860): xdg-desktop-portal-WARNING **: 19:06:25.076: The preferred method to match portal implementations to desktop environments is to use the portals.conf(5) configuration file
dbus-daemon[1846]: [session uid=1001 pid=1846] Successfully activated service 'org.freedesktop.portal.Desktop'
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
No backend specified, automatically choosing drm
Unable to determine system time zone: please check your system configuration.
kwin_screencast: Failed to connect PipeWire context
Initializing  "/usr/local/lib/qt6/plugins/plasma/kcms/systemsettings/kcm_style.so"
org.kde.startup: "kdeinit5_shutdown" QList() exited with code 255
startplasma-wayland: Shutting down...
startplasmacompositor: Shutting down...
startplasmacompositor: Done.
A connection to the bus can't be made
/usr/local/bin/xrdb: Connection refused
/usr/local/bin/xrdb: Can't open display ':0'
/usr/local/bin/xsetroot:  unable to open display ':0'
Initializing  "/usr/local/lib/qt6/plugins/plasma/kcms/systemsettings/kcm_mouse.so"
kcm_mouse: Not able to select appropriate backend.
 
What we have here ?

1) wayland and wayfire works
2) kde 6 on top of xorg works :

Screenshot-2024-07-23-19-18-11.png


so what ? can the conclusion be that if wayland + kde 6 does not work is because there are bugs ? because if we take only point 1 we can assume that Wayland works. If we take only point 2 we can say that kde 6 works...they don't work together,so logic wants that in this case cause are bugs or some unfinished work between some relationship that bind them.
 
it will be easier to figure out what the issue is
if you dont export so much stuff in your script

start with exporting a few variables

Code:
#!/bin/sh

export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

export QT_QPA_PLATFORMTHEME=qt6ct
export LIBSEAT_BACKEND=consolekit2

dbus-launch --sh-syntax --exit-with-session startplasma-wayland 2> startplasma.log

and then see whats needed,
most desktop will automatically set what they need most of the time

you probably dont need this

Code:
export __GLX_VENDOR_LIBRARY_NAME=nvidia

thats the code i gave you for a davinci resolve fix

the idea of not exporting all those variables is to test if any of them are causing the issue
then just add them back one at a time and see if it works or breaks

at least that way you will know if they are the problem or you need to look elsewhere
 
because if we take only point 1 we can assume that Wayland works.
no assumption needed wayland works on Freebsd
ive been using it for the last 6 months with wayfire, labwc, hikari and dwl

exporting variable like QT with the wrong settings can stop stop wayland from running
for instance xcb is for X11 and not wayland

thats why mention not exporting lots of stuff in your script

i know this from getting davinci resolve to work in a linux jail on freebsd
resolve is a qt application

i dont export any "wayland" settings

~/.zshenv

Code:
# xdg directories
export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

# qt5
export QT_QPA_PLATFORMTHEME=qt5ct

Code:
printenv

Code:
WAYLAND_DISPLAY=wayland-0
XDG_CACHE_HOME=/home/djwilcox/.cache
XDG_CONFIG_HOME=/home/djwilcox/.config
XDG_DATA_HOME=/home/djwilcox/.local/share
XDG_RUNTIME_DIR=/var/run/xdg/djwilcox
XDG_SESSION_TYPE=wayland

you can see the XDG_SESSION_TYPE is set
as well as the WAYLAND_DISPLAY
 
no assumption needed wayland works on Freebsd
ive been using it for the last 6 months with wayfire, labwc, hikari and dwl

come on man. I'm not talking in absolute way. I mean that it is working now for me,in the same v. machine where KDE 6 also works,so they are WELL CONFIGURED if considered separately.
 
no assumption needed wayland works on Freebsd
ive been using it for the last 6 months with wayfire, labwc, hikari and dwl

exporting variable like QT with the wrong settings can stop stop wayland from running
for instance xcb is for X11 and not wayland

thats why mention not exporting lots of stuff in your script

i know this from getting davinci resolve to work in a linux jail on freebsd
resolve is a qt application

i dont export any "wayland" settings

~/.zshenv

Code:
# xdg directories
export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

# qt5
export QT_QPA_PLATFORMTHEME=qt5ct

Code:
printenv

Code:
WAYLAND_DISPLAY=wayland-0
XDG_CACHE_HOME=/home/djwilcox/.cache
XDG_CONFIG_HOME=/home/djwilcox/.config
XDG_DATA_HOME=/home/djwilcox/.local/share
XDG_RUNTIME_DIR=/var/run/xdg/djwilcox
XDG_SESSION_TYPE=wayland

you can see the XDG_SESSION_TYPE is set
as well as the WAYLAND_DISPLAY

I've already tried to include and exclude variables,but I haven't yet touched the wayland settings...good idea to play with them...
 
so kde works on x11 with no missing fonts or anything like that
and wayland is working with wayfire

you have all the needed kde package installed

in your startup script you are

1 - exporting variables
2- running dbus-launch
3 - startplasma-wayland

so which of those 3 things might be causing the issue

so if you rule them out one by one you might track down the cause of the issue

if you commented out all the exported variables and then uncomment them you could could rule that out
then move onto the dbus command and the different ways you can use that

then finally you could see if the issue is with the startplasma-wayland script
i did see people mention issues with it in the past on the forum
 
I've added these lines to /home/marietto/.shrc

Code:
export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"
export QT_QPA_PLATFORMTHEME=qt5ct

and this is what happened :

Istantanea_2024-07-23_21-54-47.png


Now I can't login inside the vm anymore.
 
are you running freebsd 14.1

i did suggest

Code:
#!/bin/sh

export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

export QT_QPA_PLATFORMTHEME=qt6ct
export LIBSEAT_BACKEND=consolekit2

dbus-launch --sh-syntax --exit-with-session startplasma-wayland 2> startplasma.log

with consolekit2 and qt6ct

you can export the variables one by one to see what the issue is
 
are you running freebsd 14.1

i did suggest

Code:
#!/bin/sh

export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

export QT_QPA_PLATFORMTHEME=qt6ct
export LIBSEAT_BACKEND=consolekit2

dbus-launch --sh-syntax --exit-with-session startplasma-wayland 2> startplasma.log

with consolekit2 and qt6ct

you can export the variables one by one to see what the issue is

You wrote : ~/.zshenv ; so I placed those lines in the equivalent file for me , .cshrc.

You don't read my messages or what ? I told you that :

dbus-launch --sh-syntax --exit-with-session startplasma-wayland 2> startplasma.log

is not good (post : https://forums.freebsd.org/threads/trying-to-run-kde-6-plasma-with-wayland.93951/post-663933)
 
Anyway,I'm not able to fix that error even if I have removed all those entries from /home/marietto/.cshrc.
 
Back
Top