From 4ea7f3467d0f0023d565c88323bdae587144d1f8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Micha=C5=82=20G=C3=B3rny?= Date: Fri, 2 Mar 2018 16:19:34 +0100 Subject: [PATCH] Support using acl_* functions on *BSD The *BSD systems have ACL routines built-in in libc rather than in separate libacl. Update the configure check to detect that and enable ACL support without adding 'acl' library. --- sapi/fpm/config.m4 | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/sapi/fpm/config.m4 b/sapi/fpm/config.m4 index e6a1a49857..8a9c60a4f9 100644 --- a/sapi/fpm/config.m4 +++ b/sapi/fpm/config.m4 @@ -630,11 +630,16 @@ if test "$PHP_FPM" != "no"; then if test "$PHP_FPM_ACL" != "no" ; then AC_CHECK_HEADERS([sys/acl.h]) - AC_CHECK_LIB(acl, acl_free, [ - PHP_ADD_LIBRARY(acl) + dnl *BSD has acl_* built into libc + AC_CHECK_FUNC(acl_free, [ AC_DEFINE(HAVE_FPM_ACL, 1, [ POSIX Access Control List ]) ],[ - AC_MSG_ERROR(libacl required not found) + AC_CHECK_LIB(acl, acl_free, [ + PHP_ADD_LIBRARY(acl) + AC_DEFINE(HAVE_FPM_ACL, 1, [ POSIX Access Control List ]) + ],[ + AC_MSG_ERROR(libacl required not found) + ]) ]) fi -- 2.40.0