aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/osmocom-latest-packages.sh
diff options
context:
space:
mode:
authorOliver Smith <osmith@sysmocom.de>2019-06-13 15:53:39 +0200
committerOliver Smith <osmith@sysmocom.de>2019-06-17 12:21:32 +0200
commite26866af0da040a7ed37b17280a7f16a96999e09 (patch)
tree4543985520878f28c8f9ae178cc042aea45358ed /scripts/osmocom-latest-packages.sh
parent83f4f25d7cae8bb1ccfa4478304c8c8480651d59 (diff)
OBS: make nightly packages conflict with latest
Add conflicting dummy packages osmocom-nightly and osmocom-latest, and make all packages from each repository depend on the right one. As usually, the latest packages will only get changed when a new release appears. So the dependency will get introduced after tagging a new release. I have tested in an own OBS namespace, that everything works as expected. Related: OS#2640 Change-Id: I79c45e798c10a65443b9fb9ecb54393d1918608a
Diffstat (limited to 'scripts/osmocom-latest-packages.sh')
-rwxr-xr-xscripts/osmocom-latest-packages.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/scripts/osmocom-latest-packages.sh b/scripts/osmocom-latest-packages.sh
index 543c43a..2a9e28d 100755
--- a/scripts/osmocom-latest-packages.sh
+++ b/scripts/osmocom-latest-packages.sh
@@ -1,4 +1,5 @@
#!/bin/sh
+. "$(dirname "$0")/common-obs.sh"
# requirements
# apt install git-buildpackage osc git
@@ -28,6 +29,9 @@ prepare() {
fi
[ -d "$DEBSRCDIR" ] && rm -rf "$DEBSRCDIR"
mkdir "$DEBSRCDIR"
+
+ cd "$TOP"
+ osmo_obs_prepare_conflict "osmocom-latest" "osmocom-nightly"
}
get_last_tag() {
@@ -84,6 +88,11 @@ build() {
VER=$(get_last_tag "$project")
if [ -x ./git-version-gen ]; then
./git-version-gen . > .tarball-version 2>/dev/null
+ fi
+
+ osmo_obs_add_debian_dependency "./debian/control" "osmocom-latest"
+
+ if [ -x ./git-version-gen ]; then
gbp buildpackage -S -uc -us -d --git-ignore-branch "--git-export-dir=$output" \
"--git-debian-branch=$VER" --git-ignore-new $gitbpargs \
--git-postexport='cp $GBP_GIT_DIR/../.tarball-version $GBP_TMP_DIR/'
@@ -152,6 +161,7 @@ build_osmocom() {
checkout_copy_debian8_jessie "osmo-gsm-manuals"
+ build osmocom-latest
build limesuite --git-upstream-tree="$(get_last_tag limesuite)"
build osmo-gsm-manuals
build osmo-gsm-manuals-debian8-jessie