import gdm-40.0-12.el8
This commit is contained in:
parent
0ffac0a180
commit
ce2a9b6701
@ -1,7 +1,7 @@
|
|||||||
From 911780e9980fe16b18d139f757ff795da1d1882d Mon Sep 17 00:00:00 2001
|
From 85951a0384cb7f37d99669575fad4aea155f25a8 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Wed, 5 May 2021 10:50:56 -0400
|
Date: Wed, 5 May 2021 10:50:56 -0400
|
||||||
Subject: [PATCH] Revert "gdm-{wayland,x}-session: don't overwrite user env
|
Subject: [PATCH 1/5] Revert "gdm-{wayland,x}-session: don't overwrite user env
|
||||||
with fallback vars"
|
with fallback vars"
|
||||||
|
|
||||||
This reverts commit ccecd9c975d04da80db4cd547b67a1a94fa83292.
|
This reverts commit ccecd9c975d04da80db4cd547b67a1a94fa83292.
|
||||||
@ -237,5 +237,5 @@ index 5962da572..b15483614 100644
|
|||||||
state->session_command,
|
state->session_command,
|
||||||
NULL);
|
NULL);
|
||||||
--
|
--
|
||||||
2.31.1
|
2.30.1
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
From b840bedd919eb321f2cefd8b9620af5bc28a28b6 Mon Sep 17 00:00:00 2001
|
From cebcf2a4d29f01061dedf8714db2842b9582900c Mon Sep 17 00:00:00 2001
|
||||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||||
Date: Tue, 8 Jun 2021 20:45:00 +0200
|
Date: Tue, 8 Jun 2021 20:45:00 +0200
|
||||||
Subject: [PATCH] data: Disable network configuration on login screen
|
Subject: [PATCH 1/3] data: Disable network configuration on login screen
|
||||||
|
|
||||||
---
|
---
|
||||||
data/meson.build | 10 ++++++++++
|
data/meson.build | 10 ++++++++++
|
||||||
@ -10,10 +10,37 @@ Subject: [PATCH] data: Disable network configuration on login screen
|
|||||||
create mode 100644 data/org.gnome.gdm.rules.in
|
create mode 100644 data/org.gnome.gdm.rules.in
|
||||||
|
|
||||||
diff --git a/data/meson.build b/data/meson.build
|
diff --git a/data/meson.build b/data/meson.build
|
||||||
index 7c5222ea..20d39a36 100644
|
index 23e2d7f9f..cbd6a6a21 100644
|
||||||
--- a/data/meson.build
|
--- a/data/meson.build
|
||||||
+++ b/data/meson.build
|
+++ b/data/meson.build
|
||||||
@@ -157,6 +157,16 @@ gdm_rules = configure_file(
|
@@ -131,60 +131,70 @@ pam_data_files_map = {
|
||||||
|
'arch': [
|
||||||
|
'gdm-autologin',
|
||||||
|
'gdm-launch-environment',
|
||||||
|
'gdm-fingerprint',
|
||||||
|
'gdm-smartcard',
|
||||||
|
'gdm-password',
|
||||||
|
'gdm-pin',
|
||||||
|
],
|
||||||
|
'none': [],
|
||||||
|
# We should no longer have 'autodetect' at this point
|
||||||
|
}
|
||||||
|
|
||||||
|
pam_data_files = pam_data_files_map[default_pam_config]
|
||||||
|
pam_prefix = (get_option('pam-prefix') != '')? get_option('pam-prefix') : get_option('sysconfdir')
|
||||||
|
foreach _pam_filename : pam_data_files
|
||||||
|
install_data('pam-@0@/@1@.pam'.format(default_pam_config, _pam_filename),
|
||||||
|
rename: _pam_filename,
|
||||||
|
install_dir: pam_prefix / 'pam.d',
|
||||||
|
)
|
||||||
|
endforeach
|
||||||
|
|
||||||
|
gdm_rules = configure_file(
|
||||||
|
input: '61-gdm.rules.in',
|
||||||
|
output: '@BASENAME@',
|
||||||
|
configuration: {
|
||||||
|
'libexecdir': gdm_prefix / get_option('libexecdir'),
|
||||||
|
},
|
||||||
install_dir: udev_dir,
|
install_dir: udev_dir,
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -30,9 +57,36 @@ index 7c5222ea..20d39a36 100644
|
|||||||
# DBus service files
|
# DBus service files
|
||||||
service_config = configuration_data()
|
service_config = configuration_data()
|
||||||
service_config.set('sbindir', gdm_prefix / get_option('sbindir'))
|
service_config.set('sbindir', gdm_prefix / get_option('sbindir'))
|
||||||
|
service_config.set('GDM_INITIAL_VT', get_option('initial-vt'))
|
||||||
|
service_config.set('LANG_CONFIG_FILE', lang_config_file)
|
||||||
|
if plymouth_dep.found()
|
||||||
|
service_config.set('PLYMOUTH_QUIT_SERVICE', 'plymouth-quit.service')
|
||||||
|
else
|
||||||
|
service_config.set('PLYMOUTH_QUIT_SERVICE', '')
|
||||||
|
endif
|
||||||
|
|
||||||
|
if get_option('systemdsystemunitdir') != ''
|
||||||
|
systemd_systemunitdir = get_option('systemdsystemunitdir')
|
||||||
|
else
|
||||||
|
systemd_systemunitdir = systemd_dep.get_pkgconfig_variable('systemdsystemunitdir')
|
||||||
|
endif
|
||||||
|
|
||||||
|
if get_option('systemduserunitdir') != ''
|
||||||
|
systemd_userunitdir = get_option('systemduserunitdir')
|
||||||
|
else
|
||||||
|
systemd_userunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir',
|
||||||
|
define_variable: ['prefix', get_option('prefix')])
|
||||||
|
endif
|
||||||
|
|
||||||
|
configure_file(
|
||||||
|
input: 'gdm.service.in',
|
||||||
|
output: '@BASENAME@',
|
||||||
|
configuration: service_config,
|
||||||
|
install_dir: systemd_systemunitdir,
|
||||||
|
format: 'cmake'
|
||||||
diff --git a/data/org.gnome.gdm.rules.in b/data/org.gnome.gdm.rules.in
|
diff --git a/data/org.gnome.gdm.rules.in b/data/org.gnome.gdm.rules.in
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 00000000..09544f11
|
index 000000000..09544f11e
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/data/org.gnome.gdm.rules.in
|
+++ b/data/org.gnome.gdm.rules.in
|
||||||
@@ -0,0 +1,8 @@
|
@@ -0,0 +1,8 @@
|
||||||
@ -45,5 +99,5 @@ index 00000000..09544f11
|
|||||||
+ return polkit.Result.NOT_HANDLED;
|
+ return polkit.Result.NOT_HANDLED;
|
||||||
+});
|
+});
|
||||||
--
|
--
|
||||||
2.31.1
|
2.30.1
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
From b1557adf711577c62609f8a784f11fad66eb54ef Mon Sep 17 00:00:00 2001
|
From 8c9fe8ebd9e584adaec0a80ee4c4eaf5357422a5 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Wed, 31 Jul 2013 17:32:55 -0400
|
Date: Wed, 31 Jul 2013 17:32:55 -0400
|
||||||
Subject: [PATCH] data: add system dconf databases to gdm profile
|
Subject: [PATCH 1/2] data: add system dconf databases to gdm profile
|
||||||
|
|
||||||
This way system settings can affect the login screen.
|
This way system settings can affect the login screen.
|
||||||
---
|
---
|
||||||
@ -20,5 +20,5 @@ index 4d8bf1748..9694078fb 100644
|
|||||||
+system-db:distro
|
+system-db:distro
|
||||||
file-db:@DATADIR@/@PACKAGE@/greeter-dconf-defaults
|
file-db:@DATADIR@/@PACKAGE@/greeter-dconf-defaults
|
||||||
--
|
--
|
||||||
2.28.0
|
2.30.1
|
||||||
|
|
||||||
|
@ -1,26 +1,48 @@
|
|||||||
From 53afc21a17f002730a53fe790de564f055c07352 Mon Sep 17 00:00:00 2001
|
From afdaf0c31c7fb44e05a271a9047a0993ff1f4ef2 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Mon, 11 Feb 2019 18:14:07 -0500
|
Date: Mon, 11 Feb 2019 18:14:07 -0500
|
||||||
Subject: [PATCH] data: disable wayland on certain hardware
|
Subject: [PATCH] data: disable wayland on certain hardware
|
||||||
|
|
||||||
We're having issues with wayland on passthrough to virt
|
We're having issues with wayland on passthrough to virt
|
||||||
setups and with the vendor nvidia driver, so
|
setups and with the vendor nvidia driver on hybrid graphics
|
||||||
disable it in those cases.
|
setups, so disable it in those cases.
|
||||||
|
|
||||||
|
Also disable it on server chips for performance reasons.
|
||||||
---
|
---
|
||||||
data/61-gdm.rules.in | 15 ++++++++++++---
|
data/61-gdm.rules.in | 36 ++++++++++++++++++++++++++++++++----
|
||||||
1 file changed, 12 insertions(+), 3 deletions(-)
|
1 file changed, 32 insertions(+), 4 deletions(-)
|
||||||
|
|
||||||
diff --git a/data/61-gdm.rules.in b/data/61-gdm.rules.in
|
diff --git a/data/61-gdm.rules.in b/data/61-gdm.rules.in
|
||||||
index b1da191f8..0230e5ca5 100644
|
index b1da191f8..d863a4a4d 100644
|
||||||
--- a/data/61-gdm.rules.in
|
--- a/data/61-gdm.rules.in
|
||||||
+++ b/data/61-gdm.rules.in
|
+++ b/data/61-gdm.rules.in
|
||||||
@@ -1,6 +1,15 @@
|
@@ -1,6 +1,34 @@
|
||||||
# disable Wayland on Hi1710 chipsets
|
# disable Wayland on Hi1710 chipsets
|
||||||
-ATTR{vendor}=="0x19e5", ATTR{device}=="0x1711", RUN+="@libexecdir@/gdm-runtime-config set daemon WaylandEnable false"
|
-ATTR{vendor}=="0x19e5", ATTR{device}=="0x1711", RUN+="@libexecdir@/gdm-runtime-config set daemon WaylandEnable false"
|
||||||
+ATTR{vendor}=="0x19e5", ATTR{device}=="0x1711", RUN+="@libexecdir@/gdm-disable-wayland"
|
-# disable Wayland when using the proprietary nvidia driver
|
||||||
# disable Wayland when using the proprietary nvidia driver
|
|
||||||
-DRIVER=="nvidia", RUN+="@libexecdir@/gdm-runtime-config set daemon WaylandEnable false"
|
-DRIVER=="nvidia", RUN+="@libexecdir@/gdm-runtime-config set daemon WaylandEnable false"
|
||||||
+DRIVER=="nvidia", RUN+="@libexecdir@/gdm-disable-wayland"
|
+ATTR{vendor}=="0x19e5", ATTR{device}=="0x1711", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+
|
||||||
|
+# disable Wayland on Matrox chipsets
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0522", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0524", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0530", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0532", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0533", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0534", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0536", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x102b", ATTR{device}=="0x0538", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+
|
||||||
|
+# disable Wayland on aspeed chipsets
|
||||||
|
+ATTR{vendor}=="0x1a03", ATTR{device}=="0x2010", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ATTR{vendor}=="0x1a03", ATTR{device}=="0x2000", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+
|
||||||
|
+# disable Wayland on hybrid systems with vendor nvidia driver
|
||||||
|
+# default to Xorg on single gpu vendor nvidia systems
|
||||||
|
+DRIVER=="nvidia", ENV{GDM_HAS_VENDOR_NVIDIA_DRIVER}="1"
|
||||||
|
+DRIVER=="nvidia", RUN+="@libexecdir@/gdm-runtime-config set daemon PreferredDisplayServer xorg"
|
||||||
|
+SUBSYSTEM=="drm", KERNEL=="card[1-9]*", ENV{GDM_HAS_NVIDIA_DRIVER}=="1", RUN+="@libexecdir@/gdm-disable-wayland"
|
||||||
|
+ACTION=="add", SUBSYSTEM=="module", KERNEL=="nvidia_drm", ATTR{parameters/modeset}=="N", RUN+="/usr/libexec/gdm-disable-wayland"
|
||||||
+
|
+
|
||||||
+# disable Wayland on passthrough graphics setups for now (assumes passthrough if
|
+# disable Wayland on passthrough graphics setups for now (assumes passthrough if
|
||||||
+# there is more than one card, and one of the cards is virt: cirrus, bochs, qxl)
|
+# there is more than one card, and one of the cards is virt: cirrus, bochs, qxl)
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
From f860f60771cd4f07ae1d06c56621a5aa8545e60b Mon Sep 17 00:00:00 2001
|
From cbfb3ef99ecc9cbb4e6850e5dd0cc9fb65dd398a Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Tue, 1 Sep 2020 13:49:27 -0400
|
Date: Tue, 1 Sep 2020 13:49:27 -0400
|
||||||
Subject: [PATCH] display: Handle failure before display registration
|
Subject: [PATCH 1/3] display: Handle failure before display registration
|
||||||
|
|
||||||
Normally, e.g., gdm-wayland-session would register its display
|
Normally, e.g., gdm-wayland-session would register its display
|
||||||
before starting the session. This display registration is how
|
before starting the session. This display registration is how
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
|||||||
From 89ec6e57e452c04ffc43ae224052c7ddeea66676 Mon Sep 17 00:00:00 2001
|
From 5c52259331ce0b37dd1b2b092ff41f96b0e5ce64 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Mon, 29 Oct 2018 06:57:59 -0400
|
Date: Mon, 29 Oct 2018 06:57:59 -0400
|
||||||
Subject: [PATCH] local-display-factory: pause for a few seconds before falling
|
Subject: [PATCH] local-display-factory: pause for a few seconds before falling
|
||||||
@ -12,14 +12,24 @@ back to X.
|
|||||||
|
|
||||||
http://bugzilla.redhat.com/1643874
|
http://bugzilla.redhat.com/1643874
|
||||||
---
|
---
|
||||||
daemon/gdm-local-display-factory.c | 5 +++++
|
daemon/gdm-local-display-factory.c | 7 +++++++
|
||||||
1 file changed, 5 insertions(+)
|
1 file changed, 7 insertions(+)
|
||||||
|
|
||||||
diff --git a/daemon/gdm-local-display-factory.c b/daemon/gdm-local-display-factory.c
|
diff --git a/daemon/gdm-local-display-factory.c b/daemon/gdm-local-display-factory.c
|
||||||
index 8a4ef06cd..8554a0442 100644
|
index 0bb3851f1..297c3ac80 100644
|
||||||
--- a/daemon/gdm-local-display-factory.c
|
--- a/daemon/gdm-local-display-factory.c
|
||||||
+++ b/daemon/gdm-local-display-factory.c
|
+++ b/daemon/gdm-local-display-factory.c
|
||||||
@@ -488,60 +488,65 @@ ensure_display_for_seat (GdmLocalDisplayFactory *factory,
|
@@ -586,60 +586,67 @@ ensure_display_for_seat (GdmLocalDisplayFactory *factory,
|
||||||
|
preferred_display_server = get_preferred_display_server (factory);
|
||||||
|
|
||||||
|
if (g_strcmp0 (preferred_display_server, "none") == 0) {
|
||||||
|
g_debug ("GdmLocalDisplayFactory: Preferred display server is none, so not creating display");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ret = sd_seat_can_graphical (seat_id);
|
||||||
|
|
||||||
|
if (ret < 0) {
|
||||||
g_critical ("Failed to query CanGraphical information for seat %s", seat_id);
|
g_critical ("Failed to query CanGraphical information for seat %s", seat_id);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -35,26 +45,25 @@ index 8a4ef06cd..8554a0442 100644
|
|||||||
if (g_strcmp0 (seat_id, "seat0") == 0) {
|
if (g_strcmp0 (seat_id, "seat0") == 0) {
|
||||||
is_seat0 = TRUE;
|
is_seat0 = TRUE;
|
||||||
|
|
||||||
/* If we've failed, or are explicitly told to, fall back to legacy X11 support
|
falling_back = factory->num_failures > 0;
|
||||||
*/
|
session_type = gdm_local_display_factory_get_session_type (factory, falling_back);
|
||||||
if (factory->num_failures > 0 || !gdm_local_display_factory_use_wayland ()) {
|
|
||||||
session_type = NULL;
|
g_debug ("GdmLocalDisplayFactory: New displays on seat0 will use %s%s",
|
||||||
g_debug ("GdmLocalDisplayFactory: New displays on seat0 will use X11 fallback");
|
session_type, falling_back? " fallback" : "");
|
||||||
+
|
+
|
||||||
|
+ if (falling_back) {
|
||||||
+ /* workaround logind race for now
|
+ /* workaround logind race for now
|
||||||
+ * bug 1643874
|
+ * bug 1643874
|
||||||
+ */
|
+ */
|
||||||
+ g_usleep (2 * G_USEC_PER_SEC);
|
+ g_usleep (2 * G_USEC_PER_SEC);
|
||||||
} else {
|
+ }
|
||||||
g_debug ("GdmLocalDisplayFactory: New displays on seat0 will use wayland");
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
is_seat0 = FALSE;
|
is_seat0 = FALSE;
|
||||||
|
|
||||||
g_debug ("GdmLocalDisplayFactory: New displays on seat %s will use X11 fallback", seat_id);
|
g_debug ("GdmLocalDisplayFactory: New displays on seat %s will use X11 fallback", seat_id);
|
||||||
/* Force legacy X11 for all auxiliary seats */
|
/* Force legacy X11 for all auxiliary seats */
|
||||||
seat_supports_graphics = TRUE;
|
seat_supports_graphics = TRUE;
|
||||||
session_type = NULL;
|
session_type = "x11";
|
||||||
}
|
}
|
||||||
|
|
||||||
/* For seat0, we have a fallback logic to still try starting it after
|
/* For seat0, we have a fallback logic to still try starting it after
|
||||||
@ -78,13 +87,6 @@ index 8a4ef06cd..8554a0442 100644
|
|||||||
if (factory->seat0_graphics_check_timeout_id == 0) {
|
if (factory->seat0_graphics_check_timeout_id == 0) {
|
||||||
g_debug ("GdmLocalDisplayFactory: seat0 doesn't yet support graphics. Waiting %d seconds to try again.", SEAT0_GRAPHICS_CHECK_TIMEOUT);
|
g_debug ("GdmLocalDisplayFactory: seat0 doesn't yet support graphics. Waiting %d seconds to try again.", SEAT0_GRAPHICS_CHECK_TIMEOUT);
|
||||||
factory->seat0_graphics_check_timeout_id = g_timeout_add_seconds (SEAT0_GRAPHICS_CHECK_TIMEOUT,
|
factory->seat0_graphics_check_timeout_id = g_timeout_add_seconds (SEAT0_GRAPHICS_CHECK_TIMEOUT,
|
||||||
on_seat0_graphics_check_timeout,
|
|
||||||
factory);
|
|
||||||
|
|
||||||
} else {
|
|
||||||
/* It is not yet time to force X11 fallback. */
|
|
||||||
g_debug ("GdmLocalDisplayFactory: seat0 display requested when there is no graphics support before graphics check timeout.");
|
|
||||||
}
|
|
||||||
--
|
--
|
||||||
2.31.1
|
2.30.1
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
From d99f12385d6b04023cbe17f3f6fc2a917066c6e8 Mon Sep 17 00:00:00 2001
|
From d80807171a457ff87bdc9bd861939161749a37a8 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Thu, 20 Dec 2018 14:51:38 -0500
|
Date: Thu, 20 Dec 2018 14:51:38 -0500
|
||||||
Subject: [PATCH 1/3] manager: allow multiple xdmcp logins for the same user
|
Subject: [PATCH 1/3] manager: allow multiple xdmcp logins for the same user
|
||||||
@ -10,19 +10,19 @@ Subject: [PATCH 1/3] manager: allow multiple xdmcp logins for the same user
|
|||||||
3 files changed, 59 insertions(+), 18 deletions(-)
|
3 files changed, 59 insertions(+), 18 deletions(-)
|
||||||
|
|
||||||
diff --git a/common/gdm-settings-keys.h b/common/gdm-settings-keys.h
|
diff --git a/common/gdm-settings-keys.h b/common/gdm-settings-keys.h
|
||||||
index f0059b5cf..33676a851 100644
|
index 87685d3cd..4b3a1ffeb 100644
|
||||||
--- a/common/gdm-settings-keys.h
|
--- a/common/gdm-settings-keys.h
|
||||||
+++ b/common/gdm-settings-keys.h
|
+++ b/common/gdm-settings-keys.h
|
||||||
@@ -28,37 +28,38 @@ G_BEGIN_DECLS
|
@@ -30,37 +30,38 @@ G_BEGIN_DECLS
|
||||||
#define GDM_KEY_USER "daemon/User"
|
|
||||||
#define GDM_KEY_GROUP "daemon/Group"
|
|
||||||
#define GDM_KEY_AUTO_LOGIN_ENABLE "daemon/AutomaticLoginEnable"
|
#define GDM_KEY_AUTO_LOGIN_ENABLE "daemon/AutomaticLoginEnable"
|
||||||
#define GDM_KEY_AUTO_LOGIN_USER "daemon/AutomaticLogin"
|
#define GDM_KEY_AUTO_LOGIN_USER "daemon/AutomaticLogin"
|
||||||
#define GDM_KEY_TIMED_LOGIN_ENABLE "daemon/TimedLoginEnable"
|
#define GDM_KEY_TIMED_LOGIN_ENABLE "daemon/TimedLoginEnable"
|
||||||
#define GDM_KEY_TIMED_LOGIN_USER "daemon/TimedLogin"
|
#define GDM_KEY_TIMED_LOGIN_USER "daemon/TimedLogin"
|
||||||
#define GDM_KEY_TIMED_LOGIN_DELAY "daemon/TimedLoginDelay"
|
#define GDM_KEY_TIMED_LOGIN_DELAY "daemon/TimedLoginDelay"
|
||||||
#define GDM_KEY_INITIAL_SETUP_ENABLE "daemon/InitialSetupEnable"
|
#define GDM_KEY_INITIAL_SETUP_ENABLE "daemon/InitialSetupEnable"
|
||||||
|
#define GDM_KEY_PREFERRED_DISPLAY_SERVER "daemon/PreferredDisplayServer"
|
||||||
#define GDM_KEY_WAYLAND_ENABLE "daemon/WaylandEnable"
|
#define GDM_KEY_WAYLAND_ENABLE "daemon/WaylandEnable"
|
||||||
|
#define GDM_KEY_XORG_ENABLE "daemon/XorgEnable"
|
||||||
|
|
||||||
#define GDM_KEY_DEBUG "debug/Enable"
|
#define GDM_KEY_DEBUG "debug/Enable"
|
||||||
|
|
||||||
@ -53,7 +53,7 @@ index f0059b5cf..33676a851 100644
|
|||||||
|
|
||||||
#endif /* _GDM_SETTINGS_KEYS_H */
|
#endif /* _GDM_SETTINGS_KEYS_H */
|
||||||
diff --git a/daemon/gdm-manager.c b/daemon/gdm-manager.c
|
diff --git a/daemon/gdm-manager.c b/daemon/gdm-manager.c
|
||||||
index 9c10adff3..b96295ab6 100644
|
index e433acf3b..ce8565bf9 100644
|
||||||
--- a/daemon/gdm-manager.c
|
--- a/daemon/gdm-manager.c
|
||||||
+++ b/daemon/gdm-manager.c
|
+++ b/daemon/gdm-manager.c
|
||||||
@@ -566,93 +566,106 @@ get_display_and_details_for_bus_sender (GdmManager *self,
|
@@ -566,93 +566,106 @@ get_display_and_details_for_bus_sender (GdmManager *self,
|
||||||
@ -297,10 +297,10 @@ index 9c10adff3..b96295ab6 100644
|
|||||||
uid,
|
uid,
|
||||||
is_remote);
|
is_remote);
|
||||||
diff --git a/data/gdm.schemas.in b/data/gdm.schemas.in
|
diff --git a/data/gdm.schemas.in b/data/gdm.schemas.in
|
||||||
index 255bff023..86059c02e 100644
|
index a1035f95e..929d13d90 100644
|
||||||
--- a/data/gdm.schemas.in
|
--- a/data/gdm.schemas.in
|
||||||
+++ b/data/gdm.schemas.in
|
+++ b/data/gdm.schemas.in
|
||||||
@@ -102,33 +102,38 @@
|
@@ -112,33 +112,38 @@
|
||||||
<schema>
|
<schema>
|
||||||
<key>xdmcp/DisplaysPerHost</key>
|
<key>xdmcp/DisplaysPerHost</key>
|
||||||
<signature>i</signature>
|
<signature>i</signature>
|
||||||
@ -340,5 +340,5 @@ index 255bff023..86059c02e 100644
|
|||||||
</gdmschemafile>
|
</gdmschemafile>
|
||||||
|
|
||||||
--
|
--
|
||||||
2.31.1
|
2.30.1
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
From 4fde9e7882e5d2e42a4ed5a0d71943d5ea966131 Mon Sep 17 00:00:00 2001
|
From 7edce4ef248af01692758caf9dbb945bdd45cb0f Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Wed, 15 Aug 2018 10:48:16 -0400
|
Date: Wed, 15 Aug 2018 10:48:16 -0400
|
||||||
Subject: [PATCH 1/5] worker: don't load user settings for program sessions
|
Subject: [PATCH 1/4] worker: don't load user settings for program sessions
|
||||||
|
|
||||||
We don't need or want the login greeter to access accountsservice
|
We don't need or want the login greeter to access accountsservice
|
||||||
for its session name
|
for its session name
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
From 81efb06506456a260d63b77e3dda1216041b5bb3 Mon Sep 17 00:00:00 2001
|
From 874b26e3674d540df37d7f145df853bcf81e5a26 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Wed, 5 Feb 2020 15:20:48 -0500
|
Date: Wed, 5 Feb 2020 15:20:48 -0500
|
||||||
Subject: [PATCH 2/3] gdm-x-session: run session bus on non-seat0 seats
|
Subject: [PATCH 2/3] gdm-x-session: run session bus on non-seat0 seats
|
||||||
@ -13,10 +13,10 @@ seats get their own session bus.
|
|||||||
1 file changed, 10 insertions(+), 1 deletion(-)
|
1 file changed, 10 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
||||||
index 5c5903a49..c891fb577 100644
|
index 418240dc0..77d6b8ff0 100644
|
||||||
--- a/daemon/gdm-session.c
|
--- a/daemon/gdm-session.c
|
||||||
+++ b/daemon/gdm-session.c
|
+++ b/daemon/gdm-session.c
|
||||||
@@ -2811,119 +2811,128 @@ on_start_program_cb (GdmDBusWorker *worker,
|
@@ -2822,119 +2822,128 @@ on_start_program_cb (GdmDBusWorker *worker,
|
||||||
if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CLOSED) ||
|
if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CLOSED) ||
|
||||||
g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
|
g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
|
||||||
return;
|
return;
|
||||||
@ -78,7 +78,7 @@ index 5c5903a49..c891fb577 100644
|
|||||||
|
|
||||||
register_session = !gdm_session_session_registers (self);
|
register_session = !gdm_session_session_registers (self);
|
||||||
|
|
||||||
+ if (g_strcmp0 (priv->display_seat_id, "seat0") != 0 && !run_launcher) {
|
+ if (g_strcmp0 (self->display_seat_id, "seat0") != 0 && !run_launcher) {
|
||||||
+ run_separate_bus = TRUE;
|
+ run_separate_bus = TRUE;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
@ -147,5 +147,5 @@ index 5c5903a49..c891fb577 100644
|
|||||||
self->selected_program);
|
self->selected_program);
|
||||||
}
|
}
|
||||||
--
|
--
|
||||||
2.31.1
|
2.30.1
|
||||||
|
|
||||||
|
131
SOURCES/0002-libgdm-Sort-session-list.patch
Normal file
131
SOURCES/0002-libgdm-Sort-session-list.patch
Normal file
@ -0,0 +1,131 @@
|
|||||||
|
From 6bdb7cf9e8ace0d9a42fd921d7192dcfece687fa Mon Sep 17 00:00:00 2001
|
||||||
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
|
Date: Tue, 20 Jul 2021 13:36:45 -0400
|
||||||
|
Subject: [PATCH 2/2] libgdm: Sort session list
|
||||||
|
|
||||||
|
Right now the session list comes out in hash table order.
|
||||||
|
|
||||||
|
This commit changes the code to sort by description.
|
||||||
|
---
|
||||||
|
libgdm/gdm-sessions.c | 19 +++++++++++++++++++
|
||||||
|
1 file changed, 19 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/libgdm/gdm-sessions.c b/libgdm/gdm-sessions.c
|
||||||
|
index 97ed5ef3d..f078e04b8 100644
|
||||||
|
--- a/libgdm/gdm-sessions.c
|
||||||
|
+++ b/libgdm/gdm-sessions.c
|
||||||
|
@@ -311,92 +311,111 @@ collect_sessions (void)
|
||||||
|
g_ptr_array_add (wayland_search_array, g_strdup (wayland_search_dirs[i]));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if (gdm_available_sessions_map == NULL) {
|
||||||
|
gdm_available_sessions_map = g_hash_table_new_full (g_str_hash, g_str_equal,
|
||||||
|
g_free, (GDestroyNotify)gdm_session_file_free);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!supported_session_types || g_strv_contains ((const char * const *) supported_session_types, "x11")) {
|
||||||
|
for (i = 0; i < xorg_search_array->len; i++) {
|
||||||
|
collect_sessions_from_directory (g_ptr_array_index (xorg_search_array, i));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef ENABLE_WAYLAND_SUPPORT
|
||||||
|
#ifdef ENABLE_USER_DISPLAY_SERVER
|
||||||
|
if (!supported_session_types || g_strv_contains ((const char * const *) supported_session_types, "wayland")) {
|
||||||
|
for (i = 0; i < wayland_search_array->len; i++) {
|
||||||
|
collect_sessions_from_directory (g_ptr_array_index (wayland_search_array, i));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
g_hash_table_foreach_remove (gdm_available_sessions_map,
|
||||||
|
remove_duplicate_sessions,
|
||||||
|
names_seen_before);
|
||||||
|
}
|
||||||
|
|
||||||
|
+static gint
|
||||||
|
+compare_session_ids (gconstpointer a,
|
||||||
|
+ gconstpointer b)
|
||||||
|
+{
|
||||||
|
+ GdmSessionFile *session_a, *session_b;
|
||||||
|
+ session_a = (GdmSessionFile *) g_hash_table_lookup (gdm_available_sessions_map, a);
|
||||||
|
+ session_b = (GdmSessionFile *) g_hash_table_lookup (gdm_available_sessions_map, b);
|
||||||
|
+
|
||||||
|
+ if (session_a == NULL)
|
||||||
|
+ return -1;
|
||||||
|
+
|
||||||
|
+ if (session_b == NULL)
|
||||||
|
+ return 1;
|
||||||
|
+
|
||||||
|
+ return g_strcmp0 (session_a->translated_name, session_b->translated_name);
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
/**
|
||||||
|
* gdm_get_session_ids:
|
||||||
|
*
|
||||||
|
* Reads /usr/share/xsessions and other relevant places for possible sessions
|
||||||
|
* to log into and returns the complete list.
|
||||||
|
*
|
||||||
|
* Returns: (transfer full): a %NULL terminated list of session ids
|
||||||
|
*/
|
||||||
|
char **
|
||||||
|
gdm_get_session_ids (void)
|
||||||
|
{
|
||||||
|
GHashTableIter iter;
|
||||||
|
gpointer key, value;
|
||||||
|
GPtrArray *array;
|
||||||
|
|
||||||
|
if (!gdm_sessions_map_is_initialized) {
|
||||||
|
collect_sessions ();
|
||||||
|
|
||||||
|
gdm_sessions_map_is_initialized = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
array = g_ptr_array_new ();
|
||||||
|
g_hash_table_iter_init (&iter, gdm_available_sessions_map);
|
||||||
|
while (g_hash_table_iter_next (&iter, &key, &value)) {
|
||||||
|
GdmSessionFile *session;
|
||||||
|
|
||||||
|
session = (GdmSessionFile *) value;
|
||||||
|
|
||||||
|
g_ptr_array_add (array, g_strdup (session->id));
|
||||||
|
}
|
||||||
|
g_ptr_array_add (array, NULL);
|
||||||
|
|
||||||
|
+ g_ptr_array_sort (array, compare_session_ids);
|
||||||
|
+
|
||||||
|
return (char **) g_ptr_array_free (array, FALSE);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* gdm_get_session_name_and_description:
|
||||||
|
* @id: an id from gdm_get_session_ids()
|
||||||
|
* @description: (out): optional returned session description
|
||||||
|
*
|
||||||
|
* Takes an xsession id and returns the name and comment about it.
|
||||||
|
*
|
||||||
|
* Returns: The session name if found, or %NULL otherwise
|
||||||
|
*/
|
||||||
|
char *
|
||||||
|
gdm_get_session_name_and_description (const char *id,
|
||||||
|
char **description)
|
||||||
|
{
|
||||||
|
GdmSessionFile *session;
|
||||||
|
char *name;
|
||||||
|
|
||||||
|
if (!gdm_sessions_map_is_initialized) {
|
||||||
|
collect_sessions ();
|
||||||
|
|
||||||
|
gdm_sessions_map_is_initialized = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
session = (GdmSessionFile *) g_hash_table_lookup (gdm_available_sessions_map,
|
||||||
|
id);
|
||||||
|
|
||||||
|
if (session == NULL) {
|
||||||
|
return NULL;
|
||||||
|
--
|
||||||
|
2.31.1
|
||||||
|
|
@ -1,7 +1,7 @@
|
|||||||
From 83cdeb662961f8910e79c56f38d9e5e296ac93be Mon Sep 17 00:00:00 2001
|
From c4716129cc3042ca9fa2ab7ee420800d85ec09db Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Tue, 14 Aug 2018 14:52:41 -0400
|
Date: Tue, 14 Aug 2018 14:52:41 -0400
|
||||||
Subject: [PATCH 2/5] session: support new accountsservice Session and
|
Subject: [PATCH 2/4] session: support new accountsservice Session and
|
||||||
SessionType props
|
SessionType props
|
||||||
|
|
||||||
At the moment the user's session is stored in a property called
|
At the moment the user's session is stored in a property called
|
||||||
@ -305,9 +305,9 @@ index 484a3b5b4..5b64cb65b 100644
|
|||||||
|
|
||||||
- session_name = act_user_get_x_session (settings->priv->user);
|
- session_name = act_user_get_x_session (settings->priv->user);
|
||||||
- g_debug ("GdmSessionSettings: saved session is %s", session_name);
|
- g_debug ("GdmSessionSettings: saved session is %s", session_name);
|
||||||
+ /* if the user doesn't have saved state, they don't have any settings worth reading */
|
+
|
||||||
+ if (!act_user_get_saved (settings->priv->user))
|
+
|
||||||
+ goto out;
|
+
|
||||||
+
|
+
|
||||||
+ session_type = act_user_get_session_type (settings->priv->user);
|
+ session_type = act_user_get_session_type (settings->priv->user);
|
||||||
+ session_name = act_user_get_session (settings->priv->user);
|
+ session_name = act_user_get_session (settings->priv->user);
|
||||||
@ -754,7 +754,7 @@ index 4280fe095..a215779c8 100644
|
|||||||
</interface>
|
</interface>
|
||||||
</node>
|
</node>
|
||||||
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
||||||
index d95cef905..2d471ec46 100644
|
index 6e6326243..73ae5cbc5 100644
|
||||||
--- a/daemon/gdm-session.c
|
--- a/daemon/gdm-session.c
|
||||||
+++ b/daemon/gdm-session.c
|
+++ b/daemon/gdm-session.c
|
||||||
@@ -61,60 +61,61 @@
|
@@ -61,60 +61,61 @@
|
||||||
@ -819,25 +819,14 @@ index d95cef905..2d471ec46 100644
|
|||||||
char *display_name;
|
char *display_name;
|
||||||
char *display_hostname;
|
char *display_hostname;
|
||||||
char *display_device;
|
char *display_device;
|
||||||
@@ -319,312 +320,328 @@ on_establish_credentials_cb (GdmDBusWorker *proxy,
|
@@ -328,309 +329,325 @@ on_establish_credentials_cb (GdmDBusWorker *proxy,
|
||||||
return;
|
case GDM_SESSION_VERIFICATION_MODE_REAUTHENTICATE:
|
||||||
|
|
||||||
self = g_object_ref (conversation->session);
|
|
||||||
service_name = g_strdup (conversation->service_name);
|
|
||||||
|
|
||||||
if (worked) {
|
|
||||||
if (self->user_verifier_interface != NULL) {
|
if (self->user_verifier_interface != NULL) {
|
||||||
gdm_dbus_user_verifier_emit_verification_complete (self->user_verifier_interface,
|
gdm_dbus_user_verifier_emit_verification_complete (self->user_verifier_interface,
|
||||||
service_name);
|
service_name);
|
||||||
g_signal_emit (self, signals[VERIFICATION_COMPLETE], 0, service_name);
|
g_signal_emit (self, signals[VERIFICATION_COMPLETE], 0, service_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (self->verification_mode) {
|
|
||||||
case GDM_SESSION_VERIFICATION_MODE_LOGIN:
|
|
||||||
case GDM_SESSION_VERIFICATION_MODE_CHOOSER:
|
|
||||||
gdm_session_open_session (self, service_name);
|
|
||||||
break;
|
break;
|
||||||
case GDM_SESSION_VERIFICATION_MODE_REAUTHENTICATE:
|
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -849,6 +838,17 @@ index d95cef905..2d471ec46 100644
|
|||||||
g_object_unref (self);
|
g_object_unref (self);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
supports_session_type (GdmSession *self,
|
||||||
|
const char *session_type)
|
||||||
|
{
|
||||||
|
if (session_type == NULL)
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
|
return g_strv_contains ((const char * const *) self->supported_session_types,
|
||||||
|
session_type);
|
||||||
|
}
|
||||||
|
|
||||||
static char **
|
static char **
|
||||||
-get_system_session_dirs (GdmSession *self)
|
-get_system_session_dirs (GdmSession *self)
|
||||||
+get_system_session_dirs (GdmSession *self,
|
+get_system_session_dirs (GdmSession *self,
|
||||||
@ -856,7 +856,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
{
|
{
|
||||||
GArray *search_array = NULL;
|
GArray *search_array = NULL;
|
||||||
char **search_dirs;
|
char **search_dirs;
|
||||||
int i;
|
int i, j;
|
||||||
const gchar * const *system_data_dirs = g_get_system_data_dirs ();
|
const gchar * const *system_data_dirs = g_get_system_data_dirs ();
|
||||||
|
|
||||||
static const char *x_search_dirs[] = {
|
static const char *x_search_dirs[] = {
|
||||||
@ -870,40 +870,33 @@ index d95cef905..2d471ec46 100644
|
|||||||
|
|
||||||
search_array = g_array_new (TRUE, TRUE, sizeof (char *));
|
search_array = g_array_new (TRUE, TRUE, sizeof (char *));
|
||||||
|
|
||||||
- for (i = 0; system_data_dirs[i]; i++) {
|
for (j = 0; self->supported_session_types[j] != NULL; j++) {
|
||||||
- gchar *dir = g_build_filename (system_data_dirs[i], "xsessions", NULL);
|
const char *supported_type = self->supported_session_types[j];
|
||||||
- g_array_append_val (search_array, dir);
|
|
||||||
- }
|
|
||||||
+ if (type == NULL || strcmp (type, "x11") == 0) {
|
|
||||||
+ for (i = 0; system_data_dirs[i]; i++) {
|
|
||||||
+ gchar *dir = g_build_filename (system_data_dirs[i], "xsessions", NULL);
|
|
||||||
+ g_array_append_val (search_array, dir);
|
|
||||||
+ }
|
|
||||||
|
|
||||||
- g_array_append_vals (search_array, x_search_dirs, G_N_ELEMENTS (x_search_dirs));
|
- if (g_str_equal (supported_type, "x11")) {
|
||||||
+ g_array_append_vals (search_array, x_search_dirs, G_N_ELEMENTS (x_search_dirs));
|
+ if (g_str_equal (supported_type, "x11") ||
|
||||||
+ }
|
+ (type == NULL || g_str_equal (type, supported_type))) {
|
||||||
|
for (i = 0; system_data_dirs[i]; i++) {
|
||||||
|
gchar *dir = g_build_filename (system_data_dirs[i], "xsessions", NULL);
|
||||||
|
g_array_append_val (search_array, dir);
|
||||||
|
}
|
||||||
|
|
||||||
|
g_array_append_vals (search_array, x_search_dirs, G_N_ELEMENTS (x_search_dirs));
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef ENABLE_WAYLAND_SUPPORT
|
#ifdef ENABLE_WAYLAND_SUPPORT
|
||||||
- if (!self->ignore_wayland) {
|
- if (g_str_equal (supported_type, "wayland")) {
|
||||||
+ if ((!self->ignore_wayland && type == NULL) || g_strcmp0 (type, "wayland") == 0) {
|
+ if (g_str_equal (supported_type, "wayland") ||
|
||||||
#ifdef ENABLE_USER_DISPLAY_SERVER
|
+ (type == NULL || g_str_equal (type, supported_type))) {
|
||||||
g_array_prepend_val (search_array, wayland_search_dir);
|
|
||||||
|
|
||||||
for (i = 0; system_data_dirs[i]; i++) {
|
|
||||||
gchar *dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
|
|
||||||
g_array_insert_val (search_array, i, dir);
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
for (i = 0; system_data_dirs[i]; i++) {
|
for (i = 0; system_data_dirs[i]; i++) {
|
||||||
gchar *dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
|
gchar *dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
|
||||||
g_array_append_val (search_array, dir);
|
g_array_append_val (search_array, dir);
|
||||||
}
|
}
|
||||||
|
|
||||||
g_array_append_val (search_array, wayland_search_dir);
|
g_array_append_val (search_array, wayland_search_dir);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
search_dirs = g_strdupv ((char **) search_array->data);
|
search_dirs = g_strdupv ((char **) search_array->data);
|
||||||
|
|
||||||
@ -983,9 +976,9 @@ index d95cef905..2d471ec46 100644
|
|||||||
*command = NULL;
|
*command = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
+ if (self->ignore_wayland && g_strcmp0 (type, "wayland") == 0) {
|
+ if (!supports_session_type (self, type)) {
|
||||||
+ g_debug ("GdmSession: ignoring wayland session command request for file '%s'",
|
+ g_debug ("GdmSession: ignoring %s session command request for file '%s'",
|
||||||
+ file);
|
+ type, file);
|
||||||
+ goto out;
|
+ goto out;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
@ -1165,7 +1158,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
|
|
||||||
out:
|
out:
|
||||||
return self->fallback_session_name;
|
return self->fallback_session_name;
|
||||||
@@ -643,60 +660,63 @@ get_default_session_name (GdmSession *self)
|
@@ -649,60 +666,63 @@ get_default_session_name (GdmSession *self)
|
||||||
static void
|
static void
|
||||||
gdm_session_defaults_changed (GdmSession *self)
|
gdm_session_defaults_changed (GdmSession *self)
|
||||||
{
|
{
|
||||||
@ -1229,7 +1222,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
|
|
||||||
static void
|
static void
|
||||||
set_pending_query (GdmSessionConversation *conversation,
|
set_pending_query (GdmSessionConversation *conversation,
|
||||||
@@ -963,80 +983,91 @@ worker_on_reauthenticated (GdmDBusWorker *worker,
|
@@ -969,80 +989,91 @@ worker_on_reauthenticated (GdmDBusWorker *worker,
|
||||||
GdmSession *self = conversation->session;
|
GdmSession *self = conversation->session;
|
||||||
g_debug ("GdmSession: Emitting 'reauthenticated' signal ");
|
g_debug ("GdmSession: Emitting 'reauthenticated' signal ");
|
||||||
g_signal_emit (self, signals[REAUTHENTICATED], 0, service_name);
|
g_signal_emit (self, signals[REAUTHENTICATED], 0, service_name);
|
||||||
@ -1322,7 +1315,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
uid_t connecting_user;
|
uid_t connecting_user;
|
||||||
|
|
||||||
connecting_user = g_credentials_get_unix_user (credentials, NULL);
|
connecting_user = g_credentials_get_unix_user (credentials, NULL);
|
||||||
@@ -1116,60 +1147,63 @@ register_worker (GdmDBusWorkerManager *worker_manager_interface,
|
@@ -1122,60 +1153,63 @@ register_worker (GdmDBusWorkerManager *worker_manager_interface,
|
||||||
g_dbus_method_invocation_return_value (invocation, NULL);
|
g_dbus_method_invocation_return_value (invocation, NULL);
|
||||||
|
|
||||||
conversation->worker_proxy = gdm_dbus_worker_proxy_new_sync (connection,
|
conversation->worker_proxy = gdm_dbus_worker_proxy_new_sync (connection,
|
||||||
@ -1386,7 +1379,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
g_debug ("GdmSession: Conversation started");
|
g_debug ("GdmSession: Conversation started");
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@@ -1912,60 +1946,63 @@ free_conversation (GdmSessionConversation *conversation)
|
@@ -1918,60 +1952,63 @@ free_conversation (GdmSessionConversation *conversation)
|
||||||
close_conversation (conversation);
|
close_conversation (conversation);
|
||||||
|
|
||||||
if (conversation->job != NULL) {
|
if (conversation->job != NULL) {
|
||||||
@ -1450,7 +1443,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
error = NULL;
|
error = NULL;
|
||||||
if (!g_file_get_contents (config_file, &contents, &length, &error)) {
|
if (!g_file_get_contents (config_file, &contents, &length, &error)) {
|
||||||
g_debug ("Failed to parse '%s': %s",
|
g_debug ("Failed to parse '%s': %s",
|
||||||
@@ -2520,83 +2557,83 @@ gdm_session_send_environment (GdmSession *self,
|
@@ -2530,83 +2567,83 @@ gdm_session_send_environment (GdmSession *self,
|
||||||
g_return_if_fail (GDM_IS_SESSION (self));
|
g_return_if_fail (GDM_IS_SESSION (self));
|
||||||
|
|
||||||
conversation = find_conversation_by_name (self, service_name);
|
conversation = find_conversation_by_name (self, service_name);
|
||||||
@ -1536,8 +1529,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
g_strdup (value));
|
g_strdup (value));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3165,85 +3202,87 @@ gdm_session_get_conversation_session_id (GdmSession *self,
|
@@ -3176,148 +3213,150 @@ gdm_session_get_conversation_session_id (GdmSession *self,
|
||||||
|
|
||||||
conversation = find_conversation_by_name (self, service_name);
|
conversation = find_conversation_by_name (self, service_name);
|
||||||
|
|
||||||
if (conversation == NULL) {
|
if (conversation == NULL) {
|
||||||
@ -1567,11 +1559,16 @@ index d95cef905..2d471ec46 100644
|
|||||||
|
|
||||||
filename = get_session_filename (self);
|
filename = get_session_filename (self);
|
||||||
|
|
||||||
|
if (supports_session_type (self, "wayland")) {
|
||||||
- key_file = load_key_file_for_file (self, filename, &full_path);
|
- key_file = load_key_file_for_file (self, filename, &full_path);
|
||||||
+ key_file = load_key_file_for_file (self, filename, "wayland", &full_path);
|
+ key_file = load_key_file_for_file (self, filename, NULL, &full_path);
|
||||||
|
|
||||||
if (key_file == NULL) {
|
- if (key_file == NULL) {
|
||||||
goto out;
|
- goto out;
|
||||||
|
- }
|
||||||
|
+ if (key_file == NULL) {
|
||||||
|
+ goto out;
|
||||||
|
+ }
|
||||||
}
|
}
|
||||||
|
|
||||||
if (full_path != NULL && strstr (full_path, "/wayland-sessions/") != NULL) {
|
if (full_path != NULL && strstr (full_path, "/wayland-sessions/") != NULL) {
|
||||||
@ -1593,7 +1590,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
- gboolean is_wayland_session;
|
- gboolean is_wayland_session;
|
||||||
+ gboolean is_wayland_session = FALSE;
|
+ gboolean is_wayland_session = FALSE;
|
||||||
+
|
+
|
||||||
+ if (!self->ignore_wayland)
|
+ if (supports_session_type (self, "wayland"))
|
||||||
+ is_wayland_session = gdm_session_is_wayland_session (self);
|
+ is_wayland_session = gdm_session_is_wayland_session (self);
|
||||||
|
|
||||||
- is_wayland_session = gdm_session_is_wayland_session (self);
|
- is_wayland_session = gdm_session_is_wayland_session (self);
|
||||||
@ -1618,7 +1615,8 @@ index d95cef905..2d471ec46 100644
|
|||||||
|
|
||||||
filename = get_session_filename (self);
|
filename = get_session_filename (self);
|
||||||
|
|
||||||
key_file = load_key_file_for_file (self, filename, NULL);
|
- key_file = load_key_file_for_file (self, filename, NULL);
|
||||||
|
+ key_file = load_key_file_for_file (self, filename, NULL, NULL);
|
||||||
|
|
||||||
session_registers = g_key_file_get_boolean (key_file,
|
session_registers = g_key_file_get_boolean (key_file,
|
||||||
G_KEY_FILE_DESKTOP_GROUP,
|
G_KEY_FILE_DESKTOP_GROUP,
|
||||||
@ -1627,7 +1625,7 @@ index d95cef905..2d471ec46 100644
|
|||||||
if (!session_registers &&
|
if (!session_registers &&
|
||||||
error != NULL &&
|
error != NULL &&
|
||||||
!g_error_matches (error, G_KEY_FILE_ERROR, G_KEY_FILE_ERROR_KEY_NOT_FOUND)) {
|
!g_error_matches (error, G_KEY_FILE_ERROR, G_KEY_FILE_ERROR_KEY_NOT_FOUND)) {
|
||||||
@@ -3251,61 +3290,61 @@ gdm_session_session_registers (GdmSession *self)
|
g_warning ("GdmSession: Couldn't read session file '%s'", filename);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
From 35e2d1d298607c3fdb2cbbfb1cf878dc9cbbf546 Mon Sep 17 00:00:00 2001
|
From 09e4f57ea2525e48bd22a34cb0c9b917ce7565df Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Mon, 20 Aug 2018 14:30:59 -0400
|
Date: Mon, 20 Aug 2018 14:30:59 -0400
|
||||||
Subject: [PATCH 3/5] daemon: save os-release in accountsservice
|
Subject: [PATCH 3/4] daemon: save os-release in accountsservice
|
||||||
|
|
||||||
It can be useful to know what OS a user was running
|
It can be useful to know what OS a user was running
|
||||||
when they logged in (to detect upgrades).
|
when they logged in (to detect upgrades).
|
||||||
@ -10,8 +10,9 @@ This commit saves that information in accountsservice.
|
|||||||
---
|
---
|
||||||
.../com.redhat.AccountsServiceUser.System.xml | 10 ++
|
.../com.redhat.AccountsServiceUser.System.xml | 10 ++
|
||||||
daemon/gdm-session-settings.c | 98 +++++++++++++++++++
|
daemon/gdm-session-settings.c | 98 +++++++++++++++++++
|
||||||
|
daemon/gdm-session.c | 4 +-
|
||||||
daemon/meson.build | 8 ++
|
daemon/meson.build | 8 ++
|
||||||
3 files changed, 116 insertions(+)
|
4 files changed, 118 insertions(+), 2 deletions(-)
|
||||||
create mode 100644 daemon/com.redhat.AccountsServiceUser.System.xml
|
create mode 100644 daemon/com.redhat.AccountsServiceUser.System.xml
|
||||||
|
|
||||||
diff --git a/daemon/com.redhat.AccountsServiceUser.System.xml b/daemon/com.redhat.AccountsServiceUser.System.xml
|
diff --git a/daemon/com.redhat.AccountsServiceUser.System.xml b/daemon/com.redhat.AccountsServiceUser.System.xml
|
||||||
@ -232,9 +233,9 @@ index 5b64cb65b..5bcfdc14f 100644
|
|||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
/* if the user doesn't have saved state, they don't have any settings worth reading */
|
|
||||||
if (!act_user_get_saved (settings->priv->user))
|
|
||||||
goto out;
|
|
||||||
|
|
||||||
session_type = act_user_get_session_type (settings->priv->user);
|
session_type = act_user_get_session_type (settings->priv->user);
|
||||||
session_name = act_user_get_session (settings->priv->user);
|
session_name = act_user_get_session (settings->priv->user);
|
||||||
@ -399,6 +400,85 @@ index 5b64cb65b..5bcfdc14f 100644
|
|||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
||||||
|
index 73ae5cbc5..ce6df14c6 100644
|
||||||
|
--- a/daemon/gdm-session.c
|
||||||
|
+++ b/daemon/gdm-session.c
|
||||||
|
@@ -351,72 +351,72 @@ supports_session_type (GdmSession *self,
|
||||||
|
if (session_type == NULL)
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
|
return g_strv_contains ((const char * const *) self->supported_session_types,
|
||||||
|
session_type);
|
||||||
|
}
|
||||||
|
|
||||||
|
static char **
|
||||||
|
get_system_session_dirs (GdmSession *self,
|
||||||
|
const char *type)
|
||||||
|
{
|
||||||
|
GArray *search_array = NULL;
|
||||||
|
char **search_dirs;
|
||||||
|
int i, j;
|
||||||
|
const gchar * const *system_data_dirs = g_get_system_data_dirs ();
|
||||||
|
|
||||||
|
static const char *x_search_dirs[] = {
|
||||||
|
"/etc/X11/sessions/",
|
||||||
|
DMCONFDIR "/Sessions/",
|
||||||
|
DATADIR "/gdm/BuiltInSessions/",
|
||||||
|
DATADIR "/xsessions/",
|
||||||
|
};
|
||||||
|
|
||||||
|
static const char *wayland_search_dir = DATADIR "/wayland-sessions/";
|
||||||
|
|
||||||
|
search_array = g_array_new (TRUE, TRUE, sizeof (char *));
|
||||||
|
|
||||||
|
for (j = 0; self->supported_session_types[j] != NULL; j++) {
|
||||||
|
const char *supported_type = self->supported_session_types[j];
|
||||||
|
|
||||||
|
- if (g_str_equal (supported_type, "x11") ||
|
||||||
|
+ if (g_str_equal (supported_type, "x11") &&
|
||||||
|
(type == NULL || g_str_equal (type, supported_type))) {
|
||||||
|
for (i = 0; system_data_dirs[i]; i++) {
|
||||||
|
gchar *dir = g_build_filename (system_data_dirs[i], "xsessions", NULL);
|
||||||
|
g_array_append_val (search_array, dir);
|
||||||
|
}
|
||||||
|
|
||||||
|
g_array_append_vals (search_array, x_search_dirs, G_N_ELEMENTS (x_search_dirs));
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef ENABLE_WAYLAND_SUPPORT
|
||||||
|
- if (g_str_equal (supported_type, "wayland") ||
|
||||||
|
+ if (g_str_equal (supported_type, "wayland") &&
|
||||||
|
(type == NULL || g_str_equal (type, supported_type))) {
|
||||||
|
for (i = 0; system_data_dirs[i]; i++) {
|
||||||
|
gchar *dir = g_build_filename (system_data_dirs[i], "wayland-sessions", NULL);
|
||||||
|
g_array_append_val (search_array, dir);
|
||||||
|
}
|
||||||
|
|
||||||
|
g_array_append_val (search_array, wayland_search_dir);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
search_dirs = g_strdupv ((char **) search_array->data);
|
||||||
|
|
||||||
|
g_array_free (search_array, TRUE);
|
||||||
|
|
||||||
|
return search_dirs;
|
||||||
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
is_prog_in_path (const char *prog)
|
||||||
|
{
|
||||||
|
char *f;
|
||||||
|
gboolean ret;
|
||||||
|
|
||||||
|
f = g_find_program_in_path (prog);
|
||||||
|
ret = (f != NULL);
|
||||||
|
g_free (f);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
diff --git a/daemon/meson.build b/daemon/meson.build
|
diff --git a/daemon/meson.build b/daemon/meson.build
|
||||||
index 2e61b6447..71c650398 100644
|
index 2e61b6447..71c650398 100644
|
||||||
--- a/daemon/meson.build
|
--- a/daemon/meson.build
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
From 9a2de416bc13fc40a6d7f2e4e6cb9cf64be2854f Mon Sep 17 00:00:00 2001
|
From 64e8db8432158e5115df18a03bb87ecc1d58ae63 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Mon, 11 Feb 2019 10:32:55 -0500
|
Date: Mon, 11 Feb 2019 10:32:55 -0500
|
||||||
Subject: [PATCH 3/3] session: ensure login screen over XDMCP connects to its
|
Subject: [PATCH 3/3] session: ensure login screen over XDMCP connects to its
|
||||||
@ -17,10 +17,10 @@ the session is X11.
|
|||||||
1 file changed, 19 insertions(+)
|
1 file changed, 19 insertions(+)
|
||||||
|
|
||||||
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
||||||
index c891fb577..d95cef905 100644
|
index 77d6b8ff0..357e4a297 100644
|
||||||
--- a/daemon/gdm-session.c
|
--- a/daemon/gdm-session.c
|
||||||
+++ b/daemon/gdm-session.c
|
+++ b/daemon/gdm-session.c
|
||||||
@@ -2686,60 +2686,79 @@ set_up_session_environment (GdmSession *self)
|
@@ -2697,60 +2697,79 @@ set_up_session_environment (GdmSession *self)
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@ -101,5 +101,5 @@ index c891fb577..d95cef905 100644
|
|||||||
gpointer key, value;
|
gpointer key, value;
|
||||||
|
|
||||||
--
|
--
|
||||||
2.31.1
|
2.30.1
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
From 234fdc6e4bd4d4c19fefba27495db5bdc9642217 Mon Sep 17 00:00:00 2001
|
From de103948b84188cd2273c9aab904a633323a9479 Mon Sep 17 00:00:00 2001
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
From: Ray Strode <rstrode@redhat.com>
|
||||||
Date: Mon, 20 Aug 2018 14:30:59 -0400
|
Date: Mon, 20 Aug 2018 14:30:59 -0400
|
||||||
Subject: [PATCH 4/5] daemon: handle upgrades from RHEL 7
|
Subject: [PATCH 4/4] daemon: handle upgrades from RHEL 7
|
||||||
|
|
||||||
RHEL 7 users need to stay on X if they were using X,
|
RHEL 7 users need to stay on X if they were using X,
|
||||||
and they need to stay on gnome-classic if they were using
|
and they need to stay on gnome-classic if they were using
|
||||||
@ -12,7 +12,8 @@ or not they were using RHEL 7 and in the event they were
|
|||||||
try to get the right settings.
|
try to get the right settings.
|
||||||
---
|
---
|
||||||
daemon/gdm-session-settings.c | 19 +++++++++++++++++++
|
daemon/gdm-session-settings.c | 19 +++++++++++++++++++
|
||||||
1 file changed, 19 insertions(+)
|
daemon/gdm-session.c | 19 ++++++++-----------
|
||||||
|
2 files changed, 27 insertions(+), 11 deletions(-)
|
||||||
|
|
||||||
diff --git a/daemon/gdm-session-settings.c b/daemon/gdm-session-settings.c
|
diff --git a/daemon/gdm-session-settings.c b/daemon/gdm-session-settings.c
|
||||||
index 5bcfdc14f..a7eaa8b2f 100644
|
index 5bcfdc14f..a7eaa8b2f 100644
|
||||||
@ -79,9 +80,9 @@ index 5bcfdc14f..a7eaa8b2f 100644
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* if the user doesn't have saved state, they don't have any settings worth reading */
|
|
||||||
if (!act_user_get_saved (settings->priv->user))
|
|
||||||
goto out;
|
|
||||||
|
|
||||||
session_type = act_user_get_session_type (settings->priv->user);
|
session_type = act_user_get_session_type (settings->priv->user);
|
||||||
session_name = act_user_get_session (settings->priv->user);
|
session_name = act_user_get_session (settings->priv->user);
|
||||||
@ -133,6 +134,117 @@ index 5bcfdc14f..a7eaa8b2f 100644
|
|||||||
G_CALLBACK (on_user_is_loaded_changed),
|
G_CALLBACK (on_user_is_loaded_changed),
|
||||||
settings);
|
settings);
|
||||||
}
|
}
|
||||||
|
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
||||||
|
index ce6df14c6..6bda6d6e2 100644
|
||||||
|
--- a/daemon/gdm-session.c
|
||||||
|
+++ b/daemon/gdm-session.c
|
||||||
|
@@ -3202,98 +3202,95 @@ gdm_session_get_session_id (GdmSession *self)
|
||||||
|
return conversation->session_id;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char *
|
||||||
|
gdm_session_get_conversation_session_id (GdmSession *self,
|
||||||
|
const char *service_name)
|
||||||
|
{
|
||||||
|
GdmSessionConversation *conversation;
|
||||||
|
|
||||||
|
g_return_val_if_fail (GDM_IS_SESSION (self), NULL);
|
||||||
|
|
||||||
|
conversation = find_conversation_by_name (self, service_name);
|
||||||
|
|
||||||
|
if (conversation == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
return conversation->session_id;
|
||||||
|
}
|
||||||
|
|
||||||
|
static char *
|
||||||
|
get_session_filename (GdmSession *self)
|
||||||
|
{
|
||||||
|
return g_strdup_printf ("%s.desktop", get_session_name (self));
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef ENABLE_WAYLAND_SUPPORT
|
||||||
|
static gboolean
|
||||||
|
gdm_session_is_wayland_session (GdmSession *self)
|
||||||
|
{
|
||||||
|
- GKeyFile *key_file;
|
||||||
|
+ g_autoptr (GKeyFile) key_file = NULL;
|
||||||
|
gboolean is_wayland_session = FALSE;
|
||||||
|
- char *filename;
|
||||||
|
- char *full_path = NULL;
|
||||||
|
+ g_autofree char *filename = NULL;
|
||||||
|
+ g_autofree char *full_path = NULL;
|
||||||
|
|
||||||
|
g_return_val_if_fail (self != NULL, FALSE);
|
||||||
|
g_return_val_if_fail (GDM_IS_SESSION (self), FALSE);
|
||||||
|
|
||||||
|
filename = get_session_filename (self);
|
||||||
|
|
||||||
|
if (supports_session_type (self, "wayland")) {
|
||||||
|
key_file = load_key_file_for_file (self, filename, NULL, &full_path);
|
||||||
|
|
||||||
|
if (key_file == NULL) {
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
- }
|
||||||
|
|
||||||
|
- if (full_path != NULL && strstr (full_path, "/wayland-sessions/") != NULL) {
|
||||||
|
- is_wayland_session = TRUE;
|
||||||
|
+ if (full_path != NULL && strstr (full_path, "/wayland-sessions/") != NULL) {
|
||||||
|
+ is_wayland_session = TRUE;
|
||||||
|
+ }
|
||||||
|
}
|
||||||
|
- g_debug ("GdmSession: checking if file '%s' is wayland session: %s", filename, is_wayland_session? "yes" : "no");
|
||||||
|
|
||||||
|
out:
|
||||||
|
- g_clear_pointer (&key_file, g_key_file_free);
|
||||||
|
- g_free (filename);
|
||||||
|
+ g_debug ("GdmSession: checking if file '%s' is wayland session: %s", filename, is_wayland_session? "yes" : "no");
|
||||||
|
return is_wayland_session;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
static void
|
||||||
|
update_session_type (GdmSession *self)
|
||||||
|
{
|
||||||
|
#ifdef ENABLE_WAYLAND_SUPPORT
|
||||||
|
gboolean is_wayland_session = FALSE;
|
||||||
|
|
||||||
|
- if (supports_session_type (self, "wayland"))
|
||||||
|
- is_wayland_session = gdm_session_is_wayland_session (self);
|
||||||
|
+ is_wayland_session = gdm_session_is_wayland_session (self);
|
||||||
|
|
||||||
|
if (is_wayland_session) {
|
||||||
|
set_session_type (self, "wayland");
|
||||||
|
} else {
|
||||||
|
set_session_type (self, NULL);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
gboolean
|
||||||
|
gdm_session_session_registers (GdmSession *self)
|
||||||
|
{
|
||||||
|
g_autoptr(GError) error = NULL;
|
||||||
|
g_autoptr(GKeyFile) key_file = NULL;
|
||||||
|
gboolean session_registers = FALSE;
|
||||||
|
g_autofree char *filename = NULL;
|
||||||
|
|
||||||
|
g_return_val_if_fail (self != NULL, FALSE);
|
||||||
|
g_return_val_if_fail (GDM_IS_SESSION (self), FALSE);
|
||||||
|
|
||||||
|
filename = get_session_filename (self);
|
||||||
|
|
||||||
|
key_file = load_key_file_for_file (self, filename, NULL, NULL);
|
||||||
|
|
||||||
|
session_registers = g_key_file_get_boolean (key_file,
|
||||||
|
G_KEY_FILE_DESKTOP_GROUP,
|
||||||
|
"X-GDM-SessionRegisters",
|
||||||
|
&error);
|
||||||
|
if (!session_registers &&
|
||||||
|
error != NULL &&
|
||||||
--
|
--
|
||||||
2.31.1
|
2.31.1
|
||||||
|
|
||||||
|
@ -1,221 +0,0 @@
|
|||||||
From 4862efc8bb38e97a785bd9c368d9b701c2acba68 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ray Strode <rstrode@redhat.com>
|
|
||||||
Date: Sun, 15 Dec 2019 14:51:44 -0500
|
|
||||||
Subject: [PATCH 5/5] daemon: fix wayland detection when deciding to bypass
|
|
||||||
Xsession
|
|
||||||
|
|
||||||
At the moment if there's a session file with the same name in
|
|
||||||
both /usr/share/xsessions and /usr/share/wayland-sessions, GDM
|
|
||||||
will think the wayland is getting used when deciding whether or
|
|
||||||
not to bypass the /etc/gdm/Xsession script, even if wayland is
|
|
||||||
explicitly being ignored.
|
|
||||||
|
|
||||||
This commit fixes the check.
|
|
||||||
---
|
|
||||||
daemon/gdm-session.c | 31 +++++++++++++++----------------
|
|
||||||
1 file changed, 15 insertions(+), 16 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
|
|
||||||
index 2d471ec46..38a32fdab 100644
|
|
||||||
--- a/daemon/gdm-session.c
|
|
||||||
+++ b/daemon/gdm-session.c
|
|
||||||
@@ -2898,61 +2898,61 @@ gdm_session_start_session (GdmSession *self,
|
|
||||||
char *command;
|
|
||||||
char *program;
|
|
||||||
gboolean register_session;
|
|
||||||
|
|
||||||
g_return_if_fail (GDM_IS_SESSION (self));
|
|
||||||
g_return_if_fail (self->session_conversation == NULL);
|
|
||||||
|
|
||||||
conversation = find_conversation_by_name (self, service_name);
|
|
||||||
|
|
||||||
if (conversation == NULL) {
|
|
||||||
g_warning ("GdmSession: Tried to start session of "
|
|
||||||
"nonexistent conversation %s", service_name);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
stop_all_other_conversations (self, conversation, FALSE);
|
|
||||||
|
|
||||||
display_mode = gdm_session_get_display_mode (self);
|
|
||||||
|
|
||||||
#ifdef ENABLE_WAYLAND_SUPPORT
|
|
||||||
is_x11 = g_strcmp0 (self->session_type, "wayland") != 0;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (display_mode == GDM_SESSION_DISPLAY_MODE_LOGIND_MANAGED ||
|
|
||||||
display_mode == GDM_SESSION_DISPLAY_MODE_NEW_VT) {
|
|
||||||
run_launcher = TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
register_session = !gdm_session_session_registers (self);
|
|
||||||
|
|
||||||
- if (g_strcmp0 (priv->display_seat_id, "seat0") != 0 && !run_launcher) {
|
|
||||||
+ if (g_strcmp0 (self->display_seat_id, "seat0") != 0 && !run_launcher) {
|
|
||||||
run_separate_bus = TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (self->selected_program == NULL) {
|
|
||||||
gboolean run_xsession_script;
|
|
||||||
|
|
||||||
command = get_session_command (self);
|
|
||||||
|
|
||||||
run_xsession_script = !gdm_session_bypasses_xsession (self);
|
|
||||||
|
|
||||||
if (self->display_is_local) {
|
|
||||||
gboolean disallow_tcp = TRUE;
|
|
||||||
gdm_settings_direct_get_boolean (GDM_KEY_DISALLOW_TCP, &disallow_tcp);
|
|
||||||
allow_remote_connections = !disallow_tcp;
|
|
||||||
} else {
|
|
||||||
allow_remote_connections = TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (run_launcher) {
|
|
||||||
if (is_x11) {
|
|
||||||
program = g_strdup_printf (LIBEXECDIR "/gdm-x-session %s%s %s\"%s\"",
|
|
||||||
register_session ? "--register-session " : "",
|
|
||||||
run_xsession_script? "--run-script " : "",
|
|
||||||
allow_remote_connections? "--allow-remote-connections " : "",
|
|
||||||
command);
|
|
||||||
} else {
|
|
||||||
program = g_strdup_printf (LIBEXECDIR "/gdm-wayland-session %s\"%s\"",
|
|
||||||
register_session ? "--register-session " : "",
|
|
||||||
command);
|
|
||||||
}
|
|
||||||
@@ -3192,119 +3192,118 @@ gdm_session_get_session_id (GdmSession *self)
|
|
||||||
return conversation->session_id;
|
|
||||||
}
|
|
||||||
|
|
||||||
const char *
|
|
||||||
gdm_session_get_conversation_session_id (GdmSession *self,
|
|
||||||
const char *service_name)
|
|
||||||
{
|
|
||||||
GdmSessionConversation *conversation;
|
|
||||||
|
|
||||||
g_return_val_if_fail (GDM_IS_SESSION (self), NULL);
|
|
||||||
|
|
||||||
conversation = find_conversation_by_name (self, service_name);
|
|
||||||
|
|
||||||
if (conversation == NULL) {
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
return conversation->session_id;
|
|
||||||
}
|
|
||||||
|
|
||||||
static char *
|
|
||||||
get_session_filename (GdmSession *self)
|
|
||||||
{
|
|
||||||
return g_strdup_printf ("%s.desktop", get_session_name (self));
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef ENABLE_WAYLAND_SUPPORT
|
|
||||||
static gboolean
|
|
||||||
gdm_session_is_wayland_session (GdmSession *self)
|
|
||||||
{
|
|
||||||
- GKeyFile *key_file;
|
|
||||||
+ g_autoptr (GKeyFile) key_file = NULL;
|
|
||||||
gboolean is_wayland_session = FALSE;
|
|
||||||
- char *filename;
|
|
||||||
- char *full_path = NULL;
|
|
||||||
+ g_autofree char *filename = NULL;
|
|
||||||
+ g_autofree char *full_path = NULL;
|
|
||||||
|
|
||||||
g_return_val_if_fail (self != NULL, FALSE);
|
|
||||||
g_return_val_if_fail (GDM_IS_SESSION (self), FALSE);
|
|
||||||
|
|
||||||
filename = get_session_filename (self);
|
|
||||||
|
|
||||||
- key_file = load_key_file_for_file (self, filename, "wayland", &full_path);
|
|
||||||
+ if (!self->ignore_wayland) {
|
|
||||||
+ key_file = load_key_file_for_file (self, filename, "wayland", &full_path);
|
|
||||||
|
|
||||||
- if (key_file == NULL) {
|
|
||||||
- goto out;
|
|
||||||
- }
|
|
||||||
+ if (key_file == NULL) {
|
|
||||||
+ goto out;
|
|
||||||
+ }
|
|
||||||
|
|
||||||
- if (full_path != NULL && strstr (full_path, "/wayland-sessions/") != NULL) {
|
|
||||||
- is_wayland_session = TRUE;
|
|
||||||
+ if (full_path != NULL && strstr (full_path, "/wayland-sessions/") != NULL) {
|
|
||||||
+ is_wayland_session = TRUE;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
- g_debug ("GdmSession: checking if file '%s' is wayland session: %s", filename, is_wayland_session? "yes" : "no");
|
|
||||||
|
|
||||||
out:
|
|
||||||
- g_clear_pointer (&key_file, g_key_file_free);
|
|
||||||
- g_free (filename);
|
|
||||||
+ g_debug ("GdmSession: checking if file '%s' is wayland session: %s", filename, is_wayland_session? "yes" : "no");
|
|
||||||
return is_wayland_session;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static void
|
|
||||||
update_session_type (GdmSession *self)
|
|
||||||
{
|
|
||||||
#ifdef ENABLE_WAYLAND_SUPPORT
|
|
||||||
gboolean is_wayland_session = FALSE;
|
|
||||||
|
|
||||||
- if (!self->ignore_wayland)
|
|
||||||
- is_wayland_session = gdm_session_is_wayland_session (self);
|
|
||||||
+ is_wayland_session = gdm_session_is_wayland_session (self);
|
|
||||||
|
|
||||||
if (is_wayland_session) {
|
|
||||||
set_session_type (self, "wayland");
|
|
||||||
} else {
|
|
||||||
set_session_type (self, NULL);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
gboolean
|
|
||||||
gdm_session_session_registers (GdmSession *self)
|
|
||||||
{
|
|
||||||
g_autoptr(GError) error = NULL;
|
|
||||||
g_autoptr(GKeyFile) key_file = NULL;
|
|
||||||
gboolean session_registers = FALSE;
|
|
||||||
g_autofree char *filename = NULL;
|
|
||||||
|
|
||||||
g_return_val_if_fail (self != NULL, FALSE);
|
|
||||||
g_return_val_if_fail (GDM_IS_SESSION (self), FALSE);
|
|
||||||
|
|
||||||
filename = get_session_filename (self);
|
|
||||||
|
|
||||||
- key_file = load_key_file_for_file (self, filename, NULL);
|
|
||||||
+ key_file = load_key_file_for_file (self, filename, NULL, NULL);
|
|
||||||
|
|
||||||
session_registers = g_key_file_get_boolean (key_file,
|
|
||||||
G_KEY_FILE_DESKTOP_GROUP,
|
|
||||||
"X-GDM-SessionRegisters",
|
|
||||||
&error);
|
|
||||||
if (!session_registers &&
|
|
||||||
error != NULL &&
|
|
||||||
!g_error_matches (error, G_KEY_FILE_ERROR, G_KEY_FILE_ERROR_KEY_NOT_FOUND)) {
|
|
||||||
g_warning ("GdmSession: Couldn't read session file '%s'", filename);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
g_debug ("GdmSession: '%s' %s self", filename,
|
|
||||||
session_registers ? "registers" : "does not register");
|
|
||||||
|
|
||||||
return session_registers;
|
|
||||||
}
|
|
||||||
|
|
||||||
gboolean
|
|
||||||
gdm_session_bypasses_xsession (GdmSession *self)
|
|
||||||
{
|
|
||||||
GError *error;
|
|
||||||
GKeyFile *key_file;
|
|
||||||
gboolean res;
|
|
||||||
gboolean bypasses_xsession = FALSE;
|
|
||||||
char *filename = NULL;
|
|
||||||
|
|
||||||
g_return_val_if_fail (self != NULL, FALSE);
|
|
||||||
g_return_val_if_fail (GDM_IS_SESSION (self), FALSE);
|
|
||||||
|
|
||||||
--
|
|
||||||
2.31.1
|
|
||||||
|
|
@ -12,7 +12,7 @@
|
|||||||
Name: gdm
|
Name: gdm
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
Version: 40.0
|
Version: 40.0
|
||||||
Release: 3%{?dist}
|
Release: 12%{?dist}
|
||||||
Summary: The GNOME Display Manager
|
Summary: The GNOME Display Manager
|
||||||
|
|
||||||
License: GPLv2+
|
License: GPLv2+
|
||||||
@ -20,6 +20,10 @@ URL: https://wiki.gnome.org/Projects/GDM
|
|||||||
Source0: http://download.gnome.org/sources/gdm/40/gdm-%{version}.tar.xz
|
Source0: http://download.gnome.org/sources/gdm/40/gdm-%{version}.tar.xz
|
||||||
Source1: org.gnome.login-screen.gschema.override
|
Source1: org.gnome.login-screen.gschema.override
|
||||||
|
|
||||||
|
# Lets customers using vendor nvidia driver pick wayland sessions from the login screen
|
||||||
|
Patch10001: 0001-local-display-factory-Provide-more-flexibility-for-c.patch
|
||||||
|
Patch10002: 0002-libgdm-Sort-session-list.patch
|
||||||
|
|
||||||
# Race fix
|
# Race fix
|
||||||
Patch40001: 0001-display-Handle-failure-before-display-registration.patch
|
Patch40001: 0001-display-Handle-failure-before-display-registration.patch
|
||||||
|
|
||||||
@ -45,7 +49,6 @@ Patch99920001: 0001-worker-don-t-load-user-settings-for-program-sessions.patch
|
|||||||
Patch99920002: 0002-session-support-new-accountsservice-Session-and-Sess.patch
|
Patch99920002: 0002-session-support-new-accountsservice-Session-and-Sess.patch
|
||||||
Patch99920003: 0003-daemon-save-os-release-in-accountsservice.patch
|
Patch99920003: 0003-daemon-save-os-release-in-accountsservice.patch
|
||||||
Patch99920004: 0004-daemon-handle-upgrades-from-RHEL-7.patch
|
Patch99920004: 0004-daemon-handle-upgrades-from-RHEL-7.patch
|
||||||
Patch99920005: 0005-daemon-fix-wayland-detection-when-deciding-to-bypass.patch
|
|
||||||
|
|
||||||
Patch99920006: 0001-data-Disable-network-configuration-on-login-screen.patch
|
Patch99920006: 0001-data-Disable-network-configuration-on-login-screen.patch
|
||||||
|
|
||||||
@ -357,6 +360,21 @@ fi
|
|||||||
%{_libdir}/pkgconfig/gdm-pam-extensions.pc
|
%{_libdir}/pkgconfig/gdm-pam-extensions.pc
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Aug 19 2021 Ray Strode <rstrode@redhat.com> - 40.0-12
|
||||||
|
- Redisable on server chips since rebase
|
||||||
|
Related: #1909300
|
||||||
|
|
||||||
|
* Wed Aug 04 2021 Ray Strode <rstrode@redhat.com> - 40.0-11
|
||||||
|
- Read session settings from users even if they've never saved
|
||||||
|
before. Needed to support accountsservice templated user
|
||||||
|
defaults.
|
||||||
|
Related: #1812788
|
||||||
|
|
||||||
|
* Tue Jul 27 2021 Ray Strode <rstrode@redhat.com> - 40.0-10
|
||||||
|
- Let customers using vendor nvidia driver choose wayland sessions
|
||||||
|
Resolves: #1962211
|
||||||
|
- Drop unused patches
|
||||||
|
|
||||||
* Tue Jun 08 2021 Florian Müllner <fmuellner@redhat.com> - 40.0-3
|
* Tue Jun 08 2021 Florian Müllner <fmuellner@redhat.com> - 40.0-3
|
||||||
- Disable network items on login screen
|
- Disable network items on login screen
|
||||||
Resolves: #1935261
|
Resolves: #1935261
|
||||||
|
Loading…
Reference in New Issue
Block a user