[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [PATCH for-4.7] configure: Fix when no libsystemd compat lib are available



From systemd change log, since version 209, libsystemd.so contain
everything, including libsystemd-daemon.so. Distro may, or may not provide
the compatibility libraries which libsystemd-daemon is part of.

So, if libsystemd-daemon is not available, check for the presence of
a recent enough libsystemd.

Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
---
Please, rerun ./autogen.sh on this patch.
---
 m4/systemd.m4 | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/m4/systemd.m4 b/m4/systemd.m4
index e4b1aa5..112dc11 100644
--- a/m4/systemd.m4
+++ b/m4/systemd.m4
@@ -41,7 +41,9 @@ AC_DEFUN([AX_ALLOW_SYSTEMD_OPTS], [
 ])
 
 AC_DEFUN([AX_CHECK_SYSTEMD_LIBS], [
-       PKG_CHECK_MODULES([SYSTEMD], [libsystemd-daemon])
+       PKG_CHECK_MODULES([SYSTEMD], [libsystemd-daemon],,
+               [PKG_CHECK_MODULES([SYSTEMD], [libsystemd >= 209])]
+        )
        dnl pkg-config older than 0.24 does not set these for
        dnl PKG_CHECK_MODULES() worth also noting is that as of version 208
        dnl of systemd pkg-config --cflags currently yields no extra flags yet.
@@ -94,8 +96,10 @@ AC_DEFUN([AX_CHECK_SYSTEMD], [
 ])
 
 AC_DEFUN([AX_CHECK_SYSTEMD_ENABLE_AVAILABLE], [
-       PKG_CHECK_MODULES([SYSTEMD], [libsystemd-daemon], [systemd="y"],
-                          [systemd="n"])
+       PKG_CHECK_MODULES([SYSTEMD], [libsystemd-daemon], [systemd="y"],[
+               PKG_CHECK_MODULES([SYSTEMD], [libsystemd >= 209],
+                                 [systemd="y"],[systemd="n"])
+       ])
 ])
 
 dnl Enables systemd by default and requires a --disable-systemd option flag
-- 
Anthony PERARD


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.