diff --git a/0001-delete-suspend-hibernate.patch b/0001-delete-suspend-hibernate.patch deleted file mode 100644 index 3169ad22f0b04e3d9216d55a6a7dc7e8772a142b..0000000000000000000000000000000000000000 --- a/0001-delete-suspend-hibernate.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 6c57151f73419204046093be838fd7e6f1081594 Mon Sep 17 00:00:00 2001 -From: root -Date: Thu, 2 Jan 2020 10:17:57 +0800 -Subject: [PATCH] delete-suspend-hibernate - ---- - mate-session/gsm-logout-dialog.c | 22 +++++++++++----------- - 1 file changed, 11 insertions(+), 11 deletions(-) - -diff --git a/mate-session/gsm-logout-dialog.c b/mate-session/gsm-logout-dialog.c -index 36aad7b..674baba 100644 ---- a/mate-session/gsm-logout-dialog.c -+++ b/mate-session/gsm-logout-dialog.c -@@ -463,17 +463,17 @@ gsm_get_dialog (GsmDialogLogoutType type, - - logout_dialog->default_response = GSM_LOGOUT_RESPONSE_SHUTDOWN; - -- if (gsm_logout_supports_system_suspend (logout_dialog)) { -- gtk_dialog_add_button (GTK_DIALOG (logout_dialog), -- _("S_uspend"), -- GSM_LOGOUT_RESPONSE_SLEEP); -- } -- -- if (gsm_logout_supports_system_hibernate (logout_dialog)) { -- gtk_dialog_add_button (GTK_DIALOG (logout_dialog), -- _("_Hibernate"), -- GSM_LOGOUT_RESPONSE_HIBERNATE); -- } -+ // if (gsm_logout_supports_system_suspend (logout_dialog)) { -+ // gtk_dialog_add_button (GTK_DIALOG (logout_dialog), -+ // _("S_uspend"), -+ // GSM_LOGOUT_RESPONSE_SLEEP); -+ // } -+ -+ // if (gsm_logout_supports_system_hibernate (logout_dialog)) { -+ // gtk_dialog_add_button (GTK_DIALOG (logout_dialog), -+ // _("_Hibernate"), -+ // GSM_LOGOUT_RESPONSE_HIBERNATE); -+ // } - - if (gsm_logout_supports_reboot (logout_dialog)) { - gtk_dialog_add_button (GTK_DIALOG (logout_dialog), --- -2.23.0 - diff --git a/mate-session-manager-1.22.2.tar.xz b/mate-session-manager-1.22.2.tar.xz deleted file mode 100644 index a7200a2f1e87c580d04330e8a999d979cdffc03e..0000000000000000000000000000000000000000 Binary files a/mate-session-manager-1.22.2.tar.xz and /dev/null differ diff --git a/mate-session-manager-1.26.1.tar.xz b/mate-session-manager-1.26.1.tar.xz new file mode 100644 index 0000000000000000000000000000000000000000..17510fa03ad8f8e188ccbdc5f5d22327d93a2205 Binary files /dev/null and b/mate-session-manager-1.26.1.tar.xz differ diff --git a/mate-session-manager.spec b/mate-session-manager.spec index 2a23db4d15808b4cf935b9d19e781e4cdbf8d92d..3eb9ce15050813fa9222d6dc8f6cf64b3d2241d1 100644 --- a/mate-session-manager.spec +++ b/mate-session-manager.spec @@ -2,7 +2,7 @@ %global rel_build 1 # This is needed, because src-url contains branched part of versioning-scheme. -%global branch 1.22 +%global branch 1.26 # Settings used for build from snapshots. %{!?rel_build:%global commit af58c2ecd98fe68360635f0e566b81e4b8c7be4d} @@ -15,12 +15,8 @@ Name: mate-session-manager Summary: MATE Desktop session manager License: GPLv2+ -Version: %{branch}.2 -%if 0%{?rel_build} -Release: 5 -%else -Release: 0.13%{?git_rel} -%endif +Version: %{branch}.1 +Release: 1 URL: http://mate-desktop.org # for downloading the tarball use 'spectool -g -R mate-session-manager.spec' @@ -29,21 +25,17 @@ URL: http://mate-desktop.org # Source for snapshot-builds. %{!?rel_build:Source0: http://git.mate-desktop.org/%{name}/snapshot/%{name}-%{commit}.tar.xz#/%{git_tar}} -# https://github.com/mate-desktop/mate-session-manager/pull/223 -Patch1: mate-session-manager_0001-Remove-GNOME_KEYRING_LIFETIME_FD.patch -Patch2: mate-session-manager_0002-Fix-timeout-with-gnome-keyring-3.34.patch -Patch3: 0001-delete-suspend-hibernate.patch - -BuildRequires: dbus-glib-devel -BuildRequires: desktop-file-utils -BuildRequires: gtk3-devel -BuildRequires: libSM-devel -BuildRequires: mate-common -BuildRequires: pangox-compat-devel -BuildRequires: systemd-devel -BuildRequires: xmlto -BuildRequires: libXtst-devel -BuildRequires: xorg-x11-xtrans-devel +BuildRequires: dbus-glib-devel +BuildRequires: desktop-file-utils +BuildRequires: gtk3-devel +BuildRequires: libSM-devel +BuildRequires: libXtst-devel +BuildRequires: make +BuildRequires: mate-common +BuildRequires: mesa-libGLES-devel +BuildRequires: systemd-devel +BuildRequires: xmlto +BuildRequires: xorg-x11-xtrans-devel Requires: system-logos # Needed for mate-settings-daemon @@ -107,18 +99,22 @@ desktop-file-install \ %{_bindir}/mate-session-properties %{_bindir}/mate-session-save %{_bindir}/mate-wm +%{_libexecdir}/mate-session-check-accelerated +%{_libexecdir}/mate-session-check-accelerated-gl-helper +%{_libexecdir}/mate-session-check-accelerated-gles-helper %{_datadir}/applications/mate-session-properties.desktop %{_datadir}/mate-session-manager %{_datadir}/icons/hicolor/*/apps/*.png %{_datadir}/icons/hicolor/scalable/apps/mate-session-properties.svg %{_datadir}/glib-2.0/schemas/org.mate.session.gschema.xml %{_datadir}/xsessions/mate.desktop -%if 0%{?fedora} > 22 || 0%{?rhel} || 0%{?openEuler} %{_docdir}/mate-session-manager/dbus/mate-session.html -%endif %changelog +* Mon Aug 19 2024 yueyaoqiang - 1.26.1-1 +- update to 1.26.1 + * Wed Jul 27 2022 longcheng - 1.22.2-5 - remove %{?dist} - fix build error in openeuler diff --git a/mate-session-manager_0001-Remove-GNOME_KEYRING_LIFETIME_FD.patch b/mate-session-manager_0001-Remove-GNOME_KEYRING_LIFETIME_FD.patch deleted file mode 100644 index 424dc75645651554a6bcb922840ba9d77f259bcf..0000000000000000000000000000000000000000 --- a/mate-session-manager_0001-Remove-GNOME_KEYRING_LIFETIME_FD.patch +++ /dev/null @@ -1,78 +0,0 @@ -From 8bcc7153e0ef5aeb5fb276350c7015579f6e432a Mon Sep 17 00:00:00 2001 -From: Jindrich Makovicka -Date: Sun, 6 Oct 2019 10:35:46 +0200 -Subject: [PATCH 1/2] Remove GNOME_KEYRING_LIFETIME_FD - -Keyring lifetime fd was removed from gnome-keyring in 2009 - -See "[daemon] Use new control protocol for daemon." ---- - mate-session/msm-gnome.c | 35 ++--------------------------------- - 1 file changed, 2 insertions(+), 33 deletions(-) - -diff --git a/mate-session/msm-gnome.c b/mate-session/msm-gnome.c -index 5e9cf02..97e08b8 100644 ---- a/mate-session/msm-gnome.c -+++ b/mate-session/msm-gnome.c -@@ -48,29 +48,9 @@ - - - static gboolean gnome_compat_started = FALSE; --static int keyring_lifetime_pipe[2]; - static pid_t gnome_keyring_daemon_pid = 0; - static Window gnome_smproxy_window = None; - --static void --child_setup (gpointer user_data) --{ -- gint open_max; -- gint fd; -- char *fd_str; -- -- open_max = sysconf (_SC_OPEN_MAX); -- for (fd = 3; fd < open_max; fd++) -- { -- if (fd != keyring_lifetime_pipe[0]) -- fcntl (fd, F_SETFD, FD_CLOEXEC); -- } -- -- fd_str = g_strdup_printf ("%d", keyring_lifetime_pipe[0]); -- g_setenv ("GNOME_KEYRING_LIFETIME_FD", fd_str, TRUE); -- g_free (fd_str); --} -- - - static void - gnome_keyring_daemon_startup (void) -@@ -87,26 +67,15 @@ gnome_keyring_daemon_startup (void) - gchar *name; - const gchar *value; - -- /* Pipe to slave keyring lifetime to */ -- if (pipe (keyring_lifetime_pipe)) -- { -- g_warning ("Failed to set up pipe for gnome-keyring: %s", strerror (errno)); -- return; -- } -- - error = NULL; - argv[0] = GNOME_KEYRING_DAEMON; - argv[1] = "--start"; - argv[2] = NULL; - g_spawn_sync (NULL, argv, NULL, -- G_SPAWN_SEARCH_PATH | G_SPAWN_LEAVE_DESCRIPTORS_OPEN, -- child_setup, NULL, -+ G_SPAWN_SEARCH_PATH, -+ NULL, NULL, - &sout, NULL, &status, &error); - -- close (keyring_lifetime_pipe[0]); -- /* We leave keyring_lifetime_pipe[1] open for the lifetime of the session, -- in order to slave the keyring daemon lifecycle to the session. */ -- - if (error != NULL) - { - g_printerr ("Failed to run gnome-keyring-daemon: %s\n", --- -2.23.0 - diff --git a/mate-session-manager_0002-Fix-timeout-with-gnome-keyring-3.34.patch b/mate-session-manager_0002-Fix-timeout-with-gnome-keyring-3.34.patch deleted file mode 100644 index 246b56913c9c1a33eb45289ae6b348076621d26f..0000000000000000000000000000000000000000 --- a/mate-session-manager_0002-Fix-timeout-with-gnome-keyring-3.34.patch +++ /dev/null @@ -1,139 +0,0 @@ -From 023f6f7b69b2a9c0399d7737d7729d464f9671e5 Mon Sep 17 00:00:00 2001 -From: Jindrich Makovicka -Date: Sun, 6 Oct 2019 10:38:05 +0200 -Subject: [PATCH 2/2] Fix timeout with gnome-keyring 3.34 - -Launch gnome-keyring-daemon asynchronously, and remove the -GNOME_KEYRING_PID reading code. - -GNOME_KEYRING_PID exposure was removed from gnome-keyring in 2014. ---- - mate-session/msm-gnome.c | 85 ++++++++++------------------------------ - 1 file changed, 20 insertions(+), 65 deletions(-) - -diff --git a/mate-session/msm-gnome.c b/mate-session/msm-gnome.c -index 97e08b8..b43f1ad 100644 ---- a/mate-session/msm-gnome.c -+++ b/mate-session/msm-gnome.c -@@ -48,88 +48,46 @@ - - - static gboolean gnome_compat_started = FALSE; --static pid_t gnome_keyring_daemon_pid = 0; - static Window gnome_smproxy_window = None; - -+static void -+gnome_keyring_daemon_finished (GPid pid, -+ gint status, -+ gpointer user_data) -+{ -+ if (WEXITSTATUS (status) != 0) -+ { -+ /* daemon failed for some reason */ -+ g_printerr ("gnome-keyring-daemon failed to start correctly, " -+ "exit code: %d\n", WEXITSTATUS (status)); -+ } -+} - - static void - gnome_keyring_daemon_startup (void) - { - GError *error = NULL; -- gchar *sout; -- gchar **lines; -- gsize lineno; -- gint status; -- glong pid; -- gchar *end; -+ GPid pid; - gchar *argv[3]; -- gchar *p; -- gchar *name; -- const gchar *value; - - error = NULL; - argv[0] = GNOME_KEYRING_DAEMON; - argv[1] = "--start"; - argv[2] = NULL; -- g_spawn_sync (NULL, argv, NULL, -- G_SPAWN_SEARCH_PATH, -- NULL, NULL, -- &sout, NULL, &status, &error); -+ g_spawn_async (NULL, argv, NULL, -+ G_SPAWN_SEARCH_PATH | G_SPAWN_DO_NOT_REAP_CHILD, -+ NULL, NULL, &pid, -+ &error); - - if (error != NULL) - { -- g_printerr ("Failed to run gnome-keyring-daemon: %s\n", -+ g_printerr ("Failed to spawn gnome-keyring-daemon: %s\n", - error->message); - g_error_free (error); -+ return; - } -- else -- { -- if (WIFEXITED (status) && WEXITSTATUS (status) == 0 && sout != NULL) -- { -- lines = g_strsplit (sout, "\n", 0); -- -- for (lineno = 0; lines[lineno] != NULL; lineno++) -- { -- p = strchr (lines[lineno], '='); -- if (p == NULL) -- continue; -- -- name = g_strndup (lines[lineno], p - lines[lineno]); -- value = p + 1; -- -- g_setenv (name, value, TRUE); -- -- if (g_strcmp0 (name, "GNOME_KEYRING_PID") == 0) -- { -- pid = strtol (value, &end, 10); -- if (end != value) -- gnome_keyring_daemon_pid = pid; -- } -- -- g_free (name); -- } -- -- g_strfreev (lines); -- } -- else -- { -- /* daemon failed for some reason */ -- g_printerr ("gnome-keyring-daemon failed to start correctly, " -- "exit code: %d\n", WEXITSTATUS (status)); -- } -- -- g_free (sout); -- } --} - --static void --gnome_keyring_daemon_shutdown (void) --{ -- if (gnome_keyring_daemon_pid != 0) -- { -- kill (gnome_keyring_daemon_pid, SIGTERM); -- gnome_keyring_daemon_pid = 0; -- } -+ g_child_watch_add (pid, gnome_keyring_daemon_finished, NULL); - } - - -@@ -232,9 +190,6 @@ msm_gnome_stop (void) - - g_debug ("MsmGnome: stopping"); - -- /* shutdown the keyring daemon */ -- gnome_keyring_daemon_shutdown (); -- - msm_compat_gnome_smproxy_shutdown (); - - gnome_compat_started = FALSE; --- -2.23.0 -