Subject: Re: Introducing a better way of updating packages (long)
To: None <tech-pkg@netbsd.org>
From: Julio Merino <jmmv@hispabsd.org>
List: tech-pkg
Date: 05/17/2002 10:04:34
--7ZAtKRhVyVSsbBD2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Thu, May 16, 2002 at 08:45:00PM -0500, Frederick Bruckman wrote:
>=20
> A solution:
> ----------
>=20
> So, this implementation follows the brainstorm I had nearly a year
> ago (below)...
>=20
> The first part of the idea, in brief, is to store these needed
> files in a way that doesn't require any extension to the format
> of ${PKG_DBDIR}, via the mechanism of creating packages "on the fly"
> with reserved names. So when "libfoo-1.0" is deleted, "libfoo-SO-1.0"
> appears, containing only the shared libraries formerly held by
> "libfoo-1.0", while carrying over all the dependencies formerly
> held by "libfoo-1.0". Despite it's dubious origin, this "libfoo-SO-1.0",
> looks just like a regular package to the package tools: the dependents
> reported by "pkg_info -R" are accurate, "pkg_info" over such
> dependents accurately reports their dependence on "libfoo-SO-1.0",
> and "pkg_info -L" lists the (few) files it contains.

I like the idea, though I have a comment. Currently, to upgrade a package
(lets say a library) I do:

pkg_delete -f mylib
cd /usr/pkgsrc/devel/mylib
make && make install

This works almost always, as packages can work with a slightly new version
of the library. I think that -so-* packages should only be done if some
package requires that version *explicetly*. That is, we usually tell pkgsrc
dependancies with something linke: mylib>=3D3.24, that is, equal or over 3.=
24.
So if we update the library to 3.25, there should be no need to keep 3.24
if packages depend on 3.24 or over.

This can be acomplished with freebsd's portupgrade technique... and this is
the only problem I'm having now. As deinstalling a package, forcing it, you
loose dependancy information. When updating a package of this kind, the old
dependancy list should be kept and "copied" in the new package information,
under /var.

I don't know if I have explained it properly...

Although I like it, and I hope this to be available "soon" ;)

--=20
Of course it runs NetBSD - http://www.netbsd.org
HispaBSD member - http://www.hispabsd.org
Julio Merino <jmmv@hispabsd.org>

--7ZAtKRhVyVSsbBD2
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (NetBSD)
Comment: For info see http://www.gnupg.org

iD8DBQE85LmSzz00ZOPKycwRAnYMAJwL4Gkqd0gCr7bczfMFucdGYCj93wCfaVkM
vMrtDKJX7UviGjKfm/gH9Y8=
=mmI4
-----END PGP SIGNATURE-----

--7ZAtKRhVyVSsbBD2--