Subject: Re: make update - wrong order?
To: segv@netctl.net <segv@netctl.net>
From: Julio M. Merino Vidal <jmmv84@gmail.com>
List: tech-pkg
Date: 10/03/2005 15:39:24
On 10/3/05, segv@netctl.net <segv@netctl.net> wrote:
> On Mon, 3 Oct 2005 15:02:41 +0200
> Jeroen Ruigrok/asmodai <asmodai@in-nomine.org> wrote:
>
> > -On [20051003 14:56], segv@netctl.net (segv@netctl.net) wrote:
> > >Maybe that's because you can have chains of dependancies:
> > >
> > >A->B->C->D
> > >
> > >So A depends on B, which depends on C, which depends on D
> > >To update A, you'd have to remove D, C, B in this order and rebuild th=
em.
> >
> > Wouldn't it be better to do:
> >
> > build D, deinstall D, install D,
> > build C, deinstall C, install C,
> > et cetera?
>
> OK
>
> A_v1 -> B_v1 -> C_v1 -> D_v1
>
> where v<num> is the version number of a package
> If C_v1 depends on D_v1 and you build D_v2 then remove D_v1 and install D=
_v2,
> then C_v1 will break (possibly breaking dependant packages B_v1 and A_v1)
>
> Many packages include shared libraries, where version numbers are critica=
l. If
> an application has been linked to a particular library and you remove tha=
t
> library and install a new (possibly incompatible) version, that applicati=
on
> will not run properly, or it may run but crash randomly.

Yes, but Jeroen's approach could maximize package availability.  Of course,
once you have updated the lowest package in the dependency chain, you
cannot warrant that all the other ones will work until you've rebuilt them,=
 but
they will be fine in most cases.

OTOH, what Jeroen proposes could be "easily" implemented by writing a
little script and using make replace (which is intended to do what he wants=
,
given that the package has to be updated while others need it).

--
Julio M. Merino Vidal <jmmv84@gmail.com>
http://www.livejournal.com/users/jmmv/
The NetBSD Project - http://www.NetBSD.org/