summaryrefslogtreecommitdiff
path: root/jenkins.sh
diff options
context:
space:
mode:
authorMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2015-07-18 11:45:09 +0200
committerMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2015-07-18 11:46:26 +0200
commit0a3ae361c151e609a578d4c727ce79c80af3833d (patch)
tree4c2f451907d29a71a1afbe3cbe4f4b407882d827 /jenkins.sh
parent442c86dc7fb7c0565c9cc9665515289b8f4a9e68 (diff)
Upload build logs whenever logserver is provided
Right now we test native AArchXX toolchains by bootstrapping them, but without running testsuites (which takes 3-4 hours). Without uploading /something/ after a successfull bootstrap to the logserver, we are bound to re-build the toolchains needlessly. This patch fixes that. Change-Id: Ia5c2e057f625cc62c461d023b3acc4f8003deada
Diffstat (limited to 'jenkins.sh')
-rwxr-xr-xjenkins.sh31
1 files changed, 15 insertions, 16 deletions
diff --git a/jenkins.sh b/jenkins.sh
index f8c8bc06..41a33d72 100755
--- a/jenkins.sh
+++ b/jenkins.sh
@@ -407,7 +407,7 @@ else
fi
# This becomes the path on the remote file server
-if test x"${logserver}" != x"" -a x"${runtests}" = xtrue; then
+if test x"${logserver}" != x""; then
# Re-eval $dir as we now have full range of variables available.
eval dir="$logname"
ssh ${logserver} mkdir -p ${basedir}/${dir}
@@ -453,35 +453,34 @@ fi
# This setups all the files needed by tcwgweb
if test x"${logserver}" != x"" && test x"${sums}" != x -o x"${runtests}" != x"true"; then
+ logs_dir=$(mktemp -d)
+
if test x"${sums}" != x; then
test_logs=""
for s in ${sums}; do
test_logs="$test_logs ${s%.sum}.log"
done
- logs_dir=$(mktemp -d)
cp ${sums} ${test_logs} ${logs_dir}/ || status=1
# Copy over the logs from make check, which we need to find testcase errors.
checks="`find ${user_workspace} -name check\*.log`"
cp ${checks} ${logs_dir}/ || status=1
-
- # Copy over the build logs
- logs="`find ${user_workspace} -name make\*.log`"
- cp ${logs} ${logs_dir}/ || status=1
+ fi
- # Copy stdout and stderr output from abe.
- cp build.out build.err ${logs_dir}/ || status=1
+ # Copy over the build logs
+ logs="`find ${user_workspace} -name make\*.log`"
+ cp ${logs} ${logs_dir}/ || status=1
- xz ${logs_dir}/* || status=1
- scp ${logs_dir}/* ${logserver}:${basedir}/${dir}/ || status=1
- rm -rf ${logs_dir} || status=1
-# scp ${abe_dir}/tcwgweb.sh ${logserver}:/tmp/tcwgweb$$.sh
-# ssh ${logserver} /tmp/tcwgweb$$.sh --email --base ${basedir}/${dir}
-# ssh ${logserver} rm -f /tmp/tcwgweb$$.sh
+ # Copy stdout and stderr output from abe.
+ cp build.out build.err ${logs_dir}/ || status=1
+
+ xz ${logs_dir}/* || status=1
+ scp ${logs_dir}/* ${logserver}:${basedir}/${dir}/ || status=1
+ rm -rf ${logs_dir} || status=1
+
+ echo "Uploaded test results and build logs to ${logserver}:${basedir}/${dir}/ with status: $status"
- echo "Sent test results"
- fi
if test x"${tarsrc}" = xtrue -a x"${release}" != x; then
allfiles="`ls ${user_snapshots}/*${release}*.xz`"
srcfiles="`echo ${allfiles} | egrep -v "arm|aarch"`"