diff --git a/go.sh b/go.sh index a1172206aa..9774a8cef5 100755 --- a/go.sh +++ b/go.sh @@ -2,6 +2,6 @@ # Runs the go command with the proper Go and cgo flags. GOFLAGS="$GOFLAGS -tags=nobadger,nomysql,nopgx" \ - CGO_CFLAGS="$CGO_CFLAGS $(php-config --includes) $(sh "$(dirname "$0")/mtls-cflags.sh")" \ - CGO_LDFLAGS="$CGO_LDFLAGS $(php-config --ldflags) $(php-config --libs)" \ + CGO_CFLAGS="$CGO_CFLAGS $(${PHP_CONFIG:-php-config} --includes) $(sh "$(dirname "$0")/mtls-cflags.sh")" \ + CGO_LDFLAGS="$CGO_LDFLAGS $(${PHP_CONFIG:-php-config} --ldflags) $(${PHP_CONFIG:-php-config} --libs)" \ go "$@"