[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 10:03:40AM +0100, Colin Watson wrote:
> On Tue, May 21, 2002 at 01:39:52AM -0700, Aleksey Tsalolikhin wrote:
> > 
> >   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.

Manually, right?  But I want to do it with dpkg. :)  

I want to be able to install letters-1.0p1.deb (to change just one file)
and then later letters-2.0.deb (replace all the files).

The reason I want to do it with dpkg is so I can track what version
of the application is installed, 1.0 versus 1.0p1, by listing the
installed deb's.

> > 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.

Just example.  They are really in /a/really/long/path. :-)  Not /etc.

> > 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?

Exactly!  I want "c" to be overwritten by the "c" from the next "letters"
deb that's installed.

> In that case, you could always just rebuild the letters package from
> source with the changes ...

*nod*  What my example omits is the deb actually contains thousands of
files.  Rebuilding it and installing it just to change tens of files
is inconvenient, which is why I'm looking into patch packages.

I am trying to find out if it's possible to build a patch dpkg to do
incremental upgrade.  (ie to upgrade just one or two files, not all files).

I still want to be able to do a full upgrade afterwards, clobbering
the incremental upgrade. 

So far I don't see how I could accomplish that with dpkg-divert.
If I'm missing something, I would love an example.

Best regards,
Aleksey.


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



Reply to: