Patchwork [4,of,4,STABLE] builddeb: add distroseries to tagged versions

login
register
mail settings
Submitter Sean Farley
Date May 6, 2016, 9:38 p.m.
Message ID <067233b570a6b42acf67.1462570720@laptop.office.atlassian.com>
Download mbox | patch
Permalink /patch/14954/
State Superseded
Headers show

Comments

Sean Farley - May 6, 2016, 9:38 p.m.
# HG changeset patch
# User Sean Farley <sean@farley.io>
# Date 1462568951 25200
#      Fri May 06 14:09:11 2016 -0700
# Branch stable
# Node ID 067233b570a6b42acf67c008ee6613a2a3deaee3
# Parent  90fb69c3cafc3a3d8feea7342be869b2f46ad354
# EXP-Topic docker-ppa
builddeb: add distroseries to tagged versions

This is needed so that launchpad and friends have a unique version number for
each distroseries (trusty, wily, xenial, etc). It was discovered when trying to
upload 3.8 to launchpad.
Sean Farley - May 7, 2016, 6:36 a.m.
Sean Farley <sean@farley.io> writes:

> # HG changeset patch
> # User Sean Farley <sean@farley.io>
> # Date 1462568951 25200
> #      Fri May 06 14:09:11 2016 -0700
> # Branch stable
> # Node ID 067233b570a6b42acf67c008ee6613a2a3deaee3
> # Parent  90fb69c3cafc3a3d8feea7342be869b2f46ad354
> # EXP-Topic docker-ppa
> builddeb: add distroseries to tagged versions
>
> This is needed so that launchpad and friends have a unique version number for
> each distroseries (trusty, wily, xenial, etc). It was discovered when trying to
> upload 3.8 to launchpad.

Please disregard this, I forgot to update the tests.

Patch

diff --git a/contrib/builddeb b/contrib/builddeb
--- a/contrib/builddeb
+++ b/contrib/builddeb
@@ -56,10 +56,14 @@  debver="$version"
 if [ -n "$type" ] ; then
     debver="$debver~$type"
 fi
 if [ -n "$distance" ] ; then
     debver="$debver+$distance-$CODENAME-$node"
+elif [ "$DEBFLAGS" = "-S" ] ; then
+    # for building a ppa (--source-only) for a release (distance == 0), we need
+    # to version the distroseries so that we can upload to launchpad
+    debver="$debver~${CODENAME}1"
 fi
 
 control=debian/control
 changelog=debian/changelog