summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRemi Collet <remi@php.net>2014-07-20 11:16:09 +0200
committerRemi Collet <remi@php.net>2014-07-20 11:16:09 +0200
commita9c8499d4b7a328482e93e6aa8273cb2d70c5bbd (patch)
tree5a56b00358d995c16cf56c3b75c78ed2d0800cb3
parent6055a53d34c445c7268ed3759854c8163653d1e7 (diff)
parentd55f23ea5a5565fa0f0439e0fa5706dcf49aa6af (diff)
downloadphp-git-a9c8499d4b7a328482e93e6aa8273cb2d70c5bbd.tar.gz
Merge branch 'PHP-5.6'
* PHP-5.6: See bug #67635
-rw-r--r--sapi/fpm/config.m416
1 files changed, 14 insertions, 2 deletions
diff --git a/sapi/fpm/config.m4 b/sapi/fpm/config.m4
index fa9aaa6e94..9c10aa6be2 100644
--- a/sapi/fpm/config.m4
+++ b/sapi/fpm/config.m4
@@ -589,17 +589,29 @@ if test "$PHP_FPM" != "no"; then
fi
unset SYSTEMD_LIBS
unset SYSTEMD_INCS
+
if test -x "$PKG_CONFIG" && $PKG_CONFIG --exists libsystemd; then
+ dnl systemd version >= 209 provides libsystemd
AC_MSG_CHECKING([for libsystemd])
SYSTEMD_LIBS=`$PKG_CONFIG --libs libsystemd`
SYSTEMD_INCS=`$PKG_CONFIG --cflags-only-I libsystemd`
SYSTEMD_VERS=`$PKG_CONFIG --modversion libsystemd`
- HAVE_SD_DAEMON_H="yes"
AC_MSG_RESULT([version $SYSTEMD_VERS])
+
+ elif test -x "$PKG_CONFIG" && $PKG_CONFIG --exists libsystemd-daemon; then
+ dnl systemd version < 209 provides libsystemd-daemon
+ AC_MSG_CHECKING([for libsystemd-daemon])
+ SYSTEMD_LIBS=`$PKG_CONFIG --libs libsystemd-daemon`
+ SYSTEMD_INCS=`$PKG_CONFIG --cflags-only-I libsystemd-daemon`
+ SYSTEMD_VERS=`$PKG_CONFIG --modversion libsystemd-daemon`
+ AC_MSG_RESULT([version $SYSTEMD_VERS])
+
else
+ dnl failback when no pkg-config
AC_CHECK_LIB(systemd-daemon, sd_notify, SYSTEMD_LIBS="-lsystemd-daemon")
- AC_CHECK_HEADERS(systemd/sd-daemon.h, [HAVE_SD_DAEMON_H="yes"], [HAVE_SD_DAEMON_H="no"])
fi
+
+ AC_CHECK_HEADERS(systemd/sd-daemon.h, [HAVE_SD_DAEMON_H="yes"], [HAVE_SD_DAEMON_H="no"])
if test $HAVE_SD_DAEMON_H = "no" || test -z "${SYSTEMD_LIBS}"; then
AC_MSG_ERROR([Your system does not support systemd.])
else