summaryrefslogtreecommitdiff
path: root/tcwg_kernel-build.sh
diff options
context:
space:
mode:
authorMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2019-01-21 11:09:28 +0000
committerMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2019-01-22 13:41:28 +0000
commit8cef89477b94fb928da6fc6357a33e274b2de96d (patch)
treee7e324f2c3a7eb07a6ec2f524569f7af45484161 /tcwg_kernel-build.sh
parent71808ab9b6a4ff8b3e6fa6c208cd35af0728e29c (diff)
jenkins-helpers.sh: Improve run_step functionality.
This is partly fix, partly cleanup. At the moment in bisection mode artifacts/results are not populated until first step successfully executes. This means that for bisections of binutils, gcc, and llvm regressions the results file is empty if the build of these projects fails (i.e., no successful steps at all). This causes empty clauses in the bisection emails due to artifacts/results file being empty. We could have fixed this by adding === Starting Y build <value of successful previous step> === to the top of every build step, but instead we refactor and cleanup run_step support to handle constant-value result entries. In addition to current "stop_on_fail" mode we add "skip_on_fail" and "reset_on_fail" modes, which simplify error handling for most build steps. Change-Id: Ic2d1a15fa490ec25be741cdaf718442260c52e6d
Diffstat (limited to 'tcwg_kernel-build.sh')
-rwxr-xr-xtcwg_kernel-build.sh21
1 files changed, 10 insertions, 11 deletions
diff --git a/tcwg_kernel-build.sh b/tcwg_kernel-build.sh
index a8188fce..6eda2248 100755
--- a/tcwg_kernel-build.sh
+++ b/tcwg_kernel-build.sh
@@ -182,8 +182,7 @@ count_linux_objs ()
(
set -euf -o pipefail
- # Run only if compiler was successfully built in the previous step.
- if [ -f $run_step_prev_artifacts/build-ok ]; then
+ if true; then
build_linux &
local res=0; wait $! || res=$?
@@ -244,20 +243,20 @@ no_regression_p ()
)
}
-run_step reset_artifacts
+run_step stop_on_fail -10 reset_artifacts
case "${rr[toolchain]}" in
gnu)
- run_step prepare_abe
- run_step build_abe binutils
- run_step build_abe stage1
+ run_step stop_on_fail x prepare_abe
+ run_step skip_on_fail -9 build_abe binutils
+ run_step skip_on_fail -8 build_abe stage1
;;
llvm)
- run_step build_llvm
+ run_step skip_on_fail -1 build_llvm
;;
esac
-run_step count_linux_objs
-run_step check_regression
-run_step update_baseline
-run_step push_baseline
+run_step skip_on_fail x count_linux_objs
+run_step reset_on_fail x check_regression
+run_step stop_on_fail x update_baseline
+run_step stop_on_fail x push_baseline
trap "" EXIT