Dear Maintainer,
Purging greetd while another display manager is the configured default
removes that display manager's /etc/systemd/system/display-manager.service
symlink. The system then boots without any display manager until the
other one is reconfigured (e.g. dpkg-reconfigure lightdm).
Steps to reproduce (Debian testing, arm64 chroot):
1. apt install lightdm greetd
2. Choose greetd as the default display manager, then
dpkg-reconfigure lightdm and choose lightdm.
display-manager.service now points to lightdm.service.
3. apt purge greetd
4. /etc/systemd/system/display-manager.service is gone.
Expected: the link to lightdm.service stays.
With "apt remove greetd" (no purge) the link stays.
Likely cause: greetd.service has Alias=display-manager.service, so
deb-systemd-helper records display-manager.service as one of greetd's
enable links. The postrm's "deb-systemd-helper purge greetd.service"
then deletes that path even though it now belongs to lightdm.
gdm3, lightdm and sddm avoid this by managing display-manager.service
themselves in their maintainer scripts (checking
/etc/X11/default-display-manager) instead of through the unit's Alias.
Thanks for packaging greetd.