Meta: Let serenity.sh's TARGET default to SERENITY_ARCH, not i686

This environment variable is already widely used across our build
scripts and tooling, so serenity.sh should respect it as well.
It still uses i686 as the fallback.
This commit is contained in:
Linus Groh 2021-08-28 11:20:52 +01:00
parent 041007e9f6
commit 822566ff1a
Notes: sideshowbarker 2024-07-18 05:09:53 +09:00

View file

@ -7,7 +7,7 @@ print_help() {
NAME=$(basename "$ARG0")
cat <<EOF
Usage: $NAME COMMAND [TARGET] [ARGS...]
Supported TARGETs: i686 (default), x86_64, lagom
Supported TARGETs: i686, x86_64, lagom. Defaults to SERENITY_ARCH, or i686 if not set.
Supported COMMANDs:
build: Compiles the target binaries, [ARGS...] are passed through to ninja
install: Installs the target binary
@ -84,7 +84,7 @@ fi
if [ -n "$1" ]; then
TARGET="$1"; shift
else
TARGET="i686"
TARGET="${SERENITY_ARCH:-"i686"}"
fi
CMD_ARGS=( "$@" )
CMAKE_ARGS=()