summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2011-12-19 22:37:05 -0500
committerDavid Zeuthen <davidz@redhat.com>2012-01-03 10:03:47 -0500
commit2027302e803a9569a370b429a475dae5ef8afe34 (patch)
treee752e6a1feb5936c8f7f7b8f19203526a6d10544 /configure.ac
parent674357c20c1b6cb421fea6eb6924b274ec477c0e (diff)
downloadpolkit-2027302e803a9569a370b429a475dae5ef8afe34.tar.gz
Add optional systemd support
When configured with --enable-systemd, this patch makes polkit use systemd for session tracking instead of ConsoleKit. Signed-off-by: David Zeuthen <davidz@redhat.com>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac24
1 files changed, 22 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 2ed8401..51d6890 100644
--- a/configure.ac
+++ b/configure.ac
@@ -148,6 +148,26 @@ if test "x$GCC" = "xyes"; then
fi
dnl ---------------------------------------------------------------------------
+dnl - Select wether to use systemd or ConsoleKit for session tracking
+dnl ---------------------------------------------------------------------------
+
+AC_ARG_ENABLE([systemd],
+ AS_HELP_STRING([--enable-systemd], [Use systemd]),
+ [with_systemd=$enableval],
+ [with_systemd=no])
+if test "$with_systemd" = "yes" ; then
+ PKG_CHECK_MODULES(SYSTEMD, [libsystemd-login])
+ SESSION_TRACKING=systemd
+else
+ SESSION_TRACKING=ConsoleKit
+fi
+
+AC_SUBST(SYSTEMD_CFLAGS)
+AC_SUBST(SYSTEMD_LIBS)
+
+AM_CONDITIONAL(HAVE_SYSTEMD, [test "$with_systemd" = "yes"], [Using systemd])
+
+dnl ---------------------------------------------------------------------------
dnl - Select which authentication framework to use
dnl ---------------------------------------------------------------------------
@@ -449,7 +469,8 @@ echo "
introspection: ${found_introspection}
Distribution/OS: ${with_os_type}
- authentication framework: ${POLKIT_AUTHFW}
+ Authentication framework: ${POLKIT_AUTHFW}
+ Session tracking: ${SESSION_TRACKING}
PAM support: ${have_pam}"
if test "$have_pam" = yes ; then
@@ -459,7 +480,6 @@ echo "
PAM file password: ${PAM_FILE_INCLUDE_PASSWORD}
PAM file session: ${PAM_FILE_INCLUDE_SESSION}"
fi
-
echo "
Maintainer mode: ${USE_MAINTAINER_MODE}
Building verbose mode: ${enable_verbose_mode}