This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
osmith gerrit-no-reply at lists.osmocom.orgosmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ci/+/22223 ) Change subject: OBS: nightly: depend on dummy pkg of current date ...................................................................... OBS: nightly: depend on dummy pkg of current date Make it impossible to mix nightly/next builds of different dates. Related: OS#4733 Change-Id: Ida8db8e6c91834c9d9e43694d9b4daea55a2f8f8 --- M scripts/common-obs.sh M scripts/osmocom-nightly-packages.sh 2 files changed, 18 insertions(+), 3 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-ci refs/changes/23/22223/1 diff --git a/scripts/common-obs.sh b/scripts/common-obs.sh index adfa076..40cacf2 100644 --- a/scripts/common-obs.sh +++ b/scripts/common-obs.sh @@ -20,16 +20,22 @@ # $1: path to debian/control file # $2: package name (e.g. "libosmocore") # $3: dependency package name (e.g. "osmocom-nightly") +# $4: dependency package version (optional, e.g. "1.0.0.202101151122") osmo_obs_add_depend_deb() { local d_control="$1" local pkgname="$2" local depend="$3" + local dependver="$4" if [ "$pkgname" = "$depend" ]; then echo "NOTE: skipping dependency on itself: $depend" return fi + if [ -n "$dependver" ]; then + depend="$depend (= $dependver)" + fi + # Note: adding the comma at the end should be fine. If there is a Depends: line, it is most likely not empty. It # should at least have ${misc:Depends} according to lintian. sed "s/^Depends: /Depends: $depend, /g" -i "$d_control" @@ -41,16 +47,22 @@ # $1: path to rpm spec file # $2: package name (e.g. "libosmocore") # $3: dependency package name (e.g. "osmocom-nightly") +# $4: dependency package version (optional, e.g. "1.0.0.202101151122") osmo_obs_add_depend_rpm() { local spec="$1" local pkgname="$2" local depend="$3" + local dependver="$4" if [ "$pkgname" = "$depend" ]; then echo "NOTE: skipping dependency on itself: $depend" return fi + if [ -n "$dependver" ]; then + depend="$depend = $dependver" + fi + ( while IFS= read -r line; do echo "$line" @@ -75,11 +87,13 @@ # $2: repodir (path to git repository) # $3: package name (e.g. "libosmocore") # $4: dependency package name (e.g. "osmocom-nightly") +# $5: dependency package version (optional, e.g. "1.0.0.202101151122") osmo_obs_add_rpm_spec() { local oscdir="$1" local repodir="$2" local name="$3" local depend="$4" + local dependver="$5" local spec_in="$(find "$repodir" -name "$name.spec.in")" local spec="$oscdir/$name.spec" local tarball @@ -92,7 +106,7 @@ cp "$spec_in" "$spec" - osmo_obs_add_depend_rpm "$spec" "$name" "$depend" + osmo_obs_add_depend_rpm "$spec" "$name" "$depend" "$dependver" # Set version version="$(grep "^Version: " "$oscdir"/*.dsc | cut -d: -f2 | xargs)" diff --git a/scripts/osmocom-nightly-packages.sh b/scripts/osmocom-nightly-packages.sh index ced0998..a6340d1 100755 --- a/scripts/osmocom-nightly-packages.sh +++ b/scripts/osmocom-nightly-packages.sh @@ -109,6 +109,7 @@ local gitbpargs=$3 local repodir=$REPO/$name local oscdir=$REPO/osc/$PROJ/$name + local dependver="$OSMO_OBS_CONFLICT_PKGVER.$DT" if [ -z "$changelog" ] ; then changelog=commit @@ -129,7 +130,7 @@ if [ "$changelog" = "commit" ] ; then VER=$(get_commit_version) - osmo_obs_add_depend_deb "./debian/control" "$name" "osmocom-$FEED" + osmo_obs_add_depend_deb "./debian/control" "$name" "osmocom-$FEED" "$dependver" dch -b -v "$VER" -m "Snapshot build" git commit -m "$VER snapshot" debian/ fi @@ -152,7 +153,7 @@ cd "$oscdir" osc add -- *.tar* *.dsc - osmo_obs_add_rpm_spec "$oscdir" "$repodir" "$name" "osmocom-$FEED" + osmo_obs_add_rpm_spec "$oscdir" "$repodir" "$name" "osmocom-$FEED" "$dependver" osc ci -m "Snapshot $name $DT" --noservice } -- To view, visit https://gerrit.osmocom.org/c/osmo-ci/+/22223 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-ci Gerrit-Branch: master Gerrit-Change-Id: Ida8db8e6c91834c9d9e43694d9b4daea55a2f8f8 Gerrit-Change-Number: 22223 Gerrit-PatchSet: 1 Gerrit-Owner: osmith <osmith at sysmocom.de> Gerrit-MessageType: newchange -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210115/c1e0bbf0/attachment.htm>