dc283d4
--- a/configure.ac
dc283d4
+++ b/configure.ac
dc283d4
@@ -606,7 +606,7 @@ AC_ARG_WITH(systemd,
dc283d4
             [with_systemd=$withval], [with_systemd=auto])
dc283d4
 
dc283d4
 PKG_CHECK_MODULES(SYSTEMD,
dc283d4
-                  [libsystemd-login libsystemd-daemon],
dc283d4
+                  [libsystemd-login],
dc283d4
                   [have_systemd=yes], [have_systemd=no])
dc283d4
 
dc283d4
 if test "x$with_systemd" = "xauto" ; then
dc283d4
--- a/src/gs-listener-dbus.c
dc283d4
+++ b/src/gs-listener-dbus.c
dc283d4
@@ -25,6 +25,7 @@
dc283d4
 #include <stdio.h>
dc283d4
 #include <time.h>
dc283d4
 #include <string.h>
dc283d4
+#include <unistd.h>
dc283d4
 
dc283d4
 #include <glib/gi18n.h>
dc283d4
 
dc283d4
@@ -33,7 +34,6 @@
dc283d4
 #include <dbus/dbus-glib-lowlevel.h>
dc283d4
 
dc283d4
 #ifdef WITH_SYSTEMD
dc283d4
-#include <systemd/sd-daemon.h>
dc283d4
 #include <systemd/sd-login.h>
dc283d4
 #endif
dc283d4
 
dc283d4
@@ -1518,7 +1518,8 @@ gs_listener_init (GSListener *listener)
dc283d4
         listener->priv = GS_LISTENER_GET_PRIVATE (listener);
dc283d4
 
dc283d4
 #ifdef WITH_SYSTEMD
dc283d4
-        listener->priv->have_systemd = sd_booted () > 0;
dc283d4
+        /* check if logind is running */
dc283d4
+        listener->priv->have_systemd = (access("/run/systemd/seats/", F_OK) >= 0);
dc283d4
 #endif
dc283d4
 
dc283d4
         gs_listener_dbus_init (listener);