summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorMartin Pitt <martinpitt@users.noreply.github.com>2017-03-08 14:20:11 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2017-03-08 14:20:11 +0100
commit37377227ff47aa88c698c4b704d68d600d695c9f (patch)
tree1fa7f51d540f010e600990c6c56d96915c7d831a /configure.ac
parentman: fix typo (#5556) (diff)
downloadsystemd-37377227ff47aa88c698c4b704d68d600d695c9f.tar.xz
systemd-37377227ff47aa88c698c4b704d68d600d695c9f.zip
build-sys: only install legacy *.pkla files with old polkit versions (#5555)
The legacy *.pkla files are not required when running against polkit ≥ 106, and we want to avoid shipping files in /var if possible (but pkla files can only be in /etc/ or /var). Only install the *.pkla files if we detect an old polkit version during configure. Don't install them if polkit isn't installed during build, as distributions other than Debian-based ones have moved to the new polkit long ago. Fixes #5523
Diffstat (limited to '')
-rw-r--r--configure.ac8
1 files changed, 7 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 3835413ad5..1efeb3a73e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1228,8 +1228,14 @@ AC_ARG_ENABLE(polkit, AS_HELP_STRING([--disable-polkit], [disable PolicyKit supp
if test "x$enable_polkit" != "xno"; then
AC_DEFINE(ENABLE_POLKIT, 1, [Define if PolicyKit support is to be enabled])
have_polkit=yes
+
+ # also enable support for *.pkla files on old polkit
+ PKG_CHECK_MODULES(POLKIT, [ polkit-gobject-1 < 0.106 ],
+ [polkit_pkla=yes],
+ [polkit_pkla=no])
fi
AM_CONDITIONAL(ENABLE_POLKIT, [test "x$have_polkit" = "xyes"])
+AM_CONDITIONAL(ENABLE_POLKIT_PKLA, [test "x$polkit_pkla" = "xyes"])
# ------------------------------------------------------------------------------
have_resolved=no
@@ -1700,7 +1706,7 @@ AC_MSG_RESULT([
default DNS servers: ${DNS_SERVERS}
default DNSSEC mode: ${DEFAULT_DNSSEC_MODE}
coredump: ${have_coredump}
- polkit: ${have_polkit}
+ polkit: ${have_polkit} (legacy pkla support: ${polkit_pkla})
efi: ${have_efi}
gnuefi: ${have_gnuefi}
efi arch: ${EFI_ARCH}