diff options
Diffstat (limited to '')
5 files changed, 123 insertions, 0 deletions
diff --git a/testing/source/vtown/kde/post-install/sddm-kcm.post-install b/testing/source/vtown/kde/post-install/sddm-kcm.post-install new file mode 100644 index 000000000..10b156d72 --- /dev/null +++ b/testing/source/vtown/kde/post-install/sddm-kcm.post-install @@ -0,0 +1,4 @@ +# Move the polkit dbus configuration files to the proper place: +mkdir -p $PKG/etc +mv $PKG/etc/kde/dbus-1 $PKG/etc/ + diff --git a/testing/source/vtown/kde/post-install/sddm.post-install b/testing/source/vtown/kde/post-install/sddm.post-install new file mode 100644 index 000000000..3d168b14f --- /dev/null +++ b/testing/source/vtown/kde/post-install/sddm.post-install @@ -0,0 +1,49 @@ +if [ "$SLACKPAM" == "no" ]; then + # Remove PAM related stuff: + rm -rf $PKG/etc/pam.d +else + # Replace systemd-centric files with ours: + rm -f $PKG/etc/pam.d/sddm* + for FILE in sddm sddm-autologin sddm-greeter ; do + install -Dm644 $CWD/post-install/sddm-qt5/pam.d/$FILE $PKG/etc/pam.d/$FILE + done +fi + +# Remove the sddm.conf file because we will generate our own in doinst.sh: +rm -f $PKG/etc/sddm.conf + +# Make sure that Plasma and SDDM work on older GPUs, +# by forcing Qt5 to use software GL rendering: +cat <<"EOGL" >> $PKG/usr/share/sddm/scripts/Xsetup + +# Make sure that Plasma and SDDM work on older GPUs, +# by forcing Qt5 to use software GL rendering: +OPENGL_VERSION=$(LANG=C glxinfo |grep '^OpenGL version string: ' |head -n 1 |sed -e 's/^OpenGL version string: \([0-9]\).*$/\1/g') +if [ "$OPENGL_VERSION" -lt 2 ]; then + QT_XCB_FORCE_SOFTWARE_OPENGL=1 + export QT_XCB_FORCE_SOFTWARE_OPENGL +fi +EOGL + +# Ensure that user customizations to the session files are not lost: +mv $PKG/usr/share/sddm/scripts/Xsession{,.new} +mv $PKG/usr/share/sddm/scripts/Xsetup{,.new} +mv $PKG/usr/share/sddm/scripts/Xstop{,.new} +mv $PKG/usr/share/sddm/scripts/wayland-session{,.new} + +# Add a wrapper for the sddm binary, to enable a custom environment: +mv $PKG/usr/bin/sddm $PKG/usr/bin/sddm.bin +cat <<"EOT" > $PKG/usr/bin/sddm +#!/bin/sh +# Customized environment (LANG definition): +if [ -f /etc/default/sddm ]; then + . /etc/default/sddm +fi +/usr/bin/sddm.bin "$*" +EOT +chmod 0755 $PKG/usr/bin/sddm + +# Let's also add an example customization (localization of the UI): +mkdir -p $PKG/etc/default +echo ". /etc/profile.d/lang.sh" > $PKG/etc/default/sddm.new + diff --git a/testing/source/vtown/kde/post-install/sddm/pam.d/sddm b/testing/source/vtown/kde/post-install/sddm/pam.d/sddm new file mode 100644 index 000000000..df016a7ec --- /dev/null +++ b/testing/source/vtown/kde/post-install/sddm/pam.d/sddm @@ -0,0 +1,26 @@ +#%PAM-1.0 + +auth substack system-auth + +# Uncomment this line to restrict login to users with a UID greater +# than 999 (in other words, don't allow login for root): +#auth required pam_succeed_if.so uid >= 1000 quiet + +-auth optional pam_gnome_keyring.so +-auth optional pam_kwallet5.so +auth include postlogin + +account include system-auth + +password substack system-auth +-password optional pam_gnome_keyring.so use_authtok +-password optional pam_kwallet5.so use_authtok + +session optional pam_keyinit.so force revoke +session substack system-auth +session required pam_loginuid.so +-session optional pam_ck_connector.so nox11 +-session optional pam_elogind.so +-session optional pam_gnome_keyring.so auto_start +-session optional pam_kwallet5.so auto_start +session include postlogin diff --git a/testing/source/vtown/kde/post-install/sddm/pam.d/sddm-autologin b/testing/source/vtown/kde/post-install/sddm/pam.d/sddm-autologin new file mode 100644 index 000000000..360239544 --- /dev/null +++ b/testing/source/vtown/kde/post-install/sddm/pam.d/sddm-autologin @@ -0,0 +1,25 @@ +#%PAM-1.0 +auth requisite pam_nologin.so +auth required pam_env.so +auth required pam_shells.so + +# Uncomment this line to restrict autologin to users with a UID greater +# than 999 (in other words, don't allow autologin for root): +#auth required pam_succeed_if.so uid >= 1000 quiet + +auth required pam_permit.so +-auth optional pam_gnome_keyring.so +-auth optional pam_kwallet5.so + +account include system-auth + +password include system-auth + +session substack system-auth +session required pam_loginuid.so +-session optional pam_ck_connector.so nox11 +-session optional pam_elogind.so +-session optional pam_gnome_keyring.so auto_start +-session optional pam_kwallet5.so auto_start +session include postlogin + diff --git a/testing/source/vtown/kde/post-install/sddm/pam.d/sddm-greeter b/testing/source/vtown/kde/post-install/sddm/pam.d/sddm-greeter new file mode 100644 index 000000000..fe30e60c2 --- /dev/null +++ b/testing/source/vtown/kde/post-install/sddm/pam.d/sddm-greeter @@ -0,0 +1,19 @@ +#%PAM-1.0 + +# Load environment from /etc/environment and ~/.pam_environment +auth required pam_env.so + +# Always let the greeter start without authentication +auth required pam_permit.so + +# No action required for account management +account required pam_permit.so + +# Can't change password +password required pam_deny.so + +# Setup session +session required pam_unix.so +-session optional pam_systemd.so +-session optional pam_ck_connector.so nox11 +-session optional pam_elogind.so |