From 0b0b0bc9c58c768cd2f4f66b9454bb21539c6d9d Mon Sep 17 00:00:00 2001 From: midoks Date: Sun, 13 Aug 2023 13:22:46 +0800 Subject: [PATCH] Update bcmath.sh --- plugins/php/versions/common/bcmath.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/plugins/php/versions/common/bcmath.sh b/plugins/php/versions/common/bcmath.sh index f297456d4..20b18c770 100755 --- a/plugins/php/versions/common/bcmath.sh +++ b/plugins/php/versions/common/bcmath.sh @@ -12,7 +12,7 @@ rootPath=$(dirname "$rootPath") rootPath=$(dirname "$rootPath") serverPath=$(dirname "$rootPath") sourcePath=${serverPath}/source/php - +SYS_ARCH=`arch` actionType=$1 version=$2 @@ -54,8 +54,13 @@ Install_lib() cd $sourcePath/php${version}/ext/${LIBNAME} + OPTIONS="" + if [ "${SYS_ARCH}" == "aarch64" ] && [ "$version" -lt "56" ];then + OPTIONS="$OPTIONS --build=aarch64-unknown-linux-gnu --host=aarch64-unknown-linux-gnu" + fi + $serverPath/php/$version/bin/phpize - ./configure --with-php-config=$serverPath/php/$version/bin/php-config + ./configure --with-php-config=$serverPath/php/$version/bin/php-config $OPTIONS make clean && make && make install && make clean