X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=configure.ac;h=0dd185b258e741c87f2283e279c09648c5f12e20;hp=eb5fb6a975dccd182e437810d16334fd1215ae6d;hb=f401e48c2db22ff9d1a05885b5599bebf19c2707;hpb=f9a61ef2c9e3b330d9e2e37977b3dd5758a4b853 diff --git a/configure.ac b/configure.ac index eb5fb6a97..0dd185b25 100644 --- a/configure.ac +++ b/configure.ac @@ -193,6 +193,43 @@ fi AC_SUBST(PAM_LIBS) AM_CONDITIONAL([HAVE_PAM], [test "x$have_pam" != xno]) +AC_ARG_ENABLE([acl], + AS_HELP_STRING([--disable-acl],[Disable optional ACL support]), + [case "${enableval}" in + yes) have_acl=yes ;; + no) have_acl=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --disable-acl) ;; + esac], + [have_acl=auto]) + +if test "x${have_acl}" != xno ; then + AC_CHECK_HEADERS( + [sys/acl.h acl/libacl.h], + [have_acl=yes], + [if test "x$have_acl" = xyes ; then + AC_MSG_ERROR([*** ACL headers not found.]) + fi]) + + AC_CHECK_LIB( + [acl], + [acl_get_file], + [have_acl=yes], + [if test "x$have_acl" = xyes ; then + AC_MSG_ERROR([*** libacl not found.]) + fi]) + + if test "x$have_acl" = xyes ; then + ACL_LIBS="-lacl" + AC_DEFINE(HAVE_ACL, 1, [ACL available]) + else + have_acl=no + fi +else + ACL_LIBS= +fi +AC_SUBST(ACL_LIBS) +AM_CONDITIONAL([HAVE_ACL], [test "x$have_acl" != xno]) + AC_ARG_ENABLE([audit], AS_HELP_STRING([--disable-audit],[Disable optional AUDIT support]), [case "${enableval}" in @@ -496,6 +533,7 @@ echo " PAM: ${have_pam} AUDIT: ${have_audit} SELinux: ${have_selinux} + ACL: ${have_acl} binfmt: ${have_binfmt} prefix: ${prefix} root dir: ${with_rootdir}