diff options
author | Ted Gould <ted@gould.cx> | 2016-10-21 14:19:39 +0000 |
---|---|---|
committer | Bileto Bot <ci-train-bot@canonical.com> | 2016-10-21 14:19:39 +0000 |
commit | 4f079d2faa6dd24f7ccd0566c4820a835fccce6a (patch) | |
tree | a02fd07a795dfe42b166fd77de83342308169a24 | |
parent | 621bec19950a83a9a5bde75a2db0b130dd03f608 (diff) | |
parent | 8ede639e1d729183f8e6324fe2dd9c2269f22e41 (diff) | |
download | ayatana-indicator-display-4f079d2faa6dd24f7ccd0566c4820a835fccce6a.tar.gz ayatana-indicator-display-4f079d2faa6dd24f7ccd0566c4820a835fccce6a.tar.bz2 ayatana-indicator-display-4f079d2faa6dd24f7ccd0566c4820a835fccce6a.zip |
Adding a systemd user session unit
Approved by: Martin Pitt
-rw-r--r-- | data/CMakeLists.txt | 32 | ||||
-rw-r--r-- | data/indicator-display.override | 1 | ||||
-rw-r--r-- | data/indicator-display.service.in | 8 | ||||
-rw-r--r-- | debian/control | 3 |
4 files changed, 44 insertions, 0 deletions
diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt index 7edaa44..2e42eda 100644 --- a/data/CMakeLists.txt +++ b/data/CMakeLists.txt @@ -60,6 +60,38 @@ install (FILES "${UPSTART_XDG_AUTOSTART_FILE}" RENAME "${XDG_AUTOSTART_NAME}") ## +## Systemd Unit File +## + +# where to install +# Uncomment when we drop Vivid +# pkg_get_variable(SYSTEMD_USER_DIR systemd systemduserunitdir) +set (SYSTEMD_USER_DIR "/usr/lib/systemd/user") +message (STATUS "${SYSTEMD_USER_DIR} is the systemd user unit file install dir") + +set (SYSTEMD_USER_NAME "${CMAKE_PROJECT_NAME}.service") +set (SYSTEMD_USER_FILE "${CMAKE_CURRENT_BINARY_DIR}/${SYSTEMD_USER_NAME}") +set (SYSTEMD_USER_FILE_IN "${CMAKE_CURRENT_SOURCE_DIR}/${SYSTEMD_USER_NAME}.in") + +# build it +set (pkglibexecdir "${CMAKE_INSTALL_FULL_PKGLIBEXECDIR}") +configure_file ("${SYSTEMD_USER_FILE_IN}" "${SYSTEMD_USER_FILE}") + +# install it +install (FILES "${SYSTEMD_USER_FILE}" + DESTINATION "${SYSTEMD_USER_DIR}") + +## +## Upstart systemd override Job File +## + +set (UPSTART_SYSTEMD_OVERRIDE_DIR "${CMAKE_INSTALL_FULL_DATADIR}/upstart/systemd-session/upstart") +message (STATUS "${UPSTART_SYSTEMD_OVERRIDE_DIR} is the Upstart override Job File for systemd dir") + +install (FILES "${CMAKE_CURRENT_SOURCE_DIR}/${CMAKE_PROJECT_NAME}.override" + DESTINATION "${UPSTART_SYSTEMD_OVERRIDE_DIR}") + +## ## Unity Indicator File ## diff --git a/data/indicator-display.override b/data/indicator-display.override new file mode 100644 index 0000000..2905494 --- /dev/null +++ b/data/indicator-display.override @@ -0,0 +1 @@ +manual diff --git a/data/indicator-display.service.in b/data/indicator-display.service.in new file mode 100644 index 0000000..8245917 --- /dev/null +++ b/data/indicator-display.service.in @@ -0,0 +1,8 @@ +[Unit] +Description=Indicator Display Backend +PartOf=graphical-session.target +After=indicators-pre.target + +[Service] +ExecStart=@pkglibexecdir@/indicator-display-service +Restart=on-failure diff --git a/debian/control b/debian/control index 90e2590..65950a2 100644 --- a/debian/control +++ b/debian/control @@ -23,6 +23,8 @@ Build-Depends: cmake, # for packaging debhelper (>= 9), dh-translations, +# for systemd unit + systemd, Standards-Version: 3.9.5 Homepage: http://launchpad.net/indicator-display/ X-Ubuntu-Use-Langpack: yes @@ -36,5 +38,6 @@ Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends}, gsettings-ubuntu-schemas (>= 0.0.2+14.10.20140813), + indicator-common, Description: Collection of small indicators Indicators too small to merit separate codebases, such as Rotation Lock |