[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: patch or "sparse package" support under dpkg



On Tue, May 21, 2002 at 01:39:52AM -0700, Aleksey Tsalolikhin wrote:
> On Thu, May 16, 2002 at 04:21:50PM +0100, Colin Watson wrote:
> > I think you're looking for dpkg-divert(8).
> 
> Dear Colin,
> 
>   Thanks for your reply.  Looks like dpkg-divert is a way to
> "put a write-protect tab" on a particular file, as far as new
> package installs are concerned...

Well, to some extent. But there's no reason you can't install another
file in its place once it's diverted.

>   What I'm trying to do is update certain files in a dpkg.

(Minor terminology nit: dpkg is the package manager, not a name for the
packages themselves. For that, we use "package", "binary package" (as
distinct from "source package"), or just "deb".)

> Let's say I have a letters-1.0.deb.
> It installs:
> 
> /etc/a   3 bytes in size
> /etc/b   3 bytes
> /etc/c   3 bytes
> 
> Now I want to patch it.

If they're literally in /etc, then just change them. It's a serious bug
for packages to overwrite changes to configuration files without asking,
and files in /etc are configuration files.

> I'd like to install letters-1.0p1.deb which will install an update to
> /etc/c, which will result in
> 
> /etc/a   3 bytes in size
> /etc/b   3 bytes
> /etc/c   300 bytes
> 
> But all three files would still be part of the "letters" dpkg.
> When letters-2.0.deb is installed, "a", "b" and "c" would be
> replaced by the new files.

So you mean that you don't want your changes to be preserved on upgrade?
In that case, you could always just rebuild the letters package from
source with the changes ...

Otherwise, dpkg-divert is probably still your best bet.

-- 
Colin Watson                                  [cjwatson@flatline.org.uk]


-- 
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



Reply to: