[PATCH] Install shibd-systemd only with --enable-systemd

Ferenc Wágner wferi at niif.hu
Wed Mar 23 09:33:43 UTC 2016


The shibd-systemd service file has Type=notify, thus it won't work
without sd_notify() compiled in.  Installing it could be confusing.

Signed-off-by: Ferenc Wágner <wferi at niif.hu>
---

Notes:
    Hi Scott,
    
    Would you please consider including something like this patch?  I'm not
    too much into Autoconf, so take this with a grain of salt, and the
    spec file might also need corresponding changes, but it withstood some
    basic compile/install testing.  I'll have to handle this some way in the
    Debian package, but eventually it would be best solved upstream, I think.
    
    Thanks,
    Feri.

 configs/Makefile.am | 4 +++-
 configure.ac        | 1 +
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/configs/Makefile.am b/configs/Makefile.am
index 31154b1..1d16ddd 100644
--- a/configs/Makefile.am
+++ b/configs/Makefile.am
@@ -11,7 +11,6 @@ pkgrundir = $(localstatedir)/run/@PACKAGE_NAME@
 pkgcachedir = $(localstatedir)/cache/@PACKAGE_NAME@
 pkgsysconfdir = $(sysconfdir)/@PACKAGE_NAME@
 pkgsysconf_DATA = \
-	shibd-systemd \
 	shibd-redhat \
 	shibd-amazon \
 	shibd-suse \
@@ -24,6 +23,9 @@ pkgsysconf_DATA = \
 	keygen.sh \
 	metagen.sh \
 	upgrade.xsl
+if BUILD_SYSTEMD
+pkgsysconf_DATA += shibd-systemd
+endif
 
 # The config files are installed "special".  Unlike the entries in
 # pkgsysconf_DATA, these files are installed as "foo.dist" and only
diff --git a/configure.ac b/configure.ac
index d9b563e..cdfaa3f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -455,6 +455,7 @@ if test "$WANT_SYSTEMD" = "yes" ; then
 	AC_SUBST([SYSTEMD_CFLAGS])
 	AC_SUBST([SYSTEMD_LIBS])
 fi
+AM_CONDITIONAL(BUILD_SYSTEMD,test "$WANT_SYSTEMD" = "yes")
 
 #
 # Build NSAPI module?
-- 
2.1.4




More information about the Pkg-shibboleth-devel mailing list