diff options
-rw-r--r-- | configure.ac | 1 | ||||
-rw-r--r-- | data/Makefile.am | 45 | ||||
-rw-r--r-- | data/indicator-keyboard.conf.in | 9 | ||||
-rw-r--r-- | data/indicator-keyboard.desktop.in | 9 | ||||
-rw-r--r-- | data/upstart/Makefile.am | 12 | ||||
-rw-r--r-- | data/upstart/indicator-keyboard.desktop.in | 9 | ||||
-rw-r--r-- | lib/Makefile.am | 2 |
7 files changed, 78 insertions, 9 deletions
diff --git a/configure.ac b/configure.ac index dc2f0bae..5c09f8fc 100644 --- a/configure.ac +++ b/configure.ac @@ -89,6 +89,7 @@ AC_SUBST(COVERAGE_LDFLAGS) AC_CONFIG_FILES([Makefile data/Makefile + data/upstart/Makefile lib/Makefile po/Makefile.in tests/Makefile diff --git a/data/Makefile.am b/data/Makefile.am index 03c377c7..06ed4662 100644 --- a/data/Makefile.am +++ b/data/Makefile.am @@ -1,3 +1,10 @@ + +SUBDIRS = upstart + +########################### +# Icon Generator +########################### + noinst_PROGRAMS = indicator-keyboard-icon-generator AM_CFLAGS = -w -DGNOME_DESKTOP_USE_UNSTABLE_API @@ -32,14 +39,29 @@ indicator_keyboard_icon_generator_LDFLAGS = $(AM_LDFLAGS) \ $(LIBXKLAVIER_LIBS) \ $(COVERAGE_LDFLAGS) -dist_service_DATA = indicator-keyboard.service -servicedir = $(DBUS_SERVICE_DIR) +########################### +# Upstart Config +########################### -indicator-keyboard.service: - $(AM_V_GEN) (echo '[D-BUS Service]'; \ - echo 'Name=com.canonical.indicator.keyboard'; \ - echo 'Exec=${libexecdir}/indicator-keyboard-service --use-gtk') > $@.tmp && \ - mv $@.tmp $@ +upstart_jobsdir = $(datadir)/upstart/sessions/ +upstart_jobs_DATA = indicator-keyboard.conf + +%.conf: %.conf.in + $(AM_V_GEN) sed -e "s|\@pkglibexecdir\@|$(pkglibexecdir)|" $< > $@ + +########################### +# XDG Autostart File +########################### + +xdg_autostartdir = /etc/xdg/autostart +xdg_autostart_DATA = indicator-keyboard.desktop + +%.desktop: %.desktop.in + $(AM_V_GEN) sed -e "s|\@pkglibexecdir\@|$(pkglibexecdir)|" $< > $@ + +########################### +# Indicator Config +########################### dist_indicator_DATA = com.canonical.indicator.keyboard indicatordir = $(INDICATOR_DIR) @@ -63,6 +85,10 @@ com.canonical.indicator.keyboard: echo 'ObjectPath=/com/canonical/indicator/keyboard/desktop') > $@.tmp && \ mv $@.tmp $@ +########################### +# GSettings Schemas +########################### + gsettings_SCHEMAS = com.canonical.indicator.keyboard.gschema.xml @GSETTINGS_RULES@ @@ -74,4 +100,7 @@ gschemas.compiled: $(gsettings_SCHEMAS) EXTRA_DIST = $(dist_service_DATA) \ $(dist_indicator_DATA) \ - $(gsettings_SCHEMAS) + $(gsettings_SCHEMAS) \ + indicator-keyboard.conf.in \ + indicator-keyboard.desktop.in + diff --git a/data/indicator-keyboard.conf.in b/data/indicator-keyboard.conf.in new file mode 100644 index 00000000..737a4830 --- /dev/null +++ b/data/indicator-keyboard.conf.in @@ -0,0 +1,9 @@ +description "Indicator Keyboard Backend" + +start on indicator-services-start +stop on desktop-end or indicator-services-end + +respawn +respawn limit 2 10 + +exec @pkglibexecdir@/indicator-keyboard-service --use-gtk diff --git a/data/indicator-keyboard.desktop.in b/data/indicator-keyboard.desktop.in new file mode 100644 index 00000000..3fca71fb --- /dev/null +++ b/data/indicator-keyboard.desktop.in @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Name=Indicator Keyboard +Exec=@pkglibexecdir@/indicator-keyboard-service +OnlyShowIn=Unity;GNOME; +NoDisplay=true +StartupNotify=false +Terminal=false +AutostartCondition=GNOME3 unless-session gnome diff --git a/data/upstart/Makefile.am b/data/upstart/Makefile.am new file mode 100644 index 00000000..c0b6a2eb --- /dev/null +++ b/data/upstart/Makefile.am @@ -0,0 +1,12 @@ +########################### +# Upstart XDG Override +########################### + +xdg_autostartdir = $(datadir)/upstart/xdg/autostart +xdg_autostart_DATA = indicator-keyboard.desktop + +%.desktop: %.desktop.in + $(AM_V_GEN) sed -e "s|\@pkglibexecdir\@|$(pkglibexecdir)|" $< > $@ + +EXTRA_DIST = indicator-keyboard.desktop.in + diff --git a/data/upstart/indicator-keyboard.desktop.in b/data/upstart/indicator-keyboard.desktop.in new file mode 100644 index 00000000..ec7e565c --- /dev/null +++ b/data/upstart/indicator-keyboard.desktop.in @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Name=Indicator Keyboard +Exec=@pkglibexecdir@/indicator-keyboard-service +OnlyShowIn=Unity; +NoDisplay=true +StartupNotify=false +Terminal=false +Hidden=true diff --git a/lib/Makefile.am b/lib/Makefile.am index a19016d9..c57725c1 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -1,4 +1,4 @@ -libexec_PROGRAMS = indicator-keyboard-service +pkglibexec_PROGRAMS = indicator-keyboard-service AM_CFLAGS = -w -DGNOME_DESKTOP_USE_UNSTABLE_API AM_LDFLAGS = -lm |