From 734003bbeb6b5d5bfc4c27f946d3905b33e879f1 Mon Sep 17 00:00:00 2001 From: Stephan Raue Date: Fri, 23 Sep 2016 14:29:49 -0700 Subject: [PATCH] config/functions: add support for 'setup_toolchain() init' and 'setup_toolchain() bootstrap' Signed-off-by: Stephan Raue --- config/functions | 4 ++-- scripts/build | 6 +----- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/config/functions b/config/functions index fdfbc8c869..a8ec026efe 100644 --- a/config/functions +++ b/config/functions @@ -1,6 +1,6 @@ setup_toolchain() { case "$1" in - target) + target|init) export DESTIMAGE="target" export CC="$TARGET_CC" export CXX="$TARGET_CXX" @@ -39,7 +39,7 @@ setup_toolchain() { export _python_prefix=/usr export _python_exec_prefix=/usr ;; - host) + host|bootstrap) export DESTIMAGE="host" export AWK=$HOST_AWK export CC="$HOST_CC" diff --git a/scripts/build b/scripts/build index 78579c4856..a7684d6a0a 100755 --- a/scripts/build +++ b/scripts/build @@ -66,11 +66,7 @@ fi if [ ! -f $STAMP ]; then rm -f $STAMP - if [ "$TARGET" = "bootstrap" -o "$TARGET" = "init" ]; then - setup_toolchain target - else - setup_toolchain $TARGET - fi + setup_toolchain $TARGET # unset functions unset -f pre_build_target