Skip to content

Commit

Permalink
Merge pull request #134 from puleeno/master
Browse files Browse the repository at this point in the history
Fix `Bad Substitution` error on Debian
  • Loading branch information
rryqszq4 authored Nov 29, 2021
2 parents 26c897c + 83b5da2 commit 62340ac
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions config
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,9 @@ fi

if [ -z "$NGX_PHP_LIBS" ]; then
PHP_VERSION="`$PHP_CONFIG --version`"
if [ ${PHP_VERSION:0:1} -ge "8" ]; then
PHP_MAJOR_VERSION=`echo $PHP_VERSION | sed -e "s#\.[0-9]*##g"`
if [ $PHP_MAJOR_VERSION -ge "8" ]; then
PHP_MAJOR_VERSION=""
else
PHP_MAJOR_VERSION=${PHP_VERSION:0:1}
fi
NGX_PHP_LIBS="`$PHP_CONFIG --ldflags` `$PHP_CONFIG --libs` -L$PHP_LIB -lphp$PHP_MAJOR_VERSION "
fi
Expand All @@ -91,4 +90,4 @@ else
CORE_LIBS="$CORE_LIBS $NGX_PHP_LIBS "
fi

have=NDK_SET_VAR . auto/have
have=NDK_SET_VAR . auto/have

0 comments on commit 62340ac

Please sign in to comment.