Subject: Re: Package update disaster
To: Anand Buddhdev <email@example.com>
From: Courtney R. Spencer <firstname.lastname@example.org>
Date: 10/06/2004 17:16:37
On Wed Oct 06, 2004 at 04:24:34PM -0400, Steven M. Bellovin wrote:
> In message <41644E92.email@example.com>, Anand Buddhdev writes:
> >And anyway, why does "make update" FIRST remove the old package? Would
> >it not make sense to first build the new package(s), and if all the
> >builds succeed, then to proceed with deleting the old packages and
> >replacing them with new ones? That makes for a very small package
> >unavailability window.
> It's a serious problem; I don't see a great way around it. "Compile
> first" works for leaf nodes; it doesn't work when there are library
> dependencies involved.
I've been bitten by this many times, and have not found an easy
solution. If you have the diskspace to be able to have all of
your packages installed twice and built once, then try the strategy in
section 5.3.6 at http://www.netbsd.org/Documentation/pkgsrc/binary.html
Follow the instructions down to #11 and forego the bulk-build parts.
After you have a working chroot, you can use this sandbox to keep
pkgsrc updated and create binary packages with 'make package'. Then,
if your chosen packages build OK, you can update your system packages
with 'pkg_add -u'. Be careful and install everything that was created
for the chosen package, because you _want_ to update libraries and
any packages that depend on them.
You could probably use the output from lintpkgsrc and make this
do most of what you want.
163 packages built in the sandbox and I have been very satisfied.
Courtney R. Spencer