From b6fdef6cf733132a7690582f63858f223fee872c Mon Sep 17 00:00:00 2001 From: Benjamin Drung Date: Tue, 11 Feb 2014 19:15:11 +0100 Subject: [PATCH] Fix wrong distribution list for feature/* builds on wheezy. --- .pbuilderrc | 10 ++++++++-- debian_build.py | 8 ++++++-- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.pbuilderrc b/.pbuilderrc index 965db7b..6b977bc 100644 --- a/.pbuilderrc +++ b/.pbuilderrc @@ -74,10 +74,16 @@ if [ "$DIST" == "wheezy" ] ; then then OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/pb-$DIST pre-staging main contrib non-free |" fi - if echo ${PB_SUITE} | grep -qE "^experimental-.*" + if echo ${PB_SUITE} | grep -qE "^wheezy-dev-.*" then + BASETGZ="/var/cache/pbuilder/$NAME-experimental-wheezy-base.tgz" + BASEPATH="/var/cache/pbuilder/$NAME-experimental-wheezy-base.cow" OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/pb-$DIST pre-staging main contrib non-free |" - OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/pb-$DIST $PB_SUITE main contrib non-free |" + if wget -q --spider "http://alexandria.pb.local/pb-$DIST/dists/$PB_SUITE/Release"; then + # Only add the wheezy-dev-* repository if it already exist + # It will not exist for the first package that targets this repository. + OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/pb-$DIST $PB_SUITE main contrib non-free |" + fi fi else OTHERMIRROR="$OTHERMIRROR deb http://alexandria.pb.local/pb-squeeze production main contrib non-free |" diff --git a/debian_build.py b/debian_build.py index 402f67f..3d7d766 100755 --- a/debian_build.py +++ b/debian_build.py @@ -252,7 +252,12 @@ if __name__ == '__main__': )) exit_error() - new_dist = 'dev-{0}'.format(local_branch.replace("/", "-")) + if curr_dist == "wheezy": + new_dist = "wheezy-dev-{0}".format(local_branch.replace("/", "-")) + pb_suite = new_dist + else: + new_dist = 'dev-{0}'.format(local_branch.replace("/", "-")) + pb_suite = 'experimental-{dist}'.format(dist=curr_dist) new_version = '{version}~experimental{date}+{build}+{commit}{suffix}'.format( version=curr_version, date=daily_date, @@ -260,7 +265,6 @@ if __name__ == '__main__': commit=curr_commit_id[0:7], suffix=options.version_suffix, ) - pb_suite = 'experimental-{dist}'.format(dist=curr_dist) reprepro_base = '/srv/dev-{dist}'.format(dist=curr_dist) else: -- 2.39.5