[Qa-jenkins-scm] [jenkins.debian.net] 01/02: reproducible Arch Linux: really prevent concurrent builds of the same package

Holger Levsen holger at layer-acht.org
Thu Dec 14 11:01:46 UTC 2017


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch master
in repository jenkins.debian.net.

commit 60d6d27e37f12a057ed1c78d0bdb96c714c7d150
Author: Holger Levsen <holger at layer-acht.org>
Date:   Thu Dec 14 10:51:00 2017 +0000

    reproducible Arch Linux: really prevent concurrent builds of the same package
    
    Signed-off-by: Holger Levsen <holger at layer-acht.org>
---
 bin/reproducible_build_archlinux_pkg.sh | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/bin/reproducible_build_archlinux_pkg.sh b/bin/reproducible_build_archlinux_pkg.sh
index 8b4f463..4b6eb16 100755
--- a/bin/reproducible_build_archlinux_pkg.sh
+++ b/bin/reproducible_build_archlinux_pkg.sh
@@ -102,6 +102,8 @@ choose_package() {
 	# very simple locking…
 	if [ -f $BASE/archlinux/$REPO/$SRCPACKAGE/pkg.needs_build ] ; then
 		rm $BASE/archlinux/$REPO/$SRCPACKAGE/pkg.needs_build
+		# prevent the package from being scheduled again while its already building (which can take several hours...)
+		touch $BASE/archlinux/$REPO/$SRCPACKAGE/build1.log
 	else
 		echo "$(date -u ) - $BASE/archlinux/$REPO/$SRCPACKAGE/pkg.needs_build does not exist?!?"
 		exit 1
@@ -111,7 +113,7 @@ choose_package() {
 	# FIXME: while this is an improvement over the previous situation, where these files were kept forever
 	#        this is still bad, as now, during this build, some files are not accessable on the web anymore.
 	for file in build1.log build2.log build1.version build2.version ; do
-		[ ! -f $BASE/archlinux/$REPO/$SRCPACKAGE/pkg.$file ] || rm $BASE/archlinux/$REPO/$SRCPACKAGE/pkg.$file
+		[ ! -f $BASE/archlinux/$REPO/$SRCPACKAGE/$file ] || rm $BASE/archlinux/$REPO/$SRCPACKAGE/$file
 	done
 	for file in $BASE/archlinux/$REPO/$SRCPACKAGE/*BUILDINFO.txt $BASE/archlinux/$REPO/$SRCPACKAGE/*html ; do
 		rm $file || true

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git



More information about the Qa-jenkins-scm mailing list