%define rel 13 # this package links to the scripts Xsession and Xsetup from the xinitrc # package. Check that these links are always matching each other, across the future # versions, should their path change. # %define xinitrc_xdmpath %{_datadir}/X11/xdm Name: sddm Version: 0.14.0 %define subrel 2 Release: %mkrel %rel License: GPLv2+ Summary: QML based X11 display manager Group: Graphical desktop/KDE Url: https://github.com/sddm/sddm Source0: https://github.com/sddm/sddm/archive/v%{version}.tar.gz # PAM configs shamelessly stolen from our gdm package Source1: sddm.pam Source2: sddm-autologin.pam # Adds sddm to drakedm Source3: 11sddm.conf # default /etc/sddm.conf, created from man sddm.conf # similar can be obtained via sddm --example-config # show users with UID >= 500 and hide system users # allow display of custom user icons read from /var/lib/AccountsService/icons/ # ( by default SDDM reads user icon from either ~/.face.icon or FacesDir/username.face.icon ) Source6: sddm.conf # new default theme without a userlist, provided by Chris Denice # https://bugs.mageia.org/show_bug.cgi?id=16493 # (patched from Papoteur included) Source7: mga-coffee-noflag.tar.gz # workaround to enable autofocus on (password) input fields # taken from examples at https://github.com/sddm/sddm/issues/501 Patch0: sddm-0.12.0-mga-autofocus.patch Patch2: sddm-0.14-cmake-display-command.patch # Patches backported from git Patch10: 0001-Fix-display-of-user-avatars.-684.patch Patch11: 0002-Remove-quotes-from-ServerArguments-696.patch Patch12: 0003-Add-a-config-option-to-enable-high-DPI-scaling-701.patch Patch13: 0004-Make-the-default-cursor-themed-705.patch Patch14: 0005-elarun-Update-date-and-time.patch Patch15: 0006-Add-Hindi-translations-706.patch Patch16: 0007-Completed-translation-to-Swedish-709.patch Patch17: 0008-Support-Non-Latin-characters-in-theme-settings-708.patch Patch18: 0009-Update-fr.ts-710.patch Patch19: 0010-add-fish-shell-specific-commands-to-Xsession-and-way.patch Patch20: 0011-Unlock-Gnome-keyring-on-login-711.patch Patch21: 0012-releng-Update-create_changelog.pl.patch Patch22: 0013-releng-Fix-Perl-errors.patch Patch23: 0014-releng-Support-GitHub-issue-references.patch Patch24: 0015-Fix-manual-for-Current-theme-setting.patch Patch25: 0016-add-kwallet5-support.patch Patch27: 0017-Implemented-kwallet5-for-autologon-as-well.patch Patch28: 0018-Failure-log-messages-if-gnome-keyring-is-not-install.patch Patch29: 0019-Cleanup-dangling-pointer-in-SocketServer-725.patch Patch30: 0020-Fix-all-incorrect-use-of-QStringLiteral.patch Patch32: 0021-Fix-QStringLiteral.patch BuildRequires: extra-cmake-modules BuildRequires: cmake BuildRequires: systemd-devel BuildRequires: upower-devel BuildRequires: pam-devel BuildRequires: python-docutils BuildRequires: libxcb-devel BuildRequires: pkgconfig BuildRequires: pkgconfig(Qt5Core) BuildRequires: pkgconfig(Qt5DBus) BuildRequires: pkgconfig(Qt5Network) BuildRequires: pkgconfig(Qt5Qml) BuildRequires: pkgconfig(Qt5Help) BuildRequires: pkgconfig(Qt5Quick) BuildRequires: pkgconfig(Qt5Test) Obsoletes: slim < 1.3.6 # /etc/dbus-1/system.d/org.freedesktop.DisplayManager.conf is also provided by lightdm, # and the upgrade files if the packages are not updated in the same transaction (mga#18633) Conflicts: lightdm < 1.14.4-2 # For default background Requires: mageia-theme # For themes, without this one gets # "module "QtQuick" is not installed" errors Requires: qtdeclarative5 Requires: xinitrc Requires: pam Requires: systemd Requires: x11-server-xorg Requires(post): systemd Requires(preun): systemd Requires(postun): systemd %description SDDM is a modern display manager for X11 aiming to be fast, simple and beautiful. It uses modern technologies like QtQuick, which in turn gives the designer the ability to create smooth, animated user interfaces. %prep %autosetup -p1 # use default mga background image in themes # # (doktor5000) - this makes most part of the themes useless and ugly (default.jpg is not resolution-optimized) # instead, a separate Mageia theme is created further below and used by default # sed -i -e 's,\(^background=\).*,\1%{_datadir}/mga/backgrounds/default.jpg,' data/themes/*/theme.conf %build # set UID_MIN and UID_MAX here as autodetection from /etc/login.defs is not # possible for normal users due to missing read permissions %cmake_qt5 \ -DUSE_QT5=ON \ -DBUILD_MAN_PAGES=ON \ -DENABLE_JOURNALD=ON \ -DUID_MIN=500 \ -DUID_MAX=60000 %make_build %install make install/fast DESTDIR=%{buildroot} -C build mv -f %{buildroot}%{_sysconfdir}/sddm.conf %{buildroot}%{_sysconfdir}/sddm.conf.default # dm config install -Dpm 644 %{_sourcedir}/11sddm.conf %{buildroot}%{_datadir}/X11/dm.d/11sddm.conf # PAM config stolen from our gdm package install -Dpm 644 %{_sourcedir}/sddm.pam %{buildroot}%{_sysconfdir}/pam.d/sddm install -Dpm 644 %{_sourcedir}/sddm-autologin.pam %{buildroot}%{_sysconfdir}/pam.d/sddm-autologin # system user home dir mkdir -p %{buildroot}%{_localstatedir}/lib/%{name} # extract new default theme mga-coffee tar -xf %{SOURCE7} -C %{buildroot}%{_datadir}/sddm/themes sed -i 's/jpg/png/' %{buildroot}%{_datadir}/sddm/themes/mga-coffee/theme.conf %if 0 #### # create Mageia theme based on default Maui theme, and use Mageia default background cp -a %{buildroot}%{_datadir}/sddm/themes/maui %{buildroot}%{_datadir}/sddm/themes/mga-maui sed -i -e 's,\(^background=\).*,\1%{_datadir}/mga/backgrounds/default.png,' %{buildroot}%{_datadir}/sddm/themes/mga-maui/theme.conf # fix display of text messages in front of Mageia logo sed -i '/id: txtMessage/,/\}/ s/anchors.margins: 20/anchors.margins: 5/' %{buildroot}%{_datadir}/sddm/themes/mga-maui/Main.qml export metadata=%{buildroot}%{_datadir}/sddm/themes/mga-maui/metadata.desktop cat > $metadata << EOF [SddmGreeterTheme] Name=Mageia Maui Description=Mageia Maui Theme - based on original Maui theme Author=doktor5000 Copyright=(c) 2013, Abdurrahman AVCI License=CC-BY-SA Type=sddm-theme Version=0.1 Website=https://github.com/sddm/sddm Screenshot=default.jpg MainScript=Main.qml ConfigFile=theme.conf TranslationsDirectory=translations Email=doktor5000@mageia.org Theme-Id=mga-maui Theme-API=2.0 EOF #### %endif # replace upstream Xsession and Xsetup scripts with the same links from the xinitrc package # (and preserve the upstream Xsession and Xsetup under the names Xsession.sddm and Xsetup.sddm) mv -f %{buildroot}/%{_datadir}/sddm/scripts/Xsession %{buildroot}/%{_datadir}/sddm/scripts/Xsession.sddm mv -f %{buildroot}/%{_datadir}/sddm/scripts/Xsetup %{buildroot}/%{_datadir}/sddm/scripts/Xsetup.sddm ln -sf %{xinitrc_xdmpath}/Xsession %{buildroot}%{_datadir}/sddm/scripts/Xsession ln -sf %{xinitrc_xdmpath}/Xsetup_0 %{buildroot}%{_datadir}/sddm/scripts/Xsetup # install default sddm.conf install -Dpm 644 %{_sourcedir}/sddm.conf %{buildroot}%{_sysconfdir}/ # fix mgangle.png icon permission find %{buildroot}%{_datadir} -not -type d -a \( -type f -name '*.png' \) -perm /u=x,g=x,o=x -exec chmod -x '{}' \; # (ngompa) pretrans must be Lua # See https://fedoraproject.org/wiki/User:Patches/PackagingDrafts/Symlink_Workarounds %pretrans -p <lua> xsetuppath = "%{_datadir}/sddm/scripts/Xsetup" st1 = posix.stat(xsetuppath) if st1 and st1.type ~= "link" then os.execute("rm -f " .. xsetuppath) end xsessionpath = "%{_datadir}/sddm/scripts/Xsession" st2 = posix.stat(xsessionpath) if st2 and st2.type ~= "link" then os.execute("rm -f " .. xsessionpath) end %pre %_pre_useradd %{name} %{_localstatedir}/lib/%{name} /sbin/nologin %if 0 %post %_post_service sddm %preun %_preun_service sddm %endif %files %attr(700,sddm,sddm) %{_localstatedir}/lib/%{name}/ %config(noreplace) %{_sysconfdir}/sddm.conf %config(noreplace) %{_sysconfdir}/sddm.conf.default %config(noreplace) %{_sysconfdir}/pam.d/sddm %config(noreplace) %{_sysconfdir}/pam.d/sddm-autologin %config(noreplace) %{_sysconfdir}/pam.d/sddm-greeter %{_datadir}/X11/dm.d/11sddm.conf %{_sysconfdir}/dbus-1/system.d/org.freedesktop.DisplayManager.conf %{_libexecdir}/sddm-helper %{_bindir}/sddm %{_bindir}/sddm-greeter %{_unitdir}/sddm.service %{_qt5_qml}/SddmComponents %{_datadir}/sddm/faces %{_datadir}/sddm/scripts %{_datadir}/sddm/themes %{_datadir}/sddm/flags %{_datadir}/sddm/translations %{_mandir}/man?/%{name}* %changelog * Fri May 18 2018 mrambo3501 <mrambo3501> 0.14.0-13.2.mga6 (not released yet) + Revision: 1230324 - rebuild against the completed qt5 in the Grand Update (mga#19988) - modify bundled mga-coffee theme to blank an incorrect password mga#19988 - increase the incorrect password message font size mga#19988:C1 * Thu Mar 16 2017 eatdirt <eatdirt> 0.14.0-13.mga6 + Revision: 1093206 - Remove flag and fix desktop file (#16493) * Sat Dec 10 2016 ngompa <ngompa> 0.14.0-12.mga6 + Revision: 1074062 - Convert %%pretrans to Lua * Fri Nov 25 2016 ghibo <ghibo> 0.14.0-11.mga6 + Revision: 1070095 - Merges patches from git or bug #18822 and others from git. - Fix a typo in sddm.conf for Enabling/Disabling HiDPI. - Clean sddm.conf from unused themes. - Preseve upstream XSession and Xsetup under XSession.sddm and Xsetup.sddm names. * Mon Oct 24 2016 ghibo <ghibo> 0.14.0-10.mga6 + Revision: 1063430 - Make SPEC file more robust across updates and add %%posttrans for replacing files with links. * Sun Oct 23 2016 ghibo <ghibo> 0.14.0-9.mga6 + Revision: 1063332 - Added Patch to support DisplayCommand configure path in cmake command line. - Backport upstream patch to support HiDPI displays (bug sddm#701). - Usr /usr/share/X11/xdm/Xsetup_0 and /usr/share/X11/xdm/Xsession script soft links as suggested by Charles Edwards in bug #19601. * Mon Oct 17 2016 neoclust <neoclust> 0.14.0-8.mga6 + Revision: 1061252 - Use fixed sddm.conf ( Giuseppe Ghibo ) mga#19601 * Sun Oct 16 2016 tv <tv> 0.14.0-7.mga6 + Revision: 1061013 - switch to %%autosetup (mga#15579) * Wed Sep 28 2016 neoclust <neoclust> 0.14.0-6.mga6 + Revision: 1057448 - Improve swedish translation * Tue Sep 20 2016 neoclust <neoclust> 0.14.0-5.mga6 + Revision: 1054613 - Revert xsession commit * Mon Sep 19 2016 ghibo <ghibo> 0.14.0-4.mga6 + Revision: 1054511 - fix mgangle.png icon permission * Mon Sep 19 2016 neoclust <neoclust> 0.14.0-3.mga6 + Revision: 1054166 - Try using upstream Xsession * Thu Sep 15 2016 barjac <barjac> 0.14.0-2.mga6 + Revision: 1053243 - change default.jpg to default.png in mga-coffee theme.conf * Mon Sep 12 2016 neoclust <neoclust> 0.14.0-1.mga6 + Revision: 1051630 - New version 0.14.0 * Thu Aug 11 2016 schultz <schultz> 0.13.0-7.mga6 + Revision: 1045781 - theme for mga6 (mga#19045) - update theme for mga6 (mga#19045) * Fri Jul 22 2016 tmb <tmb> 0.13.0-6.mga6 + Revision: 1043165 - drop mistakenly added 'RememberLastUser=false' in sddm.conf * Fri Jul 22 2016 tmb <tmb> 0.13.0-5.mga6 + Revision: 1043098 - Honor RememberLastUser and RememberLastSession settings - Activate window for the primary screen - Quit SDDM if X fails to start * Wed Jun 22 2016 akien <akien> 0.13.0-4.mga6 + Revision: 1037170 - Add a conflict with mga5 lightdm to fix upgrade path (mga#18633) + umeabot <umeabot> - Mageia 6 Mass Rebuild * Wed Dec 09 2015 neoclust <neoclust> 0.13.0-2.mga6 + Revision: 909140 - Add P1: Fix crash reading lists from configuration * Mon Nov 09 2015 doktor5000 <doktor5000> 0.13.0-1.mga6 + Revision: 900206 - new version 0.13 * Thu Nov 05 2015 doktor5000 <doktor5000> 0.12.0-4.mga6 + Revision: 898008 - add workaround to enable autofocus on input field (mga#17073) - do not use /var/lib/AccountsService/icons for user faces/icons, use default o would require accountsservice to be installed * Thu Nov 05 2015 wally <wally> 0.12.0-3.mga6 + Revision: 897920 - rebuild with latest rpm to fix weird file conflict issue that shouldn't happen * Thu Oct 15 2015 doktor5000 <doktor5000> 0.12.0-2.mga6 + Revision: 891922 - added patch for CVE-2015-0856 (mga#16966) o prevent themes from loading KDE crash handler * Sat Oct 03 2015 doktor5000 <doktor5000> 0.12.0-1.mga6 + Revision: 886043 - new version 0.12 o SDDM now depends on Qt >= 5.3 o Display setup script is now killed if it hasn't finished within 30 seconds o new default X ServerArguments "-nolisten tcp" o wayland sessions support - added newly supported options as comments to %%{_sysconfdir}/sddm.conf - added mga-coffee as new default theme provided by Chris Denice o disables display of userlist, fixes (mga#16493) - fix display of text messages in front of Mageia logo with mga-maui theme - allow display of user icons from /var/lib/AccountsService/icons - hide more system users on login screen o mysql,apache and mldonkey via HideUsers as they use real shells o openvpn via HideShells as it uses /bin/false - specify MIN_UID and MAX_UID directly as autodetection from /etc/login.defs is not possible due to no read permission for others * Wed Dec 03 2014 doktor5000 <doktor5000> 0.11.0-1.mga5 + Revision: 800515 - new version 0.11.0 - drop Patch to use system locale on greeter start, merged upstream - really update numix theme to work with sddm >= 0.10.0 - do not change background for all themes to Mageia default background - create and use custom Mageia theme based on Maui as default - updated URL to new naming scheme, reenables automatic downloads * Fri Nov 21 2014 doktor5000 <doktor5000> 0.10.0-5.mga5 + Revision: 798141 - added /usr/sbin/nologin to HideShells stanza * Thu Nov 20 2014 doktor5000 <doktor5000> 0.10.0-4.mga5 + Revision: 797925 - add Patch to use system locale on greeter start o from upstream https://github.com/sddm/sddm/pull/312 - remove pam_gnome_keyring.so to fix the impossibility to log out (rhbz#1150283) - use %%config(noreplace) for /etc/sddm.conf - add default /etc/sddm.conf with comments on all stanzas o allows to show users with UID >= 500 for upgrades from mga4 (mga#11401) o hides system users (with login shells /sbin/nologin and /bin/false for now) * Sat Oct 25 2014 doktor5000 <doktor5000> 0.10.0-2.mga5 + Revision: 793095 - add numix theme from http://intialonso.github.io/ based on Maui theme * Fri Oct 24 2014 doktor5000 <doktor5000> 0.10.0-1.mga5 + Revision: 793031 - new version 0.10.0 - security issues fixed (mga#14238) : o Never try to login as the sddm user (CVE-2014-7271) o Fix race condition in XAUTHORITY file generation (CVE-2014-7272) o XAUTHORITY file is no longer owned by root - drops QT4 support - fixes PAM variable handling and some autologin issues * Wed Oct 15 2014 umeabot <umeabot> 0.9.0-10.mga5 + Revision: 740556 - Second Mageia 5 Mass Rebuild * Tue Sep 16 2014 umeabot <umeabot> 0.9.0-9.mga5 + Revision: 689088 - Mageia 5 Mass Rebuild * Thu Sep 04 2014 colin <colin> 0.9.0-8.mga5 + Revision: 671891 - Rebuild for new systemd * Wed Aug 27 2014 wally <wally> 0.9.0-7.mga5 + Revision: 668797 - require xinitrc * Wed Aug 06 2014 wally <wally> 0.9.0-6.mga5 + Revision: 660249 - obsolete slim - require qtdeclarative5 for themes * Wed Aug 06 2014 wally <wally> 0.9.0-5.mga5 + Revision: 660199 - use default Mageia background image in themes - add dm config file to add sddm to drakedm - use pam config files from our gdm (sddm and sddm-autologin) * Wed Aug 06 2014 wally <wally> 0.9.0-4.mga5 + Revision: 660143 - disable systemd post/preun scripts for now - create sddm system user for greeter - tag pam config files as %%config(noreplace) - build man pages * Wed Aug 06 2014 neoclust <neoclust> 0.9.0-3.mga5 + Revision: 660110 - Build against Qt5 * Tue Aug 05 2014 neoclust <neoclust> 0.9.0-2.mga5 + Revision: 659889 - Fix login (P0) * Sat Aug 02 2014 neoclust <neoclust> 0.9.0-1.mga5 + Revision: 659261 - New version 0.9.0 * Sat Oct 19 2013 umeabot <umeabot> 0.1.0-7.mga4 + Revision: 531342 - Mageia 4 Mass Rebuild * Sun Aug 04 2013 sander85 <sander85> 0.1.0-6.mga4 + Revision: 463132 - Fix requires * Sat Aug 03 2013 neoclust <neoclust> 0.1.0-5.mga4 + Revision: 462782 - imported package sddm * Mon Jul 22 2013 Martin Briza <mbriza@redhat.com> - 0.1.0-5 - Store xauth in /var/run/sddm * Mon Jul 22 2013 Martin Briza <mbriza@redhat.com> - 0.1.0-4 - Added the documentation bits * Thu Jul 18 2013 Martin Briza <mbriza@redhat.com> - 0.1.0-3 - Changed the source package to tar.gz - Config files are now noreplace - Buildrequires -systemd-devel +systemd +cmake * Tue Jul 16 2013 Martin Briza <mbriza@redhat.com> - 0.1.0-2 - Removed unneeded BuildRequires - Fixed systemd scriptlets - Fixed release - Simplified setup - Added Requires needed for basic function - Added Provides for graphical login * Thu Jul 04 2013 Martin Briza <mbriza@redhat.com> - 0.1.0-1 - Initial build