$ git diff --patch-with-stat --summary bb145515bad03174778ef1397039a95933758745..a37dfa8b7ae1f55129cb92bbb81aae94e01c16f3
.abf.yml | 2 +-
0002-helper-Declare-dependency-on-Qt5-Qml.patch | 27 ---
...ion-of-PropertiesChanged-event-for-Logind.patch | 37 ---
0006-Added-missing-utmp-wtmp-btmp-handling.patch | 258 ---------------------
...r-see-icons-set-by-AccountsServices.-Reso.patch | 30 ---
sddm-0.12.0-waitForFinished.patch | 10 +-
sddm.spec | 9 +-
7 files changed, 9 insertions(+), 364 deletions(-)
delete mode 100644 0002-helper-Declare-dependency-on-Qt5-Qml.patch
delete mode 100644 0005-Fix-connection-of-PropertiesChanged-event-for-Logind.patch
delete mode 100644 0006-Added-missing-utmp-wtmp-btmp-handling.patch
delete mode 100644 0007-Make-greeter-see-icons-set-by-AccountsServices.-Reso.patch
diff --git a/.abf.yml b/.abf.yml
index a1bd327..40e7c2d 100644
--- a/.abf.yml
+++ b/.abf.yml
@@ -1,2 +1,2 @@
sources:
- sddm-0.16.0.tar.xz: 0aed7cc8cefb83b3b4f12d1ec4933e1e74372265
+ sddm-0.17.0.tar.xz: 93ec9237416668889e855f8b108887dda34d4c85
diff --git a/0002-helper-Declare-dependency-on-Qt5-Qml.patch b/0002-helper-Declare-dependency-on-Qt5-Qml.patch
deleted file mode 100644
index 8c31264..0000000
--- a/0002-helper-Declare-dependency-on-Qt5-Qml.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 74a265f9f04f7f5ff96800f5f0fb3ad31faf5427 Mon Sep 17 00:00:00 2001
-From: Marius Bakke <mbakke@fastmail.com>
-Date: Sun, 22 Oct 2017 03:27:51 +0200
-Subject: [PATCH 2/9] helper: Declare dependency on Qt5::Qml.
-
-Authrequest.h includes <QtQml>, so make sure it's found on systems
-where it exists in a different directory from the rest of Qt.
----
- src/helper/CMakeLists.txt | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/helper/CMakeLists.txt b/src/helper/CMakeLists.txt
-index 6e13653..ebf4a6e 100644
---- a/src/helper/CMakeLists.txt
-+++ b/src/helper/CMakeLists.txt
-@@ -31,7 +31,7 @@ else()
- endif()
-
- add_executable(sddm-helper ${HELPER_SOURCES})
--target_link_libraries(sddm-helper Qt5::Network Qt5::DBus)
-+target_link_libraries(sddm-helper Qt5::Network Qt5::DBus Qt5::Qml)
- if(PAM_FOUND)
- target_link_libraries(sddm-helper ${PAM_LIBRARIES})
- else()
---
-2.8.3
-
diff --git a/0005-Fix-connection-of-PropertiesChanged-event-for-Logind.patch b/0005-Fix-connection-of-PropertiesChanged-event-for-Logind.patch
deleted file mode 100644
index f7e36c8..0000000
--- a/0005-Fix-connection-of-PropertiesChanged-event-for-Logind.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 46e8006d8d04ae7c3e45f0827e7775d6bdafb69e Mon Sep 17 00:00:00 2001
-From: Johannes Pointner <johannes.pointner@gmail.com>
-Date: Sat, 11 Nov 2017 15:02:18 +0100
-Subject: [PATCH 5/9] Fix connection of PropertiesChanged event for LogindSeat
-
-SDDM fails to start properly because the seat0 changes the property
-canGraphical after SDDM is started and the connection to watch the
-PropertiesChanged event didn't work.
----
- src/daemon/SeatManager.cpp | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/daemon/SeatManager.cpp b/src/daemon/SeatManager.cpp
-index c5afc57..530977c 100644
---- a/src/daemon/SeatManager.cpp
-+++ b/src/daemon/SeatManager.cpp
-@@ -40,7 +40,7 @@ namespace SDDM {
- Q_SIGNALS:
- void canGraphicalChanged(bool);
- private Q_SLOTS:
-- void propertiesChanged(const QString &interface, QVariantMap &changedProperties , const QStringList &invalidatedProperties);
-+ void propertiesChanged(const QString &interface, const QVariantMap &changedProperties , const QStringList &invalidatedProperties);
- private:
- QString m_name;
- bool m_canGraphical;
-@@ -80,7 +80,7 @@ namespace SDDM {
- return m_name;
- }
-
-- void LogindSeat::propertiesChanged(const QString& interface, QVariantMap& changedProperties, const QStringList& invalidatedProperties)
-+ void LogindSeat::propertiesChanged(const QString& interface, const QVariantMap& changedProperties, const QStringList& invalidatedProperties)
- {
- Q_UNUSED(invalidatedProperties);
- if (interface != Logind::seatIfaceName()) {
---
-2.8.3
-
diff --git a/0006-Added-missing-utmp-wtmp-btmp-handling.patch b/0006-Added-missing-utmp-wtmp-btmp-handling.patch
deleted file mode 100644
index 0a2c9f4..0000000
--- a/0006-Added-missing-utmp-wtmp-btmp-handling.patch
+++ /dev/null
@@ -1,258 +0,0 @@
-From b06c3ab0c579b2528782df660402ae5a907724ae Mon Sep 17 00:00:00 2001
-From: Robert Hoffmann <externer.dl.hoffmann@muenchen.de>
-Date: Fri, 10 Nov 2017 12:58:10 +0100
-Subject: [PATCH 6/9] Added missing utmp/wtmp/btmp handling
-
----
- src/helper/HelperApp.cpp | 121 +++++++++++++++++++++++++++++++++++++++++++++
- src/helper/HelperApp.h | 18 +++++++
- src/helper/UserSession.cpp | 9 ++++
- src/helper/UserSession.h | 14 ++++++
- 4 files changed, 162 insertions(+)
-
-diff --git a/src/helper/HelperApp.cpp b/src/helper/HelperApp.cpp
-index d942dcc..8912370 100644
---- a/src/helper/HelperApp.cpp
-+++ b/src/helper/HelperApp.cpp
-@@ -34,6 +34,9 @@
- #include <unistd.h>
- #include <sys/socket.h>
-
-+#include <utmp.h>
-+#include <utmpx.h>
-+#include <QByteArray>
-
- namespace SDDM {
- HelperApp::HelperApp(int& argc, char** argv)
-@@ -115,12 +118,26 @@ namespace SDDM {
-
- if (!m_backend->start(m_user)) {
- authenticated(QString());
-+
-+ // write failed login to btmp
-+ QProcessEnvironment env = m_session->processEnvironment();
-+ QString displayId = env.value(QStringLiteral("DISPLAY"));
-+ QString vt = env.value(QStringLiteral("XDG_VTNR"));
-+ utmpLogin(vt, displayId, m_user, 0, false);
-+
- exit(Auth::HELPER_AUTH_ERROR);
- return;
- }
-
- if (!m_backend->authenticate()) {
- authenticated(QString());
-+
-+ // write failed login to btmp
-+ QProcessEnvironment env = m_session->processEnvironment();
-+ QString displayId = env.value(QStringLiteral("DISPLAY"));
-+ QString vt = env.value(QStringLiteral("XDG_VTNR"));
-+ utmpLogin(vt, displayId, m_user, 0, false);
-+
- exit(Auth::HELPER_AUTH_ERROR);
- return;
- }
-@@ -139,6 +156,16 @@ namespace SDDM {
- }
-
- sessionOpened(true);
-+
-+ // write successful login to utmp/wtmp
-+ QProcessEnvironment env = m_session->processEnvironment();
-+ QString displayId = env.value(QStringLiteral("DISPLAY"));
-+ QString vt = env.value(QStringLiteral("XDG_VTNR"));
-+ if (env.value(QStringLiteral("XDG_SESSION_CLASS")) != QLatin1String("greeter")) {
-+ // cache pid for session end
-+ m_session->setCachedProcessId(m_session->processId());
-+ utmpLogin(vt, displayId, m_user, m_session->processId(), true);
-+ }
- }
- else
- exit(Auth::HELPER_SUCCESS);
-@@ -147,6 +174,16 @@ namespace SDDM {
-
- void HelperApp::sessionFinished(int status) {
- m_backend->closeSession();
-+
-+ // write logout to utmp/wtmp
-+ qint64 pid = m_session->cachedProcessId();
-+ QProcessEnvironment env = m_session->processEnvironment();
-+ if (env.value(QStringLiteral("XDG_SESSION_CLASS")) != QLatin1String("greeter")) {
-+ QString vt = env.value(QStringLiteral("XDG_VTNR"));
-+ QString displayId = env.value(QStringLiteral("DISPLAY"));
-+ utmpLogout(vt, displayId, pid);
-+ }
-+
- exit(status);
- }
-
-@@ -224,6 +261,90 @@ namespace SDDM {
- HelperApp::~HelperApp() {
-
- }
-+
-+ void HelperApp::utmpLogin(const QString &vt, const QString &displayName, const QString &user, qint64 pid, bool authSuccessful) {
-+ struct utmpx entry;
-+ struct timeval tv;
-+
-+ entry = { 0 };
-+ entry.ut_type = USER_PROCESS;
-+ entry.ut_pid = pid;
-+
-+ // ut_line: vt
-+ if (!vt.isEmpty()) {
-+ QString tty = QStringLiteral("tty");
-+ tty.append(vt);
-+ QByteArray ttyBa = tty.toLocal8Bit();
-+ const char* ttyChar = ttyBa.constData();
-+ strncpy(entry.ut_line, ttyChar, sizeof(entry.ut_line));
-+ }
-+
-+ // ut_host: displayName
-+ QByteArray displayBa = displayName.toLocal8Bit();
-+ const char* displayChar = displayBa.constData();
-+ strncpy(entry.ut_host, displayChar, sizeof(entry.ut_host));
-+
-+ // ut_user: user
-+ QByteArray userBa = user.toLocal8Bit();
-+ const char* userChar = userBa.constData();
-+ strncpy(entry.ut_user, userChar, sizeof(entry.ut_user));
-+
-+ gettimeofday(&tv, NULL);
-+ entry.ut_tv.tv_sec = tv.tv_sec;
-+ entry.ut_tv.tv_usec = tv.tv_usec;
-+
-+ // write to utmp
-+ setutxent();
-+ if (!pututxline (&entry))
-+ qWarning() << "Failed to write utmpx: " << strerror(errno);
-+ endutxent();
-+
-+ // append to failed login database btmp
-+ if (!authSuccessful) {
-+ updwtmpx("/var/log/btmp", &entry);
-+ }
-+
-+ // append to wtmp
-+ else {
-+ updwtmpx("/var/log/wtmp", &entry);
-+ }
-+ }
-+
-+ void HelperApp::utmpLogout(const QString &vt, const QString &displayName, qint64 pid) {
-+ struct utmpx entry;
-+ struct timeval tv;
-+
-+ entry = { 0 };
-+ entry.ut_type = DEAD_PROCESS;
-+ entry.ut_pid = pid;
-+
-+ // ut_line: vt
-+ if (!vt.isEmpty()) {
-+ QString tty = QStringLiteral("tty");
-+ tty.append(vt);
-+ QByteArray ttyBa = tty.toLocal8Bit();
-+ const char* ttyChar = ttyBa.constData();
-+ strncpy(entry.ut_line, ttyChar, sizeof(entry.ut_line));
-+ }
-+
-+ // ut_host: displayName
-+ QByteArray displayBa = displayName.toLocal8Bit();
-+ const char* displayChar = displayBa.constData();
-+ strncpy(entry.ut_host, displayChar, sizeof(entry.ut_host));
-+
-+ gettimeofday(&tv, NULL);
-+ entry.ut_tv.tv_sec = tv.tv_sec;
-+ entry.ut_tv.tv_usec = tv.tv_usec;
-+
-+ // write to utmp
-+ setutxent();
-+ if (!pututxline (&entry))
-+ qWarning() << "Failed to write utmpx: " << strerror(errno);
-+ endutxent();
-+
-+ // append to wtmp
-+ updwtmpx("/var/log/wtmp", &entry);
-+ }
- }
-
- int main(int argc, char** argv) {
-diff --git a/src/helper/HelperApp.h b/src/helper/HelperApp.h
-index b83eade..3742df1 100644
---- a/src/helper/HelperApp.h
-+++ b/src/helper/HelperApp.h
-@@ -63,6 +63,24 @@ namespace SDDM {
- QString m_user { };
- // TODO: get rid of this in a nice clean way along the way with moving to user session X server
- QString m_cookie { };
-+
-+ /*!
-+ \brief Write utmp/wtmp/btmp records when a user logs in
-+ \param vt Virtual terminal (tty7, tty8,...)
-+ \param displayName Display (:0, :1,...)
-+ \param user User logging in
-+ \param pid User process ID (e.g. PID of startkde)
-+ \param authSuccessful Was authentication successful
-+ */
-+ void utmpLogin(const QString &vt, const QString &displayName, const QString &user, qint64 pid, bool authSuccessful);
-+
-+ /*!
-+ \brief Write utmp/wtmp records when a user logs out
-+ \param vt Virtual terminal (tty7, tty8,...)
-+ \param displayName Display (:0, :1,...)
-+ \param pid User process ID (e.g. PID of startkde)
-+ */
-+ void utmpLogout(const QString &vt, const QString &displayName, qint64 pid);
- };
- }
-
-diff --git a/src/helper/UserSession.cpp b/src/helper/UserSession.cpp
-index 4b32a29..8166c93 100644
---- a/src/helper/UserSession.cpp
-+++ b/src/helper/UserSession.cpp
-@@ -198,4 +198,13 @@ namespace SDDM {
- pclose(fp);
- }
- }
-+
-+ void UserSession::setCachedProcessId(qint64 pid) {
-+ m_cachedProcessId = pid;
-+ }
-+
-+ qint64 UserSession::cachedProcessId() {
-+ return m_cachedProcessId;
-+ }
-+
- }
-diff --git a/src/helper/UserSession.h b/src/helper/UserSession.h
-index 81ff3f0..7069084 100644
---- a/src/helper/UserSession.h
-+++ b/src/helper/UserSession.h
-@@ -40,11 +40,25 @@ namespace SDDM {
- void setPath(const QString &path);
- QString path() const;
-
-+ /*!
-+ \brief Sets m_cachedProcessId. Needed for getting the PID of a finished UserSession
-+ and calling HelperApp::utmpLogout
-+ \param pid The process ID
-+ */
-+ void setCachedProcessId(qint64 pid);
-+
-+ /*!
-+ \brief Gets m_cachedProcessId
-+ \return The cached process ID
-+ */
-+ qint64 cachedProcessId();
-+
- protected:
- void setupChildProcess();
-
- private:
- QString m_path { };
-+ qint64 m_cachedProcessId;
- };
- }
-
---
-2.8.3
-
diff --git a/0007-Make-greeter-see-icons-set-by-AccountsServices.-Reso.patch b/0007-Make-greeter-see-icons-set-by-AccountsServices.-Reso.patch
deleted file mode 100644
index c75b194..0000000
--- a/0007-Make-greeter-see-icons-set-by-AccountsServices.-Reso.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 6015d10fe771614d38026d37ceb26025dd711a28 Mon Sep 17 00:00:00 2001
-From: Nathaniel Graham <pointedstick@zoho.com>
-Date: Tue, 14 Nov 2017 22:54:18 -0700
-Subject: [PATCH 7/9] Make greeter see icons set by AccountsServices. Resolves
- #683
-
----
- src/greeter/UserModel.cpp | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/src/greeter/UserModel.cpp b/src/greeter/UserModel.cpp
-index 33114d0..ebc1819 100644
---- a/src/greeter/UserModel.cpp
-+++ b/src/greeter/UserModel.cpp
-@@ -116,9 +116,12 @@ namespace SDDM {
- if (avatarsEnabled) {
- const QString userFace = QStringLiteral("%1/.face.icon").arg(user->homeDir);
- const QString systemFace = QStringLiteral("%1/%2.face.icon").arg(facesDir).arg(user->name);
-+ QString accountsServiceFace = QStringLiteral("/var/lib/AccountsService/icons/%1").arg(user->name);
-
- if (QFile::exists(userFace))
- user->icon = QStringLiteral("file://%1").arg(userFace);
-+ else if (QFile::exists(accountsServiceFace))
-+ user->icon = accountsServiceFace;
- else if (QFile::exists(systemFace))
- user->icon = QStringLiteral("file://%1").arg(systemFace);
- }
---
-2.8.3
-
diff --git a/sddm-0.12.0-waitForFinished.patch b/sddm-0.12.0-waitForFinished.patch
index 5284060..487f4c3 100644
--- a/sddm-0.12.0-waitForFinished.patch
+++ b/sddm-0.12.0-waitForFinished.patch
@@ -1,8 +1,8 @@
-diff -aur sddm-0.12.0.old/src/daemon/XorgDisplayServer.cpp sddm-0.12.0/src/daemon/XorgDisplayServer.cpp
---- sddm-0.12.0.old/src/daemon/XorgDisplayServer.cpp 2015-10-27 11:52:31.000000000 -0400
-+++ sddm-0.12.0/src/daemon/XorgDisplayServer.cpp 2015-10-27 11:54:00.000000000 -0400
-@@ -291,7 +291,7 @@
- displayScript->start(displayCommand);
+diff -Naur sddm-0.17.0/src/daemon/XorgDisplayServer.cpp sddm-0.17.0.tpg/src/daemon/XorgDisplayServer.cpp
+--- sddm-0.17.0/src/daemon/XorgDisplayServer.cpp 2017-12-05 12:00:22.010667376 +0000
++++ sddm-0.17.0.tpg/src/daemon/XorgDisplayServer.cpp 2017-12-11 18:32:28.339121658 +0000
+@@ -316,7 +316,7 @@
+ connect(displayScript, SIGNAL(finished(int,QProcess::ExitStatus)), displayScript, SLOT(deleteLater()));
// wait for finished
- if (!displayScript->waitForFinished(30000))
diff --git a/sddm.spec b/sddm.spec
index 8794d7a..1f84f3e 100644
--- a/sddm.spec
+++ b/sddm.spec
@@ -2,14 +2,14 @@
Name: sddm
Summary: Lightweight display manager
-Version: 0.16.0
+Version: 0.17.0
%if %{date}
Release: 0.%{date}.1
# Packaged from git for the time being -- no download URL available
# git archive --format=tar --prefix sddm-0.11.0-$(date +%Y%m%d)/ HEAD | xz -vf > sddm-0.11.0-$(date +%Y%m%d).tar.xz
Source0: sddm-%{version}-%{date}.tar.xz
%else
-Release: 4
+Release: 1
Source0: https://github.com/sddm/sddm/releases/download/v%{version}/%{name}-%{version}.tar.xz
%endif
# Adds sddm to drakedm
@@ -34,10 +34,7 @@ Patch2: sddm-0.14.0-call-retain-splash-on-plymouth.patch
# (tpg) https://github.com/sddm/sddm/pull/817
Patch5: sddm-0.15.0-Avoid-leaking-sockets-to-user-sessions.patch
Patch6: 0001-Execute-etc-X11-Xsession.patch
-Patch7: 0002-helper-Declare-dependency-on-Qt5-Qml.patch
-Patch8: 0005-Fix-connection-of-PropertiesChanged-event-for-Logind.patch
-Patch9: 0006-Added-missing-utmp-wtmp-btmp-handling.patch
-Patch10: 0007-Make-greeter-see-icons-set-by-AccountsServices.-Reso.patch
+
BuildRequires: cmake(ECM)
BuildRequires: pkgconfig(Qt5Core)
BuildRequires: pkgconfig(Qt5Gui)