Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 08 Feb 2001 09:49:40 -0800
From:      Jordan Hubbard <jkh@winston.osd.bsdi.com>
To:        Brian Kraemer <kraemer@u.washington.edu>
Cc:        freebsd-ports@FreeBSD.ORG
Subject:   Re: Ports updating... Good ways? 
Message-ID:  <17287.981654580@winston.osd.bsdi.com>
In-Reply-To: Message from Brian Kraemer <kraemer@u.washington.edu>  of "Thu, 08 Feb 2001 09:28:47 PST." <Pine.A41.4.21.0102080920510.79438-100000@mead4.u.washington.edu> 

next in thread | previous in thread | raw e-mail | index | archive | help
[cc line trimmed to just include -ports; this is clearly applicable to ONLY
 that mailing list]

> What about extending "make" so that it is possible to do the following:
> 
>   $ cd /usr/ports/foo/bar
>   $ make update
> 
> "make" would then automatically deal with updating dependencies for that
> specific port, remove the old version and build the new one.

Well, this is a cool concept on the face of it but it needs more
infrastructure work to actually function.

Let's say I install the "gtkwooba" port which depends on gtk,
libtools, glib and libwooba.  Then I come back over a year later and
do a "make update" in gtkwooba.  It's pretty much a surety that just
about everything it depends on has been updated, so I have to upgrade
gtk, libtools, glib and libwooba too.  Because of the other things
which depend on them and the manner in which they're constructed,
however, these four items fall into different categories:

gtk:	  older version cannot be removed, new version must go alongside

libtools, glib: older versions can be replaced by new version with full
	  backwards compatibility

libwooba: no other dependencies, can be replaced by new version with
	  no other concerns

Now there may also be a safe way to achieve the upgrades in all cases,
depending on the skill and dedication of the people maintaining the
ports, but the ports collection doesn't currently have enough
descriptive metadata to be *sure* of that or to know when it can
safely pkg_delete an older version.

That's why more sophisticated package management systems than our own
have keywords like "replaces", "augments" and "occludes" in their
metadata, each followed by a list of previous versions for which that
keyword applies.  If it replaces a version, it's backwards compatible
with that version.  If it augments a version, it's strictly an upgrade
kit (e.g. just the deltas) and if it occludes a version, it means you
have to have both installed if there are remaining dependencies on the
old version.  Reference counts also help for knowing when the last
dependency on something drops away and you can remove it too. :)

Anyway, "make update" is basically a feature which is awaiting a Ports
Hero to come along and add the necessary intelligence to actually
automate it properly. :)

- Jordan


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?17287.981654580>