[gnome-shell/benzea/systemd-user-units: 8/12] data: Use new method of hiding desktop file from autostart
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/benzea/systemd-user-units: 8/12] data: Use new method of hiding desktop file from autostart
- Date: Fri, 2 Aug 2019 09:20:40 +0000 (UTC)
commit 05044180ba9c429e61787fcd3e7b5361c14a399e
Author: Benjamin Berg <bberg redhat com>
Date: Sat Apr 20 00:11:18 2019 +0200
data: Use new method of hiding desktop file from autostart
GNOME Shell did not bother to hide its desktop file because
gnome-session would simply ignore all required components and the shell
was not installed into the XDG autostart directory.
Change this to the new method and update the build files to align closer
to the other modules.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/507
data/meson.build | 6 ++++--
data/org.gnome.Shell.desktop.in.in | 1 +
meson.build | 16 +++++++---------
3 files changed, 12 insertions(+), 11 deletions(-)
---
diff --git a/data/meson.build b/data/meson.build
index 31ac4514e..50d00da2e 100644
--- a/data/meson.build
+++ b/data/meson.build
@@ -14,6 +14,8 @@ desktopconf = configuration_data()
# file when built in a non-system prefix
desktopconf.set('bindir', bindir)
desktopconf.set('VERSION', meson.project_version())
+desktopconf.set('systemd_hidden', have_systemd ? 'true' : 'false')
+
foreach desktop_file : desktop_files
i18n.merge_file('desktop',
input: configure_file(
@@ -102,13 +104,13 @@ if have_systemd
input: 'gnome-shell.service.in',
output: 'gnome-shell.service',
configuration: unitconf,
- install_dir: systemduserunitdir
+ install_dir: systemd_userunitdir
)
units = files('gnome-shell-wayland.target',
'gnome-shell-x11.target')
- install_data(units, install_dir: systemduserunitdir)
+ install_data(units, install_dir: systemd_userunitdir)
endif
# for unit tests - gnome.compile_schemas() only looks in srcdir
diff --git a/data/org.gnome.Shell.desktop.in.in b/data/org.gnome.Shell.desktop.in.in
index 09543e858..1b46ef944 100644
--- a/data/org.gnome.Shell.desktop.in.in
+++ b/data/org.gnome.Shell.desktop.in.in
@@ -14,3 +14,4 @@ X-GNOME-Autostart-Phase=DisplayServer
X-GNOME-Provides=panel;windowmanager;
X-GNOME-Autostart-Notify=true
X-GNOME-AutoRestart=false
+X-GNOME-HiddenUnderSystemd=@systemd_hidden@
diff --git a/meson.build b/meson.build
index 307cd6be6..6a6b4a38f 100644
--- a/meson.build
+++ b/meson.build
@@ -61,13 +61,6 @@ portaldir = join_paths(datadir, 'xdg-desktop-portal', 'portals')
schemadir = join_paths(datadir, 'glib-2.0', 'schemas')
servicedir = join_paths(datadir, 'dbus-1', 'services')
-# XXX: Once https://github.com/systemd/systemd/issues/9595 is fixed and we can
-# depend on this version, replace with something like:
-# systemduserunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir',
-# define_variable: ['prefix', prefix])
-# and uncomment systemd_dep below
-systemduserunitdir = join_paths(prefix, 'lib', 'systemd', 'user')
-
keybindings_dep = dependency('gnome-keybindings', required: false)
if keybindings_dep.found()
keysdir = keybindings_dep.get_pkgconfig_variable('keysdir')
@@ -124,9 +117,14 @@ endif
if get_option('systemd')
libsystemd_dep = dependency('libsystemd')
- # XXX: see systemduserunitdir
- # systemd_dep = dependency('systemd')
+ systemd_dep = dependency('systemd')
have_systemd = true
+
+ # XXX: Once https://github.com/systemd/systemd/issues/9595 is fixed and we can
+ # depend on this version, replace with something like:
+ # systemd_userunitdir = systemd_dep.get_pkgconfig_variable('systemduserunitdir',
+ # define_variable: ['prefix', prefix])
+ systemd_userunitdir = join_paths(prefix, 'lib', 'systemd', 'user')
else
libsystemd_dep = []
have_systemd = false
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]