From 6b3293e97062732f087732152ad6222eb4d281a9 Mon Sep 17 00:00:00 2001 From: Michael Spang Date: Tue, 2 Feb 2021 13:05:01 -0500 Subject: [PATCH] Put the commang line args last in gn_build.sh (#4594) This lets the command line args override the defaults, since the last assignment wins. --- gn_build.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gn_build.sh b/gn_build.sh index 00f25932ba0796..e456f895ce7d38 100755 --- a/gn_build.sh +++ b/gn_build.sh @@ -73,6 +73,7 @@ echo gn args "$CHIP_ROOT/out/custom" echo ninja -C "$CHIP_ROOT/out/custom" extra_args="" +user_args="" for arg; do case $arg in @@ -80,7 +81,7 @@ for arg; do qpg6100_enabled=1 ;; esac - extra_args+=" $arg" + user_args+=" $arg" done # Android SDK setup @@ -136,8 +137,8 @@ echo _chip_banner "Build: GN configure" -gn --root="$CHIP_ROOT" gen --check --fail-on-unused-args "$CHIP_ROOT/out/debug" --args='target_os="all"'"$extra_args" -gn --root="$CHIP_ROOT" gen --check --fail-on-unused-args "$CHIP_ROOT/out/release" --args='target_os="all" is_debug=false'"$extra_args" +gn --root="$CHIP_ROOT" gen --check --fail-on-unused-args "$CHIP_ROOT/out/debug" --args='target_os="all"'"$extra_args$user_args" +gn --root="$CHIP_ROOT" gen --check --fail-on-unused-args "$CHIP_ROOT/out/release" --args='target_os="all" is_debug=false'"$extra_arg$user_args" _chip_banner "Build: Ninja build"