summaryrefslogtreecommitdiff
path: root/MakeRelease.job
diff options
context:
space:
mode:
authorChristophe Lyon <christophe.lyon@linaro.org>2016-12-15 18:00:07 +0100
committerChristophe Lyon <christophe.lyon@linaro.org>2017-01-10 17:23:54 +0100
commitcc657f90399c6a9d2c8dd213004e043fe530abe6 (patch)
treec890f58d928365dd4fda510aefb56781569d091f /MakeRelease.job
parent7831446563d8e8baf85e0fc578afe9fdd951d5fb (diff)
MakeRelease.job: add --binariesdir and --logsdir options.
They are currently optional, the script uses them if present, but still computes default values and warns if they differ. Change-Id: I62b1ab5ce19a430ed274091650d8a6cc703bff09
Diffstat (limited to 'MakeRelease.job')
-rwxr-xr-xMakeRelease.job24
1 files changed, 23 insertions, 1 deletions
diff --git a/MakeRelease.job b/MakeRelease.job
index 11ed9841..126badfd 100755
--- a/MakeRelease.job
+++ b/MakeRelease.job
@@ -16,6 +16,8 @@ usage() {
echo " --glibc XXX - Specify Glibc version to build"
echo " --gcc XXX - Specify GCC version to build"
echo " --binutils XXX - Specify Binutils version to build"
+ echo " --binariesdir XXX - Specify where to upload the generated binaries"
+ echo " --logsdir XXX - Specify where to upload the logs"
echo " --help"
exit
}
@@ -38,8 +40,10 @@ extra=
toolchain_config=""
user_workspace="${WORKSPACE:-/home/${USER:-buildslave}/workspace}"
abe_dir=
+binariesdir=
+logsdir=
-OPTS="`getopt -o t:f:d:w:m:l:g:u:h -l target:,date:,fileserver:,workspace:,toolchainconfig:,manifest:,glibc:,gcc:,binutils:,help,abedir:`"
+OPTS="`getopt -o t:f:d:w:m:l:g:u:h -l target:,date:,fileserver:,workspace:,toolchainconfig:,manifest:,glibc:,gcc:,binutils:,help,abedir:,binariesdir:,logsdir:`"
while test $# -gt 0; do
case $1 in
--abedir) abe_dir=$2 ;;
@@ -52,6 +56,8 @@ while test $# -gt 0; do
-l|--glibc) glibc_src=$2 ;;
-g|--gcc) gcc_src=$2 ;;
-u|--binutils) binutils_src=$2 ;;
+ --binariesdir) binariesdir=$2 ;;
+ --logsdir) logsdir=$2 ;;
-h|--help) usage ;;
--) break ;;
esac
@@ -202,6 +208,22 @@ buildid=`printf '%04d' ${BUILD_NUMBER}`
binaries="releases/binaries/${gcc_release}-${series_date}-${buildid}/${target}"
logs="releases/logs/${gcc_release}-${series_date}-${buildid}/${target}"
+if [ "x${binariesdir}" != "x" -a \
+ "x${binariesdir}" != "x${binaries}" ]; then
+ echo "WARNING: Provided binaries dirname does not match with what was computed"
+ echo "Provided: ${binariesdir}"
+ echo "Computed: ${binaries}"
+ binaries=${binariesdir}
+fi
+
+if [ "x${logsdir}" != "x" -a \
+ "x${logsdir}" != "x${logs}" ]; then
+ echo "WARNING: Provided logs dirname does not match with what was computed"
+ echo "Provided: ${logsdir}"
+ echo "Computed: ${logs}"
+ logs=${logsdir}
+fi
+
# Copy the build log to the fileserver
if test -e ${logfile}; then
echo "Compressing log file..."