aboutsummaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
Diffstat (limited to 'data')
-rw-r--r--data/CMakeLists.txt18
-rw-r--r--data/indicator-session.conf.in14
-rw-r--r--data/indicator-session.service.in3
3 files changed, 23 insertions, 12 deletions
diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt
index ac4e76c..d52d388 100644
--- a/data/CMakeLists.txt
+++ b/data/CMakeLists.txt
@@ -17,24 +17,24 @@ add_schema (${SCHEMA_FILE})
##
-## DBus Service File
+## Upstart Config File
##
# where to install
-set (DBUS_SERVICE_DIR "${CMAKE_INSTALL_FULL_DATADIR}/dbus-1/services")
-message (STATUS "${DBUS_SERVICE_DIR} is the DBus Service File install dir")
+set (UPSTART_JOB_DIR "${CMAKE_INSTALL_FULL_DATADIR}/upstart/sessions")
+message (STATUS "${UPSTART_JOB_DIR} is the Upstart Job install dir")
-set (SERVICE_NAME "${CMAKE_PROJECT_NAME}.service")
-set (SERVICE_FILE "${CMAKE_CURRENT_BINARY_DIR}/${SERVICE_NAME}")
-set (SERVICE_FILE_IN "${CMAKE_CURRENT_SOURCE_DIR}/${SERVICE_NAME}.in")
+set (UPSTART_JOB_NAME "${CMAKE_PROJECT_NAME}.conf")
+set (UPSTART_JOB_FILE "${CMAKE_CURRENT_BINARY_DIR}/${UPSTART_JOB_NAME}")
+set (UPSTART_JOB_FILE_IN "${CMAKE_CURRENT_SOURCE_DIR}/${UPSTART_JOB_NAME}.in")
# build it
set (pkglibexecdir "${CMAKE_INSTALL_FULL_PKGLIBEXECDIR}")
-configure_file ("${SERVICE_FILE_IN}" "${SERVICE_FILE}")
+configure_file ("${UPSTART_JOB_FILE_IN}" "${UPSTART_JOB_FILE}")
# install it
-install (FILES "${SERVICE_FILE}"
- DESTINATION "${DBUS_SERVICE_DIR}")
+install (FILES "${UPSTART_JOB_FILE}"
+ DESTINATION "${UPSTART_JOB_DIR}")
##
diff --git a/data/indicator-session.conf.in b/data/indicator-session.conf.in
new file mode 100644
index 0000000..d5c4c8c
--- /dev/null
+++ b/data/indicator-session.conf.in
@@ -0,0 +1,14 @@
+description "Indicator Session Service"
+
+# NOTE: Limiting only to Unity 7 right now as it's only needed
+# on the desktop
+
+start on (indicators-loaded or indicator-services-start) and xsession SESSION=ubuntu
+stop on desktop-end or indicator-services-end
+
+env G_MESSAGES_DEBUG=all
+export G_MESSAGES_DEBUG
+
+respawn
+
+exec @pkglibexecdir@/indicator-session-service
diff --git a/data/indicator-session.service.in b/data/indicator-session.service.in
deleted file mode 100644
index e520e20..0000000
--- a/data/indicator-session.service.in
+++ /dev/null
@@ -1,3 +0,0 @@
-[D-BUS Service]
-Name=com.canonical.indicator.session
-Exec=@pkglibexecdir@/indicator-session-service