Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,15 @@ AC_DEFUN([PHP_BSON_CLOCK],
fi
])

AC_MSG_CHECKING(PHP version)
PHP_FOUND_VERSION=`${PHP_CONFIG} --version`
PHP_FOUND_VERNUM=`echo "${PHP_FOUND_VERSION}" | $AWK 'BEGIN { FS = "."; } { printf "%d", ([$]1 * 100 + [$]2) * 100 + [$]3;}'`
AC_MSG_RESULT($PHP_FOUND_VERNUM)

if test "$MONGODB" != "no"; then
AC_MSG_CHECKING([Check for supported PHP versions])
PHP_MONGODB_FOUND_VERSION=`${PHP_CONFIG} --version`
PHP_MONGODB_FOUND_VERNUM=`echo "${PHP_MONGODB_FOUND_VERSION}" | $AWK 'BEGIN { FS = "."; } { printf "%d", ([$]1 * 100 + [$]2) * 100 + [$]3;}'`
AC_MSG_RESULT($PHP_MONGODB_FOUND_VERSION)
if test "$PHP_MONGODB_FOUND_VERNUM" -lt "50500"; then
AC_MSG_ERROR([not supported. Need a PHP version >= 5.5.0 (found $PHP_MONGODB_FOUND_VERSION)])
fi

PHP_ARG_ENABLE(developer-flags, whether to enable developer build flags,
[ --enable-developer-flags Enable developer flags],, no)

Expand Down