From e0f816b0de333b4c318a24237a3278144985136c Mon Sep 17 00:00:00 2001 From: Thomas Schwinge Date: Sun, 23 Dec 2012 15:57:24 +0100 Subject: process: Fix »no step/action/host specified« cases. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- process | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/process b/process index 9688cb85..9a6864e4 100755 --- a/process +++ b/process @@ -6,6 +6,7 @@ set -e -x # passed to another shell. project=$1 +[ $# = 0 ] || shift build_suffix=.build case $project in binutils) @@ -34,17 +35,17 @@ case $project in exit 1 ;; esac -shift step=$1 +[ $# = 0 ] || shift case $step in build | install | test) ;; '') # If there is no step specified, try a default set. - "$0" "$project" build - "$0" "$project" install - "$0" "$project" test + "$0" "$project" build "$@" + "$0" "$project" install "$@" + "$0" "$project" test "$@" exit ;; *) @@ -52,16 +53,16 @@ case $step in exit 1 ;; esac -shift action=$1 +[ $# = 0 ] || shift case $action in fetch | diff) ;; '') # If there is no action specified, try a default set. - "$0" "$project" "$step" fetch - "$0" "$project" "$step" diff + "$0" "$project" "$step" fetch "$@" + "$0" "$project" "$step" diff "$@" exit ;; *) @@ -69,11 +70,11 @@ case $action in exit 1 ;; esac -shift case $project:$action in binutils:fetch | gcc:fetch | gdb:fetch | glibc:fetch) host=$1 + [ $# = 0 ] || shift case $host in coulomb.SCHWINGE) project_base=tmp/"$project" @@ -87,8 +88,8 @@ case $project:$action in # If there is no host specified, try a default set. : "${linux_host:?}" : "${hurd_host:?}" - "$0" "$project" "$step" "$action" "$linux_host" - "$0" "$project" "$step" "$action" "$hurd_host" + "$0" "$project" "$step" "$action" "$linux_host" "$@" + "$0" "$project" "$step" "$action" "$hurd_host" "$@" exit ;; *) @@ -96,7 +97,6 @@ case $project:$action in exit 1 ;; esac - shift [ $# = 0 ] -- cgit v1.2.3