Skip to content

Commit a444361

Browse files
dunglashenderkes
authored andcommitted
feat: download the mostly static binary when possible (php#1467)
* feat: download the mostly static binary when possible * cs
1 parent 401d25d commit a444361

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

install.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ DEST=${BIN_DIR}/frankenphp
1111

1212
OS=$(uname -s)
1313
ARCH=$(uname -m)
14+
GNU=""
1415

1516
if type "tput" >/dev/null 2>&1; then
1617
bold=$(tput bold || true)
@@ -31,6 +32,11 @@ Linux*)
3132
THE_ARCH_BIN=""
3233
;;
3334
esac
35+
36+
if getconf GNU_LIBC_VERSION >/dev/null 2>&1; then
37+
THE_ARCH_BIN="${THE_ARCH_BIN}-gnu"
38+
GNU=" (glibc)"
39+
fi
3440
;;
3541
Darwin*)
3642
case ${ARCH} in
@@ -58,7 +64,7 @@ fi
5864

5965
SUDO=""
6066

61-
echo "📦 Downloading ${bold}FrankenPHP${normal} for ${OS} (${ARCH}):"
67+
echo "📦 Downloading ${bold}FrankenPHP${normal} for ${OS}${GNU} (${ARCH}):"
6268

6369
# check if $DEST is writable and suppress an error message
6470
touch "${DEST}" 2>/dev/null

0 commit comments

Comments
 (0)