aboutsummaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
Diffstat (limited to 'data')
-rw-r--r--data/CMakeLists.txt34
-rw-r--r--data/indicator-sound.conf.in11
-rw-r--r--data/indicator-sound.desktop.in9
-rw-r--r--data/indicator-sound.service.in3
4 files changed, 47 insertions, 10 deletions
diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt
index c66ca69..565e652 100644
--- a/data/CMakeLists.txt
+++ b/data/CMakeLists.txt
@@ -17,23 +17,43 @@ install(
)
###########################
-# Dbus Service
+# Upstart Job
###########################
set(
- INDICATOR_SOUND_SERVICE
- "${CMAKE_CURRENT_BINARY_DIR}/indicator-sound.service"
+ INDICATOR_SOUND_CONF
+ "${CMAKE_CURRENT_BINARY_DIR}/indicator-sound.conf"
)
configure_file(
- "indicator-sound.service.in"
- ${INDICATOR_SOUND_SERVICE}
+ "indicator-sound.conf.in"
+ ${INDICATOR_SOUND_CONF}
@ONLY
)
install(
- FILES "${INDICATOR_SOUND_SERVICE}"
- DESTINATION "${CMAKE_INSTALL_DATADIR}/dbus-1/services/"
+ FILES "${INDICATOR_SOUND_CONF}"
+ DESTINATION "${CMAKE_INSTALL_DATADIR}/upstart/sessions/"
+)
+
+###########################
+# XDG Autostart
+###########################
+
+set(
+ INDICATOR_SOUND_XDG_AUTOSTART
+ "${CMAKE_CURRENT_BINARY_DIR}/indicator-sound.desktop"
+)
+
+configure_file(
+ "indicator-sound.desktop.in"
+ ${INDICATOR_SOUND_XDG_AUTOSTART}
+ @ONLY
+)
+
+install(
+ FILES "${INDICATOR_SOUND_XDG_AUTOSTART}"
+ DESTINATION "/etc/xdg/autostart"
)
###########################
diff --git a/data/indicator-sound.conf.in b/data/indicator-sound.conf.in
new file mode 100644
index 0000000..a5f4b4d
--- /dev/null
+++ b/data/indicator-sound.conf.in
@@ -0,0 +1,11 @@
+description "Indicator Sound Backend"
+
+# Want to move to indicator-services-[start|end], but that's not all
+# there yet. Use the signals that exist today for now.
+
+start on indicators-loaded or indicator-services-start
+stop on desktop-end or indicator-services-end
+
+respawn
+
+exec @CMAKE_INSTALL_FULL_LIBEXECDIR@/indicator-sound/indicator-sound-service
diff --git a/data/indicator-sound.desktop.in b/data/indicator-sound.desktop.in
new file mode 100644
index 0000000..aeb6440
--- /dev/null
+++ b/data/indicator-sound.desktop.in
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Type=Application
+Name=Indicator Sound
+Exec=@CMAKE_INSTALL_FULL_LIBEXECDIR@/indicator-sound/indicator-sound-service
+NotShowIn=Unity;
+NoDisplay=true
+StartupNotify=false
+Terminal=false
+
diff --git a/data/indicator-sound.service.in b/data/indicator-sound.service.in
deleted file mode 100644
index 34309b2..0000000
--- a/data/indicator-sound.service.in
+++ /dev/null
@@ -1,3 +0,0 @@
-[D-BUS Service]
-Name=com.canonical.indicator.sound
-Exec=@CMAKE_INSTALL_FULL_LIBEXECDIR@/indicator-sound/indicator-sound-service