Skip to content

Instantly share code, notes, and snippets.

@a-a
Last active November 29, 2023 16:56
Show Gist options
  • Save a-a/79e3228f90e6bdf6dd30bb6dffd4a9b6 to your computer and use it in GitHub Desktop.
Save a-a/79e3228f90e6bdf6dd30bb6dffd4a9b6 to your computer and use it in GitHub Desktop.
pure wayland sddm on debian bookworm (raspberry pi 5, but probably similar for x86 and friends)
[General]
DisplayServer=wayland
[Wayland]
# Path of the directory containing session files
SessionDir=/usr/share/wayland-sessions
# Path of script to execute when starting the desktop session
SessionCommand=/usr/share/sddm/scripts/wayland-session
# Path to the user session log file, relative to the home directory.
SessionLogFile=.local/share/sddm/wayland-session.log
# Enables Qt's automatic HiDPI scaling. Can be either "true" or "false".Default value is "false".
EnableHiDPI=false

Pure Wayland sddm+KDE on Debian Bookworm, Raspberry Pi 5

Note: this assumes arm64, since I was using a Raspberry Pi 5. YMMV on other platforms.

1: sudo apt install task-kde-desktop

2: wget http://ftp.de.debian.org/debian/pool/main/s/sddm/sddm_0.20.0-1_arm64.deb; sudo dpkg -i sddm_0.20.0-1_arm64.deb (Replace as per your system's architecture, see also https://packages.debian.org/sid/sddm for latest version, maybe a new one dropped)

3: sudo vim /etc/sddm.conf.d/10-wayland.conf and fill it as per the .conf file in this gist

4: sudo apt install weston

5: sudo systemctl enable sddm.service

6: sudo systemctl start sddm.service

maybe i forgot something. if it doesn't work, read the comments, someone will have figured it out.

why the weird-ass sddm package from sid?

debian ships old crap. version 0.20 and above is needed for wayland support. lower versions will just ignore the config and start x. pulling in the package from sid like this is nasty, unsupported, etc, but it seems to just work with the current dependencies shipped if you don't care for it being updated properly. i don't think i do at this point, i just want a display.

why weston?

in theory kde has it's own compositor and you can reference this in the config with CompositorCommand as per man sddm.conf, but i couldn't be arsed to figure out how that worked. sddm calls weston by default, so let's just give it what it wants and it will work. no idea why it's not pulled in as a suggest in the sddm package because when sddm fails to find weston, it fails back to x11 and makes misleading log entries that suggest it ignored your config rather than anything useful to say there was a problem, and only when you start it manually with --v flag does it spit an error code for you to eventually figure you should manually try running the greeter before you get an actually useful error message to say what went wrong. hatehatehate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment