1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 14:47:46 +00:00

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

View file

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