aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@ubuntu.com>2017-05-15 12:20:44 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2017-05-15 12:20:44 +0200
commita0993948b82c63a0c2687fde303c5993545bb693 (patch)
treea0d601864aafad420a878fc9281dba89ac886528
parent9afe090a17da59e60706a13ddafd3e8ef2f97869 (diff)
downloadayatana-indicator-application-a0993948b82c63a0c2687fde303c5993545bb693.tar.gz
ayatana-indicator-application-a0993948b82c63a0c2687fde303c5993545bb693.tar.bz2
ayatana-indicator-application-a0993948b82c63a0c2687fde303c5993545bb693.zip
Adding a systemd user unit.
-rw-r--r--configure.ac4
-rw-r--r--data/Makefile.am15
-rw-r--r--data/ayatana-indicator-application.override1
-rw-r--r--data/ayatana-indicator-application.service.in8
-rw-r--r--debian/control2
5 files changed, 28 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 167f1d6..c2a4272 100644
--- a/configure.ac
+++ b/configure.ac
@@ -50,6 +50,9 @@ PKG_CHECK_MODULES(INDICATOR, glib-2.0 >= $GLIB_REQUIRED_VERSION
dbusmenu-gtk3-0.4 >= $DBUSMENUGTK_REQUIRED_VERSION)
PKG_CHECK_MODULES(APPINDICATOR, ayatana-appindicator3-0.1 >= $LIBAPPINDICATOR_REQUIRED_VERSION)
+SYSTEMD_USERDIR=`$PKG_CONFIG --variable=systemduserunitdir systemd`
+AC_SUBST(SYSTEMD_USERDIR)
+
###########################
# gcov coverage reporting
###########################
@@ -113,4 +116,5 @@ Application Indicator Configuration:
Prefix: $prefix
Indicator Dir: $INDICATORDIR
gcov: $use_gcov
+ systemd unit: $SYSTEMD_USERDIR
])
diff --git a/data/Makefile.am b/data/Makefile.am
index bc5260d..3851097 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -16,12 +16,23 @@ xdg_autostart_DATA = ayatana-indicator-application.desktop
overridedir = $(pkgdatadir)
override_DATA = ordering-override.keyfile
+%.service: %.service.in
+ $(AM_V_GEN) sed -e "s|\@pkglibexecdir\@|$(pkglibexecdir)|" $< > $@
+
+systemddir = $(SYSTEMD_USERDIR)
+systemd_DATA = ayatana-indicator-application.service
+
+upstartsystemdoverridedir = $(datadir)/upstart/systemd-session/upstart
+upstartsystemdoverride_DATA = ayatana-indicator-application.override
+
EXTRA_DIST = \
ayatana-indicator-application.desktop.in \
ayatana-indicator-application.conf.in \
+ ayatana-indicator-application.service.in \
+ ayatana-indicator-application.override \
ordering-override.keyfile
CLEANFILES = \
ayatana-indicator-application.conf \
- ayatana-indicator-application.desktop
-
+ ayatana-indicator-application.desktop \
+ ayatana-indicator-application.service
diff --git a/data/ayatana-indicator-application.override b/data/ayatana-indicator-application.override
new file mode 100644
index 0000000..2905494
--- /dev/null
+++ b/data/ayatana-indicator-application.override
@@ -0,0 +1 @@
+manual
diff --git a/data/ayatana-indicator-application.service.in b/data/ayatana-indicator-application.service.in
new file mode 100644
index 0000000..b1068d0
--- /dev/null
+++ b/data/ayatana-indicator-application.service.in
@@ -0,0 +1,8 @@
+[Unit]
+Description=Ayatana Indicator Application Service
+PartOf=graphical-session.target
+After=ayatana-indicators-pre.target
+
+[Service]
+ExecStart=@pkglibexecdir@/ayatana-indicator-application-service
+Restart=on-failure
diff --git a/debian/control b/debian/control
index 36ae417..ae7504c 100644
--- a/debian/control
+++ b/debian/control
@@ -16,6 +16,7 @@ Build-Depends: debhelper (>= 9.0),
libayatana-indicator3-dev (>= 0.6.0~),
libdbusmenu-glib-dev (>= 0.5.90),
libdbusmenu-gtk3-dev (>= 0.5.90),
+ systemd,
Standards-Version: 3.9.6
Homepage: https://github.com/ArcticaProject/ayatana-indicator-application
Vcs-Git: git://cgit.arctica-project.org/ayatana/ayatana-indicator-application.git
@@ -25,5 +26,6 @@ Package: ayatana-indicator-application
Architecture: any
Depends: ${shlibs:Depends},
${misc:Depends},
+ ayatana-indicator-common,
Description: Ayatana Application Indicators
An indicator to take menus from applications and place them in the panel.