From 2945f91e99d50bb4035247a953db7e0fa3270cc6 Mon Sep 17 00:00:00 2001 From: Benedikt Morbach Date: Wed, 18 Jan 2012 19:29:59 +0100 Subject: [PATCH] fix autotools wrt the new systemd support --- configure.ac | 6 ++++-- data/Makefile.am | 10 ++++------ data/colord.service.in | 9 +-------- 3 files changed, 9 insertions(+), 16 deletions(-) diff --git a/configure.ac b/configure.ac index fdf840b..5dd60c9 100644 --- a/configure.ac +++ b/configure.ac @@ -178,8 +178,10 @@ AC_ARG_WITH([systemdsystemunitdir], AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]), [], [with_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)]) -AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir]) -AM_CONDITIONAL(HAVE_SYSTEMD, [test -n "$with_systemdsystemunitdir"]) +if test "x$with_systemdsystemunitdir" != "xno"; then + AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir]) +fi +AM_CONDITIONAL(HAVE_SYSTEMD, [test -n "$systemdsystemunitdir"]) dnl --------------------------------------------------------------------------- dnl - Build DBus examples diff --git a/data/Makefile.am b/data/Makefile.am index 516c6a2..40f55e0 100644 --- a/data/Makefile.am +++ b/data/Makefile.am @@ -15,9 +15,10 @@ $(dbusservicemain_DATA): $(dbusservicemain_in_files) Makefile @sed -e "s|\@servicedir\@|$(libexecdir)|" $< | \ sed -e "s|\@daemon_user\@|$(daemon_user)|" > $@ +systemdservicemain_in_files = colord.service.in + if HAVE_SYSTEMD systemdservicemaindir = $(systemdsystemunitdir) -systemdservicemain_in_files = colord.service.in systemdservicemain_DATA = $(systemdservicemain_in_files:.service.in=.service) $(systemdservicemain_DATA): $(systemdservicemain_in_files) Makefile @sed -e "s|\@servicedir\@|$(libexecdir)|" $< | \ @@ -25,13 +26,10 @@ $(systemdservicemain_DATA): $(systemdservicemain_in_files) Makefile endif EXTRA_DIST = \ - $(dbusservicemain_in_files) \ + $(systemdservicemain_in_files) \ + $(dbusservicemain_in_files) \ org.freedesktop.ColorManager.conf.in -if HAVE_SYSTEMD -EXTRA_DIST += $(systemdservicemain_in_files) -endif - x11-colors.icc: $(top_builddir)/client/cd-create-profile --output $@ --named-color-palette ./x11-colors.csv --nc-prefix="X11" --named-color-type srgb -d "X11 Colors" -c "No copyright" -n "Richard Hughes" diff --git a/data/colord.service.in b/data/colord.service.in index 4050d84..e1f787b 100644 --- a/data/colord.service.in +++ b/data/colord.service.in @@ -1,15 +1,8 @@ [Unit] -Description=Daemon for managing, installing and generating color profiles +Description=Manage, Install and Generate Color Profiles [Service] Type=dbus BusName=org.freedesktop.ColorManager ExecStart=@servicedir@/colord User=@daemon_user@ - -[Install] -# We pull this in by graphical.target instead of waiting for the bus -# activation, to speed things up a little: gdm uses this anyway so it is nice -# if it is already around when gdm wants to use it and doesn't have to wait for -# it. -WantedBy=graphical.target -- 1.7.8.1