aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac4
-rw-r--r--data/Makefile.am11
-rw-r--r--data/indicator-printers.service.in3
4 files changed, 19 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 1474d2b..753bde1 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,3 +1,3 @@
-SUBDIRS = src test
+SUBDIRS = src data test
diff --git a/configure.ac b/configure.ac
index ef57d5c..d19933a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -14,6 +14,7 @@ AC_CONFIG_HEADER(config.h)
AC_CONFIG_FILES([
Makefile
src/Makefile
+ data/Makefile
test/Makefile
])
@@ -35,8 +36,11 @@ SERVICE_LIBS+=`$CUPS_CONFIG --libs`
INDICATORDIR=`$PKG_CONFIG --variable=indicatordir indicator3-0.4`
INDICATORICONSDIR=`$PKG_CONFIG --variable=iconsdir indicator3-0.4`
+DBUSSERVICEDIR=`$PKG_CONFIG --variable=session_bus_services_dir dbus-1`
+
AC_SUBST(INDICATORDIR)
AC_SUBST(INDICATORICONDIR)
+AC_SUBST(DBUSSERVICEDIR)
AC_SUBST(AM_CFLAGS, "-Wall")
diff --git a/data/Makefile.am b/data/Makefile.am
new file mode 100644
index 0000000..1ecc4e7
--- /dev/null
+++ b/data/Makefile.am
@@ -0,0 +1,11 @@
+
+dbus_servicesdir = $(DBUSSERVICEDIR)
+dbus_services_DATA = indicator-printers.service
+
+%.service: %.service.in
+ sed -e "s|\@libexecdir\@|$(libexecdir)|" $< > $@
+
+EXTRA_DIST = indicator-printers.service
+
+CLEANFILES = $(dbus_services_DATA)
+
diff --git a/data/indicator-printers.service.in b/data/indicator-printers.service.in
new file mode 100644
index 0000000..d89bcd2
--- /dev/null
+++ b/data/indicator-printers.service.in
@@ -0,0 +1,3 @@
+[D-BUS Service]
+Name=com.canonical.indicator.printers
+Exec=@libexecdir@/indicator-printers-service