summaryrefslogtreecommitdiff
path: root/bus
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2015-09-25 17:07:40 +0100
committerMike Gorse <mgorse@suse.com>2015-09-27 12:53:24 -0500
commit02c5e3e34238f159e02c3560e28dce8c20ce691d (patch)
treef86557b447447198821c999c5ac9f11f196b1364 /bus
parentce7357e55a786ffd2df7ddd06ffcbb2bce6d4201 (diff)
downloadat-spi2-core-02c5e3e34238f159e02c3560e28dce8c20ce691d.tar.gz
Add a systemd user service corresponding to the D-Bus session service
When using a systemd user session, this ensures that org.a11y.Bus and its child processes (such as org.a11y.atspi.Registry) are placed in their own cgroup, instead of being treated as part of dbus.service. https://bugzilla.gnome.org/show_bug.cgi?id=755637
Diffstat (limited to 'bus')
-rw-r--r--bus/Makefile.am7
-rw-r--r--bus/at-spi-dbus-bus.service.in7
-rw-r--r--bus/org.a11y.Bus.service.in1
3 files changed, 15 insertions, 0 deletions
diff --git a/bus/Makefile.am b/bus/Makefile.am
index 530d2312..d9664abb 100644
--- a/bus/Makefile.am
+++ b/bus/Makefile.am
@@ -25,13 +25,20 @@ dbusservice_DATA = org.a11y.Bus.service
org.a11y.Bus.service: org.a11y.Bus.service.in
sed -e $(substitutions) $< > $@.tmp && mv $@.tmp $@
+systemd_userdir = $(prefix)/lib/systemd/user
+systemd_user_DATA = at-spi-dbus-bus.service
+at-spi-dbus-bus.service: at-spi-dbus-bus.service.in Makefile
+ sed -e $(substitutions) $< > $@.tmp && mv $@.tmp $@
+
accessibility.conf: accessibility.conf.in
sed -e "s|[@]DATADIR[@]|$(datadir)|" $(srcdir)/$@.in > $@
EXTRA_DIST += org.a11y.Bus.service.in \
+ at-spi-dbus-bus.service.in \
accessibility.conf.in
DISTCLEANFILES = org.a11y.Bus.service \
+ $(systemd_user_DATA) \
accessibility.conf
-include $(top_srcdir)/git.mk
diff --git a/bus/at-spi-dbus-bus.service.in b/bus/at-spi-dbus-bus.service.in
new file mode 100644
index 00000000..28ffa1cd
--- /dev/null
+++ b/bus/at-spi-dbus-bus.service.in
@@ -0,0 +1,7 @@
+[Unit]
+Description=Accessibility services bus
+
+[Service]
+Type=dbus
+BusName=org.a11y.Bus
+ExecStart=@libexecdir@/at-spi-bus-launcher
diff --git a/bus/org.a11y.Bus.service.in b/bus/org.a11y.Bus.service.in
index 60edc28e..86724daa 100644
--- a/bus/org.a11y.Bus.service.in
+++ b/bus/org.a11y.Bus.service.in
@@ -1,3 +1,4 @@
[D-BUS Service]
Name=org.a11y.Bus
Exec=@libexecdir@/at-spi-bus-launcher
+SystemdService=at-spi-dbus-bus.service