Subject: Re: difficulty from renaming packages, and how to deal
To: Geert Hendrickx <ghen@telenet.be>
From: matthew sporleder <msporleder@gmail.com>
List: tech-pkg
Date: 09/21/2007 12:04:53
On 9/21/07, Geert Hendrickx <ghen@telenet.be> wrote:
> On Fri, Sep 21, 2007 at 11:23:25AM -0400, matthew sporleder wrote:
> > On 9/21/07, Geert Hendrickx <ghen@telenet.be> wrote:
> > > On Fri, Sep 21, 2007 at 10:58:12AM -0400, matthew sporleder wrote:
> > > > Maybe each pkg should get a unique PKGID so that pkgsrc would actually be
> > > > attempting to update pkgid=2574FFA instead of pkg=gconf2.
> > >
> > > And then a pkgid disappears, e.g. when we get rid of firefox15.
> >
> > Why?  It would be just as easy to point the old pkgid to whatever the
> > new firefox is.
>
> Firefox may be a bad example, upgrades usually "just work".
>
> But what with packages that have a differrent API or datafile format in
> newer versions?  E.g. if apache-1.3.x or PostgreSQL 7.x get's EOL'd, I'd
> vastly prefer my update script to error out than to blindly update it to
> the latest version.

Then maybe a combined approach would be best:
PKGID=FF01
PKGNAME=PostgreSQL7
NEWID=FFF5

PKGID=FFF5
PKGNAME=PostgreSQL8
NEWID=FFFF

PKGID=FFFF
PKGNAME=PostgreSQL9
PKGPATH=databases/postgresql9

That way you would never lose your old pkg and it could simply follow
the path of NEWID's (and prompt, fail, or whatever pkg_tools want to
do) until it finds the current one with an existing PKGPATH.