diff options
author | Tiago Natel de Moura <t.nateldemoura@f5.com> | 2020-07-28 16:17:18 +0100 |
---|---|---|
committer | Tiago Natel de Moura <t.nateldemoura@f5.com> | 2020-07-28 16:17:18 +0100 |
commit | f3471c29c0870cffff3d96c1c50c88c47a4d8009 (patch) | |
tree | 08f7fbcf73772708848cb37571349d0798d45496 /auto | |
parent | c3e6901f5328ffaaf3201dc75262e21ee0eedc32 (diff) | |
download | unit-f3471c29c0870cffff3d96c1c50c88c47a4d8009.tar.gz unit-f3471c29c0870cffff3d96c1c50c88c47a4d8009.tar.bz2 |
PHP: fixed version comparison in configure script.
Some PPAs for Ubuntu package PHP with versions like:
7.2.28-3+ubuntu18.04.1+deb.sury.org+1
But the script expected only "X.Y.Z".
The issue was introduced in:
http://hg.nginx.org/unit/rev/2ecb15904ba5
Diffstat (limited to 'auto')
-rw-r--r-- | auto/modules/php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/auto/modules/php b/auto/modules/php index 2cec2f44..75d60242 100644 --- a/auto/modules/php +++ b/auto/modules/php @@ -77,8 +77,8 @@ if /bin/sh -c "${NXT_PHP_CONFIG} --version" >> $NXT_AUTOCONF_ERR 2>&1; then $echo " + PHP SAPI: [`${NXT_PHP_CONFIG} --php-sapis`]" NXT_PHP_MAJOR_VERSION=${NXT_PHP_VERSION%%.*} - NXT_PHP_MINOR_VERSION=${NXT_PHP_VERSION#??} - NXT_PHP_MINOR_VERSION=${NXT_PHP_MINOR_VERSION%.*} + NXT_PHP_MINOR_VERSION=${NXT_PHP_VERSION#*.} + NXT_PHP_MINOR_VERSION=${NXT_PHP_MINOR_VERSION%%.*} if [ $NXT_PHP_MAJOR_VERSION = 5 -a $NXT_PHP_MINOR_VERSION -lt 4 ]; then NXT_PHP_ADDITIONAL_FLAGS=-Wno-write-strings |