summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorMattia Rizzolo <mattia@mapreri.org>2015-04-06 14:48:15 +0200
committerHolger Levsen <holger@layer-acht.org>2015-04-18 17:20:08 +0200
commit63a2d41c77ab8a0f1f4f338bd54a4e418cf5f482 (patch)
tree56f5932d7c60592b4c339d57b40580d45167efa1 /bin
parenta5ead45478ec7ba4a5a75581d62f60d98b953fc5 (diff)
downloadjenkins.debian.net-63a2d41c77ab8a0f1f4f338bd54a4e418cf5f482.tar.xz
reproducible: build: refactor: slim down the call_debbindiff() function: strip out init_debbindiff() where we check for locks
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_build.sh8
1 files changed, 6 insertions, 2 deletions
diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh
index 94c66b29..16ad7996 100755
--- a/bin/reproducible_build.sh
+++ b/bin/reproducible_build.sh
@@ -81,10 +81,10 @@ print_out_duration() {
echo "$(date) - total duration: ${HOUR}h ${MIN}m ${SEC}s." | tee -a ${RBUILDLOG}
}
-call_debbindiff() {
+init_debbindiff() {
# the schroot for debbindiff gets updated once a day. wait patiently if that's the case
if [ -f $DBDCHROOT_WRITELOCK ] || [ -f $DBDCHROOT_READLOCK ] ; then
- for i in $(seq 0 200) ; do # this loop also exists in _common.sh and _setup_pbuilder.sh
+ for i in $(seq 0 200) ; do # this loop also exists in _common.sh and _setup_schroot.sh
sleep 15
echo "sleeping 15s, debbindiff schroot is locked."
if [ ! -f $DBDCHROOT_WRITELOCK ] && [ ! -f $DBDCHROOT_READLOCK ] ; then
@@ -100,6 +100,10 @@ call_debbindiff() {
# write locks are only done by the schroot setup job
touch $DBDCHROOT_READLOCK
fi
+}
+
+call_debbindiff() {
+ init_debbindiff
echo | tee -a ${RBUILDLOG}
TIMEOUT="30m" # don't forget to also change the "seq 0 200" loop 17 lines above
DBDVERSION="$(schroot --directory /tmp -c source:jenkins-reproducible-unstable-debbindiff debbindiff -- --version 2>&1)"