[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Package versioning and upgrades



On Fri, Mar 27, 2015 at 05:25:51PM -0400, Lennart Sorensen wrote:
> On Fri, Mar 27, 2015 at 09:46:06PM +0100, Turbo Fredriksson wrote:
> > Since ZoL (ZFS On Linux) isn't yet in Debian GNU/Linux, I've been
> > doing my own packages for ZoL in that package repo.
> > 
> > This include changes to the installer (debian-installer, base-installer,
> > grub-installer, partman-target and partman-zfs). But because the Debian
> > GNU/Linux git repo refuses force pushes, they latest versions is now
> > in the ZoL GIT repo (https://github.com/zfsonlinux/debian-installers).
> > 
> > 
> > But I think I've painted myself into a corner regarding the upgrade
> > path.
> > 
> > I have four repos:
> > 
> > 	wheezy		=> The released ZoL version for Wheezy
> > 	wheezy-daily	=> The GIT master releases of ZoL for Wheezy
> > 	jessie		=> The released ZoL version for Jessie
> > 	jessie-daily	=> The GIT master releases of ZoL for Jessie
> > 
> > So basically, the packages in 'wheezy' and 'jessie' are identical,
> > except they're compiled on the different versions of Debian GNU/Linux.
> > 
> > Same for 'wheezy-daily' vs. 'jessie-daily'.
> > 
> > Identical, in the meaning that it uses the exact same codebase/version
> > and patch set of ZoL, just compiled for different libraries
> > on two different platform version.
> > 
> > 
> > But certain upgrade paths isn't working (which isn't much of a
> > surprise actually - didn't quite think this through I guess):
> > 
> > UPGRADE PATH			STATUS	VERSION COMPARE
> > wheezy => wheezy-daily          = YES   0.6.3-1.3-1~wheezy lt 0.6.3-38-7d90f5-wheezy
> > wheezy => jessie                = NO    0.6.3-1.3-1~wheezy lt 0.6.3-1.3-1~jessie
> > wheezy => jessie-daily          = YES   0.6.3-1.3-1~wheezy lt 0.6.3-35-7d90f5-jessie
> > wheezy-daily => jessie          = NO    0.6.3-38-7d90f5-wheezy lt 0.6.3-1.3-1~jessie
> > wheezy-daily => jessie-daily    = NO    0.6.3-38-7d90f5-wheezy lt 0.6.3-35-7d90f5-jessie
> > jessie => jessie-daily          = YES   0.6.3-1.3-1~jessie lt 0.6.3-35-7d90f5-jessie
> > 
> > The versions here is the actually versions currently in the repository,
> > and the result (YES/NO) is the status of "dpkg --compare-versions".
> 
> I suppose the big problem you have is that jessie is alphabetically lower than wheezy.
> 
> > My question now is: How do I setup/change the versioning so that all
> > of these upgrade paths work?
> 
> Well you can solve the wheezy to jessue upgradesm but I don't think you
> can solve wheezy-daily => jessie, since that really is a downgrade.
> 
> > Doing this in intermediate steps isn't a problem, but I prefer not
> > to use epochs if possible (even if that would be the simplest
> > solution :)...
> 
> If you were to do this:
> 
> Change 0.6.3-1.3-1~wheezy to 0.6.3-1.3-2~wheezy
> Change 0.6.3-1.3-1~jessie to 0.6.3-1.3-2
> Change 0.6.3-38-7d90f5-wheezy to 0.6.3-39-7d90f5~wheezy
> Change 0.6.3-35-7d90f5-jessie to 0.6.3-39-7d90f5
> 
> So always use ~wheezy suffix when building for wheezy and use no suffix
> when building for jessie, and bump the main packaging version up to make
> the new versions higher than they were before.

Alternatively, you could use release version numbers rather than code names:

0.6.3-1.3-1~Debian7 (rather than wheezy), and
0.6.3-1.3-1~Debian8 (rather than jessie)

-- 
It is easy to love a country that is famous for chocolate and beer

  -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26


Reply to: